Skip to content

Instantly share code, notes, and snippets.

@sanuj
Created August 17, 2016 10:39
Show Gist options
  • Save sanuj/2ac8849db2764dcc27f99639e935503e to your computer and use it in GitHub Desktop.
Save sanuj/2ac8849db2764dcc27f99639e935503e to your computer and use it in GitHub Desktop.
This file has been truncated, but you can view the full file.
/* ----------------------------------------------------------------------------
* This file was automatically generated by SWIG (http://www.swig.org).
* Version 3.0.10
*
* This file is not intended to be easily readable and contains a number of
* coding conventions designed to improve portability and efficiency. Do not make
* changes to this file unless you know what you are doing--modify the SWIG
* interface file instead.
* ----------------------------------------------------------------------------- */
#ifndef SWIGRUBY
#define SWIGRUBY
#endif
#ifdef __cplusplus
/* SwigValueWrapper is described in swig.swg */
template<typename T> class SwigValueWrapper {
struct SwigMovePointer {
T *ptr;
SwigMovePointer(T *p) : ptr(p) { }
~SwigMovePointer() { delete ptr; }
SwigMovePointer& operator=(SwigMovePointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; }
} pointer;
SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
SwigValueWrapper(const SwigValueWrapper<T>& rhs);
public:
SwigValueWrapper() : pointer(0) { }
SwigValueWrapper& operator=(const T& t) { SwigMovePointer tmp(new T(t)); pointer = tmp; return *this; }
operator T&() const { return *pointer.ptr; }
T *operator&() { return pointer.ptr; }
};
template <typename T> T SwigValueInit() {
return T();
}
#endif
/* -----------------------------------------------------------------------------
* This section contains generic SWIG labels for method/variable
* declarations/attributes, and other compiler dependent labels.
* ----------------------------------------------------------------------------- */
/* template workaround for compilers that cannot correctly implement the C++ standard */
#ifndef SWIGTEMPLATEDISAMBIGUATOR
# if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
# define SWIGTEMPLATEDISAMBIGUATOR template
# elif defined(__HP_aCC)
/* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
/* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
# define SWIGTEMPLATEDISAMBIGUATOR template
# else
# define SWIGTEMPLATEDISAMBIGUATOR
# endif
#endif
/* inline attribute */
#ifndef SWIGINLINE
# if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
# define SWIGINLINE inline
# else
# define SWIGINLINE
# endif
#endif
/* attribute recognised by some compilers to avoid 'unused' warnings */
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
#endif
#ifndef SWIG_MSC_UNSUPPRESS_4505
# if defined(_MSC_VER)
# pragma warning(disable : 4505) /* unreferenced local function has been removed */
# endif
#endif
#ifndef SWIGUNUSEDPARM
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
/* internal SWIG method */
#ifndef SWIGINTERN
# define SWIGINTERN static SWIGUNUSED
#endif
/* internal inline SWIG method */
#ifndef SWIGINTERNINLINE
# define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
#endif
/* exporting methods */
#if defined(__GNUC__)
# if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
# ifndef GCC_HASCLASSVISIBILITY
# define GCC_HASCLASSVISIBILITY
# endif
# endif
#endif
#ifndef SWIGEXPORT
# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
# if defined(STATIC_LINKED)
# define SWIGEXPORT
# else
# define SWIGEXPORT __declspec(dllexport)
# endif
# else
# if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
# define SWIGEXPORT __attribute__ ((visibility("default")))
# else
# define SWIGEXPORT
# endif
# endif
#endif
/* calling conventions for Windows */
#ifndef SWIGSTDCALL
# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
#if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
# define _CRT_SECURE_NO_DEPRECATE
#endif
/* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
#if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
# define _SCL_SECURE_NO_DEPRECATE
#endif
/* Deal with Apple's deprecated 'AssertMacros.h' from Carbon-framework */
#if defined(__APPLE__) && !defined(__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES)
# define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0
#endif
/* Intel's compiler complains if a variable which was never initialised is
* cast to void, which is a common idiom which we use to indicate that we
* are aware a variable isn't used. So we just silence that warning.
* See: https://github.com/swig/swig/issues/192 for more discussion.
*/
#ifdef __INTEL_COMPILER
# pragma warning disable 592
#endif
/* -----------------------------------------------------------------------------
* This section contains generic SWIG labels for method/variable
* declarations/attributes, and other compiler dependent labels.
* ----------------------------------------------------------------------------- */
/* template workaround for compilers that cannot correctly implement the C++ standard */
#ifndef SWIGTEMPLATEDISAMBIGUATOR
# if defined(__SUNPRO_CC) && (__SUNPRO_CC <= 0x560)
# define SWIGTEMPLATEDISAMBIGUATOR template
# elif defined(__HP_aCC)
/* Needed even with `aCC -AA' when `aCC -V' reports HP ANSI C++ B3910B A.03.55 */
/* If we find a maximum version that requires this, the test would be __HP_aCC <= 35500 for A.03.55 */
# define SWIGTEMPLATEDISAMBIGUATOR template
# else
# define SWIGTEMPLATEDISAMBIGUATOR
# endif
#endif
/* inline attribute */
#ifndef SWIGINLINE
# if defined(__cplusplus) || (defined(__GNUC__) && !defined(__STRICT_ANSI__))
# define SWIGINLINE inline
# else
# define SWIGINLINE
# endif
#endif
/* attribute recognised by some compilers to avoid 'unused' warnings */
#ifndef SWIGUNUSED
# if defined(__GNUC__)
# if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
# elif defined(__ICC)
# define SWIGUNUSED __attribute__ ((__unused__))
# else
# define SWIGUNUSED
# endif
#endif
#ifndef SWIG_MSC_UNSUPPRESS_4505
# if defined(_MSC_VER)
# pragma warning(disable : 4505) /* unreferenced local function has been removed */
# endif
#endif
#ifndef SWIGUNUSEDPARM
# ifdef __cplusplus
# define SWIGUNUSEDPARM(p)
# else
# define SWIGUNUSEDPARM(p) p SWIGUNUSED
# endif
#endif
/* internal SWIG method */
#ifndef SWIGINTERN
# define SWIGINTERN static SWIGUNUSED
#endif
/* internal inline SWIG method */
#ifndef SWIGINTERNINLINE
# define SWIGINTERNINLINE SWIGINTERN SWIGINLINE
#endif
/* exporting methods */
#if defined(__GNUC__)
# if (__GNUC__ >= 4) || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)
# ifndef GCC_HASCLASSVISIBILITY
# define GCC_HASCLASSVISIBILITY
# endif
# endif
#endif
#ifndef SWIGEXPORT
# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
# if defined(STATIC_LINKED)
# define SWIGEXPORT
# else
# define SWIGEXPORT __declspec(dllexport)
# endif
# else
# if defined(__GNUC__) && defined(GCC_HASCLASSVISIBILITY)
# define SWIGEXPORT __attribute__ ((visibility("default")))
# else
# define SWIGEXPORT
# endif
# endif
#endif
/* calling conventions for Windows */
#ifndef SWIGSTDCALL
# if defined(_WIN32) || defined(__WIN32__) || defined(__CYGWIN__)
# define SWIGSTDCALL __stdcall
# else
# define SWIGSTDCALL
# endif
#endif
/* Deal with Microsoft's attempt at deprecating C standard runtime functions */
#if !defined(SWIG_NO_CRT_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_CRT_SECURE_NO_DEPRECATE)
# define _CRT_SECURE_NO_DEPRECATE
#endif
/* Deal with Microsoft's attempt at deprecating methods in the standard C++ library */
#if !defined(SWIG_NO_SCL_SECURE_NO_DEPRECATE) && defined(_MSC_VER) && !defined(_SCL_SECURE_NO_DEPRECATE)
# define _SCL_SECURE_NO_DEPRECATE
#endif
/* Deal with Apple's deprecated 'AssertMacros.h' from Carbon-framework */
#if defined(__APPLE__) && !defined(__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES)
# define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0
#endif
/* Intel's compiler complains if a variable which was never initialised is
* cast to void, which is a common idiom which we use to indicate that we
* are aware a variable isn't used. So we just silence that warning.
* See: https://github.com/swig/swig/issues/192 for more discussion.
*/
#ifdef __INTEL_COMPILER
# pragma warning disable 592
#endif
/* -----------------------------------------------------------------------------
* swigrun.swg
*
* This file contains generic C API SWIG runtime support for pointer
* type checking.
* ----------------------------------------------------------------------------- */
/* This should only be incremented when either the layout of swig_type_info changes,
or for whatever reason, the runtime changes incompatibly */
#define SWIG_RUNTIME_VERSION "4"
/* define SWIG_TYPE_TABLE_NAME as "SWIG_TYPE_TABLE" */
#ifdef SWIG_TYPE_TABLE
# define SWIG_QUOTE_STRING(x) #x
# define SWIG_EXPAND_AND_QUOTE_STRING(x) SWIG_QUOTE_STRING(x)
# define SWIG_TYPE_TABLE_NAME SWIG_EXPAND_AND_QUOTE_STRING(SWIG_TYPE_TABLE)
#else
# define SWIG_TYPE_TABLE_NAME
#endif
/*
You can use the SWIGRUNTIME and SWIGRUNTIMEINLINE macros for
creating a static or dynamic library from the SWIG runtime code.
In 99.9% of the cases, SWIG just needs to declare them as 'static'.
But only do this if strictly necessary, ie, if you have problems
with your compiler or suchlike.
*/
#ifndef SWIGRUNTIME
# define SWIGRUNTIME SWIGINTERN
#endif
#ifndef SWIGRUNTIMEINLINE
# define SWIGRUNTIMEINLINE SWIGRUNTIME SWIGINLINE
#endif
/* Generic buffer size */
#ifndef SWIG_BUFFER_SIZE
# define SWIG_BUFFER_SIZE 1024
#endif
/* Flags for pointer conversions */
#define SWIG_POINTER_DISOWN 0x1
#define SWIG_CAST_NEW_MEMORY 0x2
/* Flags for new pointer objects */
#define SWIG_POINTER_OWN 0x1
/*
Flags/methods for returning states.
The SWIG conversion methods, as ConvertPtr, return an integer
that tells if the conversion was successful or not. And if not,
an error code can be returned (see swigerrors.swg for the codes).
Use the following macros/flags to set or process the returning
states.
In old versions of SWIG, code such as the following was usually written:
if (SWIG_ConvertPtr(obj,vptr,ty.flags) != -1) {
// success code
} else {
//fail code
}
Now you can be more explicit:
int res = SWIG_ConvertPtr(obj,vptr,ty.flags);
if (SWIG_IsOK(res)) {
// success code
} else {
// fail code
}
which is the same really, but now you can also do
Type *ptr;
int res = SWIG_ConvertPtr(obj,(void **)(&ptr),ty.flags);
if (SWIG_IsOK(res)) {
// success code
if (SWIG_IsNewObj(res) {
...
delete *ptr;
} else {
...
}
} else {
// fail code
}
I.e., now SWIG_ConvertPtr can return new objects and you can
identify the case and take care of the deallocation. Of course that
also requires SWIG_ConvertPtr to return new result values, such as
int SWIG_ConvertPtr(obj, ptr,...) {
if (<obj is ok>) {
if (<need new object>) {
*ptr = <ptr to new allocated object>;
return SWIG_NEWOBJ;
} else {
*ptr = <ptr to old object>;
return SWIG_OLDOBJ;
}
} else {
return SWIG_BADOBJ;
}
}
Of course, returning the plain '0(success)/-1(fail)' still works, but you can be
more explicit by returning SWIG_BADOBJ, SWIG_ERROR or any of the
SWIG errors code.
Finally, if the SWIG_CASTRANK_MODE is enabled, the result code
allows to return the 'cast rank', for example, if you have this
int food(double)
int fooi(int);
and you call
food(1) // cast rank '1' (1 -> 1.0)
fooi(1) // cast rank '0'
just use the SWIG_AddCast()/SWIG_CheckState()
*/
#define SWIG_OK (0)
#define SWIG_ERROR (-1)
#define SWIG_IsOK(r) (r >= 0)
#define SWIG_ArgError(r) ((r != SWIG_ERROR) ? r : SWIG_TypeError)
/* The CastRankLimit says how many bits are used for the cast rank */
#define SWIG_CASTRANKLIMIT (1 << 8)
/* The NewMask denotes the object was created (using new/malloc) */
#define SWIG_NEWOBJMASK (SWIG_CASTRANKLIMIT << 1)
/* The TmpMask is for in/out typemaps that use temporal objects */
#define SWIG_TMPOBJMASK (SWIG_NEWOBJMASK << 1)
/* Simple returning values */
#define SWIG_BADOBJ (SWIG_ERROR)
#define SWIG_OLDOBJ (SWIG_OK)
#define SWIG_NEWOBJ (SWIG_OK | SWIG_NEWOBJMASK)
#define SWIG_TMPOBJ (SWIG_OK | SWIG_TMPOBJMASK)
/* Check, add and del mask methods */
#define SWIG_AddNewMask(r) (SWIG_IsOK(r) ? (r | SWIG_NEWOBJMASK) : r)
#define SWIG_DelNewMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_NEWOBJMASK) : r)
#define SWIG_IsNewObj(r) (SWIG_IsOK(r) && (r & SWIG_NEWOBJMASK))
#define SWIG_AddTmpMask(r) (SWIG_IsOK(r) ? (r | SWIG_TMPOBJMASK) : r)
#define SWIG_DelTmpMask(r) (SWIG_IsOK(r) ? (r & ~SWIG_TMPOBJMASK) : r)
#define SWIG_IsTmpObj(r) (SWIG_IsOK(r) && (r & SWIG_TMPOBJMASK))
/* Cast-Rank Mode */
#if defined(SWIG_CASTRANK_MODE)
# ifndef SWIG_TypeRank
# define SWIG_TypeRank unsigned long
# endif
# ifndef SWIG_MAXCASTRANK /* Default cast allowed */
# define SWIG_MAXCASTRANK (2)
# endif
# define SWIG_CASTRANKMASK ((SWIG_CASTRANKLIMIT) -1)
# define SWIG_CastRank(r) (r & SWIG_CASTRANKMASK)
SWIGINTERNINLINE int SWIG_AddCast(int r) {
return SWIG_IsOK(r) ? ((SWIG_CastRank(r) < SWIG_MAXCASTRANK) ? (r + 1) : SWIG_ERROR) : r;
}
SWIGINTERNINLINE int SWIG_CheckState(int r) {
return SWIG_IsOK(r) ? SWIG_CastRank(r) + 1 : 0;
}
#else /* no cast-rank mode */
# define SWIG_AddCast(r) (r)
# define SWIG_CheckState(r) (SWIG_IsOK(r) ? 1 : 0)
#endif
#include <string.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef void *(*swig_converter_func)(void *, int *);
typedef struct swig_type_info *(*swig_dycast_func)(void **);
/* Structure to store information on one type */
typedef struct swig_type_info {
const char *name; /* mangled name of this type */
const char *str; /* human readable name of this type */
swig_dycast_func dcast; /* dynamic cast function down a hierarchy */
struct swig_cast_info *cast; /* linked list of types that can cast into this type */
void *clientdata; /* language specific type data */
int owndata; /* flag if the structure owns the clientdata */
} swig_type_info;
/* Structure to store a type and conversion function used for casting */
typedef struct swig_cast_info {
swig_type_info *type; /* pointer to type that is equivalent to this type */
swig_converter_func converter; /* function to cast the void pointers */
struct swig_cast_info *next; /* pointer to next cast in linked list */
struct swig_cast_info *prev; /* pointer to the previous cast */
} swig_cast_info;
/* Structure used to store module information
* Each module generates one structure like this, and the runtime collects
* all of these structures and stores them in a circularly linked list.*/
typedef struct swig_module_info {
swig_type_info **types; /* Array of pointers to swig_type_info structures that are in this module */
size_t size; /* Number of types in this module */
struct swig_module_info *next; /* Pointer to next element in circularly linked list */
swig_type_info **type_initial; /* Array of initially generated type structures */
swig_cast_info **cast_initial; /* Array of initially generated casting structures */
void *clientdata; /* Language specific module data */
} swig_module_info;
/*
Compare two type names skipping the space characters, therefore
"char*" == "char *" and "Class<int>" == "Class<int >", etc.
Return 0 when the two name types are equivalent, as in
strncmp, but skipping ' '.
*/
SWIGRUNTIME int
SWIG_TypeNameComp(const char *f1, const char *l1,
const char *f2, const char *l2) {
for (;(f1 != l1) && (f2 != l2); ++f1, ++f2) {
while ((*f1 == ' ') && (f1 != l1)) ++f1;
while ((*f2 == ' ') && (f2 != l2)) ++f2;
if (*f1 != *f2) return (*f1 > *f2) ? 1 : -1;
}
return (int)((l1 - f1) - (l2 - f2));
}
/*
Check type equivalence in a name list like <name1>|<name2>|...
Return 0 if equal, -1 if nb < tb, 1 if nb > tb
*/
SWIGRUNTIME int
SWIG_TypeCmp(const char *nb, const char *tb) {
int equiv = 1;
const char* te = tb + strlen(tb);
const char* ne = nb;
while (equiv != 0 && *ne) {
for (nb = ne; *ne; ++ne) {
if (*ne == '|') break;
}
equiv = SWIG_TypeNameComp(nb, ne, tb, te);
if (*ne) ++ne;
}
return equiv;
}
/*
Check type equivalence in a name list like <name1>|<name2>|...
Return 0 if not equal, 1 if equal
*/
SWIGRUNTIME int
SWIG_TypeEquiv(const char *nb, const char *tb) {
return SWIG_TypeCmp(nb, tb) == 0 ? 1 : 0;
}
/*
Check the typename
*/
SWIGRUNTIME swig_cast_info *
SWIG_TypeCheck(const char *c, swig_type_info *ty) {
if (ty) {
swig_cast_info *iter = ty->cast;
while (iter) {
if (strcmp(iter->type->name, c) == 0) {
if (iter == ty->cast)
return iter;
/* Move iter to the top of the linked list */
iter->prev->next = iter->next;
if (iter->next)
iter->next->prev = iter->prev;
iter->next = ty->cast;
iter->prev = 0;
if (ty->cast) ty->cast->prev = iter;
ty->cast = iter;
return iter;
}
iter = iter->next;
}
}
return 0;
}
/*
Identical to SWIG_TypeCheck, except strcmp is replaced with a pointer comparison
*/
SWIGRUNTIME swig_cast_info *
SWIG_TypeCheckStruct(swig_type_info *from, swig_type_info *ty) {
if (ty) {
swig_cast_info *iter = ty->cast;
while (iter) {
if (iter->type == from) {
if (iter == ty->cast)
return iter;
/* Move iter to the top of the linked list */
iter->prev->next = iter->next;
if (iter->next)
iter->next->prev = iter->prev;
iter->next = ty->cast;
iter->prev = 0;
if (ty->cast) ty->cast->prev = iter;
ty->cast = iter;
return iter;
}
iter = iter->next;
}
}
return 0;
}
/*
Cast a pointer up an inheritance hierarchy
*/
SWIGRUNTIMEINLINE void *
SWIG_TypeCast(swig_cast_info *ty, void *ptr, int *newmemory) {
return ((!ty) || (!ty->converter)) ? ptr : (*ty->converter)(ptr, newmemory);
}
/*
Dynamic pointer casting. Down an inheritance hierarchy
*/
SWIGRUNTIME swig_type_info *
SWIG_TypeDynamicCast(swig_type_info *ty, void **ptr) {
swig_type_info *lastty = ty;
if (!ty || !ty->dcast) return ty;
while (ty && (ty->dcast)) {
ty = (*ty->dcast)(ptr);
if (ty) lastty = ty;
}
return lastty;
}
/*
Return the name associated with this type
*/
SWIGRUNTIMEINLINE const char *
SWIG_TypeName(const swig_type_info *ty) {
return ty->name;
}
/*
Return the pretty name associated with this type,
that is an unmangled type name in a form presentable to the user.
*/
SWIGRUNTIME const char *
SWIG_TypePrettyName(const swig_type_info *type) {
/* The "str" field contains the equivalent pretty names of the
type, separated by vertical-bar characters. We choose
to print the last name, as it is often (?) the most
specific. */
if (!type) return NULL;
if (type->str != NULL) {
const char *last_name = type->str;
const char *s;
for (s = type->str; *s; s++)
if (*s == '|') last_name = s+1;
return last_name;
}
else
return type->name;
}
/*
Set the clientdata field for a type
*/
SWIGRUNTIME void
SWIG_TypeClientData(swig_type_info *ti, void *clientdata) {
swig_cast_info *cast = ti->cast;
/* if (ti->clientdata == clientdata) return; */
ti->clientdata = clientdata;
while (cast) {
if (!cast->converter) {
swig_type_info *tc = cast->type;
if (!tc->clientdata) {
SWIG_TypeClientData(tc, clientdata);
}
}
cast = cast->next;
}
}
SWIGRUNTIME void
SWIG_TypeNewClientData(swig_type_info *ti, void *clientdata) {
SWIG_TypeClientData(ti, clientdata);
ti->owndata = 1;
}
/*
Search for a swig_type_info structure only by mangled name
Search is a O(log #types)
We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
SWIG_MangledTypeQueryModule(swig_module_info *start,
swig_module_info *end,
const char *name) {
swig_module_info *iter = start;
do {
if (iter->size) {
size_t l = 0;
size_t r = iter->size - 1;
do {
/* since l+r >= 0, we can (>> 1) instead (/ 2) */
size_t i = (l + r) >> 1;
const char *iname = iter->types[i]->name;
if (iname) {
int compare = strcmp(name, iname);
if (compare == 0) {
return iter->types[i];
} else if (compare < 0) {
if (i) {
r = i - 1;
} else {
break;
}
} else if (compare > 0) {
l = i + 1;
}
} else {
break; /* should never happen */
}
} while (l <= r);
}
iter = iter->next;
} while (iter != end);
return 0;
}
/*
Search for a swig_type_info structure for either a mangled name or a human readable name.
It first searches the mangled names of the types, which is a O(log #types)
If a type is not found it then searches the human readable names, which is O(#types).
We start searching at module start, and finish searching when start == end.
Note: if start == end at the beginning of the function, we go all the way around
the circular list.
*/
SWIGRUNTIME swig_type_info *
SWIG_TypeQueryModule(swig_module_info *start,
swig_module_info *end,
const char *name) {
/* STEP 1: Search the name field using binary search */
swig_type_info *ret = SWIG_MangledTypeQueryModule(start, end, name);
if (ret) {
return ret;
} else {
/* STEP 2: If the type hasn't been found, do a complete search
of the str field (the human readable name) */
swig_module_info *iter = start;
do {
size_t i = 0;
for (; i < iter->size; ++i) {
if (iter->types[i]->str && (SWIG_TypeEquiv(iter->types[i]->str, name)))
return iter->types[i];
}
iter = iter->next;
} while (iter != end);
}
/* neither found a match */
return 0;
}
/*
Pack binary data into a string
*/
SWIGRUNTIME char *
SWIG_PackData(char *c, void *ptr, size_t sz) {
static const char hex[17] = "0123456789abcdef";
const unsigned char *u = (unsigned char *) ptr;
const unsigned char *eu = u + sz;
for (; u != eu; ++u) {
unsigned char uu = *u;
*(c++) = hex[(uu & 0xf0) >> 4];
*(c++) = hex[uu & 0xf];
}
return c;
}
/*
Unpack binary data from a string
*/
SWIGRUNTIME const char *
SWIG_UnpackData(const char *c, void *ptr, size_t sz) {
unsigned char *u = (unsigned char *) ptr;
const unsigned char *eu = u + sz;
for (; u != eu; ++u) {
char d = *(c++);
unsigned char uu;
if ((d >= '0') && (d <= '9'))
uu = (unsigned char)((d - '0') << 4);
else if ((d >= 'a') && (d <= 'f'))
uu = (unsigned char)((d - ('a'-10)) << 4);
else
return (char *) 0;
d = *(c++);
if ((d >= '0') && (d <= '9'))
uu |= (unsigned char)(d - '0');
else if ((d >= 'a') && (d <= 'f'))
uu |= (unsigned char)(d - ('a'-10));
else
return (char *) 0;
*u = uu;
}
return c;
}
/*
Pack 'void *' into a string buffer.
*/
SWIGRUNTIME char *
SWIG_PackVoidPtr(char *buff, void *ptr, const char *name, size_t bsz) {
char *r = buff;
if ((2*sizeof(void *) + 2) > bsz) return 0;
*(r++) = '_';
r = SWIG_PackData(r,&ptr,sizeof(void *));
if (strlen(name) + 1 > (bsz - (r - buff))) return 0;
strcpy(r,name);
return buff;
}
SWIGRUNTIME const char *
SWIG_UnpackVoidPtr(const char *c, void **ptr, const char *name) {
if (*c != '_') {
if (strcmp(c,"NULL") == 0) {
*ptr = (void *) 0;
return name;
} else {
return 0;
}
}
return SWIG_UnpackData(++c,ptr,sizeof(void *));
}
SWIGRUNTIME char *
SWIG_PackDataName(char *buff, void *ptr, size_t sz, const char *name, size_t bsz) {
char *r = buff;
size_t lname = (name ? strlen(name) : 0);
if ((2*sz + 2 + lname) > bsz) return 0;
*(r++) = '_';
r = SWIG_PackData(r,ptr,sz);
if (lname) {
strncpy(r,name,lname+1);
} else {
*r = 0;
}
return buff;
}
SWIGRUNTIME const char *
SWIG_UnpackDataName(const char *c, void *ptr, size_t sz, const char *name) {
if (*c != '_') {
if (strcmp(c,"NULL") == 0) {
memset(ptr,0,sz);
return name;
} else {
return 0;
}
}
return SWIG_UnpackData(++c,ptr,sz);
}
#ifdef __cplusplus
}
#endif
/* Errors in SWIG */
#define SWIG_UnknownError -1
#define SWIG_IOError -2
#define SWIG_RuntimeError -3
#define SWIG_IndexError -4
#define SWIG_TypeError -5
#define SWIG_DivisionByZero -6
#define SWIG_OverflowError -7
#define SWIG_SyntaxError -8
#define SWIG_ValueError -9
#define SWIG_SystemError -10
#define SWIG_AttributeError -11
#define SWIG_MemoryError -12
#define SWIG_NullReferenceError -13
#include <ruby.h>
/* Ruby 1.9.1 has a "memoisation optimisation" when compiling with GCC which
* breaks using rb_intern as an lvalue, as SWIG does. We work around this
* issue for now by disabling this.
* https://sourceforge.net/tracker/?func=detail&aid=2859614&group_id=1645&atid=101645
*/
#ifdef rb_intern
# undef rb_intern
#endif
/* Remove global macros defined in Ruby's win32.h */
#ifdef write
# undef write
#endif
#ifdef read
# undef read
#endif
#ifdef bind
# undef bind
#endif
#ifdef close
# undef close
#endif
#ifdef connect
# undef connect
#endif
/* Ruby 1.7 defines NUM2LL(), LL2NUM() and ULL2NUM() macros */
#ifndef NUM2LL
#define NUM2LL(x) NUM2LONG((x))
#endif
#ifndef LL2NUM
#define LL2NUM(x) INT2NUM((long) (x))
#endif
#ifndef ULL2NUM
#define ULL2NUM(x) UINT2NUM((unsigned long) (x))
#endif
/* Ruby 1.7 doesn't (yet) define NUM2ULL() */
#ifndef NUM2ULL
#ifdef HAVE_LONG_LONG
#define NUM2ULL(x) rb_num2ull((x))
#else
#define NUM2ULL(x) NUM2ULONG(x)
#endif
#endif
/* RSTRING_LEN, etc are new in Ruby 1.9, but ->ptr and ->len no longer work */
/* Define these for older versions so we can just write code the new way */
#ifndef RSTRING_LEN
# define RSTRING_LEN(x) RSTRING(x)->len
#endif
#ifndef RSTRING_PTR
# define RSTRING_PTR(x) RSTRING(x)->ptr
#endif
#ifndef RSTRING_END
# define RSTRING_END(x) (RSTRING_PTR(x) + RSTRING_LEN(x))
#endif
#ifndef RARRAY_LEN
# define RARRAY_LEN(x) RARRAY(x)->len
#endif
#ifndef RARRAY_PTR
# define RARRAY_PTR(x) RARRAY(x)->ptr
#endif
#ifndef RFLOAT_VALUE
# define RFLOAT_VALUE(x) RFLOAT(x)->value
#endif
#ifndef DOUBLE2NUM
# define DOUBLE2NUM(x) rb_float_new(x)
#endif
#ifndef RHASH_TBL
# define RHASH_TBL(x) (RHASH(x)->tbl)
#endif
#ifndef RHASH_ITER_LEV
# define RHASH_ITER_LEV(x) (RHASH(x)->iter_lev)
#endif
#ifndef RHASH_IFNONE
# define RHASH_IFNONE(x) (RHASH(x)->ifnone)
#endif
#ifndef RHASH_SIZE
# define RHASH_SIZE(x) (RHASH(x)->tbl->num_entries)
#endif
#ifndef RHASH_EMPTY_P
# define RHASH_EMPTY_P(x) (RHASH_SIZE(x) == 0)
#endif
#ifndef RSTRUCT_LEN
# define RSTRUCT_LEN(x) RSTRUCT(x)->len
#endif
#ifndef RSTRUCT_PTR
# define RSTRUCT_PTR(x) RSTRUCT(x)->ptr
#endif
/*
* Need to be very careful about how these macros are defined, especially
* when compiling C++ code or C code with an ANSI C compiler.
*
* VALUEFUNC(f) is a macro used to typecast a C function that implements
* a Ruby method so that it can be passed as an argument to API functions
* like rb_define_method() and rb_define_singleton_method().
*
* VOIDFUNC(f) is a macro used to typecast a C function that implements
* either the "mark" or "free" stuff for a Ruby Data object, so that it
* can be passed as an argument to API functions like Data_Wrap_Struct()
* and Data_Make_Struct().
*/
#ifdef __cplusplus
# ifndef RUBY_METHOD_FUNC /* These definitions should work for Ruby 1.4.6 */
# define PROTECTFUNC(f) ((VALUE (*)()) f)
# define VALUEFUNC(f) ((VALUE (*)()) f)
# define VOIDFUNC(f) ((void (*)()) f)
# else
# ifndef ANYARGS /* These definitions should work for Ruby 1.6 */
# define PROTECTFUNC(f) ((VALUE (*)()) f)
# define VALUEFUNC(f) ((VALUE (*)()) f)
# define VOIDFUNC(f) ((RUBY_DATA_FUNC) f)
# else /* These definitions should work for Ruby 1.7+ */
# define PROTECTFUNC(f) ((VALUE (*)(VALUE)) f)
# define VALUEFUNC(f) ((VALUE (*)(ANYARGS)) f)
# define VOIDFUNC(f) ((RUBY_DATA_FUNC) f)
# endif
# endif
#else
# define VALUEFUNC(f) (f)
# define VOIDFUNC(f) (f)
#endif
/* Don't use for expressions have side effect */
#ifndef RB_STRING_VALUE
#define RB_STRING_VALUE(s) (TYPE(s) == T_STRING ? (s) : (*(volatile VALUE *)&(s) = rb_str_to_str(s)))
#endif
#ifndef StringValue
#define StringValue(s) RB_STRING_VALUE(s)
#endif
#ifndef StringValuePtr
#define StringValuePtr(s) RSTRING_PTR(RB_STRING_VALUE(s))
#endif
#ifndef StringValueLen
#define StringValueLen(s) RSTRING_LEN(RB_STRING_VALUE(s))
#endif
#ifndef SafeStringValue
#define SafeStringValue(v) do {\
StringValue(v);\
rb_check_safe_str(v);\
} while (0)
#endif
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
#define rb_define_alloc_func(klass, func) rb_define_singleton_method((klass), "new", VALUEFUNC((func)), -1)
#define rb_undef_alloc_func(klass) rb_undef_method(CLASS_OF((klass)), "new")
#endif
static VALUE _mSWIG = Qnil;
/* -----------------------------------------------------------------------------
* error manipulation
* ----------------------------------------------------------------------------- */
/* Define some additional error types */
#define SWIG_ObjectPreviouslyDeletedError -100
/* Define custom exceptions for errors that do not map to existing Ruby
exceptions. Note this only works for C++ since a global cannot be
initialized by a function in C. For C, fallback to rb_eRuntimeError.*/
SWIGINTERN VALUE
getNullReferenceError(void) {
static int init = 0;
static VALUE rb_eNullReferenceError ;
if (!init) {
init = 1;
rb_eNullReferenceError = rb_define_class("NullReferenceError", rb_eRuntimeError);
}
return rb_eNullReferenceError;
}
SWIGINTERN VALUE
getObjectPreviouslyDeletedError(void) {
static int init = 0;
static VALUE rb_eObjectPreviouslyDeleted ;
if (!init) {
init = 1;
rb_eObjectPreviouslyDeleted = rb_define_class("ObjectPreviouslyDeleted", rb_eRuntimeError);
}
return rb_eObjectPreviouslyDeleted;
}
SWIGINTERN VALUE
SWIG_Ruby_ErrorType(int SWIG_code) {
VALUE type;
switch (SWIG_code) {
case SWIG_MemoryError:
type = rb_eNoMemError;
break;
case SWIG_IOError:
type = rb_eIOError;
break;
case SWIG_RuntimeError:
type = rb_eRuntimeError;
break;
case SWIG_IndexError:
type = rb_eIndexError;
break;
case SWIG_TypeError:
type = rb_eTypeError;
break;
case SWIG_DivisionByZero:
type = rb_eZeroDivError;
break;
case SWIG_OverflowError:
type = rb_eRangeError;
break;
case SWIG_SyntaxError:
type = rb_eSyntaxError;
break;
case SWIG_ValueError:
type = rb_eArgError;
break;
case SWIG_SystemError:
type = rb_eFatal;
break;
case SWIG_AttributeError:
type = rb_eRuntimeError;
break;
case SWIG_NullReferenceError:
type = getNullReferenceError();
break;
case SWIG_ObjectPreviouslyDeletedError:
type = getObjectPreviouslyDeletedError();
break;
case SWIG_UnknownError:
type = rb_eRuntimeError;
break;
default:
type = rb_eRuntimeError;
}
return type;
}
/* This function is called when a user inputs a wrong argument to
a method.
*/
SWIGINTERN
const char* Ruby_Format_TypeError( const char* msg,
const char* type,
const char* name,
const int argn,
VALUE input )
{
char buf[128];
VALUE str;
VALUE asStr;
if ( msg && *msg )
{
str = rb_str_new2(msg);
}
else
{
str = rb_str_new(NULL, 0);
}
str = rb_str_cat2( str, "Expected argument " );
sprintf( buf, "%d of type ", argn-1 );
str = rb_str_cat2( str, buf );
str = rb_str_cat2( str, type );
str = rb_str_cat2( str, ", but got " );
str = rb_str_cat2( str, rb_obj_classname(input) );
str = rb_str_cat2( str, " " );
asStr = rb_inspect(input);
if ( RSTRING_LEN(asStr) > 30 )
{
str = rb_str_cat( str, StringValuePtr(asStr), 30 );
str = rb_str_cat2( str, "..." );
}
else
{
str = rb_str_append( str, asStr );
}
if ( name )
{
str = rb_str_cat2( str, "\n\tin SWIG method '" );
str = rb_str_cat2( str, name );
str = rb_str_cat2( str, "'" );
}
return StringValuePtr( str );
}
/* This function is called when an overloaded method fails */
SWIGINTERN
void Ruby_Format_OverloadedError(
const int argc,
const int maxargs,
const char* method,
const char* prototypes
)
{
const char* msg = "Wrong # of arguments";
if ( argc <= maxargs ) msg = "Wrong arguments";
rb_raise(rb_eArgError,"%s for overloaded method '%s'.\n"
"Possible C/C++ prototypes are:\n%s",
msg, method, prototypes);
}
/* -----------------------------------------------------------------------------
* rubytracking.swg
*
* This file contains support for tracking mappings from
* Ruby objects to C++ objects. This functionality is needed
* to implement mark functions for Ruby's mark and sweep
* garbage collector.
* ----------------------------------------------------------------------------- */
#ifdef __cplusplus
extern "C" {
#endif
#if !defined(ST_DATA_T_DEFINED)
/* Needs to be explicitly included for Ruby 1.8 and earlier */
#include <st.h>
#endif
/* Ruby 1.8 actually assumes the first case. */
#if SIZEOF_VOIDP == SIZEOF_LONG
# define SWIG2NUM(v) LONG2NUM((unsigned long)v)
# define NUM2SWIG(x) (unsigned long)NUM2LONG(x)
#elif SIZEOF_VOIDP == SIZEOF_LONG_LONG
# define SWIG2NUM(v) LL2NUM((unsigned long long)v)
# define NUM2SWIG(x) (unsigned long long)NUM2LL(x)
#else
# error sizeof(void*) is not the same as long or long long
#endif
/* Global hash table to store Trackings from C/C++
structs to Ruby Objects.
*/
static st_table* swig_ruby_trackings = NULL;
static VALUE swig_ruby_trackings_count(ANYARGS) {
return SWIG2NUM(swig_ruby_trackings->num_entries);
}
/* Setup a hash table to store Trackings */
SWIGRUNTIME void SWIG_RubyInitializeTrackings(void) {
/* Create a hash table to store Trackings from C++
objects to Ruby objects. */
/* Try to see if some other .so has already created a
tracking hash table, which we keep hidden in an instance var
in the SWIG module.
This is done to allow multiple DSOs to share the same
tracking table.
*/
VALUE trackings_value = Qnil;
/* change the variable name so that we can mix modules
compiled with older SWIG's - this used to be called "@__trackings__" */
ID trackings_id = rb_intern( "@__safetrackings__" );
VALUE verbose = rb_gv_get("VERBOSE");
rb_gv_set("VERBOSE", Qfalse);
trackings_value = rb_ivar_get( _mSWIG, trackings_id );
rb_gv_set("VERBOSE", verbose);
/* The trick here is that we have to store the hash table
pointer in a Ruby variable. We do not want Ruby's GC to
treat this pointer as a Ruby object, so we convert it to
a Ruby numeric value. */
if (trackings_value == Qnil) {
/* No, it hasn't. Create one ourselves */
swig_ruby_trackings = st_init_numtable();
rb_ivar_set( _mSWIG, trackings_id, SWIG2NUM(swig_ruby_trackings) );
} else {
swig_ruby_trackings = (st_table*)NUM2SWIG(trackings_value);
}
rb_define_virtual_variable("SWIG_TRACKINGS_COUNT", swig_ruby_trackings_count, NULL);
}
/* Add a Tracking from a C/C++ struct to a Ruby object */
SWIGRUNTIME void SWIG_RubyAddTracking(void* ptr, VALUE object) {
/* Store the mapping to the global hash table. */
st_insert(swig_ruby_trackings, (st_data_t)ptr, object);
}
/* Get the Ruby object that owns the specified C/C++ struct */
SWIGRUNTIME VALUE SWIG_RubyInstanceFor(void* ptr) {
/* Now lookup the value stored in the global hash table */
VALUE value;
if (st_lookup(swig_ruby_trackings, (st_data_t)ptr, &value)) {
return value;
} else {
return Qnil;
}
}
/* Remove a Tracking from a C/C++ struct to a Ruby object. It
is very important to remove objects once they are destroyed
since the same memory address may be reused later to create
a new object. */
SWIGRUNTIME void SWIG_RubyRemoveTracking(void* ptr) {
/* Delete the object from the hash table */
st_delete(swig_ruby_trackings, (st_data_t *)&ptr, NULL);
}
/* This is a helper method that unlinks a Ruby object from its
underlying C++ object. This is needed if the lifetime of the
Ruby object is longer than the C++ object */
SWIGRUNTIME void SWIG_RubyUnlinkObjects(void* ptr) {
VALUE object = SWIG_RubyInstanceFor(ptr);
if (object != Qnil) {
if (TYPE(object) != T_DATA)
abort();
DATA_PTR(object) = 0;
}
}
/* This is a helper method that iterates over all the trackings
passing the C++ object pointer and its related Ruby object
to the passed callback function. */
/* Proxy method to abstract the internal trackings datatype */
static int swig_ruby_internal_iterate_callback(void* ptr, VALUE obj, void(*meth)(void* ptr, VALUE obj)) {
(*meth)(ptr, obj);
return ST_CONTINUE;
}
SWIGRUNTIME void SWIG_RubyIterateTrackings( void(*meth)(void* ptr, VALUE obj) ) {
st_foreach(swig_ruby_trackings, (int (*)(ANYARGS))&swig_ruby_internal_iterate_callback, (st_data_t)meth);
}
#ifdef __cplusplus
}
#endif
/* -----------------------------------------------------------------------------
* Ruby API portion that goes into the runtime
* ----------------------------------------------------------------------------- */
#ifdef __cplusplus
extern "C" {
#endif
SWIGINTERN VALUE
SWIG_Ruby_AppendOutput(VALUE target, VALUE o) {
if (NIL_P(target)) {
target = o;
} else {
if (TYPE(target) != T_ARRAY) {
VALUE o2 = target;
target = rb_ary_new();
rb_ary_push(target, o2);
}
rb_ary_push(target, o);
}
return target;
}
/* For ruby1.8.4 and earlier. */
#ifndef RUBY_INIT_STACK
RUBY_EXTERN void Init_stack(VALUE* addr);
# define RUBY_INIT_STACK \
VALUE variable_in_this_stack_frame; \
Init_stack(&variable_in_this_stack_frame);
#endif
#ifdef __cplusplus
}
#endif
/* -----------------------------------------------------------------------------
* rubyrun.swg
*
* This file contains the runtime support for Ruby modules
* and includes code for managing global variables and pointer
* type checking.
* ----------------------------------------------------------------------------- */
/* For backward compatibility only */
#define SWIG_POINTER_EXCEPTION 0
/* for raw pointers */
#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Ruby_ConvertPtrAndOwn(obj, pptr, type, flags, 0)
#define SWIG_ConvertPtrAndOwn(obj,pptr,type,flags,own) SWIG_Ruby_ConvertPtrAndOwn(obj, pptr, type, flags, own)
#define SWIG_NewPointerObj(ptr, type, flags) SWIG_Ruby_NewPointerObj(ptr, type, flags)
#define SWIG_AcquirePtr(ptr, own) SWIG_Ruby_AcquirePtr(ptr, own)
#define swig_owntype swig_ruby_owntype
/* for raw packed data */
#define SWIG_ConvertPacked(obj, ptr, sz, ty) SWIG_Ruby_ConvertPacked(obj, ptr, sz, ty, flags)
#define SWIG_NewPackedObj(ptr, sz, type) SWIG_Ruby_NewPackedObj(ptr, sz, type)
/* for class or struct pointers */
#define SWIG_ConvertInstance(obj, pptr, type, flags) SWIG_ConvertPtr(obj, pptr, type, flags)
#define SWIG_NewInstanceObj(ptr, type, flags) SWIG_NewPointerObj(ptr, type, flags)
/* for C or C++ function pointers */
#define SWIG_ConvertFunctionPtr(obj, pptr, type) SWIG_ConvertPtr(obj, pptr, type, 0)
#define SWIG_NewFunctionPtrObj(ptr, type) SWIG_NewPointerObj(ptr, type, 0)
/* for C++ member pointers, ie, member methods */
#define SWIG_ConvertMember(obj, ptr, sz, ty) SWIG_Ruby_ConvertPacked(obj, ptr, sz, ty)
#define SWIG_NewMemberObj(ptr, sz, type) SWIG_Ruby_NewPackedObj(ptr, sz, type)
/* Runtime API */
#define SWIG_GetModule(clientdata) SWIG_Ruby_GetModule(clientdata)
#define SWIG_SetModule(clientdata, pointer) SWIG_Ruby_SetModule(pointer)
/* Error manipulation */
#define SWIG_ErrorType(code) SWIG_Ruby_ErrorType(code)
#define SWIG_Error(code, msg) rb_raise(SWIG_Ruby_ErrorType(code), "%s", msg)
#define SWIG_fail goto fail
/* Ruby-specific SWIG API */
#define SWIG_InitRuntime() SWIG_Ruby_InitRuntime()
#define SWIG_define_class(ty) SWIG_Ruby_define_class(ty)
#define SWIG_NewClassInstance(value, ty) SWIG_Ruby_NewClassInstance(value, ty)
#define SWIG_MangleStr(value) SWIG_Ruby_MangleStr(value)
#define SWIG_CheckConvert(value, ty) SWIG_Ruby_CheckConvert(value, ty)
#include "assert.h"
/* -----------------------------------------------------------------------------
* pointers/data manipulation
* ----------------------------------------------------------------------------- */
#ifdef __cplusplus
extern "C" {
#endif
typedef struct {
VALUE klass;
VALUE mImpl;
void (*mark)(void *);
void (*destroy)(void *);
int trackObjects;
} swig_class;
/* Global pointer used to keep some internal SWIG stuff */
static VALUE _cSWIG_Pointer = Qnil;
static VALUE swig_runtime_data_type_pointer = Qnil;
/* Global IDs used to keep some internal SWIG stuff */
static ID swig_arity_id = 0;
static ID swig_call_id = 0;
/*
If your swig extension is to be run within an embedded ruby and has
director callbacks, you should set -DRUBY_EMBEDDED during compilation.
This will reset ruby's stack frame on each entry point from the main
program the first time a virtual director function is invoked (in a
non-recursive way).
If this is not done, you run the risk of Ruby trashing the stack.
*/
#ifdef RUBY_EMBEDDED
# define SWIG_INIT_STACK \
if ( !swig_virtual_calls ) { RUBY_INIT_STACK } \
++swig_virtual_calls;
# define SWIG_RELEASE_STACK --swig_virtual_calls;
# define Ruby_DirectorTypeMismatchException(x) \
rb_raise( rb_eTypeError, "%s", x ); return c_result;
static unsigned int swig_virtual_calls = 0;
#else /* normal non-embedded extension */
# define SWIG_INIT_STACK
# define SWIG_RELEASE_STACK
# define Ruby_DirectorTypeMismatchException(x) \
throw Swig::DirectorTypeMismatchException( x );
#endif /* RUBY_EMBEDDED */
SWIGRUNTIME VALUE
getExceptionClass(void) {
static int init = 0;
static VALUE rubyExceptionClass ;
if (!init) {
init = 1;
rubyExceptionClass = rb_const_get(_mSWIG, rb_intern("Exception"));
}
return rubyExceptionClass;
}
/* This code checks to see if the Ruby object being raised as part
of an exception inherits from the Ruby class Exception. If so,
the object is simply returned. If not, then a new Ruby exception
object is created and that will be returned to Ruby.*/
SWIGRUNTIME VALUE
SWIG_Ruby_ExceptionType(swig_type_info *desc, VALUE obj) {
VALUE exceptionClass = getExceptionClass();
if (rb_obj_is_kind_of(obj, exceptionClass)) {
return obj;
} else {
return rb_exc_new3(rb_eRuntimeError, rb_obj_as_string(obj));
}
}
/* Initialize Ruby runtime support */
SWIGRUNTIME void
SWIG_Ruby_InitRuntime(void)
{
if (_mSWIG == Qnil) {
_mSWIG = rb_define_module("SWIG");
swig_call_id = rb_intern("call");
swig_arity_id = rb_intern("arity");
}
}
/* Define Ruby class for C type */
SWIGRUNTIME void
SWIG_Ruby_define_class(swig_type_info *type)
{
char *klass_name = (char *) malloc(4 + strlen(type->name) + 1);
sprintf(klass_name, "TYPE%s", type->name);
if (NIL_P(_cSWIG_Pointer)) {
_cSWIG_Pointer = rb_define_class_under(_mSWIG, "Pointer", rb_cObject);
rb_undef_method(CLASS_OF(_cSWIG_Pointer), "new");
}
rb_define_class_under(_mSWIG, klass_name, _cSWIG_Pointer);
free((void *) klass_name);
}
/* Create a new pointer object */
SWIGRUNTIME VALUE
SWIG_Ruby_NewPointerObj(void *ptr, swig_type_info *type, int flags)
{
int own = flags & SWIG_POINTER_OWN;
int track;
char *klass_name;
swig_class *sklass;
VALUE klass;
VALUE obj;
if (!ptr)
return Qnil;
if (type->clientdata) {
sklass = (swig_class *) type->clientdata;
/* Are we tracking this class and have we already returned this Ruby object? */
track = sklass->trackObjects;
if (track) {
obj = SWIG_RubyInstanceFor(ptr);
/* Check the object's type and make sure it has the correct type.
It might not in cases where methods do things like
downcast methods. */
if (obj != Qnil) {
VALUE value = rb_iv_get(obj, "@__swigtype__");
const char* type_name = RSTRING_PTR(value);
if (strcmp(type->name, type_name) == 0) {
return obj;
}
}
}
/* Create a new Ruby object */
obj = Data_Wrap_Struct(sklass->klass, VOIDFUNC(sklass->mark),
( own ? VOIDFUNC(sklass->destroy) :
(track ? VOIDFUNC(SWIG_RubyRemoveTracking) : 0 )
), ptr);
/* If tracking is on for this class then track this object. */
if (track) {
SWIG_RubyAddTracking(ptr, obj);
}
} else {
klass_name = (char *) malloc(4 + strlen(type->name) + 1);
sprintf(klass_name, "TYPE%s", type->name);
klass = rb_const_get(_mSWIG, rb_intern(klass_name));
free((void *) klass_name);
obj = Data_Wrap_Struct(klass, 0, 0, ptr);
}
rb_iv_set(obj, "@__swigtype__", rb_str_new2(type->name));
return obj;
}
/* Create a new class instance (always owned) */
SWIGRUNTIME VALUE
SWIG_Ruby_NewClassInstance(VALUE klass, swig_type_info *type)
{
VALUE obj;
swig_class *sklass = (swig_class *) type->clientdata;
obj = Data_Wrap_Struct(klass, VOIDFUNC(sklass->mark), VOIDFUNC(sklass->destroy), 0);
rb_iv_set(obj, "@__swigtype__", rb_str_new2(type->name));
return obj;
}
/* Get type mangle from class name */
SWIGRUNTIMEINLINE char *
SWIG_Ruby_MangleStr(VALUE obj)
{
VALUE stype = rb_iv_get(obj, "@__swigtype__");
return StringValuePtr(stype);
}
/* Acquire a pointer value */
typedef struct {
void (*datafree)(void *);
int own;
} swig_ruby_owntype;
SWIGRUNTIME swig_ruby_owntype
SWIG_Ruby_AcquirePtr(VALUE obj, swig_ruby_owntype own) {
swig_ruby_owntype oldown = {0, 0};
if (obj) {
oldown.datafree = RDATA(obj)->dfree;
RDATA(obj)->dfree = own.datafree;
}
return oldown;
}
/* Convert a pointer value */
SWIGRUNTIME int
SWIG_Ruby_ConvertPtrAndOwn(VALUE obj, void **ptr, swig_type_info *ty, int flags, swig_ruby_owntype *own)
{
char *c;
swig_cast_info *tc;
void *vptr = 0;
/* Grab the pointer */
if (NIL_P(obj)) {
if (ptr)
*ptr = 0;
return SWIG_OK;
} else {
if (TYPE(obj) != T_DATA) {
return SWIG_ERROR;
}
Data_Get_Struct(obj, void, vptr);
}
if (own) {
own->datafree = RDATA(obj)->dfree;
own->own = 0;
}
/* Check to see if the input object is giving up ownership
of the underlying C struct or C++ object. If so then we
need to reset the destructor since the Ruby object no
longer owns the underlying C++ object.*/
if (flags & SWIG_POINTER_DISOWN) {
/* Is tracking on for this class? */
int track = 0;
if (ty && ty->clientdata) {
swig_class *sklass = (swig_class *) ty->clientdata;
track = sklass->trackObjects;
}
if (track) {
/* We are tracking objects for this class. Thus we change the destructor
* to SWIG_RubyRemoveTracking. This allows us to
* remove the mapping from the C++ to Ruby object
* when the Ruby object is garbage collected. If we don't
* do this, then it is possible we will return a reference
* to a Ruby object that no longer exists thereby crashing Ruby. */
RDATA(obj)->dfree = SWIG_RubyRemoveTracking;
} else {
RDATA(obj)->dfree = 0;
}
}
/* Do type-checking if type info was provided */
if (ty) {
if (ty->clientdata) {
if (rb_obj_is_kind_of(obj, ((swig_class *) (ty->clientdata))->klass)) {
if (vptr == 0) {
/* The object has already been deleted */
return SWIG_ObjectPreviouslyDeletedError;
}
}
}
if ((c = SWIG_MangleStr(obj)) == NULL) {
return SWIG_ERROR;
}
tc = SWIG_TypeCheck(c, ty);
if (!tc) {
return SWIG_ERROR;
} else {
if (ptr) {
if (tc->type == ty) {
*ptr = vptr;
} else {
int newmemory = 0;
*ptr = SWIG_TypeCast(tc, vptr, &newmemory);
if (newmemory == SWIG_CAST_NEW_MEMORY) {
assert(own); /* badly formed typemap which will lead to a memory leak - it must set and use own to delete *ptr */
if (own)
own->own = own->own | SWIG_CAST_NEW_MEMORY;
}
}
}
}
} else {
if (ptr)
*ptr = vptr;
}
return SWIG_OK;
}
/* Check convert */
SWIGRUNTIMEINLINE int
SWIG_Ruby_CheckConvert(VALUE obj, swig_type_info *ty)
{
char *c = SWIG_MangleStr(obj);
if (!c) return 0;
return SWIG_TypeCheck(c,ty) != 0;
}
SWIGRUNTIME VALUE
SWIG_Ruby_NewPackedObj(void *ptr, int sz, swig_type_info *type) {
char result[1024];
char *r = result;
if ((2*sz + 1 + strlen(type->name)) > 1000) return 0;
*(r++) = '_';
r = SWIG_PackData(r, ptr, sz);
strcpy(r, type->name);
return rb_str_new2(result);
}
/* Convert a packed value value */
SWIGRUNTIME int
SWIG_Ruby_ConvertPacked(VALUE obj, void *ptr, int sz, swig_type_info *ty) {
swig_cast_info *tc;
const char *c;
if (TYPE(obj) != T_STRING) goto type_error;
c = StringValuePtr(obj);
/* Pointer values must start with leading underscore */
if (*c != '_') goto type_error;
c++;
c = SWIG_UnpackData(c, ptr, sz);
if (ty) {
tc = SWIG_TypeCheck(c, ty);
if (!tc) goto type_error;
}
return SWIG_OK;
type_error:
return SWIG_ERROR;
}
SWIGRUNTIME swig_module_info *
SWIG_Ruby_GetModule(void *SWIGUNUSEDPARM(clientdata))
{
VALUE pointer;
swig_module_info *ret = 0;
VALUE verbose = rb_gv_get("VERBOSE");
/* temporarily disable warnings, since the pointer check causes warnings with 'ruby -w' */
rb_gv_set("VERBOSE", Qfalse);
/* first check if pointer already created */
pointer = rb_gv_get("$swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME);
if (pointer != Qnil) {
Data_Get_Struct(pointer, swig_module_info, ret);
}
/* reinstate warnings */
rb_gv_set("VERBOSE", verbose);
return ret;
}
SWIGRUNTIME void
SWIG_Ruby_SetModule(swig_module_info *pointer)
{
/* register a new class */
VALUE cl = rb_define_class("swig_runtime_data", rb_cObject);
/* create and store the structure pointer to a global variable */
swig_runtime_data_type_pointer = Data_Wrap_Struct(cl, 0, 0, pointer);
rb_define_readonly_variable("$swig_runtime_data_type_pointer" SWIG_RUNTIME_VERSION SWIG_TYPE_TABLE_NAME, &swig_runtime_data_type_pointer);
}
/* This function can be used to check whether a proc or method or similarly
callable function has been passed. Usually used in a %typecheck, like:
%typecheck(c_callback_t, precedence=SWIG_TYPECHECK_POINTER) {
$result = SWIG_Ruby_isCallable( $input );
}
*/
SWIGINTERN
int SWIG_Ruby_isCallable( VALUE proc )
{
if ( rb_respond_to( proc, swig_call_id ) )
return 1;
return 0;
}
/* This function can be used to check the arity (number of arguments)
a proc or method can take. Usually used in a %typecheck.
Valid arities will be that equal to minimal or those < 0
which indicate a variable number of parameters at the end.
*/
SWIGINTERN
int SWIG_Ruby_arity( VALUE proc, int minimal )
{
if ( rb_respond_to( proc, swig_arity_id ) )
{
VALUE num = rb_funcall( proc, swig_arity_id, 0 );
int arity = NUM2INT(num);
if ( arity < 0 && (arity+1) < -minimal ) return 1;
if ( arity == minimal ) return 1;
return 1;
}
return 0;
}
#ifdef __cplusplus
}
#endif
#define SWIG_exception_fail(code, msg) do { SWIG_Error(code, msg); SWIG_fail; } while(0)
#define SWIG_contract_assert(expr, msg) if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } else
#define SWIG_exception(code, msg) do { SWIG_Error(code, msg);; } while(0)
/* -------- TYPES TABLE (BEGIN) -------- */
#define SWIGTYPE_m_CVwParser__f_p_CIOBuffer_r_p_shogun__VwExample__int swig_types[0]
#define SWIGTYPE_p_CDenseFeaturesT_bool_t swig_types[1]
#define SWIGTYPE_p_CDenseFeaturesT_char_t swig_types[2]
#define SWIGTYPE_p_CDenseFeaturesT_double_t swig_types[3]
#define SWIGTYPE_p_CDenseFeaturesT_float_t swig_types[4]
#define SWIGTYPE_p_CDenseFeaturesT_int_t swig_types[5]
#define SWIGTYPE_p_CDenseFeaturesT_long_t swig_types[6]
#define SWIGTYPE_p_CDenseFeaturesT_unsigned_char_t swig_types[7]
#define SWIGTYPE_p_CDenseFeaturesT_unsigned_long_t swig_types[8]
#define SWIGTYPE_p_CDenseFeaturesT_unsigned_short_t swig_types[9]
#define SWIGTYPE_p_CFactorGraphObservation swig_types[10]
#define SWIGTYPE_p_CIOBuffer swig_types[11]
#define SWIGTYPE_p_CLossFunction swig_types[12]
#define SWIGTYPE_p_CSparseFeaturesT_bool_t swig_types[13]
#define SWIGTYPE_p_CSparseFeaturesT_char_t swig_types[14]
#define SWIGTYPE_p_CSparseFeaturesT_double_t swig_types[15]
#define SWIGTYPE_p_CSparseFeaturesT_float_t swig_types[16]
#define SWIGTYPE_p_CSparseFeaturesT_int_t swig_types[17]
#define SWIGTYPE_p_CSparseFeaturesT_long_t swig_types[18]
#define SWIGTYPE_p_CSparseFeaturesT_unsigned_char_t swig_types[19]
#define SWIGTYPE_p_CSparseFeaturesT_unsigned_long_t swig_types[20]
#define SWIGTYPE_p_CSparseFeaturesT_unsigned_short_t swig_types[21]
#define SWIGTYPE_p_CStateModel swig_types[22]
#define SWIGTYPE_p_CSubsetStack swig_types[23]
#define SWIGTYPE_p_CTreeMachineNodeT_C45TreeNodeData_t swig_types[24]
#define SWIGTYPE_p_CTreeMachineNodeT_CARTreeNodeData_t swig_types[25]
#define SWIGTYPE_p_CTreeMachineNodeT_CHAIDTreeNodeData_t swig_types[26]
#define SWIGTYPE_p_CTreeMachineNodeT_id3TreeNodeData_t swig_types[27]
#define SWIGTYPE_p_CTreeMachineNodeT_shogun__ConditionalProbabilityTreeNodeData_t swig_types[28]
#define SWIGTYPE_p_CTreeMachineNodeT_shogun__RelaxedTreeNodeData_t swig_types[29]
#define SWIGTYPE_p_CVwEnvironment swig_types[30]
#define SWIGTYPE_p_CVwLearner swig_types[31]
#define SWIGTYPE_p_ELabelType swig_types[32]
#define SWIGTYPE_p_EPrimitiveType swig_types[33]
#define SWIGTYPE_p_EVwCacheType swig_types[34]
#define SWIGTYPE_p_EigenMatrixXt swig_types[35]
#define SWIGTYPE_p_EigenMatrixXtMap swig_types[36]
#define SWIGTYPE_p_EigenRowVectorXt swig_types[37]
#define SWIGTYPE_p_EigenRowVectorXtMap swig_types[38]
#define SWIGTYPE_p_EigenVectorXt swig_types[39]
#define SWIGTYPE_p_EigenVectorXtMap swig_types[40]
#define SWIGTYPE_p_Eigen__MatrixT_double__1__1_0__1__1_t swig_types[41]
#define SWIGTYPE_p_FILE swig_types[42]
#define SWIGTYPE_p_FirstOrderCostFunction swig_types[43]
#define SWIGTYPE_p_Penalty swig_types[44]
#define SWIGTYPE_p_SGMatrixListT_bool_t swig_types[45]
#define SWIGTYPE_p_SGMatrixListT_char_t swig_types[46]
#define SWIGTYPE_p_SGMatrixListT_double_t swig_types[47]
#define SWIGTYPE_p_SGMatrixListT_float_t swig_types[48]
#define SWIGTYPE_p_SGMatrixListT_int_t swig_types[49]
#define SWIGTYPE_p_SGMatrixListT_long_t swig_types[50]
#define SWIGTYPE_p_SGMatrixListT_unsigned_char_t swig_types[51]
#define SWIGTYPE_p_SGMatrixListT_unsigned_long_t swig_types[52]
#define SWIGTYPE_p_SGMatrixListT_unsigned_short_t swig_types[53]
#define SWIGTYPE_p_Scalar swig_types[54]
#define SWIGTYPE_p_ShogunException swig_types[55]
#define SWIGTYPE_p_VwFeature swig_types[56]
#define SWIGTYPE_p_a_256__char swig_types[57]
#define SWIGTYPE_p_a_8__double swig_types[58]
#define SWIGTYPE_p_allocator_type swig_types[59]
#define SWIGTYPE_p_bnode_t swig_types[60]
#define SWIGTYPE_p_bool swig_types[61]
#define SWIGTYPE_p_char swig_types[62]
#define SWIGTYPE_p_clock_t swig_types[63]
#define SWIGTYPE_p_difference_type swig_types[64]
#define SWIGTYPE_p_dirent swig_types[65]
#define SWIGTYPE_p_double swig_types[66]
#define SWIGTYPE_p_entry_t swig_types[67]
#define SWIGTYPE_p_f_p_FILE_p_q_const__char__void swig_types[68]
#define SWIGTYPE_p_f_p_shogun__CMKL_p_q_const__double_q_const__double__bool swig_types[69]
#define SWIGTYPE_p_f_r_bool_r_bool__void swig_types[70]
#define SWIGTYPE_p_float swig_types[71]
#define SWIGTYPE_p_hash_func_t swig_types[72]
#define SWIGTYPE_p_int swig_types[73]
#define SWIGTYPE_p_long swig_types[74]
#define SWIGTYPE_p_long_double swig_types[75]
#define SWIGTYPE_p_m_CVwParser__f_p_CIOBuffer_r_p_shogun__VwExample__int swig_types[76]
#define SWIGTYPE_p_node_t swig_types[77]
#define SWIGTYPE_p_p_bool swig_types[78]
#define SWIGTYPE_p_p_char swig_types[79]
#define SWIGTYPE_p_p_double swig_types[80]
#define SWIGTYPE_p_p_float swig_types[81]
#define SWIGTYPE_p_p_int swig_types[82]
#define SWIGTYPE_p_p_long swig_types[83]
#define SWIGTYPE_p_p_shogun__CANOVAKernel swig_types[84]
#define SWIGTYPE_p_p_shogun__CAUCKernel swig_types[85]
#define SWIGTYPE_p_p_shogun__CAccuracyMeasure swig_types[86]
#define SWIGTYPE_p_p_shogun__CAlphabet swig_types[87]
#define SWIGTYPE_p_p_shogun__CAttributeFeatures swig_types[88]
#define SWIGTYPE_p_p_shogun__CAutoencoder swig_types[89]
#define SWIGTYPE_p_p_shogun__CAveragedPerceptron swig_types[90]
#define SWIGTYPE_p_p_shogun__CAvgDiagKernelNormalizer swig_types[91]
#define SWIGTYPE_p_p_shogun__CBAHSIC swig_types[92]
#define SWIGTYPE_p_p_shogun__CBALMeasure swig_types[93]
#define SWIGTYPE_p_p_shogun__CBaggingMachine swig_types[94]
#define SWIGTYPE_p_p_shogun__CBalancedConditionalProbabilityTree swig_types[95]
#define SWIGTYPE_p_p_shogun__CBaseMulticlassMachine swig_types[96]
#define SWIGTYPE_p_p_shogun__CBinaryClassEvaluation swig_types[97]
#define SWIGTYPE_p_p_shogun__CBinaryFile swig_types[98]
#define SWIGTYPE_p_p_shogun__CBinaryLabels swig_types[99]
#define SWIGTYPE_p_p_shogun__CBinnedDotFeatures swig_types[100]
#define SWIGTYPE_p_p_shogun__CBrayCurtisDistance swig_types[101]
#define SWIGTYPE_p_p_shogun__CC45ClassifierTree swig_types[102]
#define SWIGTYPE_p_p_shogun__CCARTree swig_types[103]
#define SWIGTYPE_p_p_shogun__CCGMShiftedFamilySolver swig_types[104]
#define SWIGTYPE_p_p_shogun__CCHAIDTree swig_types[105]
#define SWIGTYPE_p_p_shogun__CCSVFile swig_types[106]
#define SWIGTYPE_p_p_shogun__CCanberraMetric swig_types[107]
#define SWIGTYPE_p_p_shogun__CCanberraWordDistance swig_types[108]
#define SWIGTYPE_p_p_shogun__CCauchyKernel swig_types[109]
#define SWIGTYPE_p_p_shogun__CChebyshewMetric swig_types[110]
#define SWIGTYPE_p_p_shogun__CChi2Kernel swig_types[111]
#define SWIGTYPE_p_p_shogun__CChiSquareDistance swig_types[112]
#define SWIGTYPE_p_p_shogun__CCircularKernel swig_types[113]
#define SWIGTYPE_p_p_shogun__CClusteringAccuracy swig_types[114]
#define SWIGTYPE_p_p_shogun__CClusteringEvaluation swig_types[115]
#define SWIGTYPE_p_p_shogun__CClusteringMutualInformation swig_types[116]
#define SWIGTYPE_p_p_shogun__CCombinationRule swig_types[117]
#define SWIGTYPE_p_p_shogun__CCombinedDotFeatures swig_types[118]
#define SWIGTYPE_p_p_shogun__CCombinedFeatures swig_types[119]
#define SWIGTYPE_p_p_shogun__CCombinedKernel swig_types[120]
#define SWIGTYPE_p_p_shogun__CCommUlongStringKernel swig_types[121]
#define SWIGTYPE_p_p_shogun__CCommWordStringKernel swig_types[122]
#define SWIGTYPE_p_p_shogun__CCompressor swig_types[123]
#define SWIGTYPE_p_p_shogun__CConditionalProbabilityTree swig_types[124]
#define SWIGTYPE_p_p_shogun__CConjugateGradientSolver swig_types[125]
#define SWIGTYPE_p_p_shogun__CConjugateOrthogonalCGSolver swig_types[126]
#define SWIGTYPE_p_p_shogun__CConstKernel swig_types[127]
#define SWIGTYPE_p_p_shogun__CConstMean swig_types[128]
#define SWIGTYPE_p_p_shogun__CContingencyTableEvaluation swig_types[129]
#define SWIGTYPE_p_p_shogun__CConverter swig_types[130]
#define SWIGTYPE_p_p_shogun__CCosineDistance swig_types[131]
#define SWIGTYPE_p_p_shogun__CCrossCorrelationMeasure swig_types[132]
#define SWIGTYPE_p_p_shogun__CCrossValidation swig_types[133]
#define SWIGTYPE_p_p_shogun__CCrossValidationMKLStorage swig_types[134]
#define SWIGTYPE_p_p_shogun__CCrossValidationMulticlassStorage swig_types[135]
#define SWIGTYPE_p_p_shogun__CCrossValidationOutput swig_types[136]
#define SWIGTYPE_p_p_shogun__CCrossValidationPrintOutput swig_types[137]
#define SWIGTYPE_p_p_shogun__CCrossValidationResult swig_types[138]
#define SWIGTYPE_p_p_shogun__CCrossValidationSplitting swig_types[139]
#define SWIGTYPE_p_p_shogun__CCustomDistance swig_types[140]
#define SWIGTYPE_p_p_shogun__CCustomKernel swig_types[141]
#define SWIGTYPE_p_p_shogun__CCustomMahalanobisDistance swig_types[142]
#define SWIGTYPE_p_p_shogun__CData swig_types[143]
#define SWIGTYPE_p_p_shogun__CDataGenerator swig_types[144]
#define SWIGTYPE_p_p_shogun__CDecompressStringT_char_t swig_types[145]
#define SWIGTYPE_p_p_shogun__CDecompressStringT_unsigned_char_t swig_types[146]
#define SWIGTYPE_p_p_shogun__CDecompressStringT_unsigned_long_t swig_types[147]
#define SWIGTYPE_p_p_shogun__CDecompressStringT_unsigned_short_t swig_types[148]
#define SWIGTYPE_p_p_shogun__CDeepAutoencoder swig_types[149]
#define SWIGTYPE_p_p_shogun__CDeepBeliefNetwork swig_types[150]
#define SWIGTYPE_p_p_shogun__CDelimiterTokenizer swig_types[151]
#define SWIGTYPE_p_p_shogun__CDenseDistanceT_char_t swig_types[152]
#define SWIGTYPE_p_p_shogun__CDenseDistanceT_double_t swig_types[153]
#define SWIGTYPE_p_p_shogun__CDenseDistanceT_int_t swig_types[154]
#define SWIGTYPE_p_p_shogun__CDenseDistanceT_unsigned_short_t swig_types[155]
#define SWIGTYPE_p_p_shogun__CDenseFeaturesT_bool_t swig_types[156]
#define SWIGTYPE_p_p_shogun__CDenseFeaturesT_char_t swig_types[157]
#define SWIGTYPE_p_p_shogun__CDenseFeaturesT_double_t swig_types[158]
#define SWIGTYPE_p_p_shogun__CDenseFeaturesT_float_t swig_types[159]
#define SWIGTYPE_p_p_shogun__CDenseFeaturesT_int_t swig_types[160]
#define SWIGTYPE_p_p_shogun__CDenseFeaturesT_long_t swig_types[161]
#define SWIGTYPE_p_p_shogun__CDenseFeaturesT_unsigned_char_t swig_types[162]
#define SWIGTYPE_p_p_shogun__CDenseFeaturesT_unsigned_long_t swig_types[163]
#define SWIGTYPE_p_p_shogun__CDenseFeaturesT_unsigned_short_t swig_types[164]
#define SWIGTYPE_p_p_shogun__CDenseLabels swig_types[165]
#define SWIGTYPE_p_p_shogun__CDenseMatrixOperatorT_double_t swig_types[166]
#define SWIGTYPE_p_p_shogun__CDenseMatrixOperatorT_std__complexT_double_t_t swig_types[167]
#define SWIGTYPE_p_p_shogun__CDensePreprocessorT_char_t swig_types[168]
#define SWIGTYPE_p_p_shogun__CDensePreprocessorT_double_t swig_types[169]
#define SWIGTYPE_p_p_shogun__CDensePreprocessorT_unsigned_char_t swig_types[170]
#define SWIGTYPE_p_p_shogun__CDensePreprocessorT_unsigned_long_t swig_types[171]
#define SWIGTYPE_p_p_shogun__CDensePreprocessorT_unsigned_short_t swig_types[172]
#define SWIGTYPE_p_p_shogun__CDenseSubsetFeaturesT_bool_t swig_types[173]
#define SWIGTYPE_p_p_shogun__CDenseSubsetFeaturesT_char_t swig_types[174]
#define SWIGTYPE_p_p_shogun__CDenseSubsetFeaturesT_double_t swig_types[175]
#define SWIGTYPE_p_p_shogun__CDenseSubsetFeaturesT_float_t swig_types[176]
#define SWIGTYPE_p_p_shogun__CDenseSubsetFeaturesT_int_t swig_types[177]
#define SWIGTYPE_p_p_shogun__CDenseSubsetFeaturesT_long_t swig_types[178]
#define SWIGTYPE_p_p_shogun__CDenseSubsetFeaturesT_unsigned_char_t swig_types[179]
#define SWIGTYPE_p_p_shogun__CDenseSubsetFeaturesT_unsigned_long_t swig_types[180]
#define SWIGTYPE_p_p_shogun__CDenseSubsetFeaturesT_unsigned_short_t swig_types[181]
#define SWIGTYPE_p_p_shogun__CDependenceMaximization swig_types[182]
#define SWIGTYPE_p_p_shogun__CDiagKernel swig_types[183]
#define SWIGTYPE_p_p_shogun__CDiceKernelNormalizer swig_types[184]
#define SWIGTYPE_p_p_shogun__CDifferentiableFunction swig_types[185]
#define SWIGTYPE_p_p_shogun__CDiffusionMaps swig_types[186]
#define SWIGTYPE_p_p_shogun__CDimensionReductionPreprocessor swig_types[187]
#define SWIGTYPE_p_p_shogun__CDirectLinearSolverComplex swig_types[188]
#define SWIGTYPE_p_p_shogun__CDirectSparseLinearSolver swig_types[189]
#define SWIGTYPE_p_p_shogun__CDisjointSet swig_types[190]
#define SWIGTYPE_p_p_shogun__CDistance swig_types[191]
#define SWIGTYPE_p_p_shogun__CDistanceKernel swig_types[192]
#define SWIGTYPE_p_p_shogun__CDistanceMachine swig_types[193]
#define SWIGTYPE_p_p_shogun__CDistantSegmentsKernel swig_types[194]
#define SWIGTYPE_p_p_shogun__CDistribution swig_types[195]
#define SWIGTYPE_p_p_shogun__CDixonQTestRejectionStrategy swig_types[196]
#define SWIGTYPE_p_p_shogun__CDomainAdaptationMulticlassLibLinear swig_types[197]
#define SWIGTYPE_p_p_shogun__CDomainAdaptationSVM swig_types[198]
#define SWIGTYPE_p_p_shogun__CDomainAdaptationSVMLinear swig_types[199]
#define SWIGTYPE_p_p_shogun__CDotFeatures swig_types[200]
#define SWIGTYPE_p_p_shogun__CDotKernel swig_types[201]
#define SWIGTYPE_p_p_shogun__CDualLibQPBMSOSVM swig_types[202]
#define SWIGTYPE_p_p_shogun__CDualVariationalGaussianLikelihood swig_types[203]
#define SWIGTYPE_p_p_shogun__CDummyFeatures swig_types[204]
#define SWIGTYPE_p_p_shogun__CDynProg swig_types[205]
#define SWIGTYPE_p_p_shogun__CDynamicArrayT_char_t swig_types[206]
#define SWIGTYPE_p_p_shogun__CDynamicArrayT_double_t swig_types[207]
#define SWIGTYPE_p_p_shogun__CDynamicArrayT_float_t swig_types[208]
#define SWIGTYPE_p_p_shogun__CDynamicArrayT_int_t swig_types[209]
#define SWIGTYPE_p_p_shogun__CDynamicArrayT_long_t swig_types[210]
#define SWIGTYPE_p_p_shogun__CDynamicArrayT_unsigned_char_t swig_types[211]
#define SWIGTYPE_p_p_shogun__CDynamicArrayT_unsigned_long_t swig_types[212]
#define SWIGTYPE_p_p_shogun__CDynamicArrayT_unsigned_short_t swig_types[213]
#define SWIGTYPE_p_p_shogun__CDynamicObjectArray swig_types[214]
#define SWIGTYPE_p_p_shogun__CECOCAEDDecoder swig_types[215]
#define SWIGTYPE_p_p_shogun__CECOCDecoder swig_types[216]
#define SWIGTYPE_p_p_shogun__CECOCDiscriminantEncoder swig_types[217]
#define SWIGTYPE_p_p_shogun__CECOCEDDecoder swig_types[218]
#define SWIGTYPE_p_p_shogun__CECOCEncoder swig_types[219]
#define SWIGTYPE_p_p_shogun__CECOCForestEncoder swig_types[220]
#define SWIGTYPE_p_p_shogun__CECOCHDDecoder swig_types[221]
#define SWIGTYPE_p_p_shogun__CECOCIHDDecoder swig_types[222]
#define SWIGTYPE_p_p_shogun__CECOCLLBDecoder swig_types[223]
#define SWIGTYPE_p_p_shogun__CECOCOVOEncoder swig_types[224]
#define SWIGTYPE_p_p_shogun__CECOCOVREncoder swig_types[225]
#define SWIGTYPE_p_p_shogun__CECOCRandomDenseEncoder swig_types[226]
#define SWIGTYPE_p_p_shogun__CECOCRandomSparseEncoder swig_types[227]
#define SWIGTYPE_p_p_shogun__CECOCSimpleDecoder swig_types[228]
#define SWIGTYPE_p_p_shogun__CECOCStrategy swig_types[229]
#define SWIGTYPE_p_p_shogun__CEPInferenceMethod swig_types[230]
#define SWIGTYPE_p_p_shogun__CEigenSolver swig_types[231]
#define SWIGTYPE_p_p_shogun__CEmbeddingConverter swig_types[232]
#define SWIGTYPE_p_p_shogun__CErrorRateMeasure swig_types[233]
#define SWIGTYPE_p_p_shogun__CEuclideanDistance swig_types[234]
#define SWIGTYPE_p_p_shogun__CEvaluation swig_types[235]
#define SWIGTYPE_p_p_shogun__CEvaluationResult swig_types[236]
#define SWIGTYPE_p_p_shogun__CExactInferenceMethod swig_types[237]
#define SWIGTYPE_p_p_shogun__CExplicitSpecFeatures swig_types[238]
#define SWIGTYPE_p_p_shogun__CExponentialARDKernel swig_types[239]
#define SWIGTYPE_p_p_shogun__CExponentialKernel swig_types[240]
#define SWIGTYPE_p_p_shogun__CF1Measure swig_types[241]
#define SWIGTYPE_p_p_shogun__CFFSep swig_types[242]
#define SWIGTYPE_p_p_shogun__CFITCInferenceMethod swig_types[243]
#define SWIGTYPE_p_p_shogun__CFKFeatures swig_types[244]
#define SWIGTYPE_p_p_shogun__CFWSOSVM swig_types[245]
#define SWIGTYPE_p_p_shogun__CFactor swig_types[246]
#define SWIGTYPE_p_p_shogun__CFactorAnalysis swig_types[247]
#define SWIGTYPE_p_p_shogun__CFactorDataSource swig_types[248]
#define SWIGTYPE_p_p_shogun__CFactorGraph swig_types[249]
#define SWIGTYPE_p_p_shogun__CFactorGraphFeatures swig_types[250]
#define SWIGTYPE_p_p_shogun__CFactorGraphLabels swig_types[251]
#define SWIGTYPE_p_p_shogun__CFactorGraphModel swig_types[252]
#define SWIGTYPE_p_p_shogun__CFactorGraphObservation swig_types[253]
#define SWIGTYPE_p_p_shogun__CFactorType swig_types[254]
#define SWIGTYPE_p_p_shogun__CFastICA swig_types[255]
#define SWIGTYPE_p_p_shogun__CFeatureBlockLogisticRegression swig_types[256]
#define SWIGTYPE_p_p_shogun__CFeatureSelectionT_char_t swig_types[257]
#define SWIGTYPE_p_p_shogun__CFeatureSelectionT_double_t swig_types[258]
#define SWIGTYPE_p_p_shogun__CFeatureSelectionT_unsigned_char_t swig_types[259]
#define SWIGTYPE_p_p_shogun__CFeatureSelectionT_unsigned_long_t swig_types[260]
#define SWIGTYPE_p_p_shogun__CFeatureSelectionT_unsigned_short_t swig_types[261]
#define SWIGTYPE_p_p_shogun__CFeatures swig_types[262]
#define SWIGTYPE_p_p_shogun__CFile swig_types[263]
#define SWIGTYPE_p_p_shogun__CFisherLDA swig_types[264]
#define SWIGTYPE_p_p_shogun__CFixedDegreeStringKernel swig_types[265]
#define SWIGTYPE_p_p_shogun__CGCArrayT_shogun__CPlifBase_p_t swig_types[266]
#define SWIGTYPE_p_p_shogun__CGMM swig_types[267]
#define SWIGTYPE_p_p_shogun__CGMNPSVM swig_types[268]
#define SWIGTYPE_p_p_shogun__CGNPPSVM swig_types[269]
#define SWIGTYPE_p_p_shogun__CGPBTSVM swig_types[270]
#define SWIGTYPE_p_p_shogun__CGaussian swig_types[271]
#define SWIGTYPE_p_p_shogun__CGaussianARDKernel swig_types[272]
#define SWIGTYPE_p_p_shogun__CGaussianARDSparseKernel swig_types[273]
#define SWIGTYPE_p_p_shogun__CGaussianBlobsDataGenerator swig_types[274]
#define SWIGTYPE_p_p_shogun__CGaussianDistribution swig_types[275]
#define SWIGTYPE_p_p_shogun__CGaussianKernel swig_types[276]
#define SWIGTYPE_p_p_shogun__CGaussianLikelihood swig_types[277]
#define SWIGTYPE_p_p_shogun__CGaussianMatchStringKernel swig_types[278]
#define SWIGTYPE_p_p_shogun__CGaussianNaiveBayes swig_types[279]
#define SWIGTYPE_p_p_shogun__CGaussianProcessClassification swig_types[280]
#define SWIGTYPE_p_p_shogun__CGaussianProcessMachine swig_types[281]
#define SWIGTYPE_p_p_shogun__CGaussianProcessRegression swig_types[282]
#define SWIGTYPE_p_p_shogun__CGaussianShiftKernel swig_types[283]
#define SWIGTYPE_p_p_shogun__CGaussianShortRealKernel swig_types[284]
#define SWIGTYPE_p_p_shogun__CGeodesicMetric swig_types[285]
#define SWIGTYPE_p_p_shogun__CGradientCriterion swig_types[286]
#define SWIGTYPE_p_p_shogun__CGradientEvaluation swig_types[287]
#define SWIGTYPE_p_p_shogun__CGradientResult swig_types[288]
#define SWIGTYPE_p_p_shogun__CGraphCut swig_types[289]
#define SWIGTYPE_p_p_shogun__CGridSearchModelSelection swig_types[290]
#define SWIGTYPE_p_p_shogun__CHDF5File swig_types[291]
#define SWIGTYPE_p_p_shogun__CHMM swig_types[292]
#define SWIGTYPE_p_p_shogun__CHMSVMModel swig_types[293]
#define SWIGTYPE_p_p_shogun__CHSIC swig_types[294]
#define SWIGTYPE_p_p_shogun__CHammingWordDistance swig_types[295]
#define SWIGTYPE_p_p_shogun__CHash swig_types[296]
#define SWIGTYPE_p_p_shogun__CHashedDocConverter swig_types[297]
#define SWIGTYPE_p_p_shogun__CHashedDocDotFeatures swig_types[298]
#define SWIGTYPE_p_p_shogun__CHashedMultilabelModel swig_types[299]
#define SWIGTYPE_p_p_shogun__CHashedWDFeatures swig_types[300]
#define SWIGTYPE_p_p_shogun__CHashedWDFeaturesTransposed swig_types[301]
#define SWIGTYPE_p_p_shogun__CHessianLocallyLinearEmbedding swig_types[302]
#define SWIGTYPE_p_p_shogun__CHierarchical swig_types[303]
#define SWIGTYPE_p_p_shogun__CHierarchicalMultilabelModel swig_types[304]
#define SWIGTYPE_p_p_shogun__CHingeLoss swig_types[305]
#define SWIGTYPE_p_p_shogun__CHistogram swig_types[306]
#define SWIGTYPE_p_p_shogun__CHistogramIntersectionKernel swig_types[307]
#define SWIGTYPE_p_p_shogun__CHistogramWordStringKernel swig_types[308]
#define SWIGTYPE_p_p_shogun__CHomogeneousKernelMap swig_types[309]
#define SWIGTYPE_p_p_shogun__CHypothesisTest swig_types[310]
#define SWIGTYPE_p_p_shogun__CICAConverter swig_types[311]
#define SWIGTYPE_p_p_shogun__CID3ClassifierTree swig_types[312]
#define SWIGTYPE_p_p_shogun__CIdentityKernelNormalizer swig_types[313]
#define SWIGTYPE_p_p_shogun__CImplicitWeightedSpecFeatures swig_types[314]
#define SWIGTYPE_p_p_shogun__CIndependenceTest swig_types[315]
#define SWIGTYPE_p_p_shogun__CIndependentComputationEngine swig_types[316]
#define SWIGTYPE_p_p_shogun__CIndependentJob swig_types[317]
#define SWIGTYPE_p_p_shogun__CIndexBlock swig_types[318]
#define SWIGTYPE_p_p_shogun__CIndexBlockGroup swig_types[319]
#define SWIGTYPE_p_p_shogun__CIndexBlockRelation swig_types[320]
#define SWIGTYPE_p_p_shogun__CIndexBlockTree swig_types[321]
#define SWIGTYPE_p_p_shogun__CIndexFeatures swig_types[322]
#define SWIGTYPE_p_p_shogun__CInference swig_types[323]
#define SWIGTYPE_p_p_shogun__CIntronList swig_types[324]
#define SWIGTYPE_p_p_shogun__CInverseMultiQuadricKernel swig_types[325]
#define SWIGTYPE_p_p_shogun__CIterativeLinearSolverT_double_double_t swig_types[326]
#define SWIGTYPE_p_p_shogun__CIterativeLinearSolverT_std__complexT_double_t_double_t swig_types[327]
#define SWIGTYPE_p_p_shogun__CIterativeShiftedLinearFamilySolverT_double_std__complexT_double_t_t swig_types[328]
#define SWIGTYPE_p_p_shogun__CJade swig_types[329]
#define SWIGTYPE_p_p_shogun__CJediSep swig_types[330]
#define SWIGTYPE_p_p_shogun__CJensenMetric swig_types[331]
#define SWIGTYPE_p_p_shogun__CJensenShannonKernel swig_types[332]
#define SWIGTYPE_p_p_shogun__CJobResult swig_types[333]
#define SWIGTYPE_p_p_shogun__CKLCholeskyInferenceMethod swig_types[334]
#define SWIGTYPE_p_p_shogun__CKLCovarianceInferenceMethod swig_types[335]
#define SWIGTYPE_p_p_shogun__CKLDiagonalInferenceMethod swig_types[336]
#define SWIGTYPE_p_p_shogun__CKLDualInferenceMethod swig_types[337]
#define SWIGTYPE_p_p_shogun__CKLDualInferenceMethodMinimizer swig_types[338]
#define SWIGTYPE_p_p_shogun__CKLInference swig_types[339]
#define SWIGTYPE_p_p_shogun__CKLLowerTriangularInference swig_types[340]
#define SWIGTYPE_p_p_shogun__CKMeans swig_types[341]
#define SWIGTYPE_p_p_shogun__CKMeansBase swig_types[342]
#define SWIGTYPE_p_p_shogun__CKMeansMiniBatch swig_types[343]
#define SWIGTYPE_p_p_shogun__CKNN swig_types[344]
#define SWIGTYPE_p_p_shogun__CKernel swig_types[345]
#define SWIGTYPE_p_p_shogun__CKernelDensity swig_types[346]
#define SWIGTYPE_p_p_shogun__CKernelDependenceMaximization swig_types[347]
#define SWIGTYPE_p_p_shogun__CKernelDistance swig_types[348]
#define SWIGTYPE_p_p_shogun__CKernelIndependenceTest swig_types[349]
#define SWIGTYPE_p_p_shogun__CKernelLocallyLinearEmbedding swig_types[350]
#define SWIGTYPE_p_p_shogun__CKernelMachine swig_types[351]
#define SWIGTYPE_p_p_shogun__CKernelMeanMatching swig_types[352]
#define SWIGTYPE_p_p_shogun__CKernelMulticlassMachine swig_types[353]
#define SWIGTYPE_p_p_shogun__CKernelNormalizer swig_types[354]
#define SWIGTYPE_p_p_shogun__CKernelPCA swig_types[355]
#define SWIGTYPE_p_p_shogun__CKernelRidgeRegression swig_types[356]
#define SWIGTYPE_p_p_shogun__CKernelSelection swig_types[357]
#define SWIGTYPE_p_p_shogun__CKernelStructuredOutputMachine swig_types[358]
#define SWIGTYPE_p_p_shogun__CKernelTwoSampleTest swig_types[359]
#define SWIGTYPE_p_p_shogun__CLBFGSMinimizer swig_types[360]
#define SWIGTYPE_p_p_shogun__CLBPPyrDotFeatures swig_types[361]
#define SWIGTYPE_p_p_shogun__CLDA swig_types[362]
#define SWIGTYPE_p_p_shogun__CLMNN swig_types[363]
#define SWIGTYPE_p_p_shogun__CLMNNStatistics swig_types[364]
#define SWIGTYPE_p_p_shogun__CLaRank swig_types[365]
#define SWIGTYPE_p_p_shogun__CLabels swig_types[366]
#define SWIGTYPE_p_p_shogun__CLabelsFactory swig_types[367]
#define SWIGTYPE_p_p_shogun__CLanczosEigenSolver swig_types[368]
#define SWIGTYPE_p_p_shogun__CLaplaceInference swig_types[369]
#define SWIGTYPE_p_p_shogun__CLaplacianEigenmaps swig_types[370]
#define SWIGTYPE_p_p_shogun__CLatentFeatures swig_types[371]
#define SWIGTYPE_p_p_shogun__CLatentLabels swig_types[372]
#define SWIGTYPE_p_p_shogun__CLatentModel swig_types[373]
#define SWIGTYPE_p_p_shogun__CLatentSVM swig_types[374]
#define SWIGTYPE_p_p_shogun__CLeastAngleRegression swig_types[375]
#define SWIGTYPE_p_p_shogun__CLeastSquaresRegression swig_types[376]
#define SWIGTYPE_p_p_shogun__CLibLinear swig_types[377]
#define SWIGTYPE_p_p_shogun__CLibLinearMTL swig_types[378]
#define SWIGTYPE_p_p_shogun__CLibLinearRegression swig_types[379]
#define SWIGTYPE_p_p_shogun__CLibSVM swig_types[380]
#define SWIGTYPE_p_p_shogun__CLibSVMFile swig_types[381]
#define SWIGTYPE_p_p_shogun__CLibSVMOneClass swig_types[382]
#define SWIGTYPE_p_p_shogun__CLibSVR swig_types[383]
#define SWIGTYPE_p_p_shogun__CLikelihoodModel swig_types[384]
#define SWIGTYPE_p_p_shogun__CLinearHMM swig_types[385]
#define SWIGTYPE_p_p_shogun__CLinearKernel swig_types[386]
#define SWIGTYPE_p_p_shogun__CLinearLatentMachine swig_types[387]
#define SWIGTYPE_p_p_shogun__CLinearLocalTangentSpaceAlignment swig_types[388]
#define SWIGTYPE_p_p_shogun__CLinearMachine swig_types[389]
#define SWIGTYPE_p_p_shogun__CLinearMulticlassMachine swig_types[390]
#define SWIGTYPE_p_p_shogun__CLinearOperatorT_double_t swig_types[391]
#define SWIGTYPE_p_p_shogun__CLinearOperatorT_std__complexT_double_t_t swig_types[392]
#define SWIGTYPE_p_p_shogun__CLinearRidgeRegression swig_types[393]
#define SWIGTYPE_p_p_shogun__CLinearSolverT_double_double_t swig_types[394]
#define SWIGTYPE_p_p_shogun__CLinearSolverT_std__complexT_double_t_double_t swig_types[395]
#define SWIGTYPE_p_p_shogun__CLinearStringKernel swig_types[396]
#define SWIGTYPE_p_p_shogun__CLinearStructuredOutputMachine swig_types[397]
#define SWIGTYPE_p_p_shogun__CLinearTimeMMD swig_types[398]
#define SWIGTYPE_p_p_shogun__CList swig_types[399]
#define SWIGTYPE_p_p_shogun__CListElement swig_types[400]
#define SWIGTYPE_p_p_shogun__CLocalAlignmentStringKernel swig_types[401]
#define SWIGTYPE_p_p_shogun__CLocalTangentSpaceAlignment swig_types[402]
#define SWIGTYPE_p_p_shogun__CLocalityImprovedStringKernel swig_types[403]
#define SWIGTYPE_p_p_shogun__CLocallyLinearEmbedding swig_types[404]
#define SWIGTYPE_p_p_shogun__CLogDetEstimator swig_types[405]
#define SWIGTYPE_p_p_shogun__CLogKernel swig_types[406]
#define SWIGTYPE_p_p_shogun__CLogLoss swig_types[407]
#define SWIGTYPE_p_p_shogun__CLogLossMargin swig_types[408]
#define SWIGTYPE_p_p_shogun__CLogPlusOne swig_types[409]
#define SWIGTYPE_p_p_shogun__CLogRationalApproximationCGM swig_types[410]
#define SWIGTYPE_p_p_shogun__CLogRationalApproximationIndividual swig_types[411]
#define SWIGTYPE_p_p_shogun__CLogitDVGLikelihood swig_types[412]
#define SWIGTYPE_p_p_shogun__CLogitLikelihood swig_types[413]
#define SWIGTYPE_p_p_shogun__CLogitVGLikelihood swig_types[414]
#define SWIGTYPE_p_p_shogun__CLogitVGPiecewiseBoundLikelihood swig_types[415]
#define SWIGTYPE_p_p_shogun__CLossFunction swig_types[416]
#define SWIGTYPE_p_p_shogun__CMAPInferImpl swig_types[417]
#define SWIGTYPE_p_p_shogun__CMAPInference swig_types[418]
#define SWIGTYPE_p_p_shogun__CMCLDA swig_types[419]
#define SWIGTYPE_p_p_shogun__CMKL swig_types[420]
#define SWIGTYPE_p_p_shogun__CMKLClassification swig_types[421]
#define SWIGTYPE_p_p_shogun__CMKLMulticlass swig_types[422]
#define SWIGTYPE_p_p_shogun__CMKLOneClass swig_types[423]
#define SWIGTYPE_p_p_shogun__CMKLRegression swig_types[424]
#define SWIGTYPE_p_p_shogun__CMMDKernelSelection swig_types[425]
#define SWIGTYPE_p_p_shogun__CMMDKernelSelectionComb swig_types[426]
#define SWIGTYPE_p_p_shogun__CMMDKernelSelectionCombMaxL2 swig_types[427]
#define SWIGTYPE_p_p_shogun__CMMDKernelSelectionCombOpt swig_types[428]
#define SWIGTYPE_p_p_shogun__CMMDKernelSelectionMax swig_types[429]
#define SWIGTYPE_p_p_shogun__CMMDKernelSelectionMedian swig_types[430]
#define SWIGTYPE_p_p_shogun__CMMDKernelSelectionOpt swig_types[431]
#define SWIGTYPE_p_p_shogun__CMPDSVM swig_types[432]
#define SWIGTYPE_p_p_shogun__CMachine swig_types[433]
#define SWIGTYPE_p_p_shogun__CMachineEvaluation swig_types[434]
#define SWIGTYPE_p_p_shogun__CMahalanobisDistance swig_types[435]
#define SWIGTYPE_p_p_shogun__CMajorityVote swig_types[436]
#define SWIGTYPE_p_p_shogun__CManhattanMetric swig_types[437]
#define SWIGTYPE_p_p_shogun__CManhattanWordDistance swig_types[438]
#define SWIGTYPE_p_p_shogun__CManifoldSculpting swig_types[439]
#define SWIGTYPE_p_p_shogun__CMatchWordStringKernel swig_types[440]
#define SWIGTYPE_p_p_shogun__CMath swig_types[441]
#define SWIGTYPE_p_p_shogun__CMatrixFeaturesT_bool_t swig_types[442]
#define SWIGTYPE_p_p_shogun__CMatrixFeaturesT_char_t swig_types[443]
#define SWIGTYPE_p_p_shogun__CMatrixFeaturesT_double_t swig_types[444]
#define SWIGTYPE_p_p_shogun__CMatrixFeaturesT_float_t swig_types[445]
#define SWIGTYPE_p_p_shogun__CMatrixFeaturesT_int_t swig_types[446]
#define SWIGTYPE_p_p_shogun__CMatrixFeaturesT_long_t swig_types[447]
#define SWIGTYPE_p_p_shogun__CMatrixFeaturesT_unsigned_char_t swig_types[448]
#define SWIGTYPE_p_p_shogun__CMatrixFeaturesT_unsigned_long_t swig_types[449]
#define SWIGTYPE_p_p_shogun__CMatrixFeaturesT_unsigned_short_t swig_types[450]
#define SWIGTYPE_p_p_shogun__CMatrixOperatorT_double_t swig_types[451]
#define SWIGTYPE_p_p_shogun__CMatrixOperatorT_std__complexT_double_t_t swig_types[452]
#define SWIGTYPE_p_p_shogun__CMeanAbsoluteError swig_types[453]
#define SWIGTYPE_p_p_shogun__CMeanFunction swig_types[454]
#define SWIGTYPE_p_p_shogun__CMeanRule swig_types[455]
#define SWIGTYPE_p_p_shogun__CMeanShiftDataGenerator swig_types[456]
#define SWIGTYPE_p_p_shogun__CMeanSquaredError swig_types[457]
#define SWIGTYPE_p_p_shogun__CMeanSquaredLogError swig_types[458]
#define SWIGTYPE_p_p_shogun__CMinkowskiMetric swig_types[459]
#define SWIGTYPE_p_p_shogun__CModelSelection swig_types[460]
#define SWIGTYPE_p_p_shogun__CModelSelectionParameters swig_types[461]
#define SWIGTYPE_p_p_shogun__CMultiLaplaceInferenceMethod swig_types[462]
#define SWIGTYPE_p_p_shogun__CMulticlassAccuracy swig_types[463]
#define SWIGTYPE_p_p_shogun__CMulticlassLabels swig_types[464]
#define SWIGTYPE_p_p_shogun__CMulticlassLibLinear swig_types[465]
#define SWIGTYPE_p_p_shogun__CMulticlassLibSVM swig_types[466]
#define SWIGTYPE_p_p_shogun__CMulticlassLogisticRegression swig_types[467]
#define SWIGTYPE_p_p_shogun__CMulticlassMachine swig_types[468]
#define SWIGTYPE_p_p_shogun__CMulticlassModel swig_types[469]
#define SWIGTYPE_p_p_shogun__CMulticlassOCAS swig_types[470]
#define SWIGTYPE_p_p_shogun__CMulticlassOVREvaluation swig_types[471]
#define SWIGTYPE_p_p_shogun__CMulticlassOneVsOneStrategy swig_types[472]
#define SWIGTYPE_p_p_shogun__CMulticlassOneVsRestStrategy swig_types[473]
#define SWIGTYPE_p_p_shogun__CMulticlassSOLabels swig_types[474]
#define SWIGTYPE_p_p_shogun__CMulticlassSVM swig_types[475]
#define SWIGTYPE_p_p_shogun__CMulticlassStrategy swig_types[476]
#define SWIGTYPE_p_p_shogun__CMulticlassTreeGuidedLogisticRegression swig_types[477]
#define SWIGTYPE_p_p_shogun__CMultidimensionalScaling swig_types[478]
#define SWIGTYPE_p_p_shogun__CMultilabelCLRModel swig_types[479]
#define SWIGTYPE_p_p_shogun__CMultilabelLabels swig_types[480]
#define SWIGTYPE_p_p_shogun__CMultilabelModel swig_types[481]
#define SWIGTYPE_p_p_shogun__CMultilabelSOLabels swig_types[482]
#define SWIGTYPE_p_p_shogun__CMultiquadricKernel swig_types[483]
#define SWIGTYPE_p_p_shogun__CMultitaskClusteredLogisticRegression swig_types[484]
#define SWIGTYPE_p_p_shogun__CMultitaskKernelMaskNormalizer swig_types[485]
#define SWIGTYPE_p_p_shogun__CMultitaskKernelMaskPairNormalizer swig_types[486]
#define SWIGTYPE_p_p_shogun__CMultitaskKernelMklNormalizer swig_types[487]
#define SWIGTYPE_p_p_shogun__CMultitaskKernelNormalizer swig_types[488]
#define SWIGTYPE_p_p_shogun__CMultitaskKernelPlifNormalizer swig_types[489]
#define SWIGTYPE_p_p_shogun__CMultitaskKernelTreeNormalizer swig_types[490]
#define SWIGTYPE_p_p_shogun__CMultitaskL12LogisticRegression swig_types[491]
#define SWIGTYPE_p_p_shogun__CMultitaskLeastSquaresRegression swig_types[492]
#define SWIGTYPE_p_p_shogun__CMultitaskLinearMachine swig_types[493]
#define SWIGTYPE_p_p_shogun__CMultitaskLogisticRegression swig_types[494]
#define SWIGTYPE_p_p_shogun__CMultitaskROCEvaluation swig_types[495]
#define SWIGTYPE_p_p_shogun__CMultitaskTraceLogisticRegression swig_types[496]
#define SWIGTYPE_p_p_shogun__CNGramTokenizer swig_types[497]
#define SWIGTYPE_p_p_shogun__CNOCCO swig_types[498]
#define SWIGTYPE_p_p_shogun__CNativeMulticlassMachine swig_types[499]
#define SWIGTYPE_p_p_shogun__CNeighborhoodPreservingEmbedding swig_types[500]
#define SWIGTYPE_p_p_shogun__CNeuralConvolutionalLayer swig_types[501]
#define SWIGTYPE_p_p_shogun__CNeuralInputLayer swig_types[502]
#define SWIGTYPE_p_p_shogun__CNeuralLayer swig_types[503]
#define SWIGTYPE_p_p_shogun__CNeuralLayers swig_types[504]
#define SWIGTYPE_p_p_shogun__CNeuralLinearLayer swig_types[505]
#define SWIGTYPE_p_p_shogun__CNeuralLogisticLayer swig_types[506]
#define SWIGTYPE_p_p_shogun__CNeuralNetwork swig_types[507]
#define SWIGTYPE_p_p_shogun__CNeuralRectifiedLinearLayer swig_types[508]
#define SWIGTYPE_p_p_shogun__CNeuralSoftmaxLayer swig_types[509]
#define SWIGTYPE_p_p_shogun__CNewtonSVM swig_types[510]
#define SWIGTYPE_p_p_shogun__CNode swig_types[511]
#define SWIGTYPE_p_p_shogun__CNormOne swig_types[512]
#define SWIGTYPE_p_p_shogun__CNormalSampler swig_types[513]
#define SWIGTYPE_p_p_shogun__CNumericalVGLikelihood swig_types[514]
#define SWIGTYPE_p_p_shogun__COligoStringKernel swig_types[515]
#define SWIGTYPE_p_p_shogun__COnlineLibLinear swig_types[516]
#define SWIGTYPE_p_p_shogun__COnlineLinearMachine swig_types[517]
#define SWIGTYPE_p_p_shogun__COnlineSVMSGD swig_types[518]
#define SWIGTYPE_p_p_shogun__COperatorFunctionT_double_t swig_types[519]
#define SWIGTYPE_p_p_shogun__CPCA swig_types[520]
#define SWIGTYPE_p_p_shogun__CPNorm swig_types[521]
#define SWIGTYPE_p_p_shogun__CPRCEvaluation swig_types[522]
#define SWIGTYPE_p_p_shogun__CParameterCombination swig_types[523]
#define SWIGTYPE_p_p_shogun__CPerceptron swig_types[524]
#define SWIGTYPE_p_p_shogun__CPeriodicKernel swig_types[525]
#define SWIGTYPE_p_p_shogun__CPlif swig_types[526]
#define SWIGTYPE_p_p_shogun__CPlifArray swig_types[527]
#define SWIGTYPE_p_p_shogun__CPlifBase swig_types[528]
#define SWIGTYPE_p_p_shogun__CPlifMatrix swig_types[529]
#define SWIGTYPE_p_p_shogun__CPluginEstimate swig_types[530]
#define SWIGTYPE_p_p_shogun__CPolyFeatures swig_types[531]
#define SWIGTYPE_p_p_shogun__CPolyKernel swig_types[532]
#define SWIGTYPE_p_p_shogun__CPolyMatchStringKernel swig_types[533]
#define SWIGTYPE_p_p_shogun__CPolyMatchWordStringKernel swig_types[534]
#define SWIGTYPE_p_p_shogun__CPositionalPWM swig_types[535]
#define SWIGTYPE_p_p_shogun__CPowerKernel swig_types[536]
#define SWIGTYPE_p_p_shogun__CPrecisionMeasure swig_types[537]
#define SWIGTYPE_p_p_shogun__CPreprocessor swig_types[538]
#define SWIGTYPE_p_p_shogun__CProbabilityDistribution swig_types[539]
#define SWIGTYPE_p_p_shogun__CProbitLikelihood swig_types[540]
#define SWIGTYPE_p_p_shogun__CProbitVGLikelihood swig_types[541]
#define SWIGTYPE_p_p_shogun__CProductKernel swig_types[542]
#define SWIGTYPE_p_p_shogun__CPruneVarSubMean swig_types[543]
#define SWIGTYPE_p_p_shogun__CPyramidChi2 swig_types[544]
#define SWIGTYPE_p_p_shogun__CQDA swig_types[545]
#define SWIGTYPE_p_p_shogun__CQuadraticTimeMMD swig_types[546]
#define SWIGTYPE_p_p_shogun__CRBM swig_types[547]
#define SWIGTYPE_p_p_shogun__CROCEvaluation swig_types[548]
#define SWIGTYPE_p_p_shogun__CRandomConditionalProbabilityTree swig_types[549]
#define SWIGTYPE_p_p_shogun__CRandomForest swig_types[550]
#define SWIGTYPE_p_p_shogun__CRandomFourierDotFeatures swig_types[551]
#define SWIGTYPE_p_p_shogun__CRandomFourierGaussPreproc swig_types[552]
#define SWIGTYPE_p_p_shogun__CRandomKitchenSinksDotFeatures swig_types[553]
#define SWIGTYPE_p_p_shogun__CRandomSearchModelSelection swig_types[554]
#define SWIGTYPE_p_p_shogun__CRationalApproximation swig_types[555]
#define SWIGTYPE_p_p_shogun__CRationalQuadraticKernel swig_types[556]
#define SWIGTYPE_p_p_shogun__CRealDistance swig_types[557]
#define SWIGTYPE_p_p_shogun__CRealFileFeatures swig_types[558]
#define SWIGTYPE_p_p_shogun__CRealNumber swig_types[559]
#define SWIGTYPE_p_p_shogun__CRecallMeasure swig_types[560]
#define SWIGTYPE_p_p_shogun__CRegressionLabels swig_types[561]
#define SWIGTYPE_p_p_shogun__CRegulatoryModulesStringKernel swig_types[562]
#define SWIGTYPE_p_p_shogun__CRejectionStrategy swig_types[563]
#define SWIGTYPE_p_p_shogun__CRelaxedTree swig_types[564]
#define SWIGTYPE_p_p_shogun__CRescaleFeatures swig_types[565]
#define SWIGTYPE_p_p_shogun__CResultSet swig_types[566]
#define SWIGTYPE_p_p_shogun__CRidgeKernelNormalizer swig_types[567]
#define SWIGTYPE_p_p_shogun__CSGDQN swig_types[568]
#define SWIGTYPE_p_p_shogun__CSGObject swig_types[569]
#define SWIGTYPE_p_p_shogun__CSNPFeatures swig_types[570]
#define SWIGTYPE_p_p_shogun__CSNPStringKernel swig_types[571]
#define SWIGTYPE_p_p_shogun__CSOBI swig_types[572]
#define SWIGTYPE_p_p_shogun__CSOSVMHelper swig_types[573]
#define SWIGTYPE_p_p_shogun__CSVM swig_types[574]
#define SWIGTYPE_p_p_shogun__CSVMLight swig_types[575]
#define SWIGTYPE_p_p_shogun__CSVMLightOneClass swig_types[576]
#define SWIGTYPE_p_p_shogun__CSVMLin swig_types[577]
#define SWIGTYPE_p_p_shogun__CSVMOcas swig_types[578]
#define SWIGTYPE_p_p_shogun__CSVMSGD swig_types[579]
#define SWIGTYPE_p_p_shogun__CSVRLight swig_types[580]
#define SWIGTYPE_p_p_shogun__CSalzbergWordStringKernel swig_types[581]
#define SWIGTYPE_p_p_shogun__CScalarResultT_bool_t swig_types[582]
#define SWIGTYPE_p_p_shogun__CScalarResultT_char_t swig_types[583]
#define SWIGTYPE_p_p_shogun__CScalarResultT_double_t swig_types[584]
#define SWIGTYPE_p_p_shogun__CScalarResultT_float_t swig_types[585]
#define SWIGTYPE_p_p_shogun__CScalarResultT_int_t swig_types[586]
#define SWIGTYPE_p_p_shogun__CScalarResultT_long_t swig_types[587]
#define SWIGTYPE_p_p_shogun__CScalarResultT_unsigned_char_t swig_types[588]
#define SWIGTYPE_p_p_shogun__CScalarResultT_unsigned_long_t swig_types[589]
#define SWIGTYPE_p_p_shogun__CScalarResultT_unsigned_short_t swig_types[590]
#define SWIGTYPE_p_p_shogun__CScatterKernelNormalizer swig_types[591]
#define SWIGTYPE_p_p_shogun__CScatterSVM swig_types[592]
#define SWIGTYPE_p_p_shogun__CSegmentLoss swig_types[593]
#define SWIGTYPE_p_p_shogun__CSequence swig_types[594]
#define SWIGTYPE_p_p_shogun__CSequenceLabels swig_types[595]
#define SWIGTYPE_p_p_shogun__CSerialComputationEngine swig_types[596]
#define SWIGTYPE_p_p_shogun__CSerializableAsciiFile swig_types[597]
#define SWIGTYPE_p_p_shogun__CSerializableFile swig_types[598]
#define SWIGTYPE_p_p_shogun__CSerializableHdf5File swig_types[599]
#define SWIGTYPE_p_p_shogun__CSerializableXmlFile swig_types[600]
#define SWIGTYPE_p_p_shogun__CShareBoost swig_types[601]
#define SWIGTYPE_p_p_shogun__CShiftInvariantKernel swig_types[602]
#define SWIGTYPE_p_p_shogun__CSigmoidKernel swig_types[603]
#define SWIGTYPE_p_p_shogun__CSignal swig_types[604]
#define SWIGTYPE_p_p_shogun__CSimpleLocalityImprovedStringKernel swig_types[605]
#define SWIGTYPE_p_p_shogun__CSingleFITCInference swig_types[606]
#define SWIGTYPE_p_p_shogun__CSingleFITCLaplaceInferenceMethod swig_types[607]
#define SWIGTYPE_p_p_shogun__CSingleFITCLaplaceNewtonOptimizer swig_types[608]
#define SWIGTYPE_p_p_shogun__CSingleLaplaceInferenceMethod swig_types[609]
#define SWIGTYPE_p_p_shogun__CSingleLaplaceNewtonOptimizer swig_types[610]
#define SWIGTYPE_p_p_shogun__CSingleSparseInference swig_types[611]
#define SWIGTYPE_p_p_shogun__CSmoothHingeLoss swig_types[612]
#define SWIGTYPE_p_p_shogun__CSoftMaxLikelihood swig_types[613]
#define SWIGTYPE_p_p_shogun__CSortUlongString swig_types[614]
#define SWIGTYPE_p_p_shogun__CSortWordString swig_types[615]
#define SWIGTYPE_p_p_shogun__CSparseDistanceT_char_t swig_types[616]
#define SWIGTYPE_p_p_shogun__CSparseDistanceT_double_t swig_types[617]
#define SWIGTYPE_p_p_shogun__CSparseDistanceT_int_t swig_types[618]
#define SWIGTYPE_p_p_shogun__CSparseDistanceT_unsigned_short_t swig_types[619]
#define SWIGTYPE_p_p_shogun__CSparseEuclideanDistance swig_types[620]
#define SWIGTYPE_p_p_shogun__CSparseFeaturesT_bool_t swig_types[621]
#define SWIGTYPE_p_p_shogun__CSparseFeaturesT_char_t swig_types[622]
#define SWIGTYPE_p_p_shogun__CSparseFeaturesT_double_t swig_types[623]
#define SWIGTYPE_p_p_shogun__CSparseFeaturesT_float_t swig_types[624]
#define SWIGTYPE_p_p_shogun__CSparseFeaturesT_int_t swig_types[625]
#define SWIGTYPE_p_p_shogun__CSparseFeaturesT_long_t swig_types[626]
#define SWIGTYPE_p_p_shogun__CSparseFeaturesT_unsigned_char_t swig_types[627]
#define SWIGTYPE_p_p_shogun__CSparseFeaturesT_unsigned_long_t swig_types[628]
#define SWIGTYPE_p_p_shogun__CSparseFeaturesT_unsigned_short_t swig_types[629]
#define SWIGTYPE_p_p_shogun__CSparseInference swig_types[630]
#define SWIGTYPE_p_p_shogun__CSparseInverseCovariance swig_types[631]
#define SWIGTYPE_p_p_shogun__CSparseKernelT_double_t swig_types[632]
#define SWIGTYPE_p_p_shogun__CSparseKernelT_unsigned_short_t swig_types[633]
#define SWIGTYPE_p_p_shogun__CSparseMatrixOperatorT_double_t swig_types[634]
#define SWIGTYPE_p_p_shogun__CSparseMatrixOperatorT_std__complexT_double_t_t swig_types[635]
#define SWIGTYPE_p_p_shogun__CSparseMultilabel swig_types[636]
#define SWIGTYPE_p_p_shogun__CSparsePolyFeatures swig_types[637]
#define SWIGTYPE_p_p_shogun__CSparseSpatialSampleStringKernel swig_types[638]
#define SWIGTYPE_p_p_shogun__CSpecificityMeasure swig_types[639]
#define SWIGTYPE_p_p_shogun__CSpectrumMismatchRBFKernel swig_types[640]
#define SWIGTYPE_p_p_shogun__CSphericalKernel swig_types[641]
#define SWIGTYPE_p_p_shogun__CSplineKernel swig_types[642]
#define SWIGTYPE_p_p_shogun__CSplittingStrategy swig_types[643]
#define SWIGTYPE_p_p_shogun__CSqrtDiagKernelNormalizer swig_types[644]
#define SWIGTYPE_p_p_shogun__CSquaredHingeLoss swig_types[645]
#define SWIGTYPE_p_p_shogun__CSquaredLoss swig_types[646]
#define SWIGTYPE_p_p_shogun__CStateModel swig_types[647]
#define SWIGTYPE_p_p_shogun__CStatistics swig_types[648]
#define SWIGTYPE_p_p_shogun__CStochasticGBMachine swig_types[649]
#define SWIGTYPE_p_p_shogun__CStochasticProximityEmbedding swig_types[650]
#define SWIGTYPE_p_p_shogun__CStochasticSOSVM swig_types[651]
#define SWIGTYPE_p_p_shogun__CStratifiedCrossValidationSplitting swig_types[652]
#define SWIGTYPE_p_p_shogun__CStreamingAsciiFile swig_types[653]
#define SWIGTYPE_p_p_shogun__CStreamingDenseFeaturesT_bool_t swig_types[654]
#define SWIGTYPE_p_p_shogun__CStreamingDenseFeaturesT_char_t swig_types[655]
#define SWIGTYPE_p_p_shogun__CStreamingDenseFeaturesT_double_t swig_types[656]
#define SWIGTYPE_p_p_shogun__CStreamingDenseFeaturesT_float_t swig_types[657]
#define SWIGTYPE_p_p_shogun__CStreamingDenseFeaturesT_int_t swig_types[658]
#define SWIGTYPE_p_p_shogun__CStreamingDenseFeaturesT_long_t swig_types[659]
#define SWIGTYPE_p_p_shogun__CStreamingDenseFeaturesT_unsigned_char_t swig_types[660]
#define SWIGTYPE_p_p_shogun__CStreamingDenseFeaturesT_unsigned_long_t swig_types[661]
#define SWIGTYPE_p_p_shogun__CStreamingDenseFeaturesT_unsigned_short_t swig_types[662]
#define SWIGTYPE_p_p_shogun__CStreamingDotFeatures swig_types[663]
#define SWIGTYPE_p_p_shogun__CStreamingFeatures swig_types[664]
#define SWIGTYPE_p_p_shogun__CStreamingFile swig_types[665]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromDenseFeaturesT_bool_t swig_types[666]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromDenseFeaturesT_char_t swig_types[667]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromDenseFeaturesT_double_t swig_types[668]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromDenseFeaturesT_float_t swig_types[669]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromDenseFeaturesT_int_t swig_types[670]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromDenseFeaturesT_long_t swig_types[671]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_char_t swig_types[672]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_long_t swig_types[673]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_short_t swig_types[674]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromFeatures swig_types[675]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromSparseFeaturesT_bool_t swig_types[676]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromSparseFeaturesT_char_t swig_types[677]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromSparseFeaturesT_double_t swig_types[678]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromSparseFeaturesT_float_t swig_types[679]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromSparseFeaturesT_int_t swig_types[680]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromSparseFeaturesT_long_t swig_types[681]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_char_t swig_types[682]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_long_t swig_types[683]
#define SWIGTYPE_p_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_short_t swig_types[684]
#define SWIGTYPE_p_p_shogun__CStreamingHashedDocDotFeatures swig_types[685]
#define SWIGTYPE_p_p_shogun__CStreamingMMD swig_types[686]
#define SWIGTYPE_p_p_shogun__CStreamingSparseFeaturesT_bool_t swig_types[687]
#define SWIGTYPE_p_p_shogun__CStreamingSparseFeaturesT_char_t swig_types[688]
#define SWIGTYPE_p_p_shogun__CStreamingSparseFeaturesT_double_t swig_types[689]
#define SWIGTYPE_p_p_shogun__CStreamingSparseFeaturesT_float_t swig_types[690]
#define SWIGTYPE_p_p_shogun__CStreamingSparseFeaturesT_int_t swig_types[691]
#define SWIGTYPE_p_p_shogun__CStreamingSparseFeaturesT_long_t swig_types[692]
#define SWIGTYPE_p_p_shogun__CStreamingSparseFeaturesT_unsigned_char_t swig_types[693]
#define SWIGTYPE_p_p_shogun__CStreamingSparseFeaturesT_unsigned_long_t swig_types[694]
#define SWIGTYPE_p_p_shogun__CStreamingSparseFeaturesT_unsigned_short_t swig_types[695]
#define SWIGTYPE_p_p_shogun__CStreamingStringFeaturesT_bool_t swig_types[696]
#define SWIGTYPE_p_p_shogun__CStreamingStringFeaturesT_char_t swig_types[697]
#define SWIGTYPE_p_p_shogun__CStreamingStringFeaturesT_double_t swig_types[698]
#define SWIGTYPE_p_p_shogun__CStreamingStringFeaturesT_float_t swig_types[699]
#define SWIGTYPE_p_p_shogun__CStreamingStringFeaturesT_int_t swig_types[700]
#define SWIGTYPE_p_p_shogun__CStreamingStringFeaturesT_long_t swig_types[701]
#define SWIGTYPE_p_p_shogun__CStreamingStringFeaturesT_unsigned_char_t swig_types[702]
#define SWIGTYPE_p_p_shogun__CStreamingStringFeaturesT_unsigned_long_t swig_types[703]
#define SWIGTYPE_p_p_shogun__CStreamingStringFeaturesT_unsigned_short_t swig_types[704]
#define SWIGTYPE_p_p_shogun__CStreamingVwCacheFile swig_types[705]
#define SWIGTYPE_p_p_shogun__CStreamingVwFeatures swig_types[706]
#define SWIGTYPE_p_p_shogun__CStreamingVwFile swig_types[707]
#define SWIGTYPE_p_p_shogun__CStringDistanceT_char_t swig_types[708]
#define SWIGTYPE_p_p_shogun__CStringDistanceT_double_t swig_types[709]
#define SWIGTYPE_p_p_shogun__CStringDistanceT_int_t swig_types[710]
#define SWIGTYPE_p_p_shogun__CStringDistanceT_unsigned_long_t swig_types[711]
#define SWIGTYPE_p_p_shogun__CStringDistanceT_unsigned_short_t swig_types[712]
#define SWIGTYPE_p_p_shogun__CStringFeaturesT_bool_t swig_types[713]
#define SWIGTYPE_p_p_shogun__CStringFeaturesT_char_t swig_types[714]
#define SWIGTYPE_p_p_shogun__CStringFeaturesT_double_t swig_types[715]
#define SWIGTYPE_p_p_shogun__CStringFeaturesT_float_t swig_types[716]
#define SWIGTYPE_p_p_shogun__CStringFeaturesT_int_t swig_types[717]
#define SWIGTYPE_p_p_shogun__CStringFeaturesT_long_t swig_types[718]
#define SWIGTYPE_p_p_shogun__CStringFeaturesT_unsigned_char_t swig_types[719]
#define SWIGTYPE_p_p_shogun__CStringFeaturesT_unsigned_long_t swig_types[720]
#define SWIGTYPE_p_p_shogun__CStringFeaturesT_unsigned_short_t swig_types[721]
#define SWIGTYPE_p_p_shogun__CStringFileFeaturesT_bool_t swig_types[722]
#define SWIGTYPE_p_p_shogun__CStringFileFeaturesT_char_t swig_types[723]
#define SWIGTYPE_p_p_shogun__CStringFileFeaturesT_double_t swig_types[724]
#define SWIGTYPE_p_p_shogun__CStringFileFeaturesT_float_t swig_types[725]
#define SWIGTYPE_p_p_shogun__CStringFileFeaturesT_int_t swig_types[726]
#define SWIGTYPE_p_p_shogun__CStringFileFeaturesT_long_t swig_types[727]
#define SWIGTYPE_p_p_shogun__CStringFileFeaturesT_unsigned_char_t swig_types[728]
#define SWIGTYPE_p_p_shogun__CStringFileFeaturesT_unsigned_long_t swig_types[729]
#define SWIGTYPE_p_p_shogun__CStringFileFeaturesT_unsigned_short_t swig_types[730]
#define SWIGTYPE_p_p_shogun__CStringKernelT_char_t swig_types[731]
#define SWIGTYPE_p_p_shogun__CStringKernelT_double_t swig_types[732]
#define SWIGTYPE_p_p_shogun__CStringKernelT_short_t swig_types[733]
#define SWIGTYPE_p_p_shogun__CStringKernelT_unsigned_char_t swig_types[734]
#define SWIGTYPE_p_p_shogun__CStringKernelT_unsigned_long_t swig_types[735]
#define SWIGTYPE_p_p_shogun__CStringKernelT_unsigned_short_t swig_types[736]
#define SWIGTYPE_p_p_shogun__CStringPreprocessorT_char_t swig_types[737]
#define SWIGTYPE_p_p_shogun__CStringPreprocessorT_unsigned_char_t swig_types[738]
#define SWIGTYPE_p_p_shogun__CStringPreprocessorT_unsigned_long_t swig_types[739]
#define SWIGTYPE_p_p_shogun__CStringPreprocessorT_unsigned_short_t swig_types[740]
#define SWIGTYPE_p_p_shogun__CStructuredAccuracy swig_types[741]
#define SWIGTYPE_p_p_shogun__CStructuredData swig_types[742]
#define SWIGTYPE_p_p_shogun__CStructuredLabels swig_types[743]
#define SWIGTYPE_p_p_shogun__CStructuredModel swig_types[744]
#define SWIGTYPE_p_p_shogun__CStructuredOutputMachine swig_types[745]
#define SWIGTYPE_p_p_shogun__CStudentsTLikelihood swig_types[746]
#define SWIGTYPE_p_p_shogun__CStudentsTVGLikelihood swig_types[747]
#define SWIGTYPE_p_p_shogun__CSubsequenceStringKernel swig_types[748]
#define SWIGTYPE_p_p_shogun__CSumOne swig_types[749]
#define SWIGTYPE_p_p_shogun__CTDistributedStochasticNeighborEmbedding swig_types[750]
#define SWIGTYPE_p_p_shogun__CTOPFeatures swig_types[751]
#define SWIGTYPE_p_p_shogun__CTStudentKernel swig_types[752]
#define SWIGTYPE_p_p_shogun__CTableFactorType swig_types[753]
#define SWIGTYPE_p_p_shogun__CTanimotoDistance swig_types[754]
#define SWIGTYPE_p_p_shogun__CTanimotoKernelNormalizer swig_types[755]
#define SWIGTYPE_p_p_shogun__CTask swig_types[756]
#define SWIGTYPE_p_p_shogun__CTaskGroup swig_types[757]
#define SWIGTYPE_p_p_shogun__CTaskRelation swig_types[758]
#define SWIGTYPE_p_p_shogun__CTaskTree swig_types[759]
#define SWIGTYPE_p_p_shogun__CTensorProductPairKernel swig_types[760]
#define SWIGTYPE_p_p_shogun__CThresholdRejectionStrategy swig_types[761]
#define SWIGTYPE_p_p_shogun__CTime swig_types[762]
#define SWIGTYPE_p_p_shogun__CTokenizer swig_types[763]
#define SWIGTYPE_p_p_shogun__CTraceSampler swig_types[764]
#define SWIGTYPE_p_p_shogun__CTreeMachineT_C45TreeNodeData_t swig_types[765]
#define SWIGTYPE_p_p_shogun__CTreeMachineT_CARTreeNodeData_t swig_types[766]
#define SWIGTYPE_p_p_shogun__CTreeMachineT_CHAIDTreeNodeData_t swig_types[767]
#define SWIGTYPE_p_p_shogun__CTreeMachineT_id3TreeNodeData_t swig_types[768]
#define SWIGTYPE_p_p_shogun__CTreeMachineT_shogun__ConditionalProbabilityTreeNodeData_t swig_types[769]
#define SWIGTYPE_p_p_shogun__CTreeMachineT_shogun__RelaxedTreeNodeData_t swig_types[770]
#define SWIGTYPE_p_p_shogun__CTwoSampleTest swig_types[771]
#define SWIGTYPE_p_p_shogun__CTwoStateModel swig_types[772]
#define SWIGTYPE_p_p_shogun__CUWedgeSep swig_types[773]
#define SWIGTYPE_p_p_shogun__CVarDTCInferenceMethod swig_types[774]
#define SWIGTYPE_p_p_shogun__CVarianceKernelNormalizer swig_types[775]
#define SWIGTYPE_p_p_shogun__CVariationalGaussianLikelihood swig_types[776]
#define SWIGTYPE_p_p_shogun__CVariationalLikelihood swig_types[777]
#define SWIGTYPE_p_p_shogun__CVectorResultT_bool_t swig_types[778]
#define SWIGTYPE_p_p_shogun__CVectorResultT_char_t swig_types[779]
#define SWIGTYPE_p_p_shogun__CVectorResultT_double_t swig_types[780]
#define SWIGTYPE_p_p_shogun__CVectorResultT_float_t swig_types[781]
#define SWIGTYPE_p_p_shogun__CVectorResultT_int_t swig_types[782]
#define SWIGTYPE_p_p_shogun__CVectorResultT_long_t swig_types[783]
#define SWIGTYPE_p_p_shogun__CVectorResultT_unsigned_char_t swig_types[784]
#define SWIGTYPE_p_p_shogun__CVectorResultT_unsigned_long_t swig_types[785]
#define SWIGTYPE_p_p_shogun__CVectorResultT_unsigned_short_t swig_types[786]
#define SWIGTYPE_p_p_shogun__CVowpalWabbit swig_types[787]
#define SWIGTYPE_p_p_shogun__CVwParser swig_types[788]
#define SWIGTYPE_p_p_shogun__CWDFeatures swig_types[789]
#define SWIGTYPE_p_p_shogun__CWDSVMOcas swig_types[790]
#define SWIGTYPE_p_p_shogun__CWRACCMeasure swig_types[791]
#define SWIGTYPE_p_p_shogun__CWaveKernel swig_types[792]
#define SWIGTYPE_p_p_shogun__CWaveletKernel swig_types[793]
#define SWIGTYPE_p_p_shogun__CWeightedCommWordStringKernel swig_types[794]
#define SWIGTYPE_p_p_shogun__CWeightedDegreePositionStringKernel swig_types[795]
#define SWIGTYPE_p_p_shogun__CWeightedDegreeRBFKernel swig_types[796]
#define SWIGTYPE_p_p_shogun__CWeightedDegreeStringKernel swig_types[797]
#define SWIGTYPE_p_p_shogun__CWeightedMajorityVote swig_types[798]
#define SWIGTYPE_p_p_shogun__CWrappedObjectArray swig_types[799]
#define SWIGTYPE_p_p_shogun__CZeroMean swig_types[800]
#define SWIGTYPE_p_p_shogun__CZeroMeanCenterKernelNormalizer swig_types[801]
#define SWIGTYPE_p_p_shogun__FirstOrderMinimizer swig_types[802]
#define SWIGTYPE_p_p_shogun__Minimizer swig_types[803]
#define SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_bool_t swig_types[804]
#define SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_char_t swig_types[805]
#define SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_double_t swig_types[806]
#define SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_float_t swig_types[807]
#define SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_int_t swig_types[808]
#define SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_long_t swig_types[809]
#define SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_unsigned_char_t swig_types[810]
#define SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_unsigned_long_t swig_types[811]
#define SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_unsigned_short_t swig_types[812]
#define SWIGTYPE_p_p_shogun__SGVectorT_int_t swig_types[813]
#define SWIGTYPE_p_p_shogun__VwExample swig_types[814]
#define SWIGTYPE_p_p_std__complexT_double_t swig_types[815]
#define SWIGTYPE_p_p_unsigned_char swig_types[816]
#define SWIGTYPE_p_p_unsigned_long swig_types[817]
#define SWIGTYPE_p_p_unsigned_short swig_types[818]
#define SWIGTYPE_p_p_void swig_types[819]
#define SWIGTYPE_p_shogun__BmrmStatistics swig_types[820]
#define SWIGTYPE_p_shogun__CANOVAKernel swig_types[821]
#define SWIGTYPE_p_shogun__CAUCKernel swig_types[822]
#define SWIGTYPE_p_shogun__CAccuracyMeasure swig_types[823]
#define SWIGTYPE_p_shogun__CAlphabet swig_types[824]
#define SWIGTYPE_p_shogun__CAttributeFeatures swig_types[825]
#define SWIGTYPE_p_shogun__CAutoencoder swig_types[826]
#define SWIGTYPE_p_shogun__CAveragedPerceptron swig_types[827]
#define SWIGTYPE_p_shogun__CAvgDiagKernelNormalizer swig_types[828]
#define SWIGTYPE_p_shogun__CBAHSIC swig_types[829]
#define SWIGTYPE_p_shogun__CBALMeasure swig_types[830]
#define SWIGTYPE_p_shogun__CBaggingMachine swig_types[831]
#define SWIGTYPE_p_shogun__CBalancedConditionalProbabilityTree swig_types[832]
#define SWIGTYPE_p_shogun__CBaseMulticlassMachine swig_types[833]
#define SWIGTYPE_p_shogun__CBesselKernel swig_types[834]
#define SWIGTYPE_p_shogun__CBinaryClassEvaluation swig_types[835]
#define SWIGTYPE_p_shogun__CBinaryFile swig_types[836]
#define SWIGTYPE_p_shogun__CBinaryLabels swig_types[837]
#define SWIGTYPE_p_shogun__CBinnedDotFeatures swig_types[838]
#define SWIGTYPE_p_shogun__CBrayCurtisDistance swig_types[839]
#define SWIGTYPE_p_shogun__CC45ClassifierTree swig_types[840]
#define SWIGTYPE_p_shogun__CCARTree swig_types[841]
#define SWIGTYPE_p_shogun__CCGMShiftedFamilySolver swig_types[842]
#define SWIGTYPE_p_shogun__CCHAIDTree swig_types[843]
#define SWIGTYPE_p_shogun__CCSVFile swig_types[844]
#define SWIGTYPE_p_shogun__CCanberraMetric swig_types[845]
#define SWIGTYPE_p_shogun__CCanberraWordDistance swig_types[846]
#define SWIGTYPE_p_shogun__CCauchyKernel swig_types[847]
#define SWIGTYPE_p_shogun__CChebyshewMetric swig_types[848]
#define SWIGTYPE_p_shogun__CChi2Kernel swig_types[849]
#define SWIGTYPE_p_shogun__CChiSquareDistance swig_types[850]
#define SWIGTYPE_p_shogun__CCircularKernel swig_types[851]
#define SWIGTYPE_p_shogun__CClusteringAccuracy swig_types[852]
#define SWIGTYPE_p_shogun__CClusteringEvaluation swig_types[853]
#define SWIGTYPE_p_shogun__CClusteringMutualInformation swig_types[854]
#define SWIGTYPE_p_shogun__CCombinationRule swig_types[855]
#define SWIGTYPE_p_shogun__CCombinedDotFeatures swig_types[856]
#define SWIGTYPE_p_shogun__CCombinedFeatures swig_types[857]
#define SWIGTYPE_p_shogun__CCombinedKernel swig_types[858]
#define SWIGTYPE_p_shogun__CCommUlongStringKernel swig_types[859]
#define SWIGTYPE_p_shogun__CCommWordStringKernel swig_types[860]
#define SWIGTYPE_p_shogun__CCompressor swig_types[861]
#define SWIGTYPE_p_shogun__CConditionalProbabilityTree swig_types[862]
#define SWIGTYPE_p_shogun__CConjugateGradientSolver swig_types[863]
#define SWIGTYPE_p_shogun__CConjugateOrthogonalCGSolver swig_types[864]
#define SWIGTYPE_p_shogun__CConstKernel swig_types[865]
#define SWIGTYPE_p_shogun__CConstMean swig_types[866]
#define SWIGTYPE_p_shogun__CContingencyTableEvaluation swig_types[867]
#define SWIGTYPE_p_shogun__CConverter swig_types[868]
#define SWIGTYPE_p_shogun__CConvolutionalFeatureMap swig_types[869]
#define SWIGTYPE_p_shogun__CCosineDistance swig_types[870]
#define SWIGTYPE_p_shogun__CCrossCorrelationMeasure swig_types[871]
#define SWIGTYPE_p_shogun__CCrossValidation swig_types[872]
#define SWIGTYPE_p_shogun__CCrossValidationMKLStorage swig_types[873]
#define SWIGTYPE_p_shogun__CCrossValidationMulticlassStorage swig_types[874]
#define SWIGTYPE_p_shogun__CCrossValidationOutput swig_types[875]
#define SWIGTYPE_p_shogun__CCrossValidationPrintOutput swig_types[876]
#define SWIGTYPE_p_shogun__CCrossValidationResult swig_types[877]
#define SWIGTYPE_p_shogun__CCrossValidationSplitting swig_types[878]
#define SWIGTYPE_p_shogun__CCustomDistance swig_types[879]
#define SWIGTYPE_p_shogun__CCustomKernel swig_types[880]
#define SWIGTYPE_p_shogun__CCustomMahalanobisDistance swig_types[881]
#define SWIGTYPE_p_shogun__CData swig_types[882]
#define SWIGTYPE_p_shogun__CDataGenerator swig_types[883]
#define SWIGTYPE_p_shogun__CDecompressStringT_char_t swig_types[884]
#define SWIGTYPE_p_shogun__CDecompressStringT_unsigned_char_t swig_types[885]
#define SWIGTYPE_p_shogun__CDecompressStringT_unsigned_long_t swig_types[886]
#define SWIGTYPE_p_shogun__CDecompressStringT_unsigned_short_t swig_types[887]
#define SWIGTYPE_p_shogun__CDeepAutoencoder swig_types[888]
#define SWIGTYPE_p_shogun__CDeepBeliefNetwork swig_types[889]
#define SWIGTYPE_p_shogun__CDelimiterTokenizer swig_types[890]
#define SWIGTYPE_p_shogun__CDenseDistanceT_char_t swig_types[891]
#define SWIGTYPE_p_shogun__CDenseDistanceT_double_t swig_types[892]
#define SWIGTYPE_p_shogun__CDenseDistanceT_int_t swig_types[893]
#define SWIGTYPE_p_shogun__CDenseDistanceT_unsigned_short_t swig_types[894]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_bool_t swig_types[895]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_char_t swig_types[896]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_double_t swig_types[897]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_float_t swig_types[898]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_int_t swig_types[899]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_long_t swig_types[900]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_unsigned_char_t swig_types[901]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_unsigned_int_t swig_types[902]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_unsigned_long_t swig_types[903]
#define SWIGTYPE_p_shogun__CDenseFeaturesT_unsigned_short_t swig_types[904]
#define SWIGTYPE_p_shogun__CDenseLabels swig_types[905]
#define SWIGTYPE_p_shogun__CDenseMatrixOperatorT_double_t swig_types[906]
#define SWIGTYPE_p_shogun__CDenseMatrixOperatorT_std__complexT_double_t_t swig_types[907]
#define SWIGTYPE_p_shogun__CDensePreprocessorT_char_t swig_types[908]
#define SWIGTYPE_p_shogun__CDensePreprocessorT_double_t swig_types[909]
#define SWIGTYPE_p_shogun__CDensePreprocessorT_unsigned_char_t swig_types[910]
#define SWIGTYPE_p_shogun__CDensePreprocessorT_unsigned_long_t swig_types[911]
#define SWIGTYPE_p_shogun__CDensePreprocessorT_unsigned_short_t swig_types[912]
#define SWIGTYPE_p_shogun__CDenseSubsetFeaturesT_bool_t swig_types[913]
#define SWIGTYPE_p_shogun__CDenseSubsetFeaturesT_char_t swig_types[914]
#define SWIGTYPE_p_shogun__CDenseSubsetFeaturesT_double_t swig_types[915]
#define SWIGTYPE_p_shogun__CDenseSubsetFeaturesT_float_t swig_types[916]
#define SWIGTYPE_p_shogun__CDenseSubsetFeaturesT_int_t swig_types[917]
#define SWIGTYPE_p_shogun__CDenseSubsetFeaturesT_long_t swig_types[918]
#define SWIGTYPE_p_shogun__CDenseSubsetFeaturesT_unsigned_char_t swig_types[919]
#define SWIGTYPE_p_shogun__CDenseSubsetFeaturesT_unsigned_long_t swig_types[920]
#define SWIGTYPE_p_shogun__CDenseSubsetFeaturesT_unsigned_short_t swig_types[921]
#define SWIGTYPE_p_shogun__CDependenceMaximization swig_types[922]
#define SWIGTYPE_p_shogun__CDiagKernel swig_types[923]
#define SWIGTYPE_p_shogun__CDiceKernelNormalizer swig_types[924]
#define SWIGTYPE_p_shogun__CDifferentiableFunction swig_types[925]
#define SWIGTYPE_p_shogun__CDiffusionMaps swig_types[926]
#define SWIGTYPE_p_shogun__CDimensionReductionPreprocessor swig_types[927]
#define SWIGTYPE_p_shogun__CDirectLinearSolverComplex swig_types[928]
#define SWIGTYPE_p_shogun__CDirectSparseLinearSolver swig_types[929]
#define SWIGTYPE_p_shogun__CDisjointSet swig_types[930]
#define SWIGTYPE_p_shogun__CDistance swig_types[931]
#define SWIGTYPE_p_shogun__CDistanceKernel swig_types[932]
#define SWIGTYPE_p_shogun__CDistanceMachine swig_types[933]
#define SWIGTYPE_p_shogun__CDistantSegmentsKernel swig_types[934]
#define SWIGTYPE_p_shogun__CDistribution swig_types[935]
#define SWIGTYPE_p_shogun__CDixonQTestRejectionStrategy swig_types[936]
#define SWIGTYPE_p_shogun__CDomainAdaptationMulticlassLibLinear swig_types[937]
#define SWIGTYPE_p_shogun__CDomainAdaptationSVM swig_types[938]
#define SWIGTYPE_p_shogun__CDomainAdaptationSVMLinear swig_types[939]
#define SWIGTYPE_p_shogun__CDotFeatures swig_types[940]
#define SWIGTYPE_p_shogun__CDotKernel swig_types[941]
#define SWIGTYPE_p_shogun__CDualLibQPBMSOSVM swig_types[942]
#define SWIGTYPE_p_shogun__CDualVariationalGaussianLikelihood swig_types[943]
#define SWIGTYPE_p_shogun__CDummyFeatures swig_types[944]
#define SWIGTYPE_p_shogun__CDynProg swig_types[945]
#define SWIGTYPE_p_shogun__CDynamicArrayT_char_t swig_types[946]
#define SWIGTYPE_p_shogun__CDynamicArrayT_double_t swig_types[947]
#define SWIGTYPE_p_shogun__CDynamicArrayT_float_t swig_types[948]
#define SWIGTYPE_p_shogun__CDynamicArrayT_int_t swig_types[949]
#define SWIGTYPE_p_shogun__CDynamicArrayT_long_t swig_types[950]
#define SWIGTYPE_p_shogun__CDynamicArrayT_unsigned_char_t swig_types[951]
#define SWIGTYPE_p_shogun__CDynamicArrayT_unsigned_long_t swig_types[952]
#define SWIGTYPE_p_shogun__CDynamicArrayT_unsigned_short_t swig_types[953]
#define SWIGTYPE_p_shogun__CDynamicObjectArray swig_types[954]
#define SWIGTYPE_p_shogun__CECOCAEDDecoder swig_types[955]
#define SWIGTYPE_p_shogun__CECOCDecoder swig_types[956]
#define SWIGTYPE_p_shogun__CECOCDiscriminantEncoder swig_types[957]
#define SWIGTYPE_p_shogun__CECOCEDDecoder swig_types[958]
#define SWIGTYPE_p_shogun__CECOCEncoder swig_types[959]
#define SWIGTYPE_p_shogun__CECOCForestEncoder swig_types[960]
#define SWIGTYPE_p_shogun__CECOCHDDecoder swig_types[961]
#define SWIGTYPE_p_shogun__CECOCIHDDecoder swig_types[962]
#define SWIGTYPE_p_shogun__CECOCLLBDecoder swig_types[963]
#define SWIGTYPE_p_shogun__CECOCOVOEncoder swig_types[964]
#define SWIGTYPE_p_shogun__CECOCOVREncoder swig_types[965]
#define SWIGTYPE_p_shogun__CECOCRandomDenseEncoder swig_types[966]
#define SWIGTYPE_p_shogun__CECOCRandomSparseEncoder swig_types[967]
#define SWIGTYPE_p_shogun__CECOCSimpleDecoder swig_types[968]
#define SWIGTYPE_p_shogun__CECOCStrategy swig_types[969]
#define SWIGTYPE_p_shogun__CEPInferenceMethod swig_types[970]
#define SWIGTYPE_p_shogun__CEigenSolver swig_types[971]
#define SWIGTYPE_p_shogun__CEmbeddingConverter swig_types[972]
#define SWIGTYPE_p_shogun__CErrorRateMeasure swig_types[973]
#define SWIGTYPE_p_shogun__CEuclideanDistance swig_types[974]
#define SWIGTYPE_p_shogun__CEvaluation swig_types[975]
#define SWIGTYPE_p_shogun__CEvaluationResult swig_types[976]
#define SWIGTYPE_p_shogun__CExactInferenceMethod swig_types[977]
#define SWIGTYPE_p_shogun__CExplicitSpecFeatures swig_types[978]
#define SWIGTYPE_p_shogun__CExponentialARDKernel swig_types[979]
#define SWIGTYPE_p_shogun__CExponentialKernel swig_types[980]
#define SWIGTYPE_p_shogun__CF1Measure swig_types[981]
#define SWIGTYPE_p_shogun__CFFSep swig_types[982]
#define SWIGTYPE_p_shogun__CFITCInferenceMethod swig_types[983]
#define SWIGTYPE_p_shogun__CFKFeatures swig_types[984]
#define SWIGTYPE_p_shogun__CFWSOSVM swig_types[985]
#define SWIGTYPE_p_shogun__CFactor swig_types[986]
#define SWIGTYPE_p_shogun__CFactorAnalysis swig_types[987]
#define SWIGTYPE_p_shogun__CFactorDataSource swig_types[988]
#define SWIGTYPE_p_shogun__CFactorGraph swig_types[989]
#define SWIGTYPE_p_shogun__CFactorGraphFeatures swig_types[990]
#define SWIGTYPE_p_shogun__CFactorGraphLabels swig_types[991]
#define SWIGTYPE_p_shogun__CFactorGraphModel swig_types[992]
#define SWIGTYPE_p_shogun__CFactorGraphObservation swig_types[993]
#define SWIGTYPE_p_shogun__CFactorType swig_types[994]
#define SWIGTYPE_p_shogun__CFastICA swig_types[995]
#define SWIGTYPE_p_shogun__CFeatureBlockLogisticRegression swig_types[996]
#define SWIGTYPE_p_shogun__CFeatureSelectionT_char_t swig_types[997]
#define SWIGTYPE_p_shogun__CFeatureSelectionT_double_t swig_types[998]
#define SWIGTYPE_p_shogun__CFeatureSelectionT_unsigned_char_t swig_types[999]
#define SWIGTYPE_p_shogun__CFeatureSelectionT_unsigned_long_t swig_types[1000]
#define SWIGTYPE_p_shogun__CFeatureSelectionT_unsigned_short_t swig_types[1001]
#define SWIGTYPE_p_shogun__CFeatures swig_types[1002]
#define SWIGTYPE_p_shogun__CFile swig_types[1003]
#define SWIGTYPE_p_shogun__CFisherLDA swig_types[1004]
#define SWIGTYPE_p_shogun__CFixedDegreeStringKernel swig_types[1005]
#define SWIGTYPE_p_shogun__CGCArrayT_shogun__CPlifBase_p_t swig_types[1006]
#define SWIGTYPE_p_shogun__CGMM swig_types[1007]
#define SWIGTYPE_p_shogun__CGMNPSVM swig_types[1008]
#define SWIGTYPE_p_shogun__CGNPPSVM swig_types[1009]
#define SWIGTYPE_p_shogun__CGPBTSVM swig_types[1010]
#define SWIGTYPE_p_shogun__CGaussian swig_types[1011]
#define SWIGTYPE_p_shogun__CGaussianARDKernel swig_types[1012]
#define SWIGTYPE_p_shogun__CGaussianARDSparseKernel swig_types[1013]
#define SWIGTYPE_p_shogun__CGaussianBlobsDataGenerator swig_types[1014]
#define SWIGTYPE_p_shogun__CGaussianDistribution swig_types[1015]
#define SWIGTYPE_p_shogun__CGaussianKernel swig_types[1016]
#define SWIGTYPE_p_shogun__CGaussianLikelihood swig_types[1017]
#define SWIGTYPE_p_shogun__CGaussianMatchStringKernel swig_types[1018]
#define SWIGTYPE_p_shogun__CGaussianNaiveBayes swig_types[1019]
#define SWIGTYPE_p_shogun__CGaussianProcessClassification swig_types[1020]
#define SWIGTYPE_p_shogun__CGaussianProcessMachine swig_types[1021]
#define SWIGTYPE_p_shogun__CGaussianProcessRegression swig_types[1022]
#define SWIGTYPE_p_shogun__CGaussianShiftKernel swig_types[1023]
#define SWIGTYPE_p_shogun__CGaussianShortRealKernel swig_types[1024]
#define SWIGTYPE_p_shogun__CGeodesicMetric swig_types[1025]
#define SWIGTYPE_p_shogun__CGradientCriterion swig_types[1026]
#define SWIGTYPE_p_shogun__CGradientEvaluation swig_types[1027]
#define SWIGTYPE_p_shogun__CGradientResult swig_types[1028]
#define SWIGTYPE_p_shogun__CGraphCut swig_types[1029]
#define SWIGTYPE_p_shogun__CGridSearchModelSelection swig_types[1030]
#define SWIGTYPE_p_shogun__CHDF5File swig_types[1031]
#define SWIGTYPE_p_shogun__CHMM swig_types[1032]
#define SWIGTYPE_p_shogun__CHMSVMModel swig_types[1033]
#define SWIGTYPE_p_shogun__CHSIC swig_types[1034]
#define SWIGTYPE_p_shogun__CHammingWordDistance swig_types[1035]
#define SWIGTYPE_p_shogun__CHash swig_types[1036]
#define SWIGTYPE_p_shogun__CHashedDocConverter swig_types[1037]
#define SWIGTYPE_p_shogun__CHashedDocDotFeatures swig_types[1038]
#define SWIGTYPE_p_shogun__CHashedMultilabelModel swig_types[1039]
#define SWIGTYPE_p_shogun__CHashedWDFeatures swig_types[1040]
#define SWIGTYPE_p_shogun__CHashedWDFeaturesTransposed swig_types[1041]
#define SWIGTYPE_p_shogun__CHessianLocallyLinearEmbedding swig_types[1042]
#define SWIGTYPE_p_shogun__CHierarchical swig_types[1043]
#define SWIGTYPE_p_shogun__CHierarchicalMultilabelModel swig_types[1044]
#define SWIGTYPE_p_shogun__CHingeLoss swig_types[1045]
#define SWIGTYPE_p_shogun__CHistogram swig_types[1046]
#define SWIGTYPE_p_shogun__CHistogramIntersectionKernel swig_types[1047]
#define SWIGTYPE_p_shogun__CHistogramWordStringKernel swig_types[1048]
#define SWIGTYPE_p_shogun__CHomogeneousKernelMap swig_types[1049]
#define SWIGTYPE_p_shogun__CHypothesisTest swig_types[1050]
#define SWIGTYPE_p_shogun__CICAConverter swig_types[1051]
#define SWIGTYPE_p_shogun__CID3ClassifierTree swig_types[1052]
#define SWIGTYPE_p_shogun__CIdentityKernelNormalizer swig_types[1053]
#define SWIGTYPE_p_shogun__CImplicitWeightedSpecFeatures swig_types[1054]
#define SWIGTYPE_p_shogun__CIndependenceTest swig_types[1055]
#define SWIGTYPE_p_shogun__CIndependentComputationEngine swig_types[1056]
#define SWIGTYPE_p_shogun__CIndependentJob swig_types[1057]
#define SWIGTYPE_p_shogun__CIndexBlock swig_types[1058]
#define SWIGTYPE_p_shogun__CIndexBlockGroup swig_types[1059]
#define SWIGTYPE_p_shogun__CIndexBlockRelation swig_types[1060]
#define SWIGTYPE_p_shogun__CIndexBlockTree swig_types[1061]
#define SWIGTYPE_p_shogun__CIndexFeatures swig_types[1062]
#define SWIGTYPE_p_shogun__CInference swig_types[1063]
#define SWIGTYPE_p_shogun__CIntronList swig_types[1064]
#define SWIGTYPE_p_shogun__CInverseMultiQuadricKernel swig_types[1065]
#define SWIGTYPE_p_shogun__CIsomap swig_types[1066]
#define SWIGTYPE_p_shogun__CIterativeLinearSolverT_double_double_t swig_types[1067]
#define SWIGTYPE_p_shogun__CIterativeLinearSolverT_std__complexT_double_t_double_t swig_types[1068]
#define SWIGTYPE_p_shogun__CIterativeShiftedLinearFamilySolverT_double_std__complexT_double_t_t swig_types[1069]
#define SWIGTYPE_p_shogun__CJade swig_types[1070]
#define SWIGTYPE_p_shogun__CJediSep swig_types[1071]
#define SWIGTYPE_p_shogun__CJensenMetric swig_types[1072]
#define SWIGTYPE_p_shogun__CJensenShannonKernel swig_types[1073]
#define SWIGTYPE_p_shogun__CJobResult swig_types[1074]
#define SWIGTYPE_p_shogun__CJobResultAggregator swig_types[1075]
#define SWIGTYPE_p_shogun__CKLCholeskyInferenceMethod swig_types[1076]
#define SWIGTYPE_p_shogun__CKLCovarianceInferenceMethod swig_types[1077]
#define SWIGTYPE_p_shogun__CKLDiagonalInferenceMethod swig_types[1078]
#define SWIGTYPE_p_shogun__CKLDualInferenceMethod swig_types[1079]
#define SWIGTYPE_p_shogun__CKLDualInferenceMethodMinimizer swig_types[1080]
#define SWIGTYPE_p_shogun__CKLInference swig_types[1081]
#define SWIGTYPE_p_shogun__CKLLowerTriangularInference swig_types[1082]
#define SWIGTYPE_p_shogun__CKMeans swig_types[1083]
#define SWIGTYPE_p_shogun__CKMeansBase swig_types[1084]
#define SWIGTYPE_p_shogun__CKMeansMiniBatch swig_types[1085]
#define SWIGTYPE_p_shogun__CKNN swig_types[1086]
#define SWIGTYPE_p_shogun__CKernel swig_types[1087]
#define SWIGTYPE_p_shogun__CKernelDensity swig_types[1088]
#define SWIGTYPE_p_shogun__CKernelDependenceMaximization swig_types[1089]
#define SWIGTYPE_p_shogun__CKernelDistance swig_types[1090]
#define SWIGTYPE_p_shogun__CKernelIndependenceTest swig_types[1091]
#define SWIGTYPE_p_shogun__CKernelLocallyLinearEmbedding swig_types[1092]
#define SWIGTYPE_p_shogun__CKernelMachine swig_types[1093]
#define SWIGTYPE_p_shogun__CKernelMeanMatching swig_types[1094]
#define SWIGTYPE_p_shogun__CKernelMulticlassMachine swig_types[1095]
#define SWIGTYPE_p_shogun__CKernelNormalizer swig_types[1096]
#define SWIGTYPE_p_shogun__CKernelPCA swig_types[1097]
#define SWIGTYPE_p_shogun__CKernelRidgeRegression swig_types[1098]
#define SWIGTYPE_p_shogun__CKernelSelection swig_types[1099]
#define SWIGTYPE_p_shogun__CKernelStructuredOutputMachine swig_types[1100]
#define SWIGTYPE_p_shogun__CKernelTwoSampleTest swig_types[1101]
#define SWIGTYPE_p_shogun__CLBFGSMinimizer swig_types[1102]
#define SWIGTYPE_p_shogun__CLBPPyrDotFeatures swig_types[1103]
#define SWIGTYPE_p_shogun__CLDA swig_types[1104]
#define SWIGTYPE_p_shogun__CLMNN swig_types[1105]
#define SWIGTYPE_p_shogun__CLMNNStatistics swig_types[1106]
#define SWIGTYPE_p_shogun__CLaRank swig_types[1107]
#define SWIGTYPE_p_shogun__CLabels swig_types[1108]
#define SWIGTYPE_p_shogun__CLabelsFactory swig_types[1109]
#define SWIGTYPE_p_shogun__CLanczosEigenSolver swig_types[1110]
#define SWIGTYPE_p_shogun__CLaplaceInference swig_types[1111]
#define SWIGTYPE_p_shogun__CLaplacianEigenmaps swig_types[1112]
#define SWIGTYPE_p_shogun__CLatentFeatures swig_types[1113]
#define SWIGTYPE_p_shogun__CLatentLabels swig_types[1114]
#define SWIGTYPE_p_shogun__CLatentModel swig_types[1115]
#define SWIGTYPE_p_shogun__CLatentSVM swig_types[1116]
#define SWIGTYPE_p_shogun__CLeastAngleRegression swig_types[1117]
#define SWIGTYPE_p_shogun__CLeastSquaresRegression swig_types[1118]
#define SWIGTYPE_p_shogun__CLibLinear swig_types[1119]
#define SWIGTYPE_p_shogun__CLibLinearMTL swig_types[1120]
#define SWIGTYPE_p_shogun__CLibLinearRegression swig_types[1121]
#define SWIGTYPE_p_shogun__CLibSVM swig_types[1122]
#define SWIGTYPE_p_shogun__CLibSVMFile swig_types[1123]
#define SWIGTYPE_p_shogun__CLibSVMOneClass swig_types[1124]
#define SWIGTYPE_p_shogun__CLibSVR swig_types[1125]
#define SWIGTYPE_p_shogun__CLikelihoodModel swig_types[1126]
#define SWIGTYPE_p_shogun__CLinearHMM swig_types[1127]
#define SWIGTYPE_p_shogun__CLinearKernel swig_types[1128]
#define SWIGTYPE_p_shogun__CLinearLatentMachine swig_types[1129]
#define SWIGTYPE_p_shogun__CLinearLocalTangentSpaceAlignment swig_types[1130]
#define SWIGTYPE_p_shogun__CLinearMachine swig_types[1131]
#define SWIGTYPE_p_shogun__CLinearMulticlassMachine swig_types[1132]
#define SWIGTYPE_p_shogun__CLinearOperatorT_double_t swig_types[1133]
#define SWIGTYPE_p_shogun__CLinearOperatorT_std__complexT_double_t_t swig_types[1134]
#define SWIGTYPE_p_shogun__CLinearRidgeRegression swig_types[1135]
#define SWIGTYPE_p_shogun__CLinearSolverT_double_double_t swig_types[1136]
#define SWIGTYPE_p_shogun__CLinearSolverT_std__complexT_double_t_double_t swig_types[1137]
#define SWIGTYPE_p_shogun__CLinearStringKernel swig_types[1138]
#define SWIGTYPE_p_shogun__CLinearStructuredOutputMachine swig_types[1139]
#define SWIGTYPE_p_shogun__CLinearTimeMMD swig_types[1140]
#define SWIGTYPE_p_shogun__CList swig_types[1141]
#define SWIGTYPE_p_shogun__CListElement swig_types[1142]
#define SWIGTYPE_p_shogun__CLocalAlignmentStringKernel swig_types[1143]
#define SWIGTYPE_p_shogun__CLocalTangentSpaceAlignment swig_types[1144]
#define SWIGTYPE_p_shogun__CLocalityImprovedStringKernel swig_types[1145]
#define SWIGTYPE_p_shogun__CLocalityPreservingProjections swig_types[1146]
#define SWIGTYPE_p_shogun__CLocallyLinearEmbedding swig_types[1147]
#define SWIGTYPE_p_shogun__CLogDetEstimator swig_types[1148]
#define SWIGTYPE_p_shogun__CLogKernel swig_types[1149]
#define SWIGTYPE_p_shogun__CLogLoss swig_types[1150]
#define SWIGTYPE_p_shogun__CLogLossMargin swig_types[1151]
#define SWIGTYPE_p_shogun__CLogPlusOne swig_types[1152]
#define SWIGTYPE_p_shogun__CLogRationalApproximationCGM swig_types[1153]
#define SWIGTYPE_p_shogun__CLogRationalApproximationIndividual swig_types[1154]
#define SWIGTYPE_p_shogun__CLogitDVGLikelihood swig_types[1155]
#define SWIGTYPE_p_shogun__CLogitLikelihood swig_types[1156]
#define SWIGTYPE_p_shogun__CLogitVGLikelihood swig_types[1157]
#define SWIGTYPE_p_shogun__CLogitVGPiecewiseBoundLikelihood swig_types[1158]
#define SWIGTYPE_p_shogun__CLossFunction swig_types[1159]
#define SWIGTYPE_p_shogun__CMAPInferImpl swig_types[1160]
#define SWIGTYPE_p_shogun__CMAPInference swig_types[1161]
#define SWIGTYPE_p_shogun__CMCLDA swig_types[1162]
#define SWIGTYPE_p_shogun__CMKL swig_types[1163]
#define SWIGTYPE_p_shogun__CMKLClassification swig_types[1164]
#define SWIGTYPE_p_shogun__CMKLMulticlass swig_types[1165]
#define SWIGTYPE_p_shogun__CMKLOneClass swig_types[1166]
#define SWIGTYPE_p_shogun__CMKLRegression swig_types[1167]
#define SWIGTYPE_p_shogun__CMMDKernelSelection swig_types[1168]
#define SWIGTYPE_p_shogun__CMMDKernelSelectionComb swig_types[1169]
#define SWIGTYPE_p_shogun__CMMDKernelSelectionCombMaxL2 swig_types[1170]
#define SWIGTYPE_p_shogun__CMMDKernelSelectionCombOpt swig_types[1171]
#define SWIGTYPE_p_shogun__CMMDKernelSelectionMax swig_types[1172]
#define SWIGTYPE_p_shogun__CMMDKernelSelectionMedian swig_types[1173]
#define SWIGTYPE_p_shogun__CMMDKernelSelectionOpt swig_types[1174]
#define SWIGTYPE_p_shogun__CMPDSVM swig_types[1175]
#define SWIGTYPE_p_shogun__CMachine swig_types[1176]
#define SWIGTYPE_p_shogun__CMachineEvaluation swig_types[1177]
#define SWIGTYPE_p_shogun__CMahalanobisDistance swig_types[1178]
#define SWIGTYPE_p_shogun__CMajorityVote swig_types[1179]
#define SWIGTYPE_p_shogun__CManhattanMetric swig_types[1180]
#define SWIGTYPE_p_shogun__CManhattanWordDistance swig_types[1181]
#define SWIGTYPE_p_shogun__CManifoldSculpting swig_types[1182]
#define SWIGTYPE_p_shogun__CMapT_shogun__TParameter_p_shogun__CSGObject_p_t swig_types[1183]
#define SWIGTYPE_p_shogun__CMapT_shogun__TParameter_p_shogun__SGVectorT_float64_t_t_t swig_types[1184]
#define SWIGTYPE_p_shogun__CMatchWordStringKernel swig_types[1185]
#define SWIGTYPE_p_shogun__CMath swig_types[1186]
#define SWIGTYPE_p_shogun__CMatrixFeaturesT_bool_t swig_types[1187]
#define SWIGTYPE_p_shogun__CMatrixFeaturesT_char_t swig_types[1188]
#define SWIGTYPE_p_shogun__CMatrixFeaturesT_double_t swig_types[1189]
#define SWIGTYPE_p_shogun__CMatrixFeaturesT_float_t swig_types[1190]
#define SWIGTYPE_p_shogun__CMatrixFeaturesT_int_t swig_types[1191]
#define SWIGTYPE_p_shogun__CMatrixFeaturesT_long_t swig_types[1192]
#define SWIGTYPE_p_shogun__CMatrixFeaturesT_unsigned_char_t swig_types[1193]
#define SWIGTYPE_p_shogun__CMatrixFeaturesT_unsigned_long_t swig_types[1194]
#define SWIGTYPE_p_shogun__CMatrixFeaturesT_unsigned_short_t swig_types[1195]
#define SWIGTYPE_p_shogun__CMatrixOperatorT_double_t swig_types[1196]
#define SWIGTYPE_p_shogun__CMatrixOperatorT_std__complexT_double_t_t swig_types[1197]
#define SWIGTYPE_p_shogun__CMeanAbsoluteError swig_types[1198]
#define SWIGTYPE_p_shogun__CMeanFunction swig_types[1199]
#define SWIGTYPE_p_shogun__CMeanRule swig_types[1200]
#define SWIGTYPE_p_shogun__CMeanShiftDataGenerator swig_types[1201]
#define SWIGTYPE_p_shogun__CMeanSquaredError swig_types[1202]
#define SWIGTYPE_p_shogun__CMeanSquaredLogError swig_types[1203]
#define SWIGTYPE_p_shogun__CMinkowskiMetric swig_types[1204]
#define SWIGTYPE_p_shogun__CModelSelection swig_types[1205]
#define SWIGTYPE_p_shogun__CModelSelectionParameters swig_types[1206]
#define SWIGTYPE_p_shogun__CMultiLaplaceInferenceMethod swig_types[1207]
#define SWIGTYPE_p_shogun__CMulticlassAccuracy swig_types[1208]
#define SWIGTYPE_p_shogun__CMulticlassLabels swig_types[1209]
#define SWIGTYPE_p_shogun__CMulticlassLibLinear swig_types[1210]
#define SWIGTYPE_p_shogun__CMulticlassLibSVM swig_types[1211]
#define SWIGTYPE_p_shogun__CMulticlassLogisticRegression swig_types[1212]
#define SWIGTYPE_p_shogun__CMulticlassMachine swig_types[1213]
#define SWIGTYPE_p_shogun__CMulticlassModel swig_types[1214]
#define SWIGTYPE_p_shogun__CMulticlassOCAS swig_types[1215]
#define SWIGTYPE_p_shogun__CMulticlassOVREvaluation swig_types[1216]
#define SWIGTYPE_p_shogun__CMulticlassOneVsOneStrategy swig_types[1217]
#define SWIGTYPE_p_shogun__CMulticlassOneVsRestStrategy swig_types[1218]
#define SWIGTYPE_p_shogun__CMulticlassSOLabels swig_types[1219]
#define SWIGTYPE_p_shogun__CMulticlassSVM swig_types[1220]
#define SWIGTYPE_p_shogun__CMulticlassStrategy swig_types[1221]
#define SWIGTYPE_p_shogun__CMulticlassTreeGuidedLogisticRegression swig_types[1222]
#define SWIGTYPE_p_shogun__CMultidimensionalScaling swig_types[1223]
#define SWIGTYPE_p_shogun__CMultilabelCLRModel swig_types[1224]
#define SWIGTYPE_p_shogun__CMultilabelLabels swig_types[1225]
#define SWIGTYPE_p_shogun__CMultilabelModel swig_types[1226]
#define SWIGTYPE_p_shogun__CMultilabelSOLabels swig_types[1227]
#define SWIGTYPE_p_shogun__CMultiquadricKernel swig_types[1228]
#define SWIGTYPE_p_shogun__CMultitaskClusteredLogisticRegression swig_types[1229]
#define SWIGTYPE_p_shogun__CMultitaskKernelMaskNormalizer swig_types[1230]
#define SWIGTYPE_p_shogun__CMultitaskKernelMaskPairNormalizer swig_types[1231]
#define SWIGTYPE_p_shogun__CMultitaskKernelMklNormalizer swig_types[1232]
#define SWIGTYPE_p_shogun__CMultitaskKernelNormalizer swig_types[1233]
#define SWIGTYPE_p_shogun__CMultitaskKernelPlifNormalizer swig_types[1234]
#define SWIGTYPE_p_shogun__CMultitaskKernelTreeNormalizer swig_types[1235]
#define SWIGTYPE_p_shogun__CMultitaskL12LogisticRegression swig_types[1236]
#define SWIGTYPE_p_shogun__CMultitaskLeastSquaresRegression swig_types[1237]
#define SWIGTYPE_p_shogun__CMultitaskLinearMachine swig_types[1238]
#define SWIGTYPE_p_shogun__CMultitaskLogisticRegression swig_types[1239]
#define SWIGTYPE_p_shogun__CMultitaskROCEvaluation swig_types[1240]
#define SWIGTYPE_p_shogun__CMultitaskTraceLogisticRegression swig_types[1241]
#define SWIGTYPE_p_shogun__CNGramTokenizer swig_types[1242]
#define SWIGTYPE_p_shogun__CNOCCO swig_types[1243]
#define SWIGTYPE_p_shogun__CNativeMulticlassMachine swig_types[1244]
#define SWIGTYPE_p_shogun__CNeighborhoodPreservingEmbedding swig_types[1245]
#define SWIGTYPE_p_shogun__CNeuralConvolutionalLayer swig_types[1246]
#define SWIGTYPE_p_shogun__CNeuralInputLayer swig_types[1247]
#define SWIGTYPE_p_shogun__CNeuralLayer swig_types[1248]
#define SWIGTYPE_p_shogun__CNeuralLayers swig_types[1249]
#define SWIGTYPE_p_shogun__CNeuralLinearLayer swig_types[1250]
#define SWIGTYPE_p_shogun__CNeuralLogisticLayer swig_types[1251]
#define SWIGTYPE_p_shogun__CNeuralNetwork swig_types[1252]
#define SWIGTYPE_p_shogun__CNeuralRectifiedLinearLayer swig_types[1253]
#define SWIGTYPE_p_shogun__CNeuralSoftmaxLayer swig_types[1254]
#define SWIGTYPE_p_shogun__CNewtonSVM swig_types[1255]
#define SWIGTYPE_p_shogun__CNode swig_types[1256]
#define SWIGTYPE_p_shogun__CNormOne swig_types[1257]
#define SWIGTYPE_p_shogun__CNormalSampler swig_types[1258]
#define SWIGTYPE_p_shogun__CNumericalVGLikelihood swig_types[1259]
#define SWIGTYPE_p_shogun__COligoStringKernel swig_types[1260]
#define SWIGTYPE_p_shogun__COnlineLibLinear swig_types[1261]
#define SWIGTYPE_p_shogun__COnlineLinearMachine swig_types[1262]
#define SWIGTYPE_p_shogun__COnlineSVMSGD swig_types[1263]
#define SWIGTYPE_p_shogun__COperatorFunctionT_double_t swig_types[1264]
#define SWIGTYPE_p_shogun__CPCA swig_types[1265]
#define SWIGTYPE_p_shogun__CPNorm swig_types[1266]
#define SWIGTYPE_p_shogun__CPRCEvaluation swig_types[1267]
#define SWIGTYPE_p_shogun__CParameterCombination swig_types[1268]
#define SWIGTYPE_p_shogun__CPerceptron swig_types[1269]
#define SWIGTYPE_p_shogun__CPeriodicKernel swig_types[1270]
#define SWIGTYPE_p_shogun__CPlif swig_types[1271]
#define SWIGTYPE_p_shogun__CPlifArray swig_types[1272]
#define SWIGTYPE_p_shogun__CPlifBase swig_types[1273]
#define SWIGTYPE_p_shogun__CPlifMatrix swig_types[1274]
#define SWIGTYPE_p_shogun__CPluginEstimate swig_types[1275]
#define SWIGTYPE_p_shogun__CPolyFeatures swig_types[1276]
#define SWIGTYPE_p_shogun__CPolyKernel swig_types[1277]
#define SWIGTYPE_p_shogun__CPolyMatchStringKernel swig_types[1278]
#define SWIGTYPE_p_shogun__CPolyMatchWordStringKernel swig_types[1279]
#define SWIGTYPE_p_shogun__CPositionalPWM swig_types[1280]
#define SWIGTYPE_p_shogun__CPowerKernel swig_types[1281]
#define SWIGTYPE_p_shogun__CPrecisionMeasure swig_types[1282]
#define SWIGTYPE_p_shogun__CPreprocessor swig_types[1283]
#define SWIGTYPE_p_shogun__CProbabilityDistribution swig_types[1284]
#define SWIGTYPE_p_shogun__CProbitLikelihood swig_types[1285]
#define SWIGTYPE_p_shogun__CProbitVGLikelihood swig_types[1286]
#define SWIGTYPE_p_shogun__CProductKernel swig_types[1287]
#define SWIGTYPE_p_shogun__CPruneVarSubMean swig_types[1288]
#define SWIGTYPE_p_shogun__CPyramidChi2 swig_types[1289]
#define SWIGTYPE_p_shogun__CQDA swig_types[1290]
#define SWIGTYPE_p_shogun__CQuadraticTimeMMD swig_types[1291]
#define SWIGTYPE_p_shogun__CRBM swig_types[1292]
#define SWIGTYPE_p_shogun__CROCEvaluation swig_types[1293]
#define SWIGTYPE_p_shogun__CRandom swig_types[1294]
#define SWIGTYPE_p_shogun__CRandomConditionalProbabilityTree swig_types[1295]
#define SWIGTYPE_p_shogun__CRandomForest swig_types[1296]
#define SWIGTYPE_p_shogun__CRandomFourierDotFeatures swig_types[1297]
#define SWIGTYPE_p_shogun__CRandomFourierGaussPreproc swig_types[1298]
#define SWIGTYPE_p_shogun__CRandomKitchenSinksDotFeatures swig_types[1299]
#define SWIGTYPE_p_shogun__CRandomSearchModelSelection swig_types[1300]
#define SWIGTYPE_p_shogun__CRationalApproximation swig_types[1301]
#define SWIGTYPE_p_shogun__CRationalQuadraticKernel swig_types[1302]
#define SWIGTYPE_p_shogun__CRealDistance swig_types[1303]
#define SWIGTYPE_p_shogun__CRealFileFeatures swig_types[1304]
#define SWIGTYPE_p_shogun__CRealNumber swig_types[1305]
#define SWIGTYPE_p_shogun__CRecallMeasure swig_types[1306]
#define SWIGTYPE_p_shogun__CRegressionLabels swig_types[1307]
#define SWIGTYPE_p_shogun__CRegulatoryModulesStringKernel swig_types[1308]
#define SWIGTYPE_p_shogun__CRejectionStrategy swig_types[1309]
#define SWIGTYPE_p_shogun__CRelaxedTree swig_types[1310]
#define SWIGTYPE_p_shogun__CRescaleFeatures swig_types[1311]
#define SWIGTYPE_p_shogun__CResultSet swig_types[1312]
#define SWIGTYPE_p_shogun__CRidgeKernelNormalizer swig_types[1313]
#define SWIGTYPE_p_shogun__CSGDQN swig_types[1314]
#define SWIGTYPE_p_shogun__CSGObject swig_types[1315]
#define SWIGTYPE_p_shogun__CSNPFeatures swig_types[1316]
#define SWIGTYPE_p_shogun__CSNPStringKernel swig_types[1317]
#define SWIGTYPE_p_shogun__CSOBI swig_types[1318]
#define SWIGTYPE_p_shogun__CSOSVMHelper swig_types[1319]
#define SWIGTYPE_p_shogun__CSVM swig_types[1320]
#define SWIGTYPE_p_shogun__CSVMLight swig_types[1321]
#define SWIGTYPE_p_shogun__CSVMLightOneClass swig_types[1322]
#define SWIGTYPE_p_shogun__CSVMLin swig_types[1323]
#define SWIGTYPE_p_shogun__CSVMOcas swig_types[1324]
#define SWIGTYPE_p_shogun__CSVMSGD swig_types[1325]
#define SWIGTYPE_p_shogun__CSVRLight swig_types[1326]
#define SWIGTYPE_p_shogun__CSalzbergWordStringKernel swig_types[1327]
#define SWIGTYPE_p_shogun__CScalarResultT_bool_t swig_types[1328]
#define SWIGTYPE_p_shogun__CScalarResultT_char_t swig_types[1329]
#define SWIGTYPE_p_shogun__CScalarResultT_double_t swig_types[1330]
#define SWIGTYPE_p_shogun__CScalarResultT_float_t swig_types[1331]
#define SWIGTYPE_p_shogun__CScalarResultT_int_t swig_types[1332]
#define SWIGTYPE_p_shogun__CScalarResultT_long_t swig_types[1333]
#define SWIGTYPE_p_shogun__CScalarResultT_unsigned_char_t swig_types[1334]
#define SWIGTYPE_p_shogun__CScalarResultT_unsigned_long_t swig_types[1335]
#define SWIGTYPE_p_shogun__CScalarResultT_unsigned_short_t swig_types[1336]
#define SWIGTYPE_p_shogun__CScatterKernelNormalizer swig_types[1337]
#define SWIGTYPE_p_shogun__CScatterSVM swig_types[1338]
#define SWIGTYPE_p_shogun__CSegmentLoss swig_types[1339]
#define SWIGTYPE_p_shogun__CSequence swig_types[1340]
#define SWIGTYPE_p_shogun__CSequenceLabels swig_types[1341]
#define SWIGTYPE_p_shogun__CSerialComputationEngine swig_types[1342]
#define SWIGTYPE_p_shogun__CSerializableAsciiFile swig_types[1343]
#define SWIGTYPE_p_shogun__CSerializableFile swig_types[1344]
#define SWIGTYPE_p_shogun__CSerializableHdf5File swig_types[1345]
#define SWIGTYPE_p_shogun__CSerializableXmlFile swig_types[1346]
#define SWIGTYPE_p_shogun__CShareBoost swig_types[1347]
#define SWIGTYPE_p_shogun__CShiftInvariantKernel swig_types[1348]
#define SWIGTYPE_p_shogun__CSigmoidKernel swig_types[1349]
#define SWIGTYPE_p_shogun__CSignal swig_types[1350]
#define SWIGTYPE_p_shogun__CSimpleLocalityImprovedStringKernel swig_types[1351]
#define SWIGTYPE_p_shogun__CSingleFITCInference swig_types[1352]
#define SWIGTYPE_p_shogun__CSingleFITCLaplaceInferenceMethod swig_types[1353]
#define SWIGTYPE_p_shogun__CSingleFITCLaplaceNewtonOptimizer swig_types[1354]
#define SWIGTYPE_p_shogun__CSingleLaplaceInferenceMethod swig_types[1355]
#define SWIGTYPE_p_shogun__CSingleLaplaceNewtonOptimizer swig_types[1356]
#define SWIGTYPE_p_shogun__CSingleSparseInference swig_types[1357]
#define SWIGTYPE_p_shogun__CSmoothHingeLoss swig_types[1358]
#define SWIGTYPE_p_shogun__CSoftMaxLikelihood swig_types[1359]
#define SWIGTYPE_p_shogun__CSortUlongString swig_types[1360]
#define SWIGTYPE_p_shogun__CSortWordString swig_types[1361]
#define SWIGTYPE_p_shogun__CSparseDistanceT_char_t swig_types[1362]
#define SWIGTYPE_p_shogun__CSparseDistanceT_double_t swig_types[1363]
#define SWIGTYPE_p_shogun__CSparseDistanceT_int_t swig_types[1364]
#define SWIGTYPE_p_shogun__CSparseDistanceT_unsigned_short_t swig_types[1365]
#define SWIGTYPE_p_shogun__CSparseEuclideanDistance swig_types[1366]
#define SWIGTYPE_p_shogun__CSparseFeaturesT_bool_t swig_types[1367]
#define SWIGTYPE_p_shogun__CSparseFeaturesT_char_t swig_types[1368]
#define SWIGTYPE_p_shogun__CSparseFeaturesT_double_t swig_types[1369]
#define SWIGTYPE_p_shogun__CSparseFeaturesT_float_t swig_types[1370]
#define SWIGTYPE_p_shogun__CSparseFeaturesT_int_t swig_types[1371]
#define SWIGTYPE_p_shogun__CSparseFeaturesT_long_t swig_types[1372]
#define SWIGTYPE_p_shogun__CSparseFeaturesT_unsigned_char_t swig_types[1373]
#define SWIGTYPE_p_shogun__CSparseFeaturesT_unsigned_long_t swig_types[1374]
#define SWIGTYPE_p_shogun__CSparseFeaturesT_unsigned_short_t swig_types[1375]
#define SWIGTYPE_p_shogun__CSparseInference swig_types[1376]
#define SWIGTYPE_p_shogun__CSparseInverseCovariance swig_types[1377]
#define SWIGTYPE_p_shogun__CSparseKernelT_double_t swig_types[1378]
#define SWIGTYPE_p_shogun__CSparseKernelT_unsigned_short_t swig_types[1379]
#define SWIGTYPE_p_shogun__CSparseMatrixOperatorT_double_t swig_types[1380]
#define SWIGTYPE_p_shogun__CSparseMatrixOperatorT_std__complexT_double_t_t swig_types[1381]
#define SWIGTYPE_p_shogun__CSparseMultilabel swig_types[1382]
#define SWIGTYPE_p_shogun__CSparsePolyFeatures swig_types[1383]
#define SWIGTYPE_p_shogun__CSparseSpatialSampleStringKernel swig_types[1384]
#define SWIGTYPE_p_shogun__CSpecificityMeasure swig_types[1385]
#define SWIGTYPE_p_shogun__CSpectrumMismatchRBFKernel swig_types[1386]
#define SWIGTYPE_p_shogun__CSphericalKernel swig_types[1387]
#define SWIGTYPE_p_shogun__CSplineKernel swig_types[1388]
#define SWIGTYPE_p_shogun__CSplittingStrategy swig_types[1389]
#define SWIGTYPE_p_shogun__CSqrtDiagKernelNormalizer swig_types[1390]
#define SWIGTYPE_p_shogun__CSquaredHingeLoss swig_types[1391]
#define SWIGTYPE_p_shogun__CSquaredLoss swig_types[1392]
#define SWIGTYPE_p_shogun__CStateModel swig_types[1393]
#define SWIGTYPE_p_shogun__CStatistics swig_types[1394]
#define SWIGTYPE_p_shogun__CStatistics__SigmoidParamters swig_types[1395]
#define SWIGTYPE_p_shogun__CStochasticGBMachine swig_types[1396]
#define SWIGTYPE_p_shogun__CStochasticProximityEmbedding swig_types[1397]
#define SWIGTYPE_p_shogun__CStochasticSOSVM swig_types[1398]
#define SWIGTYPE_p_shogun__CStratifiedCrossValidationSplitting swig_types[1399]
#define SWIGTYPE_p_shogun__CStreamingAsciiFile swig_types[1400]
#define SWIGTYPE_p_shogun__CStreamingDenseFeaturesT_bool_t swig_types[1401]
#define SWIGTYPE_p_shogun__CStreamingDenseFeaturesT_char_t swig_types[1402]
#define SWIGTYPE_p_shogun__CStreamingDenseFeaturesT_double_t swig_types[1403]
#define SWIGTYPE_p_shogun__CStreamingDenseFeaturesT_float_t swig_types[1404]
#define SWIGTYPE_p_shogun__CStreamingDenseFeaturesT_int_t swig_types[1405]
#define SWIGTYPE_p_shogun__CStreamingDenseFeaturesT_long_t swig_types[1406]
#define SWIGTYPE_p_shogun__CStreamingDenseFeaturesT_unsigned_char_t swig_types[1407]
#define SWIGTYPE_p_shogun__CStreamingDenseFeaturesT_unsigned_long_t swig_types[1408]
#define SWIGTYPE_p_shogun__CStreamingDenseFeaturesT_unsigned_short_t swig_types[1409]
#define SWIGTYPE_p_shogun__CStreamingDotFeatures swig_types[1410]
#define SWIGTYPE_p_shogun__CStreamingFeatures swig_types[1411]
#define SWIGTYPE_p_shogun__CStreamingFile swig_types[1412]
#define SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_bool_t swig_types[1413]
#define SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_char_t swig_types[1414]
#define SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_double_t swig_types[1415]
#define SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_float_t swig_types[1416]
#define SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_int_t swig_types[1417]
#define SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_long_t swig_types[1418]
#define SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_char_t swig_types[1419]
#define SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_long_t swig_types[1420]
#define SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_short_t swig_types[1421]
#define SWIGTYPE_p_shogun__CStreamingFileFromFeatures swig_types[1422]
#define SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_bool_t swig_types[1423]
#define SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_char_t swig_types[1424]
#define SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_double_t swig_types[1425]
#define SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_float_t swig_types[1426]
#define SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_int_t swig_types[1427]
#define SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_long_t swig_types[1428]
#define SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_char_t swig_types[1429]
#define SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_long_t swig_types[1430]
#define SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_short_t swig_types[1431]
#define SWIGTYPE_p_shogun__CStreamingHashedDocDotFeatures swig_types[1432]
#define SWIGTYPE_p_shogun__CStreamingMMD swig_types[1433]
#define SWIGTYPE_p_shogun__CStreamingSparseFeaturesT_bool_t swig_types[1434]
#define SWIGTYPE_p_shogun__CStreamingSparseFeaturesT_char_t swig_types[1435]
#define SWIGTYPE_p_shogun__CStreamingSparseFeaturesT_double_t swig_types[1436]
#define SWIGTYPE_p_shogun__CStreamingSparseFeaturesT_float_t swig_types[1437]
#define SWIGTYPE_p_shogun__CStreamingSparseFeaturesT_int_t swig_types[1438]
#define SWIGTYPE_p_shogun__CStreamingSparseFeaturesT_long_t swig_types[1439]
#define SWIGTYPE_p_shogun__CStreamingSparseFeaturesT_unsigned_char_t swig_types[1440]
#define SWIGTYPE_p_shogun__CStreamingSparseFeaturesT_unsigned_long_t swig_types[1441]
#define SWIGTYPE_p_shogun__CStreamingSparseFeaturesT_unsigned_short_t swig_types[1442]
#define SWIGTYPE_p_shogun__CStreamingStringFeaturesT_bool_t swig_types[1443]
#define SWIGTYPE_p_shogun__CStreamingStringFeaturesT_char_t swig_types[1444]
#define SWIGTYPE_p_shogun__CStreamingStringFeaturesT_double_t swig_types[1445]
#define SWIGTYPE_p_shogun__CStreamingStringFeaturesT_float_t swig_types[1446]
#define SWIGTYPE_p_shogun__CStreamingStringFeaturesT_int_t swig_types[1447]
#define SWIGTYPE_p_shogun__CStreamingStringFeaturesT_long_t swig_types[1448]
#define SWIGTYPE_p_shogun__CStreamingStringFeaturesT_unsigned_char_t swig_types[1449]
#define SWIGTYPE_p_shogun__CStreamingStringFeaturesT_unsigned_long_t swig_types[1450]
#define SWIGTYPE_p_shogun__CStreamingStringFeaturesT_unsigned_short_t swig_types[1451]
#define SWIGTYPE_p_shogun__CStreamingVwCacheFile swig_types[1452]
#define SWIGTYPE_p_shogun__CStreamingVwFeatures swig_types[1453]
#define SWIGTYPE_p_shogun__CStreamingVwFile swig_types[1454]
#define SWIGTYPE_p_shogun__CStringDistanceT_char_t swig_types[1455]
#define SWIGTYPE_p_shogun__CStringDistanceT_double_t swig_types[1456]
#define SWIGTYPE_p_shogun__CStringDistanceT_int_t swig_types[1457]
#define SWIGTYPE_p_shogun__CStringDistanceT_unsigned_long_t swig_types[1458]
#define SWIGTYPE_p_shogun__CStringDistanceT_unsigned_short_t swig_types[1459]
#define SWIGTYPE_p_shogun__CStringFeaturesT_bool_t swig_types[1460]
#define SWIGTYPE_p_shogun__CStringFeaturesT_char_t swig_types[1461]
#define SWIGTYPE_p_shogun__CStringFeaturesT_double_t swig_types[1462]
#define SWIGTYPE_p_shogun__CStringFeaturesT_float_t swig_types[1463]
#define SWIGTYPE_p_shogun__CStringFeaturesT_int_t swig_types[1464]
#define SWIGTYPE_p_shogun__CStringFeaturesT_long_t swig_types[1465]
#define SWIGTYPE_p_shogun__CStringFeaturesT_unsigned_char_t swig_types[1466]
#define SWIGTYPE_p_shogun__CStringFeaturesT_unsigned_long_t swig_types[1467]
#define SWIGTYPE_p_shogun__CStringFeaturesT_unsigned_short_t swig_types[1468]
#define SWIGTYPE_p_shogun__CStringFileFeaturesT_bool_t swig_types[1469]
#define SWIGTYPE_p_shogun__CStringFileFeaturesT_char_t swig_types[1470]
#define SWIGTYPE_p_shogun__CStringFileFeaturesT_double_t swig_types[1471]
#define SWIGTYPE_p_shogun__CStringFileFeaturesT_float_t swig_types[1472]
#define SWIGTYPE_p_shogun__CStringFileFeaturesT_int_t swig_types[1473]
#define SWIGTYPE_p_shogun__CStringFileFeaturesT_long_t swig_types[1474]
#define SWIGTYPE_p_shogun__CStringFileFeaturesT_unsigned_char_t swig_types[1475]
#define SWIGTYPE_p_shogun__CStringFileFeaturesT_unsigned_long_t swig_types[1476]
#define SWIGTYPE_p_shogun__CStringFileFeaturesT_unsigned_short_t swig_types[1477]
#define SWIGTYPE_p_shogun__CStringKernelT_char_t swig_types[1478]
#define SWIGTYPE_p_shogun__CStringKernelT_double_t swig_types[1479]
#define SWIGTYPE_p_shogun__CStringKernelT_short_t swig_types[1480]
#define SWIGTYPE_p_shogun__CStringKernelT_unsigned_char_t swig_types[1481]
#define SWIGTYPE_p_shogun__CStringKernelT_unsigned_long_t swig_types[1482]
#define SWIGTYPE_p_shogun__CStringKernelT_unsigned_short_t swig_types[1483]
#define SWIGTYPE_p_shogun__CStringPreprocessorT_char_t swig_types[1484]
#define SWIGTYPE_p_shogun__CStringPreprocessorT_unsigned_char_t swig_types[1485]
#define SWIGTYPE_p_shogun__CStringPreprocessorT_unsigned_long_t swig_types[1486]
#define SWIGTYPE_p_shogun__CStringPreprocessorT_unsigned_short_t swig_types[1487]
#define SWIGTYPE_p_shogun__CStructuredAccuracy swig_types[1488]
#define SWIGTYPE_p_shogun__CStructuredData swig_types[1489]
#define SWIGTYPE_p_shogun__CStructuredLabels swig_types[1490]
#define SWIGTYPE_p_shogun__CStructuredModel swig_types[1491]
#define SWIGTYPE_p_shogun__CStructuredOutputMachine swig_types[1492]
#define SWIGTYPE_p_shogun__CStudentsTLikelihood swig_types[1493]
#define SWIGTYPE_p_shogun__CStudentsTVGLikelihood swig_types[1494]
#define SWIGTYPE_p_shogun__CSubsequenceStringKernel swig_types[1495]
#define SWIGTYPE_p_shogun__CSumOne swig_types[1496]
#define SWIGTYPE_p_shogun__CTDistributedStochasticNeighborEmbedding swig_types[1497]
#define SWIGTYPE_p_shogun__CTOPFeatures swig_types[1498]
#define SWIGTYPE_p_shogun__CTStudentKernel swig_types[1499]
#define SWIGTYPE_p_shogun__CTableFactorType swig_types[1500]
#define SWIGTYPE_p_shogun__CTanimotoDistance swig_types[1501]
#define SWIGTYPE_p_shogun__CTanimotoKernelNormalizer swig_types[1502]
#define SWIGTYPE_p_shogun__CTask swig_types[1503]
#define SWIGTYPE_p_shogun__CTaskGroup swig_types[1504]
#define SWIGTYPE_p_shogun__CTaskRelation swig_types[1505]
#define SWIGTYPE_p_shogun__CTaskTree swig_types[1506]
#define SWIGTYPE_p_shogun__CTaxonomy swig_types[1507]
#define SWIGTYPE_p_shogun__CTensorProductPairKernel swig_types[1508]
#define SWIGTYPE_p_shogun__CThresholdRejectionStrategy swig_types[1509]
#define SWIGTYPE_p_shogun__CTime swig_types[1510]
#define SWIGTYPE_p_shogun__CTokenizer swig_types[1511]
#define SWIGTYPE_p_shogun__CTraceSampler swig_types[1512]
#define SWIGTYPE_p_shogun__CTreeMachineT_C45TreeNodeData_t swig_types[1513]
#define SWIGTYPE_p_shogun__CTreeMachineT_CARTreeNodeData_t swig_types[1514]
#define SWIGTYPE_p_shogun__CTreeMachineT_CHAIDTreeNodeData_t swig_types[1515]
#define SWIGTYPE_p_shogun__CTreeMachineT_id3TreeNodeData_t swig_types[1516]
#define SWIGTYPE_p_shogun__CTreeMachineT_shogun__ConditionalProbabilityTreeNodeData_t swig_types[1517]
#define SWIGTYPE_p_shogun__CTreeMachineT_shogun__RelaxedTreeNodeData_t swig_types[1518]
#define SWIGTYPE_p_shogun__CTwoSampleTest swig_types[1519]
#define SWIGTYPE_p_shogun__CTwoStateModel swig_types[1520]
#define SWIGTYPE_p_shogun__CUWedgeSep swig_types[1521]
#define SWIGTYPE_p_shogun__CVarDTCInferenceMethod swig_types[1522]
#define SWIGTYPE_p_shogun__CVarianceKernelNormalizer swig_types[1523]
#define SWIGTYPE_p_shogun__CVariationalGaussianLikelihood swig_types[1524]
#define SWIGTYPE_p_shogun__CVariationalLikelihood swig_types[1525]
#define SWIGTYPE_p_shogun__CVectorResultT_bool_t swig_types[1526]
#define SWIGTYPE_p_shogun__CVectorResultT_char_t swig_types[1527]
#define SWIGTYPE_p_shogun__CVectorResultT_double_t swig_types[1528]
#define SWIGTYPE_p_shogun__CVectorResultT_float_t swig_types[1529]
#define SWIGTYPE_p_shogun__CVectorResultT_int_t swig_types[1530]
#define SWIGTYPE_p_shogun__CVectorResultT_long_t swig_types[1531]
#define SWIGTYPE_p_shogun__CVectorResultT_unsigned_char_t swig_types[1532]
#define SWIGTYPE_p_shogun__CVectorResultT_unsigned_long_t swig_types[1533]
#define SWIGTYPE_p_shogun__CVectorResultT_unsigned_short_t swig_types[1534]
#define SWIGTYPE_p_shogun__CVowpalWabbit swig_types[1535]
#define SWIGTYPE_p_shogun__CVwParser swig_types[1536]
#define SWIGTYPE_p_shogun__CWDFeatures swig_types[1537]
#define SWIGTYPE_p_shogun__CWDSVMOcas swig_types[1538]
#define SWIGTYPE_p_shogun__CWRACCMeasure swig_types[1539]
#define SWIGTYPE_p_shogun__CWaveKernel swig_types[1540]
#define SWIGTYPE_p_shogun__CWaveletKernel swig_types[1541]
#define SWIGTYPE_p_shogun__CWeightedCommWordStringKernel swig_types[1542]
#define SWIGTYPE_p_shogun__CWeightedDegreePositionStringKernel swig_types[1543]
#define SWIGTYPE_p_shogun__CWeightedDegreeRBFKernel swig_types[1544]
#define SWIGTYPE_p_shogun__CWeightedDegreeStringKernel swig_types[1545]
#define SWIGTYPE_p_shogun__CWeightedMajorityVote swig_types[1546]
#define SWIGTYPE_p_shogun__CWrappedObjectArray swig_types[1547]
#define SWIGTYPE_p_shogun__CZeroMean swig_types[1548]
#define SWIGTYPE_p_shogun__CZeroMeanCenterKernelNormalizer swig_types[1549]
#define SWIGTYPE_p_shogun__ConditionalProbabilityTreeNodeData swig_types[1550]
#define SWIGTYPE_p_shogun__DynArrayT_shogun__CPlifBase_p_t swig_types[1551]
#define SWIGTYPE_p_shogun__DynArrayT_shogun__Parameter_p_t swig_types[1552]
#define SWIGTYPE_p_shogun__FirstOrderMinimizer swig_types[1553]
#define SWIGTYPE_p_shogun__GCEdge swig_types[1554]
#define SWIGTYPE_p_shogun__GCNode swig_types[1555]
#define SWIGTYPE_p_shogun__GCNodePtr swig_types[1556]
#define SWIGTYPE_p_shogun__LBFGSLineSearchHelper swig_types[1557]
#define SWIGTYPE_p_shogun__MappedSparseMatrix swig_types[1558]
#define SWIGTYPE_p_shogun__Minimizer swig_types[1559]
#define SWIGTYPE_p_shogun__Model swig_types[1560]
#define SWIGTYPE_p_shogun__Parallel swig_types[1561]
#define SWIGTYPE_p_shogun__Parameter swig_types[1562]
#define SWIGTYPE_p_shogun__RelaxedTreeNodeData swig_types[1563]
#define SWIGTYPE_p_shogun__SGIO swig_types[1564]
#define SWIGTYPE_p_shogun__SGMatrixT_bool_t swig_types[1565]
#define SWIGTYPE_p_shogun__SGMatrixT_char_t swig_types[1566]
#define SWIGTYPE_p_shogun__SGMatrixT_double_t swig_types[1567]
#define SWIGTYPE_p_shogun__SGMatrixT_float_t swig_types[1568]
#define SWIGTYPE_p_shogun__SGMatrixT_int_t swig_types[1569]
#define SWIGTYPE_p_shogun__SGMatrixT_long_t swig_types[1570]
#define SWIGTYPE_p_shogun__SGMatrixT_std__complexT_double_t_t swig_types[1571]
#define SWIGTYPE_p_shogun__SGMatrixT_unsigned_char_t swig_types[1572]
#define SWIGTYPE_p_shogun__SGMatrixT_unsigned_long_t swig_types[1573]
#define SWIGTYPE_p_shogun__SGMatrixT_unsigned_short_t swig_types[1574]
#define SWIGTYPE_p_shogun__SGNDArrayT_bool_t swig_types[1575]
#define SWIGTYPE_p_shogun__SGNDArrayT_char_t swig_types[1576]
#define SWIGTYPE_p_shogun__SGNDArrayT_double_t swig_types[1577]
#define SWIGTYPE_p_shogun__SGNDArrayT_float_t swig_types[1578]
#define SWIGTYPE_p_shogun__SGNDArrayT_int_t swig_types[1579]
#define SWIGTYPE_p_shogun__SGNDArrayT_long_t swig_types[1580]
#define SWIGTYPE_p_shogun__SGNDArrayT_unsigned_char_t swig_types[1581]
#define SWIGTYPE_p_shogun__SGNDArrayT_unsigned_long_t swig_types[1582]
#define SWIGTYPE_p_shogun__SGNDArrayT_unsigned_short_t swig_types[1583]
#define SWIGTYPE_p_shogun__SGReferencedData swig_types[1584]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_bool_t swig_types[1585]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_char_t swig_types[1586]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_double_t swig_types[1587]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_float_t swig_types[1588]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_int_t swig_types[1589]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_long_t swig_types[1590]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_std__complexT_double_t_t swig_types[1591]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_unsigned_char_t swig_types[1592]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_unsigned_long_t swig_types[1593]
#define SWIGTYPE_p_shogun__SGSparseMatrixT_unsigned_short_t swig_types[1594]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_bool_t swig_types[1595]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_char_t swig_types[1596]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_double_t swig_types[1597]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_float_t swig_types[1598]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_int_t swig_types[1599]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_long_t swig_types[1600]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_std__complexT_double_t_t swig_types[1601]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_unsigned_char_t swig_types[1602]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_unsigned_long_t swig_types[1603]
#define SWIGTYPE_p_shogun__SGSparseVectorEntryT_unsigned_short_t swig_types[1604]
#define SWIGTYPE_p_shogun__SGSparseVectorT_bool_t swig_types[1605]
#define SWIGTYPE_p_shogun__SGSparseVectorT_char_t swig_types[1606]
#define SWIGTYPE_p_shogun__SGSparseVectorT_double_t swig_types[1607]
#define SWIGTYPE_p_shogun__SGSparseVectorT_float_t swig_types[1608]
#define SWIGTYPE_p_shogun__SGSparseVectorT_int_t swig_types[1609]
#define SWIGTYPE_p_shogun__SGSparseVectorT_long_t swig_types[1610]
#define SWIGTYPE_p_shogun__SGSparseVectorT_std__complexT_double_t_t swig_types[1611]
#define SWIGTYPE_p_shogun__SGSparseVectorT_unsigned_char_t swig_types[1612]
#define SWIGTYPE_p_shogun__SGSparseVectorT_unsigned_long_t swig_types[1613]
#define SWIGTYPE_p_shogun__SGSparseVectorT_unsigned_short_t swig_types[1614]
#define SWIGTYPE_p_shogun__SGStringListT_bool_t swig_types[1615]
#define SWIGTYPE_p_shogun__SGStringListT_char_t swig_types[1616]
#define SWIGTYPE_p_shogun__SGStringListT_double_t swig_types[1617]
#define SWIGTYPE_p_shogun__SGStringListT_float_t swig_types[1618]
#define SWIGTYPE_p_shogun__SGStringListT_int_t swig_types[1619]
#define SWIGTYPE_p_shogun__SGStringListT_long_t swig_types[1620]
#define SWIGTYPE_p_shogun__SGStringListT_unsigned_char_t swig_types[1621]
#define SWIGTYPE_p_shogun__SGStringListT_unsigned_long_t swig_types[1622]
#define SWIGTYPE_p_shogun__SGStringListT_unsigned_short_t swig_types[1623]
#define SWIGTYPE_p_shogun__SGStringT_bool_t swig_types[1624]
#define SWIGTYPE_p_shogun__SGStringT_char_t swig_types[1625]
#define SWIGTYPE_p_shogun__SGStringT_double_t swig_types[1626]
#define SWIGTYPE_p_shogun__SGStringT_float_t swig_types[1627]
#define SWIGTYPE_p_shogun__SGStringT_int_t swig_types[1628]
#define SWIGTYPE_p_shogun__SGStringT_long_t swig_types[1629]
#define SWIGTYPE_p_shogun__SGStringT_unsigned_char_t swig_types[1630]
#define SWIGTYPE_p_shogun__SGStringT_unsigned_long_t swig_types[1631]
#define SWIGTYPE_p_shogun__SGStringT_unsigned_short_t swig_types[1632]
#define SWIGTYPE_p_shogun__SGVectorT_bool_t swig_types[1633]
#define SWIGTYPE_p_shogun__SGVectorT_char_t swig_types[1634]
#define SWIGTYPE_p_shogun__SGVectorT_double_t swig_types[1635]
#define SWIGTYPE_p_shogun__SGVectorT_float_t swig_types[1636]
#define SWIGTYPE_p_shogun__SGVectorT_int_t swig_types[1637]
#define SWIGTYPE_p_shogun__SGVectorT_long_t swig_types[1638]
#define SWIGTYPE_p_shogun__SGVectorT_std__complexT_double_t_t swig_types[1639]
#define SWIGTYPE_p_shogun__SGVectorT_unsigned_char_t swig_types[1640]
#define SWIGTYPE_p_shogun__SGVectorT_unsigned_int_t swig_types[1641]
#define SWIGTYPE_p_shogun__SGVectorT_unsigned_long_t swig_types[1642]
#define SWIGTYPE_p_shogun__SGVectorT_unsigned_short_t swig_types[1643]
#define SWIGTYPE_p_shogun__SparsityStructure swig_types[1644]
#define SWIGTYPE_p_shogun__TMultipleCPinfo swig_types[1645]
#define SWIGTYPE_p_shogun__TParameter swig_types[1646]
#define SWIGTYPE_p_shogun__T_HMM_INDIZES swig_types[1647]
#define SWIGTYPE_p_shogun__Version swig_types[1648]
#define SWIGTYPE_p_shogun__VwExample swig_types[1649]
#define SWIGTYPE_p_shogun__larank_kcache_s swig_types[1650]
#define SWIGTYPE_p_shogun__substring swig_types[1651]
#define SWIGTYPE_p_short swig_types[1652]
#define SWIGTYPE_p_signed_char swig_types[1653]
#define SWIGTYPE_p_size_type swig_types[1654]
#define SWIGTYPE_p_std__allocatorT_double_t swig_types[1655]
#define SWIGTYPE_p_std__allocatorT_int_t swig_types[1656]
#define SWIGTYPE_p_std__complexT_double_t swig_types[1657]
#define SWIGTYPE_p_std__mapT_std__string_int_t swig_types[1658]
#define SWIGTYPE_p_std__string swig_types[1659]
#define SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t swig_types[1660]
#define SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t swig_types[1661]
#define SWIGTYPE_p_std__vectorT_shogun__CGaussian_p_std__allocatorT_shogun__CGaussian_p_t_t swig_types[1662]
#define SWIGTYPE_p_std__vectorT_std__mapT_int_double_t_std__allocatorT_std__mapT_int_double_t_t_t swig_types[1663]
#define SWIGTYPE_p_std__vectorT_std__pairT_int_int_t_std__allocatorT_std__pairT_int_int_t_t_t swig_types[1664]
#define SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t swig_types[1665]
#define SWIGTYPE_p_swig__ConstIterator swig_types[1666]
#define SWIGTYPE_p_swig__GC_VALUE swig_types[1667]
#define SWIGTYPE_p_swig__Iterator swig_types[1668]
#define SWIGTYPE_p_unsigned_char swig_types[1669]
#define SWIGTYPE_p_unsigned_int swig_types[1670]
#define SWIGTYPE_p_unsigned_long swig_types[1671]
#define SWIGTYPE_p_unsigned_short swig_types[1672]
#define SWIGTYPE_p_v_arrayT_VwFeature_t swig_types[1673]
#define SWIGTYPE_p_value_type swig_types[1674]
#define SWIGTYPE_p_void swig_types[1675]
#define SWIGTYPE_p_vw_size_t swig_types[1676]
static swig_type_info *swig_types[1678];
static swig_module_info swig_module = {swig_types, 1677, 0, 0, 0, 0};
#define SWIG_TypeQuery(name) SWIG_TypeQueryModule(&swig_module, &swig_module, name)
#define SWIG_MangledTypeQuery(name) SWIG_MangledTypeQueryModule(&swig_module, &swig_module, name)
/* -------- TYPES TABLE (END) -------- */
#define SWIG_init Init_modshogun
#define SWIG_name "Modshogun"
/*
Document-module: Modshogun
The `modshogun` module gathers all modules available in the SHOGUN toolkit.
*/
static VALUE mModshogun;
#define SWIG_RUBY_THREAD_BEGIN_BLOCK
#define SWIG_RUBY_THREAD_END_BLOCK
#define SWIGVERSION 0x030010
#define SWIG_VERSION SWIGVERSION
#define SWIG_as_voidptr(a) const_cast< void * >(static_cast< const void * >(a))
#define SWIG_as_voidptrptr(a) ((void)SWIG_as_voidptr(*a),reinterpret_cast< void** >(a))
#include <stdexcept>
#if defined(__APPLE__)
#define __ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES 0
#endif // defined(__APPLE__)
SWIGINTERN swig_type_info*
SWIG_pchar_descriptor(void)
{
static int init = 0;
static swig_type_info* info = 0;
if (!init) {
info = SWIG_TypeQuery("_p_char");
init = 1;
}
return info;
}
SWIGINTERNINLINE VALUE
SWIG_FromCharPtrAndSize(const char* carray, size_t size)
{
if (carray) {
if (size > LONG_MAX) {
swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
return pchar_descriptor ?
SWIG_NewPointerObj(const_cast< char * >(carray), pchar_descriptor, 0) : Qnil;
} else {
return rb_str_new(carray, static_cast< long >(size));
}
} else {
return Qnil;
}
}
SWIGINTERNINLINE VALUE
SWIG_FromCharPtr(const char *cptr)
{
return SWIG_FromCharPtrAndSize(cptr, (cptr ? strlen(cptr) : 0));
}
#include <limits.h>
#if !defined(SWIG_NO_LLONG_MAX)
# if !defined(LLONG_MAX) && defined(__GNUC__) && defined (__LONG_LONG_MAX__)
# define LLONG_MAX __LONG_LONG_MAX__
# define LLONG_MIN (-LLONG_MAX - 1LL)
# define ULLONG_MAX (LLONG_MAX * 2ULL + 1ULL)
# endif
#endif
#define SWIG_From_long LONG2NUM
SWIGINTERNINLINE VALUE
SWIG_From_int (int value)
{
return SWIG_From_long (value);
}
#include <shogun/machine/Machine.h>
#include <shogun/classifier/svm/GNPPSVM.h>
#ifdef USE_GPL_SHOGUN
#include <shogun/classifier/svm/GPBTSVM.h>
#endif //USE_GPL_SHOGUN
#include <shogun/machine/DistanceMachine.h>
#include <shogun/classifier/LDA.h>
#include <shogun/classifier/svm/LibLinear.h>
#include <shogun/classifier/svm/LibSVM.h>
#include <shogun/classifier/svm/LibSVMOneClass.h>
#ifdef USE_SVMLIGHT
#include <shogun/classifier/svm/SVMLight.h>
#include <shogun/classifier/svm/SVMLightOneClass.h>
#endif //USE_SVMLIGHT
#include <shogun/machine/LinearMachine.h>
#include <shogun/machine/OnlineLinearMachine.h>
#include <shogun/classifier/LPBoost.h>
#include <shogun/classifier/LPM.h>
#include <shogun/classifier/svm/MPDSVM.h>
#include <shogun/classifier/svm/OnlineSVMSGD.h>
#include <shogun/classifier/svm/OnlineLibLinear.h>
#include <shogun/classifier/Perceptron.h>
#include <shogun/classifier/AveragedPerceptron.h>
#include <shogun/classifier/svm/SVM.h>
#include <shogun/classifier/svm/SVMLin.h>
#include <shogun/machine/KernelMachine.h>
#ifdef USE_GPL_SHOGUN
#include <shogun/classifier/svm/SVMOcas.h>
#endif //USE_GPL_SHOGUN
#include <shogun/classifier/svm/SVMSGD.h>
#include <shogun/classifier/svm/SGDQN.h>
#ifdef USE_GPL_SHOGUN
#include <shogun/classifier/svm/WDSVMOcas.h>
#endif //USE_GPL_SHOGUN
#include <shogun/classifier/PluginEstimate.h>
#include <shogun/classifier/mkl/MKL.h>
#include <shogun/classifier/mkl/MKLClassification.h>
#include <shogun/classifier/mkl/MKLOneClass.h>
#include <shogun/classifier/vw/VowpalWabbit.h>
#include <shogun/classifier/svm/NewtonSVM.h>
#include <shogun/classifier/FeatureBlockLogisticRegression.h>
#include <shogun/machine/DirectorLinearMachine.h>
#include <shogun/machine/DirectorKernelMachine.h>
#include <shogun/machine/BaggingMachine.h>
#include <shogun/machine/DistanceMachine.h>
#include <shogun/clustering/KMeansBase.h>
#include <shogun/clustering/KMeans.h>
#include <shogun/clustering/KMeansMiniBatch.h>
#include <shogun/clustering/Hierarchical.h>
#include <shogun/clustering/GMM.h>
#include <shogun/features/FeatureTypes.h>
#include <shogun/distance/Distance.h>
#include <shogun/distance/CustomDistance.h>
#include <shogun/distance/KernelDistance.h>
#include <shogun/distance/DenseDistance.h>
#include <shogun/distance/SparseDistance.h>
#include <shogun/distance/RealDistance.h>
#include <shogun/distance/StringDistance.h>
#include <shogun/distance/CanberraMetric.h>
#include <shogun/distance/ChebyshewMetric.h>
#include <shogun/distance/GeodesicMetric.h>
#include <shogun/distance/JensenMetric.h>
#include <shogun/distance/ManhattanMetric.h>
#include <shogun/distance/MinkowskiMetric.h>
#include <shogun/distance/HammingWordDistance.h>
#include <shogun/distance/ManhattanWordDistance.h>
#include <shogun/distance/CanberraWordDistance.h>
#include <shogun/distance/EuclideanDistance.h>
#include <shogun/distance/SparseEuclideanDistance.h>
#include <shogun/distance/BrayCurtisDistance.h>
#include <shogun/distance/ChiSquareDistance.h>
#include <shogun/distance/CosineDistance.h>
#include <shogun/distance/TanimotoDistance.h>
#include <shogun/distance/MahalanobisDistance.h>
#include <shogun/distance/DirectorDistance.h>
#include <shogun/distance/CustomMahalanobisDistance.h>
#include <shogun/distributions/Distribution.h>
#include <shogun/distributions/Histogram.h>
#include <shogun/distributions/HMM.h>
#include <shogun/distributions/LinearHMM.h>
#include <shogun/distributions/PositionalPWM.h>
#include <shogun/distributions/Gaussian.h>
#include <shogun/distributions/KernelDensity.h>
#include <shogun/clustering/GMM.h>
#include <shogun/distributions/classical/ProbabilityDistribution.h>
#include <shogun/distributions/classical/GaussianDistribution.h>
#include <shogun/evaluation/EvaluationResult.h>
#include <shogun/evaluation/Evaluation.h>
#include <shogun/evaluation/BinaryClassEvaluation.h>
#include <shogun/evaluation/ClusteringEvaluation.h>
#include <shogun/evaluation/ClusteringAccuracy.h>
#include <shogun/evaluation/ClusteringMutualInformation.h>
#include <shogun/evaluation/ContingencyTableEvaluation.h>
#include <shogun/evaluation/MulticlassAccuracy.h>
#include <shogun/evaluation/MeanAbsoluteError.h>
#include <shogun/evaluation/MeanSquaredError.h>
#include <shogun/evaluation/MeanSquaredLogError.h>
#include <shogun/evaluation/ROCEvaluation.h>
#include <shogun/evaluation/PRCEvaluation.h>
#include <shogun/evaluation/MachineEvaluation.h>
#include <shogun/evaluation/CrossValidation.h>
#include <shogun/evaluation/DifferentiableFunction.h>
#include <shogun/evaluation/GradientCriterion.h>
#include <shogun/evaluation/GradientEvaluation.h>
#include <shogun/evaluation/GradientResult.h>
#include <shogun/evaluation/MulticlassOVREvaluation.h>
#include <shogun/evaluation/SplittingStrategy.h>
#include <shogun/evaluation/StratifiedCrossValidationSplitting.h>
#include <shogun/evaluation/CrossValidationSplitting.h>
#include <shogun/evaluation/CrossValidationOutput.h>
#include <shogun/evaluation/CrossValidationPrintOutput.h>
#include <shogun/evaluation/CrossValidationMKLStorage.h>
#include <shogun/evaluation/CrossValidationMulticlassStorage.h>
#include <shogun/evaluation/StructuredAccuracy.h>
#include <shogun/evaluation/DirectorContingencyTableEvaluation.h>
#include <shogun/lib/Compressor.h>
#include <shogun/features/FeatureTypes.h>
#include <shogun/features/Features.h>
#include <shogun/features/streaming/StreamingFeatures.h>
#include <shogun/features/StringFeatures.h>
#include <shogun/features/streaming/StreamingStringFeatures.h>
#include <shogun/features/StringFileFeatures.h>
#include <shogun/features/DotFeatures.h>
#include <shogun/features/DirectorDotFeatures.h>
#include <shogun/features/BinnedDotFeatures.h>
#include <shogun/features/streaming/StreamingDotFeatures.h>
#include <shogun/features/SparseFeatures.h>
#include <shogun/features/streaming/StreamingSparseFeatures.h>
#include <shogun/features/DenseFeatures.h>
#include <shogun/features/streaming/StreamingDenseFeatures.h>
#include <shogun/features/DenseSubsetFeatures.h>
#include <shogun/features/DummyFeatures.h>
#include <shogun/features/AttributeFeatures.h>
#include <shogun/features/Alphabet.h>
#include <shogun/features/CombinedFeatures.h>
#include <shogun/features/CombinedDotFeatures.h>
#include <shogun/features/hashed/HashedDocDotFeatures.h>
#include <shogun/features/streaming/StreamingHashedDocDotFeatures.h>
#include <shogun/features/RandomKitchenSinksDotFeatures.h>
#include <shogun/features/RandomFourierDotFeatures.h>
#include <shogun/labels/Labels.h>
#include <shogun/labels/LabelsFactory.h>
#include <shogun/labels/DenseLabels.h>
#include <shogun/labels/BinaryLabels.h>
#include <shogun/labels/LatentLabels.h>
#include <shogun/labels/MulticlassLabels.h>
#include <shogun/labels/RegressionLabels.h>
#include <shogun/labels/StructuredLabels.h>
#include <shogun/labels/MultilabelLabels.h>
#include <shogun/features/RealFileFeatures.h>
#include <shogun/features/RealFileFeatures.h>
#include <shogun/features/FKFeatures.h>
#include <shogun/features/TOPFeatures.h>
#include <shogun/features/SNPFeatures.h>
#include <shogun/features/WDFeatures.h>
#include <shogun/features/hashed/HashedWDFeatures.h>
#include <shogun/features/hashed/HashedWDFeaturesTransposed.h>
#include <shogun/features/PolyFeatures.h>
#include <shogun/features/SparsePolyFeatures.h>
#include <shogun/features/LBPPyrDotFeatures.h>
#include <shogun/features/ExplicitSpecFeatures.h>
#include <shogun/features/ImplicitWeightedSpecFeatures.h>
#include <shogun/features/DataGenerator.h>
#include <shogun/features/streaming/generators/MeanShiftDataGenerator.h>
#include <shogun/features/streaming/generators/GaussianBlobsDataGenerator.h>
#include <shogun/features/LatentFeatures.h>
#include <shogun/features/MatrixFeatures.h>
#include <shogun/features/IndexFeatures.h>
#include <shogun/io/IOBuffer.h>
#include <shogun/io/streaming/ParseBuffer.h>
#include <shogun/io/streaming/InputParser.h>
#include <shogun/io/File.h>
#include <shogun/io/streaming/StreamingFile.h>
#include <shogun/io/streaming/StreamingFileFromFeatures.h>
#include <shogun/io/streaming/StreamingFileFromSparseFeatures.h>
#include <shogun/io/streaming/StreamingFileFromDenseFeatures.h>
#include <shogun/io/CSVFile.h>
#include <shogun/io/LibSVMFile.h>
#include <shogun/io/streaming/StreamingAsciiFile.h>
#include <shogun/classifier/vw/VwParser.h>
#include <shogun/io/streaming/StreamingVwFile.h>
#include <shogun/io/streaming/StreamingVwCacheFile.h>
#include <shogun/io/BinaryFile.h>
#include <shogun/io/HDF5File.h>
#include <shogun/io/SerializableFile.h>
#include <shogun/io/SerializableAsciiFile.h>
#include <shogun/io/SerializableHdf5File.h>
#include <shogun/io/SerializableJsonFile.h>
#include <shogun/io/SerializableXmlFile.h>
#include <shogun/io/NeuralNetworkFileReader.h>
#include <shogun/io/SimpleFile.h>
#include <shogun/io/MemoryMappedFile.h>
#include <shogun/features/FeatureTypes.h>
#include <shogun/kernel/Kernel.h>
#include <shogun/kernel/normalizer/KernelNormalizer.h>
#include <shogun/kernel/PyramidChi2.h>
#include <shogun/kernel/ANOVAKernel.h>
#include <shogun/kernel/AUCKernel.h>
#include <shogun/kernel/BesselKernel.h>
#include <shogun/kernel/normalizer/AvgDiagKernelNormalizer.h>
#include <shogun/kernel/normalizer/RidgeKernelNormalizer.h>
#include <shogun/kernel/CauchyKernel.h>
#include <shogun/kernel/Chi2Kernel.h>
#include <shogun/kernel/CombinedKernel.h>
#include <shogun/kernel/ProductKernel.h>
#include <shogun/kernel/string/CommUlongStringKernel.h>
#include <shogun/kernel/string/CommWordStringKernel.h>
#include <shogun/kernel/CircularKernel.h>
#include <shogun/kernel/ConstKernel.h>
#include <shogun/kernel/CustomKernel.h>
#include <shogun/kernel/DiagKernel.h>
#include <shogun/kernel/string/DistantSegmentsKernel.h>
#include <shogun/kernel/normalizer/DiceKernelNormalizer.h>
#include <shogun/kernel/ExponentialKernel.h>
#include <shogun/kernel/normalizer/ScatterKernelNormalizer.h>
#include <shogun/kernel/normalizer/VarianceKernelNormalizer.h>
#include <shogun/kernel/DistanceKernel.h>
#include <shogun/kernel/string/FixedDegreeStringKernel.h>
#include <shogun/kernel/ShiftInvariantKernel.h>
#include <shogun/kernel/GaussianKernel.h>
#include <shogun/kernel/DirectorKernel.h>
#include <shogun/kernel/GaussianShiftKernel.h>
#include <shogun/kernel/GaussianShortRealKernel.h>
#include <shogun/kernel/HistogramIntersectionKernel.h>
#include <shogun/kernel/string/HistogramWordStringKernel.h>
#include <shogun/kernel/normalizer/IdentityKernelNormalizer.h>
#include <shogun/kernel/InverseMultiQuadricKernel.h>
#include <shogun/kernel/DotKernel.h>
#include <shogun/kernel/string/LinearStringKernel.h>
#include <shogun/kernel/string/SparseSpatialSampleStringKernel.h>
#include <shogun/kernel/string/LocalAlignmentStringKernel.h>
#include <shogun/kernel/string/LocalityImprovedStringKernel.h>
#include <shogun/kernel/string/MatchWordStringKernel.h>
#include <shogun/kernel/MultiquadricKernel.h>
#include <shogun/kernel/string/OligoStringKernel.h>
#include <shogun/kernel/PolyKernel.h>
#include <shogun/kernel/string/PolyMatchStringKernel.h>
#include <shogun/kernel/PowerKernel.h>
#include <shogun/kernel/LogKernel.h>
#include <shogun/kernel/string/GaussianMatchStringKernel.h>
#include <shogun/kernel/string/SNPStringKernel.h>
#include <shogun/kernel/string/RegulatoryModulesStringKernel.h>
#include <shogun/kernel/string/PolyMatchWordStringKernel.h>
#include <shogun/kernel/string/SalzbergWordStringKernel.h>
#include <shogun/kernel/SigmoidKernel.h>
#include <shogun/kernel/string/SimpleLocalityImprovedStringKernel.h>
#include <shogun/kernel/SparseKernel.h>
#include <shogun/kernel/SphericalKernel.h>
#include <shogun/kernel/SplineKernel.h>
#include <shogun/kernel/normalizer/SqrtDiagKernelNormalizer.h>
#include <shogun/kernel/string/StringKernel.h>
#include <shogun/kernel/normalizer/TanimotoKernelNormalizer.h>
#include <shogun/kernel/TensorProductPairKernel.h>
#include <shogun/kernel/TStudentKernel.h>
#include <shogun/kernel/WaveletKernel.h>
#include <shogun/kernel/WaveKernel.h>
#include <shogun/kernel/string/WeightedCommWordStringKernel.h>
#include <shogun/kernel/string/WeightedDegreePositionStringKernel.h>
#include <shogun/kernel/string/WeightedDegreeStringKernel.h>
#include <shogun/kernel/WeightedDegreeRBFKernel.h>
#include <shogun/kernel/string/SpectrumMismatchRBFKernel.h>
#include <shogun/kernel/normalizer/ZeroMeanCenterKernelNormalizer.h>
#include <shogun/kernel/RationalQuadraticKernel.h>
#include <shogun/kernel/CircularKernel.h>
#include <shogun/kernel/JensenShannonKernel.h>
#include <shogun/kernel/LinearKernel.h>
#include <shogun/kernel/string/SubsequenceStringKernel.h>
#include <shogun/kernel/PeriodicKernel.h>
#include <shogun/kernel/LinearKernel.h>
#ifdef HAVE_LINALG_LIB
#include <shogun/kernel/ExponentialARDKernel.h>
#include <shogun/kernel/GaussianARDKernel.h>
#include <shogun/machine/gp/GaussianARDSparseKernel.h>
#endif
#include <shogun/lib/DataType.h>
#include <shogun/lib/SGReferencedData.h>
#include <shogun/lib/SGVector.h>
#include <shogun/lib/SGMatrix.h>
#include <shogun/lib/SGSparseVector.h>
#include <shogun/lib/SGSparseMatrix.h>
#include <shogun/lib/SGString.h>
#include <shogun/lib/SGStringList.h>
#include <shogun/lib/SGNDArray.h>
#include <shogun/lib/Cache.h>
#include <shogun/lib/List.h>
#include <shogun/lib/Signal.h>
#include <shogun/lib/Time.h>
#include <shogun/lib/Trie.h>
#include <shogun/lib/DynamicArray.h>
#include <shogun/structure/PlifBase.h>
#include <shogun/lib/Hash.h>
#include <shogun/lib/GCArray.h>
#include <shogun/lib/Compressor.h>
#include <shogun/lib/StructuredDataTypes.h>
#include <shogun/lib/StructuredData.h>
#include <shogun/lib/DynamicObjectArray.h>
#include <shogun/lib/WrappedObjectArray.h>
#include <shogun/lib/IndexBlock.h>
#include <shogun/lib/IndexBlockRelation.h>
#include <shogun/lib/IndexBlockGroup.h>
#include <shogun/lib/IndexBlockTree.h>
#include <shogun/lib/Data.h>
#include <shogun/lib/Tokenizer.h>
#include <shogun/lib/DelimiterTokenizer.h>
#include <shogun/lib/NGramTokenizer.h>
#include <shogun/lib/computation/engine/IndependentComputationEngine.h>
#include <shogun/lib/computation/engine/SerialComputationEngine.h>
#include <shogun/lib/computation/job/IndependentJob.h>
#include <shogun/lib/computation/jobresult/JobResult.h>
#include <shogun/lib/computation/jobresult/ScalarResult.h>
#include <shogun/lib/computation/jobresult/VectorResult.h>
#include <shogun/mathematics/Math.h>
#include <shogun/mathematics/Statistics.h>
#include <shogun/mathematics/SparseInverseCovariance.h>
/* Log-det framework */
#include <shogun/mathematics/linalg/ratapprox/tracesampler/TraceSampler.h>
#include <shogun/mathematics/linalg/ratapprox/tracesampler/NormalSampler.h>
#include <shogun/mathematics/linalg/ratapprox/tracesampler/ProbingSampler.h>
#include <shogun/mathematics/linalg/linop/LinearOperator.h>
#include <shogun/mathematics/linalg/linop/MatrixOperator.h>
#include <shogun/mathematics/linalg/linop/SparseMatrixOperator.h>
#include <shogun/mathematics/linalg/linop/DenseMatrixOperator.h>
#include <shogun/mathematics/linalg/ratapprox/opfunc/OperatorFunction.h>
#include <shogun/mathematics/linalg/ratapprox/opfunc/RationalApproximation.h>
#include <shogun/mathematics/linalg/ratapprox/logdet/opfunc/LogRationalApproximationIndividual.h>
#include <shogun/mathematics/linalg/ratapprox/logdet/opfunc/LogRationalApproximationCGM.h>
#include <shogun/mathematics/linalg/linsolver/LinearSolver.h>
#include <shogun/mathematics/linalg/linsolver/DirectSparseLinearSolver.h>
#include <shogun/mathematics/linalg/linsolver/DirectLinearSolverComplex.h>
#include <shogun/mathematics/linalg/linsolver/IterativeLinearSolver.h>
#include <shogun/mathematics/linalg/linsolver/ConjugateGradientSolver.h>
#include <shogun/mathematics/linalg/linsolver/ConjugateOrthogonalCGSolver.h>
#include <shogun/mathematics/linalg/linsolver/IterativeShiftedLinearFamilySolver.h>
#include <shogun/mathematics/linalg/linsolver/CGMShiftedFamilySolver.h>
#include <shogun/mathematics/linalg/eigsolver/EigenSolver.h>
#include <shogun/mathematics/linalg/eigsolver/LanczosEigenSolver.h>
#include <shogun/mathematics/linalg/ratapprox/logdet/LogDetEstimator.h>
#include <shogun/modelselection/ModelSelection.h>
#include <shogun/modelselection/ModelSelectionParameters.h>
#include <shogun/modelselection/GridSearchModelSelection.h>
#include <shogun/modelselection/RandomSearchModelSelection.h>
#ifdef USE_GPL_SHOGUN
#include <shogun/modelselection/GradientModelSelection.h>
#endif //USE_GPL_SHOGUN
#include <shogun/modelselection/ParameterCombination.h>
#include <shogun/converter/Converter.h>
#include <shogun/converter/EmbeddingConverter.h>
#ifdef USE_GPL_SHOGUN
#include <shogun/converter/LocallyLinearEmbedding.h>
#include <shogun/converter/NeighborhoodPreservingEmbedding.h>
#include <shogun/converter/LocalTangentSpaceAlignment.h>
#include <shogun/converter/LinearLocalTangentSpaceAlignment.h>
#include <shogun/converter/HessianLocallyLinearEmbedding.h>
#include <shogun/converter/KernelLocallyLinearEmbedding.h>
#include <shogun/converter/StochasticProximityEmbedding.h>
#endif //USE_GPL_SHOGUN
#include <shogun/converter/LocalityPreservingProjections.h>
#include <shogun/converter/Isomap.h>
#include <shogun/converter/DiffusionMaps.h>
#include <shogun/converter/LaplacianEigenmaps.h>
#include <shogun/converter/MultidimensionalScaling.h>
#include <shogun/converter/FactorAnalysis.h>
#include <shogun/converter/TDistributedStochasticNeighborEmbedding.h>
#include <shogun/converter/ManifoldSculpting.h>
#include <shogun/converter/HashedDocConverter.h>
#include <shogun/converter/ica/ICAConverter.h>
#include <shogun/converter/ica/Jade.h>
#include <shogun/converter/ica/SOBI.h>
#include <shogun/converter/ica/FFSep.h>
#include <shogun/converter/ica/JediSep.h>
#include <shogun/converter/ica/UWedgeSep.h>
#include <shogun/converter/ica/FastICA.h>
#include <shogun/lib/Compressor.h>
#include <shogun/features/FeatureTypes.h>
#include <shogun/preprocessor/Preprocessor.h>
#include <shogun/preprocessor/SparsePreprocessor.h>
#include <shogun/preprocessor/DensePreprocessor.h>
#include <shogun/preprocessor/SumOne.h>
#include <shogun/preprocessor/NormOne.h>
#include <shogun/preprocessor/LogPlusOne.h>
#include <shogun/preprocessor/PruneVarSubMean.h>
#include <shogun/preprocessor/RandomFourierGaussPreproc.h>
#include <shogun/preprocessor/HomogeneousKernelMap.h>
#include <shogun/preprocessor/PNorm.h>
#include <shogun/preprocessor/RescaleFeatures.h>
#include <shogun/preprocessor/DimensionReductionPreprocessor.h>
#include <shogun/preprocessor/PCA.h>
#include <shogun/preprocessor/KernelPCA.h>
#include <shogun/preprocessor/FisherLDA.h>
#include <shogun/preprocessor/StringPreprocessor.h>
#include <shogun/preprocessor/DecompressString.h>
#include <shogun/preprocessor/SortUlongString.h>
#include <shogun/preprocessor/SortWordString.h>
#include <shogun/preprocessor/FeatureSelection.h>
#include <shogun/preprocessor/DependenceMaximization.h>
#include <shogun/preprocessor/KernelDependenceMaximization.h>
#include <shogun/preprocessor/BAHSIC.h>
#include <shogun/regression/Regression.h>
#include <shogun/machine/Machine.h>
#include <shogun/machine/KernelMachine.h>
#include <shogun/regression/GaussianProcessRegression.h>
#include <shogun/regression/KernelRidgeRegression.h>
#include <shogun/regression/LinearRidgeRegression.h>
#include <shogun/regression/LeastSquaresRegression.h>
#include <shogun/regression/LeastAngleRegression.h>
#include <shogun/classifier/svm/SVM.h>
#include <shogun/classifier/svm/LibSVM.h>
#include <shogun/regression/svr/LibSVR.h>
#include <shogun/regression/svr/LibLinearRegression.h>
#include <shogun/classifier/mkl/MKL.h>
#include <shogun/regression/svr/MKLRegression.h>
#ifdef USE_SVMLIGHT
#include <shogun/classifier/svm/SVMLight.h>
#include <shogun/regression/svr/SVRLight.h>
#endif //USE_SVMLIGHT
#include <shogun/structure/PlifBase.h>
#include <shogun/structure/Plif.h>
#include <shogun/structure/PlifArray.h>
#include <shogun/structure/DynProg.h>
#include <shogun/structure/PlifMatrix.h>
#include <shogun/structure/IntronList.h>
#include <shogun/structure/SegmentLoss.h>
#include <shogun/structure/BmrmStatistics.h>
#include <shogun/structure/StructuredModel.h>
#include <shogun/structure/MulticlassModel.h>
#include <shogun/structure/MulticlassSOLabels.h>
#include <shogun/structure/HMSVMModel.h>
#include <shogun/structure/SequenceLabels.h>
#include <shogun/structure/StateModelTypes.h>
#include <shogun/structure/StateModel.h>
#include <shogun/structure/TwoStateModel.h>
#include <shogun/structure/DirectorStructuredModel.h>
#include <shogun/structure/MultilabelSOLabels.h>
#include <shogun/structure/MultilabelModel.h>
#include <shogun/structure/HashedMultilabelModel.h>
#include <shogun/structure/MultilabelCLRModel.h>
#include <shogun/structure/HierarchicalMultilabelModel.h>
#include <shogun/structure/FactorType.h>
#include <shogun/structure/Factor.h>
#include <shogun/structure/DisjointSet.h>
#include <shogun/structure/FactorGraph.h>
#include <shogun/features/FactorGraphFeatures.h>
#include <shogun/labels/FactorGraphLabels.h>
#include <shogun/structure/MAPInference.h>
#include <shogun/structure/GraphCut.h>
#include <shogun/structure/FactorGraphModel.h>
#include <shogun/structure/SOSVMHelper.h>
#include <shogun/machine/StructuredOutputMachine.h>
#include <shogun/machine/LinearStructuredOutputMachine.h>
#include <shogun/machine/KernelStructuredOutputMachine.h>
#include <shogun/structure/DualLibQPBMSOSVM.h>
#ifdef USE_MOSEK
#include <shogun/structure/PrimalMosekSOSVM.h>
#endif /* USE_MOSEK */
#include <shogun/structure/StochasticSOSVM.h>
#include <shogun/structure/FWSOSVM.h>
#include <shogun/multiclass/tree/TreeMachine.h>
#include <shogun/multiclass/tree/RelaxedTreeNodeData.h>
#include <shogun/multiclass/tree/ConditionalProbabilityTreeNodeData.h>
#include <shogun/multiclass/tree/ConditionalProbabilityTree.h>
#include <shogun/multiclass/tree/BalancedConditionalProbabilityTree.h>
#include <shogun/multiclass/tree/RandomConditionalProbabilityTree.h>
#include <shogun/multiclass/tree/RelaxedTree.h>
#include <shogun/multiclass/tree/RelaxedTreeUtil.h>
#include <shogun/multiclass/tree/TreeMachineNode.h>
#include <shogun/multiclass/tree/VwConditionalProbabilityTree.h>
#include <shogun/multiclass/tree/ID3TreeNodeData.h>
#include <shogun/multiclass/tree/ID3ClassifierTree.h>
#include <shogun/multiclass/tree/C45TreeNodeData.h>
#include <shogun/multiclass/tree/C45ClassifierTree.h>
#include <shogun/multiclass/tree/CARTreeNodeData.h>
#include <shogun/multiclass/tree/CARTree.h>
#include <shogun/multiclass/tree/CHAIDTreeNodeData.h>
#include <shogun/multiclass/tree/CHAIDTree.h>
#include <shogun/multiclass/RejectionStrategy.h>
#include <shogun/multiclass/MulticlassStrategy.h>
#include <shogun/multiclass/MulticlassOneVsRestStrategy.h>
#include <shogun/multiclass/MulticlassOneVsOneStrategy.h>
#include <shogun/machine/BaseMulticlassMachine.h>
#include <shogun/machine/MulticlassMachine.h>
#include <shogun/machine/NativeMulticlassMachine.h>
#include <shogun/machine/LinearMulticlassMachine.h>
#include <shogun/machine/KernelMulticlassMachine.h>
#include <shogun/multiclass/MulticlassSVM.h>
#include <shogun/classifier/mkl/MKLMulticlass.h>
#include <shogun/multiclass/ecoc/ECOCStrategy.h>
#include <shogun/multiclass/ecoc/ECOCEncoder.h>
#include <shogun/multiclass/ecoc/ECOCOVOEncoder.h>
#include <shogun/multiclass/ecoc/ECOCRandomSparseEncoder.h>
#include <shogun/multiclass/ecoc/ECOCRandomDenseEncoder.h>
#include <shogun/multiclass/ecoc/ECOCDiscriminantEncoder.h>
#include <shogun/multiclass/ecoc/ECOCForestEncoder.h>
#include <shogun/multiclass/ecoc/ECOCDecoder.h>
#include <shogun/multiclass/ecoc/ECOCOVREncoder.h>
#include <shogun/multiclass/ecoc/ECOCSimpleDecoder.h>
#include <shogun/multiclass/ecoc/ECOCHDDecoder.h>
#include <shogun/multiclass/ecoc/ECOCIHDDecoder.h>
#include <shogun/multiclass/ecoc/ECOCEDDecoder.h>
#include <shogun/multiclass/ecoc/ECOCAEDDecoder.h>
#include <shogun/multiclass/ecoc/ECOCLLBDecoder.h>
#include <shogun/multiclass/MulticlassTreeGuidedLogisticRegression.h>
#include <shogun/multiclass/MulticlassLogisticRegression.h>
#include <shogun/multiclass/MulticlassLibLinear.h>
#include <shogun/multiclass/MulticlassOCAS.h>
#include <shogun/multiclass/MulticlassSVM.h>
#include <shogun/multiclass/LaRank.h>
#include <shogun/multiclass/MulticlassLibSVM.h>
#include <shogun/multiclass/GMNPSVM.h>
#include <shogun/multiclass/ScatterSVM.h>
#include <shogun/multiclass/KNN.h>
#include <shogun/multiclass/GaussianNaiveBayes.h>
#include <shogun/multiclass/QDA.h>
#include <shogun/multiclass/MCLDA.h>
#include <shogun/multiclass/ShareBoost.h>
#include <shogun/transfer/multitask/MultitaskKernelNormalizer.h>
#include <shogun/transfer/multitask/MultitaskKernelMklNormalizer.h>
#include <shogun/transfer/multitask/MultitaskKernelTreeNormalizer.h>
#include <shogun/transfer/multitask/MultitaskKernelMaskNormalizer.h>
#include <shogun/transfer/multitask/MultitaskKernelMaskPairNormalizer.h>
#include <shogun/transfer/multitask/MultitaskKernelPlifNormalizer.h>
#include <shogun/transfer/multitask/LibLinearMTL.h>
#include <shogun/transfer/multitask/Task.h>
#include <shogun/transfer/multitask/TaskRelation.h>
#include <shogun/transfer/multitask/TaskTree.h>
#include <shogun/transfer/multitask/TaskGroup.h>
#include <shogun/transfer/multitask/MultitaskLinearMachine.h>
#include <shogun/transfer/multitask/MultitaskLeastSquaresRegression.h>
#include <shogun/transfer/multitask/MultitaskLogisticRegression.h>
#include <shogun/transfer/multitask/MultitaskL12LogisticRegression.h>
#include <shogun/transfer/multitask/MultitaskTraceLogisticRegression.h>
#include <shogun/transfer/multitask/MultitaskClusteredLogisticRegression.h>
#include <shogun/transfer/multitask/MultitaskROCEvaluation.h>
#ifdef USE_SVMLIGHT
#include <shogun/transfer/domain_adaptation/DomainAdaptationSVM.h>
#endif /* USE_SVMLIGHT */
#include <shogun/transfer/domain_adaptation/DomainAdaptationSVMLinear.h>
#include <shogun/transfer/domain_adaptation/DomainAdaptationMulticlassLibLinear.h>
#include <shogun/loss/LossFunction.h>
#include <shogun/loss/HingeLoss.h>
#include <shogun/loss/LogLoss.h>
#include <shogun/loss/LogLossMargin.h>
#include <shogun/loss/SmoothHingeLoss.h>
#include <shogun/loss/SquaredHingeLoss.h>
#include <shogun/loss/SquaredLoss.h>
#include <shogun/statistics/HypothesisTest.h>
#include <shogun/statistics/IndependenceTest.h>
#include <shogun/statistics/TwoSampleTest.h>
#include <shogun/statistics/KernelTwoSampleTest.h>
#include <shogun/statistics/StreamingMMD.h>
#include <shogun/statistics/LinearTimeMMD.h>
#include <shogun/statistics/QuadraticTimeMMD.h>
#include <shogun/statistics/KernelIndependenceTest.h>
#include <shogun/statistics/HSIC.h>
#include <shogun/statistics/NOCCO.h>
#include <shogun/statistics/KernelMeanMatching.h>
#include <shogun/statistics/KernelSelection.h>
#include <shogun/statistics/MMDKernelSelection.h>
#include <shogun/statistics/MMDKernelSelectionComb.h>
#include <shogun/statistics/MMDKernelSelectionMedian.h>
#include <shogun/statistics/MMDKernelSelectionMax.h>
#include <shogun/statistics/MMDKernelSelectionOpt.h>
#include <shogun/statistics/MMDKernelSelectionCombOpt.h>
#include <shogun/statistics/MMDKernelSelectionCombMaxL2.h>
#include <shogun/latent/LatentModel.h>
#include <shogun/latent/DirectorLatentModel.h>
#include <shogun/machine/LinearLatentMachine.h>
#include <shogun/latent/LatentSVM.h>
#include <shogun/metric/LMNN.h>
#include <shogun/optimization/Minimizer.h>
#include <shogun/optimization/FirstOrderMinimizer.h>
#include <shogun/optimization/lbfgs/lbfgscommon.h>
#include <shogun/optimization/lbfgs/LBFGSMinimizer.h>
#ifdef USE_GPL_SHOGUN
#ifdef HAVE_NLOPT
#include <shogun/optimization/nloptcommon.h>
#include <shogun/optimization/NLOPTMinimizer.h>
#endif //HAVE_NLOPT
#endif //USE_GPL_SHOGUN
#include <shogun/evaluation/DifferentiableFunction.h>
#include <shogun/machine/gp/LikelihoodModel.h>
#include <shogun/machine/gp/ProbitLikelihood.h>
#include <shogun/machine/gp/LogitLikelihood.h>
#include <shogun/machine/gp/SoftMaxLikelihood.h>
#include <shogun/machine/gp/GaussianLikelihood.h>
#include <shogun/machine/gp/StudentsTLikelihood.h>
#include <shogun/machine/gp/VariationalLikelihood.h>
#include <shogun/machine/gp/VariationalGaussianLikelihood.h>
#include <shogun/machine/gp/NumericalVGLikelihood.h>
#include <shogun/machine/gp/DualVariationalGaussianLikelihood.h>
#include <shogun/machine/gp/LogitVGLikelihood.h>
#include <shogun/machine/gp/LogitVGPiecewiseBoundLikelihood.h>
#include <shogun/machine/gp/LogitDVGLikelihood.h>
#include <shogun/machine/gp/ProbitVGLikelihood.h>
#include <shogun/machine/gp/StudentsTVGLikelihood.h>
#include <shogun/machine/gp/MeanFunction.h>
#include <shogun/machine/gp/ZeroMean.h>
#include <shogun/machine/gp/ConstMean.h>
#include <shogun/machine/gp/Inference.h>
#include <shogun/machine/gp/LaplaceInference.h>
#include <shogun/machine/gp/SparseInference.h>
#include <shogun/machine/gp/SingleFITCInference.h>
#include <shogun/machine/gp/SingleLaplaceInferenceMethod.h>
#include <shogun/machine/gp/SingleSparseInference.h>
#include <shogun/machine/gp/MultiLaplaceInferenceMethod.h>
#include <shogun/machine/gp/ExactInferenceMethod.h>
#include <shogun/machine/gp/FITCInferenceMethod.h>
#include <shogun/machine/gp/VarDTCInferenceMethod.h>
#include <shogun/machine/gp/SingleFITCLaplaceInferenceMethod.h>
#include <shogun/machine/gp/EPInferenceMethod.h>
#include <shogun/machine/gp/KLInference.h>
#include <shogun/machine/gp/KLLowerTriangularInference.h>
#include <shogun/machine/gp/KLCovarianceInferenceMethod.h>
#include <shogun/machine/gp/KLDiagonalInferenceMethod.h>
#include <shogun/machine/gp/KLCholeskyInferenceMethod.h>
#include <shogun/machine/gp/KLDualInferenceMethod.h>
#include <shogun/machine/GaussianProcessMachine.h>
#include <shogun/classifier/GaussianProcessClassification.h>
#include <shogun/regression/GaussianProcessRegression.h>
#include <shogun/ensemble/CombinationRule.h>
#include <shogun/ensemble/MeanRule.h>
#include <shogun/ensemble/WeightedMajorityVote.h>
#include <shogun/ensemble/MajorityVote.h>
#include <shogun/neuralnets/NeuralNetwork.h>
#include <shogun/neuralnets/NeuralLayer.h>
#include <shogun/neuralnets/NeuralInputLayer.h>
#include <shogun/neuralnets/NeuralLinearLayer.h>
#include <shogun/neuralnets/NeuralLogisticLayer.h>
#include <shogun/neuralnets/NeuralSoftmaxLayer.h>
#include <shogun/neuralnets/NeuralRectifiedLinearLayer.h>
#include <shogun/neuralnets/ConvolutionalFeatureMap.h>
#include <shogun/neuralnets/NeuralConvolutionalLayer.h>
#include <shogun/neuralnets/RBM.h>
#include <shogun/neuralnets/DeepBeliefNetwork.h>
#include <shogun/neuralnets/Autoencoder.h>
#include <shogun/neuralnets/DeepAutoencoder.h>
#include <shogun/neuralnets/NeuralLayers.h>
#include <shogun/machine/BaggingMachine.h>
#include <shogun/machine/RandomForest.h>
#include <shogun/machine/StochasticGBMachine.h>
#include <stdint.h> // Use the C99 official header
#define SWIGWORDSIZE64
#ifndef LONG_MAX
#include <limits.h>
#endif
#if (__WORDSIZE == 32) || (LONG_MAX == INT_MAX)
# error "SWIG wrapped code invalid in 32 bit architecture, regenerate code using -DSWIGWORDSIZE32"
#endif
#ifdef SWIGRUBY
extern "C" {
#include <ruby.h>
#include <narray.h>
#include <stdlib.h>
#include <stdio.h>
}
VALUE (*na_to_array_dl)(VALUE);
VALUE (*na_to_narray_dl)(VALUE);
VALUE cNArray;
#include <dlfcn.h>
#endif
#if defined(SWIGPERL) && defined(HAVE_PDL)
#ifdef __cplusplus
extern "C" {
#endif
#include <pdlcore.h>
#include <ppport.h>
#ifdef __cplusplus
}
#endif
#endif
/* required for python */
#define SWIG_FILE_WITH_INIT
#include <shogun/base/init.h>
#include <shogun/lib/common.h>
#include <shogun/io/SGIO.h>
#include <shogun/lib/ShogunException.h>
#include <shogun/lib/DataType.h>
#include <shogun/base/Version.h>
#include <shogun/base/Parallel.h>
#include <shogun/base/SGObject.h>
extern void sg_global_print_message(FILE* target, const char* str);
extern void sg_global_print_warning(FILE* target, const char* str);
extern void sg_global_print_error(FILE* target, const char* str);
#ifndef DISABLE_CANCEL_CALLBACK
extern void sg_global_cancel_computations(bool &delayed, bool &immediately);
#endif
#ifdef SWIGR
#include <Rdefines.h>
#endif
#ifdef SWIGPYTHON
#include <shogun/io/SerializableFile.h>
#include <shogun/io/SerializableAsciiFile.h>
#include <shogun/io/SerializableHdf5File.h>
static int pickle_ascii;
#endif
using namespace shogun;
#include <iostream>
#include <stdexcept>
namespace swig {
class SwigGCReferences {
VALUE _hash;
SwigGCReferences() : _hash(Qnil) {
}
~SwigGCReferences() {
if (_hash != Qnil)
rb_gc_unregister_address(&_hash);
}
static void EndProcHandler(VALUE) {
// Ruby interpreter ending - _hash can no longer be accessed.
SwigGCReferences &s_references = instance();
s_references._hash = Qnil;
}
public:
static SwigGCReferences& instance() {
// Hash of all GC_VALUE's currently in use
static SwigGCReferences s_references;
return s_references;
}
static void initialize() {
SwigGCReferences &s_references = instance();
if (s_references._hash == Qnil) {
rb_set_end_proc(&EndProcHandler, Qnil);
s_references._hash = rb_hash_new();
rb_gc_register_address(&s_references._hash);
}
}
void GC_register(VALUE& obj) {
if (FIXNUM_P(obj) || SPECIAL_CONST_P(obj) || SYMBOL_P(obj))
return;
if (_hash != Qnil) {
VALUE val = rb_hash_aref(_hash, obj);
unsigned n = FIXNUM_P(val) ? NUM2UINT(val) : 0;
++n;
rb_hash_aset(_hash, obj, INT2NUM(n));
}
}
void GC_unregister(const VALUE& obj) {
if (FIXNUM_P(obj) || SPECIAL_CONST_P(obj) || SYMBOL_P(obj))
return;
// this test should not be needed but I've noticed some very erratic
// behavior of none being unregistered in some very rare situations.
if (BUILTIN_TYPE(obj) == T_NONE)
return;
if (_hash != Qnil) {
VALUE val = rb_hash_aref(_hash, obj);
unsigned n = FIXNUM_P(val) ? NUM2UINT(val) : 1;
--n;
if (n)
rb_hash_aset(_hash, obj, INT2NUM(n));
else
rb_hash_delete(_hash, obj);
}
}
};
class GC_VALUE {
protected:
VALUE _obj;
static ID hash_id;
static ID lt_id;
static ID gt_id;
static ID eq_id;
static ID le_id;
static ID ge_id;
static ID pos_id;
static ID neg_id;
static ID inv_id;
static ID add_id;
static ID sub_id;
static ID mul_id;
static ID div_id;
static ID mod_id;
static ID and_id;
static ID or_id;
static ID xor_id;
static ID lshift_id;
static ID rshift_id;
struct OpArgs
{
VALUE src;
ID id;
int nargs;
VALUE target;
};
public:
GC_VALUE() : _obj(Qnil)
{
}
GC_VALUE(const GC_VALUE& item) : _obj(item._obj)
{
SwigGCReferences::instance().GC_register(_obj);
}
GC_VALUE(VALUE obj) :_obj(obj)
{
SwigGCReferences::instance().GC_register(_obj);
}
~GC_VALUE()
{
SwigGCReferences::instance().GC_unregister(_obj);
}
GC_VALUE & operator=(const GC_VALUE& item)
{
SwigGCReferences::instance().GC_unregister(_obj);
_obj = item._obj;
SwigGCReferences::instance().GC_register(_obj);
return *this;
}
operator VALUE() const
{
return _obj;
}
VALUE inspect() const
{
return rb_inspect(_obj);
}
VALUE to_s() const
{
return rb_inspect(_obj);
}
static VALUE swig_rescue_swallow(VALUE)
{
/*
VALUE errstr = rb_obj_as_string(rb_errinfo());
printf("Swallowing error: '%s'\n", RSTRING_PTR(StringValue(errstr)));
*/
return Qnil; /* Swallow Ruby exception */
}
static VALUE swig_rescue_funcall(VALUE p)
{
OpArgs* args = (OpArgs*) p;
return rb_funcall(args->src, args->id, args->nargs, args->target);
}
bool relational_equal_op(const GC_VALUE& other, const ID& op_id, bool (*op_func)(const VALUE& a, const VALUE& b)) const
{
if (FIXNUM_P(_obj) && FIXNUM_P(other._obj)) {
return op_func(_obj, other._obj);
}
bool res = false;
VALUE ret = Qnil;
SWIG_RUBY_THREAD_BEGIN_BLOCK;
if (rb_respond_to(_obj, op_id)) {
OpArgs args;
args.src = _obj;
args.id = op_id;
args.nargs = 1;
args.target = VALUE(other);
ret = rb_rescue(RUBY_METHOD_FUNC(swig_rescue_funcall), VALUE(&args),
(RUBY_METHOD_FUNC(swig_rescue_swallow)), Qnil);
}
if (ret == Qnil) {
VALUE a = rb_funcall( _obj, hash_id, 0 );
VALUE b = rb_funcall( VALUE(other), hash_id, 0 );
res = op_func(a, b);
} else {
res = RTEST(ret);
}
SWIG_RUBY_THREAD_END_BLOCK;
return res;
}
static bool operator_eq(const VALUE& a, const VALUE& b) { return a == b; }
static bool operator_lt(const VALUE& a, const VALUE& b) { return a < b; }
static bool operator_le(const VALUE& a, const VALUE& b) { return a <= b; }
static bool operator_gt(const VALUE& a, const VALUE& b) { return a > b; }
static bool operator_ge(const VALUE& a, const VALUE& b) { return a >= b; }
bool operator==(const GC_VALUE& other) const { return relational_equal_op(other, eq_id, operator_eq); }
bool operator<(const GC_VALUE& other) const { return relational_equal_op(other, lt_id, operator_lt); }
bool operator<=(const GC_VALUE& other) const { return relational_equal_op(other, le_id, operator_le); }
bool operator>(const GC_VALUE& other) const { return relational_equal_op(other, gt_id, operator_gt); }
bool operator>=(const GC_VALUE& other) const { return relational_equal_op(other, ge_id, operator_ge); }
bool operator!=(const GC_VALUE& other) const
{
return !(this->operator==(other));
}
GC_VALUE unary_op(const ID& op_id) const
{
VALUE ret = Qnil;
SWIG_RUBY_THREAD_BEGIN_BLOCK;
OpArgs args;
args.src = _obj;
args.id = op_id;
args.nargs = 0;
args.target = Qnil;
ret = rb_rescue(RUBY_METHOD_FUNC(swig_rescue_funcall), VALUE(&args),
(RUBY_METHOD_FUNC(swig_rescue_swallow)), Qnil);
SWIG_RUBY_THREAD_END_BLOCK;
return ret;
}
GC_VALUE operator+() const { return unary_op(pos_id); }
GC_VALUE operator-() const { return unary_op(neg_id); }
GC_VALUE operator~() const { return unary_op(inv_id); }
GC_VALUE binary_op(const GC_VALUE& other, const ID& op_id) const
{
VALUE ret = Qnil;
SWIG_RUBY_THREAD_BEGIN_BLOCK;
OpArgs args;
args.src = _obj;
args.id = op_id;
args.nargs = 1;
args.target = VALUE(other);
ret = rb_rescue(RUBY_METHOD_FUNC(swig_rescue_funcall), VALUE(&args),
(RUBY_METHOD_FUNC(swig_rescue_swallow)), Qnil);
SWIG_RUBY_THREAD_END_BLOCK;
return GC_VALUE(ret);
}
GC_VALUE operator+(const GC_VALUE& other) const { return binary_op(other, add_id); }
GC_VALUE operator-(const GC_VALUE& other) const { return binary_op(other, sub_id); }
GC_VALUE operator*(const GC_VALUE& other) const { return binary_op(other, mul_id); }
GC_VALUE operator/(const GC_VALUE& other) const { return binary_op(other, div_id); }
GC_VALUE operator%(const GC_VALUE& other) const { return binary_op(other, mod_id); }
GC_VALUE operator&(const GC_VALUE& other) const { return binary_op(other, and_id); }
GC_VALUE operator^(const GC_VALUE& other) const { return binary_op(other, xor_id); }
GC_VALUE operator|(const GC_VALUE& other) const { return binary_op(other, or_id); }
GC_VALUE operator<<(const GC_VALUE& other) const { return binary_op(other, lshift_id); }
GC_VALUE operator>>(const GC_VALUE& other) const { return binary_op(other, rshift_id); }
};
ID GC_VALUE::hash_id = rb_intern("hash");
ID GC_VALUE::lt_id = rb_intern("<");
ID GC_VALUE::gt_id = rb_intern(">");
ID GC_VALUE::eq_id = rb_intern("==");
ID GC_VALUE::le_id = rb_intern("<=");
ID GC_VALUE::ge_id = rb_intern(">=");
ID GC_VALUE::pos_id = rb_intern("+@");
ID GC_VALUE::neg_id = rb_intern("-@");
ID GC_VALUE::inv_id = rb_intern("~");
ID GC_VALUE::add_id = rb_intern("+");
ID GC_VALUE::sub_id = rb_intern("-");
ID GC_VALUE::mul_id = rb_intern("*");
ID GC_VALUE::div_id = rb_intern("/");
ID GC_VALUE::mod_id = rb_intern("%");
ID GC_VALUE::and_id = rb_intern("&");
ID GC_VALUE::or_id = rb_intern("|");
ID GC_VALUE::xor_id = rb_intern("^");
ID GC_VALUE::lshift_id = rb_intern("<<");
ID GC_VALUE::rshift_id = rb_intern(">>");
typedef GC_VALUE LANGUAGE_OBJ;
} // namespace swig
#if defined(__GNUC__)
# if __GNUC__ == 2 && __GNUC_MINOR <= 96
# define SWIG_STD_NOMODERN_STL
# endif
#endif
#include <string>
#include <stddef.h>
namespace swig {
struct stop_iteration {
};
/**
* Abstract base class used to represent all iterators of STL containers.
*/
struct ConstIterator {
public:
typedef ConstIterator self_type;
protected:
GC_VALUE _seq;
protected:
ConstIterator(VALUE seq) : _seq(seq)
{
}
// Random access iterator methods, but not required in Ruby
virtual ptrdiff_t distance(const ConstIterator &x) const
{
throw std::invalid_argument("distance not supported");
}
virtual bool equal (const ConstIterator &x) const
{
throw std::invalid_argument("equal not supported");
}
virtual self_type* advance(ptrdiff_t n)
{
throw std::invalid_argument("advance not supported");
}
public:
virtual ~ConstIterator() {}
// Access iterator method, required by Ruby
virtual VALUE value() const {
throw std::invalid_argument("value not supported");
return Qnil;
};
virtual VALUE setValue( const VALUE& v ) {
throw std::invalid_argument("value= not supported");
return Qnil;
}
virtual self_type* next( size_t n = 1 )
{
return this->advance( n );
}
virtual self_type* previous( size_t n = 1 )
{
ptrdiff_t nn = n;
return this->advance( -nn );
}
virtual VALUE to_s() const {
throw std::invalid_argument("to_s not supported");
return Qnil;
}
virtual VALUE inspect() const {
throw std::invalid_argument("inspect not supported");
return Qnil;
}
virtual ConstIterator *dup() const
{
throw std::invalid_argument("dup not supported");
return NULL;
}
//
// C++ common/needed methods. We emulate a bidirectional
// operator, to be compatible with all the STL.
// The iterator traits will then tell the STL what type of
// iterator we really are.
//
ConstIterator() : _seq( Qnil )
{
}
ConstIterator( const self_type& b ) : _seq( b._seq )
{
}
self_type& operator=( const self_type& b )
{
_seq = b._seq;
return *this;
}
bool operator == (const ConstIterator& x) const
{
return equal(x);
}
bool operator != (const ConstIterator& x) const
{
return ! operator==(x);
}
// Pre-decrement operator
self_type& operator--()
{
return *previous();
}
// Pre-increment operator
self_type& operator++()
{
return *next();
}
// Post-decrement operator
self_type operator--(int)
{
self_type r = *this;
previous();
return r;
}
// Post-increment operator
self_type operator++(int)
{
self_type r = *this;
next();
return r;
}
ConstIterator& operator += (ptrdiff_t n)
{
return *advance(n);
}
ConstIterator& operator -= (ptrdiff_t n)
{
return *advance(-n);
}
ConstIterator* operator + (ptrdiff_t n) const
{
return dup()->advance(n);
}
ConstIterator* operator - (ptrdiff_t n) const
{
return dup()->advance(-n);
}
ptrdiff_t operator - (const ConstIterator& x) const
{
return x.distance(*this);
}
static swig_type_info* descriptor() {
static int init = 0;
static swig_type_info* desc = 0;
if (!init) {
desc = SWIG_TypeQuery("swig::ConstIterator *");
init = 1;
}
return desc;
}
};
/**
* Abstract base class used to represent all non-const iterators of STL containers.
*
*/
struct Iterator : public ConstIterator {
public:
typedef Iterator self_type;
protected:
Iterator(VALUE seq) : ConstIterator(seq)
{
}
virtual self_type* advance(ptrdiff_t n)
{
throw std::invalid_argument("operation not supported");
}
public:
static swig_type_info* descriptor() {
static int init = 0;
static swig_type_info* desc = 0;
if (!init) {
desc = SWIG_TypeQuery("swig::Iterator *");
init = 1;
}
return desc;
}
virtual Iterator *dup() const
{
throw std::invalid_argument("dup not supported");
return NULL;
}
virtual self_type* next( size_t n = 1 )
{
return this->advance( n );
}
virtual self_type* previous( size_t n = 1 )
{
ptrdiff_t nn = n;
return this->advance( -nn );
}
bool operator == (const ConstIterator& x) const
{
return equal(x);
}
bool operator != (const Iterator& x) const
{
return ! operator==(x);
}
Iterator& operator += (ptrdiff_t n)
{
return *advance(n);
}
Iterator& operator -= (ptrdiff_t n)
{
return *advance(-n);
}
Iterator* operator + (ptrdiff_t n) const
{
return dup()->advance(n);
}
Iterator* operator - (ptrdiff_t n) const
{
return dup()->advance(-n);
}
ptrdiff_t operator - (const Iterator& x) const
{
return x.distance(*this);
}
};
}
SWIGINTERN VALUE
SWIG_ruby_failed(void)
{
return Qnil;
}
/*@SWIG:/usr/local/share/swig/3.0.10/ruby/rubyprimtypes.swg,19,%ruby_aux_method@*/
SWIGINTERN VALUE SWIG_AUX_NUM2ULONG(VALUE *args)
{
VALUE obj = args[0];
VALUE type = TYPE(obj);
unsigned long *res = (unsigned long *)(args[1]);
*res = type == T_FIXNUM ? NUM2ULONG(obj) : rb_big2ulong(obj);
return obj;
}
/*@SWIG@*/
SWIGINTERN int
SWIG_AsVal_unsigned_SS_long (VALUE obj, unsigned long *val)
{
VALUE type = TYPE(obj);
if ((type == T_FIXNUM) || (type == T_BIGNUM)) {
unsigned long v;
VALUE a[2];
a[0] = obj;
a[1] = (VALUE)(&v);
if (rb_rescue(RUBY_METHOD_FUNC(SWIG_AUX_NUM2ULONG), (VALUE)a, RUBY_METHOD_FUNC(SWIG_ruby_failed), 0) != Qnil) {
if (val) *val = v;
return SWIG_OK;
}
}
return SWIG_TypeError;
}
#if defined(LLONG_MAX) && !defined(SWIG_LONG_LONG_AVAILABLE)
# define SWIG_LONG_LONG_AVAILABLE
#endif
#ifdef SWIG_LONG_LONG_AVAILABLE
/*@SWIG:/usr/local/share/swig/3.0.10/ruby/rubyprimtypes.swg,19,%ruby_aux_method@*/
SWIGINTERN VALUE SWIG_AUX_NUM2ULL(VALUE *args)
{
VALUE obj = args[0];
VALUE type = TYPE(obj);
long long *res = (long long *)(args[1]);
*res = type == T_FIXNUM ? NUM2ULL(obj) : rb_big2ull(obj);
return obj;
}
/*@SWIG@*/
SWIGINTERN int
SWIG_AsVal_unsigned_SS_long_SS_long (VALUE obj, unsigned long long *val)
{
VALUE type = TYPE(obj);
if ((type == T_FIXNUM) || (type == T_BIGNUM)) {
unsigned long long v;
VALUE a[2];
a[0] = obj;
a[1] = (VALUE)(&v);
if (rb_rescue(RUBY_METHOD_FUNC(SWIG_AUX_NUM2ULL), (VALUE)a, RUBY_METHOD_FUNC(SWIG_ruby_failed), 0) != Qnil) {
if (val) *val = v;
return SWIG_OK;
}
}
return SWIG_TypeError;
}
#endif
SWIGINTERNINLINE int
SWIG_AsVal_size_t (VALUE obj, size_t *val)
{
int res = SWIG_TypeError;
#ifdef SWIG_LONG_LONG_AVAILABLE
if (sizeof(size_t) <= sizeof(unsigned long)) {
#endif
unsigned long v;
res = SWIG_AsVal_unsigned_SS_long (obj, val ? &v : 0);
if (SWIG_IsOK(res) && val) *val = static_cast< size_t >(v);
#ifdef SWIG_LONG_LONG_AVAILABLE
} else if (sizeof(size_t) <= sizeof(unsigned long long)) {
unsigned long long v;
res = SWIG_AsVal_unsigned_SS_long_SS_long (obj, val ? &v : 0);
if (SWIG_IsOK(res) && val) *val = static_cast< size_t >(v);
}
#endif
return res;
}
/*@SWIG:/usr/local/share/swig/3.0.10/ruby/rubyprimtypes.swg,19,%ruby_aux_method@*/
SWIGINTERN VALUE SWIG_AUX_NUM2LONG(VALUE *args)
{
VALUE obj = args[0];
VALUE type = TYPE(obj);
long *res = (long *)(args[1]);
*res = type == T_FIXNUM ? NUM2LONG(obj) : rb_big2long(obj);
return obj;
}
/*@SWIG@*/
SWIGINTERN int
SWIG_AsVal_long (VALUE obj, long* val)
{
VALUE type = TYPE(obj);
if ((type == T_FIXNUM) || (type == T_BIGNUM)) {
long v;
VALUE a[2];
a[0] = obj;
a[1] = (VALUE)(&v);
if (rb_rescue(RUBY_METHOD_FUNC(SWIG_AUX_NUM2LONG), (VALUE)a, RUBY_METHOD_FUNC(SWIG_ruby_failed), 0) != Qnil) {
if (val) *val = v;
return SWIG_OK;
}
}
return SWIG_TypeError;
}
#ifdef SWIG_LONG_LONG_AVAILABLE
/*@SWIG:/usr/local/share/swig/3.0.10/ruby/rubyprimtypes.swg,19,%ruby_aux_method@*/
SWIGINTERN VALUE SWIG_AUX_NUM2LL(VALUE *args)
{
VALUE obj = args[0];
VALUE type = TYPE(obj);
long long *res = (long long *)(args[1]);
*res = type == T_FIXNUM ? NUM2LL(obj) : rb_big2ll(obj);
return obj;
}
/*@SWIG@*/
SWIGINTERN int
SWIG_AsVal_long_SS_long (VALUE obj, long long *val)
{
VALUE type = TYPE(obj);
if ((type == T_FIXNUM) || (type == T_BIGNUM)) {
long long v;
VALUE a[2];
a[0] = obj;
a[1] = (VALUE)(&v);
if (rb_rescue(RUBY_METHOD_FUNC(SWIG_AUX_NUM2LL), (VALUE)a, RUBY_METHOD_FUNC(SWIG_ruby_failed), 0) != Qnil) {
if (val) *val = v;
return SWIG_OK;
}
}
return SWIG_TypeError;
}
#endif
SWIGINTERNINLINE int
SWIG_AsVal_ptrdiff_t (VALUE obj, ptrdiff_t *val)
{
int res = SWIG_TypeError;
#ifdef SWIG_LONG_LONG_AVAILABLE
if (sizeof(ptrdiff_t) <= sizeof(long)) {
#endif
long v;
res = SWIG_AsVal_long (obj, val ? &v : 0);
if (SWIG_IsOK(res) && val) *val = static_cast< ptrdiff_t >(v);
#ifdef SWIG_LONG_LONG_AVAILABLE
} else if (sizeof(ptrdiff_t) <= sizeof(long long)) {
long long v;
res = SWIG_AsVal_long_SS_long (obj, val ? &v : 0);
if (SWIG_IsOK(res) && val) *val = static_cast< ptrdiff_t >(v);
}
#endif
return res;
}
#ifdef SWIG_LONG_LONG_AVAILABLE
SWIGINTERNINLINE VALUE
SWIG_From_long_SS_long (long long value)
{
return LL2NUM(value);
}
#endif
SWIGINTERNINLINE VALUE
SWIG_From_ptrdiff_t (ptrdiff_t value)
{
#ifdef SWIG_LONG_LONG_AVAILABLE
if (sizeof(ptrdiff_t) <= sizeof(long)) {
#endif
return SWIG_From_long (static_cast< long >(value));
#ifdef SWIG_LONG_LONG_AVAILABLE
} else {
/* assume sizeof(ptrdiff_t) <= sizeof(long long) */
return SWIG_From_long_SS_long (static_cast< long long >(value));
}
#endif
}
#include <algorithm>
#include <vector>
SWIGINTERN int
SWIG_AsVal_int (VALUE obj, int *val)
{
long v;
int res = SWIG_AsVal_long (obj, &v);
if (SWIG_IsOK(res)) {
if ((v < INT_MIN || v > INT_MAX)) {
return SWIG_OverflowError;
} else {
if (val) *val = static_cast< int >(v);
}
}
return res;
}
namespace swig {
template <class Type>
struct noconst_traits {
typedef Type noconst_type;
};
template <class Type>
struct noconst_traits<const Type> {
typedef Type noconst_type;
};
/*
type categories
*/
struct pointer_category { };
struct value_category { };
/*
General traits that provides type_name and type_info
*/
template <class Type> struct traits { };
template <class Type>
inline const char* type_name() {
return traits<typename noconst_traits<Type >::noconst_type >::type_name();
}
template <class Type>
struct traits_info {
static swig_type_info *type_query(std::string name) {
name += " *";
return SWIG_TypeQuery(name.c_str());
}
static swig_type_info *type_info() {
static swig_type_info *info = type_query(type_name<Type>());
return info;
}
};
template <class Type>
inline swig_type_info *type_info() {
return traits_info<Type>::type_info();
}
/*
Partial specialization for pointers
*/
template <class Type> struct traits <Type *> {
typedef pointer_category category;
static std::string make_ptr_name(const char* name) {
std::string ptrname = name;
ptrname += " *";
return ptrname;
}
static const char* type_name() {
static std::string name = make_ptr_name(swig::type_name<Type>());
return name.c_str();
}
};
template <class Type, class Category>
struct traits_as { };
template <class Type, class Category>
struct traits_check { };
}
namespace swig {
/*
Traits that provides the from method
*/
template <class Type> struct traits_from_ptr {
static VALUE from(Type *val, int owner = 0) {
return SWIG_NewPointerObj(val, type_info<Type>(), owner);
}
};
template <class Type> struct traits_from {
static VALUE from(const Type& val) {
return traits_from_ptr<Type>::from(new Type(val), 1);
}
};
template <class Type> struct traits_from<Type *> {
static VALUE from(Type* val) {
return traits_from_ptr<Type>::from(val, 0);
}
};
template <class Type> struct traits_from<const Type *> {
static VALUE from(const Type* val) {
return traits_from_ptr<Type>::from(const_cast<Type*>(val), 0);
}
};
template <class Type>
inline VALUE from(const Type& val) {
return traits_from<Type>::from(val);
}
template <class Type>
inline VALUE from_ptr(Type* val, int owner) {
return traits_from_ptr<Type>::from(val, owner);
}
/*
Traits that provides the asval/as/check method
*/
template <class Type>
struct traits_asptr {
static int asptr(VALUE obj, Type **val) {
Type *p;
int res = SWIG_ConvertPtr(obj, (void**)&p, type_info<Type>(), 0);
if (SWIG_IsOK(res)) {
if (val) *val = p;
}
return res;
}
};
template <class Type>
inline int asptr(VALUE obj, Type **vptr) {
return traits_asptr<Type>::asptr(obj, vptr);
}
template <class Type>
struct traits_asval {
static int asval(VALUE obj, Type *val) {
if (val) {
Type *p = 0;
int res = traits_asptr<Type>::asptr(obj, &p);
if (!SWIG_IsOK(res)) return res;
if (p) {
typedef typename noconst_traits<Type>::noconst_type noconst_type;
*(const_cast<noconst_type*>(val)) = *p;
if (SWIG_IsNewObj(res)){
delete p;
res = SWIG_DelNewMask(res);
}
return res;
} else {
return SWIG_ERROR;
}
} else {
return traits_asptr<Type>::asptr(obj, (Type **)(0));
}
}
};
template <class Type> struct traits_asval<Type*> {
static int asval(VALUE obj, Type **val) {
if (val) {
typedef typename noconst_traits<Type>::noconst_type noconst_type;
noconst_type *p = 0;
int res = traits_asptr<noconst_type>::asptr(obj, &p);
if (SWIG_IsOK(res)) {
*(const_cast<noconst_type**>(val)) = p;
}
return res;
} else {
return traits_asptr<Type>::asptr(obj, (Type **)(0));
}
}
};
template <class Type>
inline int asval(VALUE obj, Type *val) {
return traits_asval<Type>::asval(obj, val);
}
template <class Type>
struct traits_as<Type, value_category> {
static Type as(VALUE obj, bool throw_error) {
Type v;
int res = asval(obj, &v);
if (!obj || !SWIG_IsOK(res)) {
if (throw_error) throw std::invalid_argument("bad type");
VALUE lastErr = rb_gv_get("$!");
if (lastErr == Qnil) {
SWIG_Error(SWIG_TypeError, swig::type_name<Type>());
}
}
return v;
}
};
template <class Type>
struct traits_as<Type, pointer_category> {
static Type as(VALUE obj, bool throw_error) {
Type *v = 0;
int res = (obj ? traits_asptr<Type>::asptr(obj, &v) : SWIG_ERROR);
if (SWIG_IsOK(res) && v) {
if (SWIG_IsNewObj(res)) {
Type r(*v);
delete v;
return r;
} else {
return *v;
}
} else {
// Uninitialized return value, no Type() constructor required.
if (throw_error) throw std::invalid_argument("bad type");
VALUE lastErr = rb_gv_get("$!");
if (lastErr == Qnil) {
SWIG_Error(SWIG_TypeError, swig::type_name<Type>());
}
static Type *v_def = (Type*) malloc(sizeof(Type));
memset(v_def,0,sizeof(Type));
return *v_def;
}
}
};
template <class Type>
struct traits_as<Type*, pointer_category> {
static Type* as(VALUE obj, bool throw_error) {
Type *v = 0;
int res = (obj ? traits_asptr<Type>::asptr(obj, &v) : SWIG_ERROR);
if (SWIG_IsOK(res)) {
return v;
} else {
if (throw_error) throw std::invalid_argument("bad type");
VALUE lastErr = rb_gv_get("$!");
if (lastErr == Qnil) {
SWIG_Error(SWIG_TypeError, swig::type_name<Type>());
}
return 0;
}
}
};
template <class Type>
inline Type as(VALUE obj, bool te = false) {
return traits_as< Type, typename traits< Type >::category >::as(obj, te);
}
template <class Type>
struct traits_check<Type, value_category> {
static bool check(VALUE obj) {
int res = obj ? asval(obj, (Type *)(0)) : SWIG_ERROR;
return SWIG_IsOK(res) ? true : false;
}
};
template <class Type>
struct traits_check<Type, pointer_category> {
static bool check(VALUE obj) {
int res = obj ? asptr(obj, (Type **)(0)) : SWIG_ERROR;
return SWIG_IsOK(res) ? true : false;
}
};
template <class Type>
inline bool check(VALUE obj) {
return traits_check<Type, typename traits<Type>::category>::check(obj);
}
}
namespace swig {
template <> struct traits< int > {
typedef value_category category;
static const char* type_name() { return"int"; }
};
template <> struct traits_asval< int > {
typedef int value_type;
static int asval(VALUE obj, value_type *val) {
return SWIG_AsVal_int (obj, val);
}
};
template <> struct traits_from< int > {
typedef int value_type;
static VALUE from(const value_type& val) {
return SWIG_From_int (val);
}
};
}
#include <functional>
namespace swig {
template < class T >
struct yield : public std::unary_function< T, bool >
{
bool
operator()( const T& v ) const
{
return RTEST( rb_yield( swig::from< T >(v) ) );
}
};
inline size_t
check_index(ptrdiff_t i, size_t size, bool insert = false) {
if ( i < 0 ) {
if ((size_t) (-i) <= size)
return (size_t) (i + size);
} else if ( (size_t) i < size ) {
return (size_t) i;
} else if (insert && ((size_t) i == size)) {
return size;
}
throw std::out_of_range("index out of range");
}
inline size_t
slice_index(ptrdiff_t i, size_t size) {
if ( i < 0 ) {
if ((size_t) (-i) <= size) {
return (size_t) (i + size);
} else {
throw std::out_of_range("index out of range");
}
} else {
return ( (size_t) i < size ) ? ((size_t) i) : size;
}
}
template <class Sequence, class Difference>
inline typename Sequence::iterator
getpos(Sequence* self, Difference i) {
typename Sequence::iterator pos = self->begin();
std::advance(pos, check_index(i,self->size()));
return pos;
}
template <class Sequence, class Difference>
inline typename Sequence::const_iterator
cgetpos(const Sequence* self, Difference i) {
typename Sequence::const_iterator pos = self->begin();
std::advance(pos, check_index(i,self->size()));
return pos;
}
template <class Sequence>
inline void
resize(Sequence *seq, typename Sequence::size_type n, typename Sequence::value_type x) {
seq->resize(n, x);
}
template <class Sequence, class Difference>
inline Sequence*
getslice(const Sequence* self, Difference i, Difference j) {
typename Sequence::size_type size = self->size();
typename Sequence::size_type ii = swig::check_index(i, size, (i == size && j == size));
typename Sequence::size_type jj = swig::slice_index(j, size);
if (jj > ii) {
typename Sequence::const_iterator vb = self->begin();
typename Sequence::const_iterator ve = self->begin();
std::advance(vb,ii);
std::advance(ve,jj);
return new Sequence(vb, ve);
} else {
return new Sequence();
}
}
template <class Sequence, class Difference, class InputSeq>
inline void
setslice(Sequence* self, Difference i, Difference j, const InputSeq& v) {
typename Sequence::size_type size = self->size();
typename Sequence::size_type ii = swig::check_index(i, size, true);
typename Sequence::size_type jj = swig::slice_index(j, size);
if (jj < ii) jj = ii;
size_t ssize = jj - ii;
if (ssize <= v.size()) {
typename Sequence::iterator sb = self->begin();
typename InputSeq::const_iterator vmid = v.begin();
std::advance(sb,ii);
std::advance(vmid, jj - ii);
self->insert(std::copy(v.begin(), vmid, sb), vmid, v.end());
} else {
typename Sequence::iterator sb = self->begin();
typename Sequence::iterator se = self->begin();
std::advance(sb,ii);
std::advance(se,jj);
self->erase(sb,se);
self->insert(sb, v.begin(), v.end());
}
}
template <class Sequence, class Difference>
inline void
delslice(Sequence* self, Difference i, Difference j) {
typename Sequence::size_type size = self->size();
typename Sequence::size_type ii = swig::check_index(i, size, true);
typename Sequence::size_type jj = swig::slice_index(j, size);
if (jj > ii) {
typename Sequence::iterator sb = self->begin();
typename Sequence::iterator se = self->begin();
std::advance(sb,ii);
std::advance(se,jj);
self->erase(sb,se);
}
}
}
#if defined(__SUNPRO_CC) && defined(_RWSTD_VER)
# if !defined(SWIG_NO_STD_NOITERATOR_TRAITS_STL)
# define SWIG_STD_NOITERATOR_TRAITS_STL
# endif
#endif
#if !defined(SWIG_STD_NOITERATOR_TRAITS_STL)
#include <iterator>
#else
namespace std {
template <class Iterator>
struct iterator_traits {
typedef ptrdiff_t difference_type;
typedef typename Iterator::value_type value_type;
};
template <class Iterator, class Category,class T, class Reference, class Pointer, class Distance>
struct iterator_traits<__reverse_bi_iterator<Iterator,Category,T,Reference,Pointer,Distance> > {
typedef Distance difference_type;
typedef T value_type;
};
template <class T>
struct iterator_traits<T*> {
typedef T value_type;
typedef ptrdiff_t difference_type;
};
template<typename _InputIterator>
inline typename iterator_traits<_InputIterator>::difference_type
distance(_InputIterator __first, _InputIterator __last)
{
typename iterator_traits<_InputIterator>::difference_type __n = 0;
while (__first != __last) {
++__first; ++__n;
}
return __n;
}
}
#endif
namespace swig {
/**
* Templated base classes for all custom const_iterators.
*
*/
template<typename OutConstIterator>
class ConstIterator_T : public ConstIterator
{
public:
typedef OutConstIterator const_iter;
typedef typename std::iterator_traits<const_iter>::value_type value_type;
typedef ConstIterator_T<const_iter> self_type;
protected:
virtual bool equal (const ConstIterator &iter) const
{
const self_type *iters = dynamic_cast<const self_type *>(&iter);
if (iters) {
return (current == iters->get_current());
} else {
throw std::invalid_argument("bad iterator type");
}
}
virtual ptrdiff_t distance(const ConstIterator &iter) const
{
const self_type *iters = dynamic_cast<const self_type *>(&iter);
if (iters) {
return std::distance(current, iters->get_current());
} else {
throw std::invalid_argument("bad iterator type");
}
}
virtual ConstIterator* advance(ptrdiff_t n)
{
std::advance( current, n );
return this;
}
public:
ConstIterator_T() : ConstIterator(Qnil)
{
}
ConstIterator_T(const_iter curr, VALUE seq = Qnil)
: ConstIterator(seq), current(curr)
{
}
const const_iter& get_current() const
{
return current;
}
const value_type& operator*() const
{
return *current;
}
virtual VALUE inspect() const
{
VALUE ret = rb_str_new2("#<");
ret = rb_str_cat2( ret, rb_obj_classname(_seq) );
ret = rb_str_cat2( ret, "::const_iterator " );
VALUE cur = value();
ret = rb_str_concat( ret, rb_inspect(cur) );
ret = rb_str_cat2( ret, ">" );
return ret;
}
virtual VALUE to_s() const
{
VALUE ret = rb_str_new2( rb_obj_classname(_seq) );
ret = rb_str_cat2( ret, "::const_iterator " );
VALUE cur = value();
ret = rb_str_concat( ret, rb_obj_as_string(cur) );
return ret;
}
protected:
const_iter current;
};
/**
* Templated base classes for all custom non-const iterators.
*
*/
template<typename InOutIterator>
class Iterator_T : public Iterator
{
public:
typedef InOutIterator nonconst_iter;
// Make this class iterator STL compatible, by using iterator_traits
typedef typename std::iterator_traits<nonconst_iter >::iterator_category iterator_category;
typedef typename std::iterator_traits<nonconst_iter >::value_type value_type;
typedef typename std::iterator_traits<nonconst_iter >::difference_type difference_type;
typedef typename std::iterator_traits<nonconst_iter >::pointer pointer;
typedef typename std::iterator_traits<nonconst_iter >::reference reference;
typedef Iterator base;
typedef Iterator_T< nonconst_iter > self_type;
protected:
virtual bool equal (const ConstIterator &iter) const
{
const self_type *iters = dynamic_cast<const self_type *>(&iter);
if (iters) {
return (current == iters->get_current());
} else {
throw std::invalid_argument("bad iterator type");
}
}
virtual ptrdiff_t distance(const ConstIterator &iter) const
{
const self_type *iters = dynamic_cast<const self_type *>(&iter);
if (iters) {
return std::distance(current, iters->get_current());
} else {
throw std::invalid_argument("bad iterator type");
}
}
virtual Iterator* advance(ptrdiff_t n)
{
std::advance( current, n );
return this;
}
public:
Iterator_T(nonconst_iter curr, VALUE seq = Qnil)
: Iterator(seq), current(curr)
{
}
const nonconst_iter& get_current() const
{
return current;
}
self_type& operator=( const self_type& b )
{
base::operator=( b );
return *this;
}
self_type& operator=( const value_type& b )
{
*current = b;
return *this;
}
const value_type& operator*() const
{
return *current;
}
value_type& operator*()
{
return *current;
}
virtual VALUE inspect() const
{
VALUE ret = rb_str_new2("#<");
ret = rb_str_cat2( ret, rb_obj_classname(_seq) );
ret = rb_str_cat2( ret, "::iterator " );
VALUE cur = value();
ret = rb_str_concat( ret, rb_inspect(cur) );
ret = rb_str_cat2( ret, ">" );
return ret;
}
virtual VALUE to_s() const
{
VALUE ret = rb_str_new2( rb_obj_classname(_seq) );
ret = rb_str_cat2( ret, "::iterator " );
VALUE cur = value();
ret = rb_str_concat( ret, rb_obj_as_string(cur) );
return ret;
}
protected:
nonconst_iter current;
};
/**
* Auxiliary functor to store the value of a ruby object inside
* a reference of a compatible C++ type. ie: Ruby -> C++
*
*/
template <class ValueType>
struct asval_oper
{
typedef ValueType value_type;
typedef bool result_type;
bool operator()(VALUE obj, value_type& v) const
{
return ( swig::asval< value_type >(obj, &v) == SWIG_OK );
}
};
/**
* Auxiliary functor to return a ruby object from a C++ type.
* ie: C++ -> Ruby
*
*/
template <class ValueType>
struct from_oper
{
typedef const ValueType& argument_type;
typedef VALUE result_type;
result_type operator()(argument_type v) const
{
return swig::from(v);
}
};
/**
* ConstIterator class for a const_iterator with no end() boundaries.
*
*/
template<typename OutConstIterator,
typename ValueType = typename std::iterator_traits<OutConstIterator>::value_type,
typename FromOper = from_oper<ValueType> >
class ConstIteratorOpen_T : public ConstIterator_T<OutConstIterator>
{
public:
FromOper from;
typedef OutConstIterator const_iter;
typedef ValueType value_type;
typedef ConstIterator_T<const_iter> base;
typedef ConstIteratorOpen_T<OutConstIterator, ValueType, FromOper> self_type;
ConstIteratorOpen_T(const_iter curr, VALUE seq = Qnil)
: ConstIterator_T<OutConstIterator>(curr, seq)
{
}
virtual VALUE value() const {
return from(static_cast<const value_type&>(*(base::current)));
}
ConstIterator *dup() const
{
return new self_type(*this);
}
};
/**
* Iterator class for an iterator with no end() boundaries.
*
*/
template<typename InOutIterator,
typename ValueType = typename std::iterator_traits<InOutIterator>::value_type,
typename FromOper = from_oper<ValueType>,
typename AsvalOper = asval_oper<ValueType> >
class IteratorOpen_T : public Iterator_T<InOutIterator>
{
public:
FromOper from;
AsvalOper asval;
typedef InOutIterator nonconst_iter;
typedef ValueType value_type;
typedef Iterator_T<nonconst_iter> base;
typedef IteratorOpen_T<InOutIterator, ValueType, FromOper, AsvalOper> self_type;
public:
IteratorOpen_T(nonconst_iter curr, VALUE seq = Qnil)
: Iterator_T<InOutIterator>(curr, seq)
{
}
virtual VALUE value() const {
return from(static_cast<const value_type&>(*(base::current)));
}
virtual VALUE setValue( const VALUE& v )
{
value_type& dst = *base::current;
if ( asval(v, dst) ) return v;
return Qnil;
}
Iterator *dup() const
{
return new self_type(*this);
}
};
/**
* ConstIterator class for a const_iterator where begin() and end() boundaries are known.
*
*/
template<typename OutConstIterator,
typename ValueType = typename std::iterator_traits<OutConstIterator>::value_type,
typename FromOper = from_oper<ValueType> >
class ConstIteratorClosed_T : public ConstIterator_T<OutConstIterator>
{
public:
FromOper from;
typedef OutConstIterator const_iter;
typedef ValueType value_type;
typedef ConstIterator_T<const_iter> base;
typedef ConstIteratorClosed_T<OutConstIterator, ValueType, FromOper> self_type;
protected:
virtual ConstIterator* advance(ptrdiff_t n)
{
std::advance( base::current, n );
if ( base::current == end )
throw stop_iteration();
return this;
}
public:
ConstIteratorClosed_T(const_iter curr, const_iter first,
const_iter last, VALUE seq = Qnil)
: ConstIterator_T<OutConstIterator>(curr, seq), begin(first), end(last)
{
}
virtual VALUE value() const {
if (base::current == end) {
throw stop_iteration();
} else {
return from(static_cast<const value_type&>(*(base::current)));
}
}
ConstIterator *dup() const
{
return new self_type(*this);
}
private:
const_iter begin;
const_iter end;
};
/**
* Iterator class for a iterator where begin() and end() boundaries are known.
*
*/
template<typename InOutIterator,
typename ValueType = typename std::iterator_traits<InOutIterator>::value_type,
typename FromOper = from_oper<ValueType>,
typename AsvalOper = asval_oper<ValueType> >
class IteratorClosed_T : public Iterator_T<InOutIterator>
{
public:
FromOper from;
AsvalOper asval;
typedef InOutIterator nonconst_iter;
typedef ValueType value_type;
typedef Iterator_T<nonconst_iter> base;
typedef IteratorClosed_T<InOutIterator, ValueType, FromOper, AsvalOper> self_type;
protected:
virtual Iterator* advance(ptrdiff_t n)
{
std::advance( base::current, n );
if ( base::current == end )
throw stop_iteration();
return this;
}
public:
IteratorClosed_T(nonconst_iter curr, nonconst_iter first,
nonconst_iter last, VALUE seq = Qnil)
: Iterator_T<InOutIterator>(curr, seq), begin(first), end(last)
{
}
virtual VALUE value() const {
if (base::current == end) {
throw stop_iteration();
} else {
return from(static_cast<const value_type&>(*(base::current)));
}
}
// Iterator setter method, required by Ruby
virtual VALUE setValue( const VALUE& v )
{
if (base::current == end)
throw stop_iteration();
value_type& dst = *base::current;
if ( asval( v, dst ) ) return v;
return Qnil;
}
Iterator *dup() const
{
return new self_type(*this);
}
private:
nonconst_iter begin;
nonconst_iter end;
};
/* Partial specialization for bools which don't allow de-referencing */
template< typename InOutIterator, typename FromOper, typename AsvalOper >
class IteratorOpen_T< InOutIterator, bool, FromOper, AsvalOper > :
public Iterator_T<InOutIterator>
{
public:
FromOper from;
AsvalOper asval;
typedef InOutIterator nonconst_iter;
typedef bool value_type;
typedef Iterator_T<nonconst_iter> base;
typedef IteratorOpen_T<InOutIterator, bool, FromOper, AsvalOper> self_type;
IteratorOpen_T(nonconst_iter curr, VALUE seq = Qnil)
: Iterator_T<InOutIterator>(curr, seq)
{
}
virtual VALUE value() const {
return from(static_cast<const value_type&>(*(base::current)));
}
virtual VALUE setValue( const VALUE& v )
{
bool tmp = *base::current;
if ( asval( v, tmp ) )
{
*base::current = tmp;
return v;
}
return Qnil;
}
Iterator *dup() const
{
return new self_type(*this);
}
};
/* Partial specialization for bools which don't allow de-referencing */
template< typename InOutIterator, typename FromOper, typename AsvalOper >
class IteratorClosed_T< InOutIterator, bool, FromOper, AsvalOper > :
public Iterator_T<InOutIterator>
{
public:
FromOper from;
AsvalOper asval;
typedef InOutIterator nonconst_iter;
typedef bool value_type;
typedef Iterator_T<nonconst_iter> base;
typedef IteratorClosed_T<InOutIterator, bool, FromOper, AsvalOper> self_type;
protected:
virtual Iterator* advance(ptrdiff_t n)
{
std::advance( base::current, n );
if ( base::current == end )
throw stop_iteration();
return this;
}
public:
IteratorClosed_T(nonconst_iter curr, nonconst_iter first,
nonconst_iter last, VALUE seq = Qnil)
: Iterator_T<InOutIterator>(curr, seq), begin(first), end(last)
{
}
virtual VALUE value() const {
if (base::current == end) {
throw stop_iteration();
} else {
return from(static_cast<const value_type&>(*(base::current)));
}
}
virtual VALUE setValue( const VALUE& v )
{
if (base::current == end)
throw stop_iteration();
bool tmp = *base::current;
if ( asval( v, tmp ) )
{
*base::current = tmp;
return v;
}
return Qnil;
}
Iterator *dup() const
{
return new self_type(*this);
}
private:
nonconst_iter begin;
nonconst_iter end;
};
/**
* Helper function used to wrap a bounded const_iterator. This is to be used in
* a %typemap(out), for example.
*
*/
template<typename InOutIter>
inline Iterator*
make_nonconst_iterator(const InOutIter& current, const InOutIter& begin,
const InOutIter& end, VALUE seq = Qnil)
{
return new IteratorClosed_T<InOutIter>(current, begin, end, seq);
}
/**
* Helper function used to wrap an unbounded const_iterator. This is to be used in
* a %typemap(out), for example.
*
*/
template<typename InOutIter>
inline Iterator*
make_nonconst_iterator(const InOutIter& current, VALUE seq = Qnil)
{
return new IteratorOpen_T<InOutIter>(current, seq);
}
/**
* Helper function used to wrap a bounded const_iterator. This is to be used in
* a %typemap(out), for example.
*
*/
template<typename OutIter>
inline ConstIterator*
make_const_iterator(const OutIter& current, const OutIter& begin,
const OutIter& end, VALUE seq = Qnil)
{
return new ConstIteratorClosed_T<OutIter>(current, begin, end, seq);
}
/**
* Helper function used to wrap an unbounded const_iterator. This is to be used in
* a %typemap(out), for example.
*
*/
template<typename OutIter>
inline ConstIterator*
make_const_iterator(const OutIter& current, VALUE seq = Qnil)
{
return new ConstIteratorOpen_T<OutIter>(current, seq);
}
}
namespace swig
{
/**
* This class is a proxy class for references, used to return and set values
* of an element of a Ruby Array of stuff.
* It can be used by RubySequence_InputIterator to make it work with STL
* algorithms.
*/
template <class T>
struct RubySequence_Ref
{
RubySequence_Ref(VALUE seq, int index)
: _seq(seq), _index(index)
{
}
operator T () const
{
VALUE item = rb_ary_entry(_seq, _index );
try {
return swig::as<T>(item, true);
} catch (std::exception& e) {
char msg[1024];
sprintf(msg, "in sequence element %d ", _index);
VALUE lastErr = rb_gv_get("$!");
if ( lastErr == Qnil ) {
SWIG_Error(SWIG_TypeError, swig::type_name<T>());
}
VALUE str = rb_str_new2(msg);
str = rb_str_cat2( str, e.what() );
SWIG_Ruby_ExceptionType( NULL, str );
throw;
}
}
RubySequence_Ref& operator=(const T& v)
{
rb_ary_set(_seq, _index, swig::from< T >(v));
return *this;
}
private:
VALUE _seq;
int _index;
};
/**
* This class is a proxy to return a pointer to a class, usually
* RubySequence_Ref.
* It can be used by RubySequence_InputIterator to make it work with STL
* algorithms.
*/
template <class T>
struct RubySequence_ArrowProxy
{
RubySequence_ArrowProxy(const T& x): m_value(x) {}
const T* operator->() const { return &m_value; }
operator const T*() const { return &m_value; }
T m_value;
};
/**
* Input Iterator. This adapator class is a random access iterator that
* allows you to use STL algorithms with a Ruby class (a Ruby Array by default).
*/
template <class T, class Reference = RubySequence_Ref< T > >
struct RubySequence_InputIterator
{
typedef RubySequence_InputIterator<T, Reference > self;
typedef std::random_access_iterator_tag iterator_category;
typedef Reference reference;
typedef T value_type;
typedef T* pointer;
typedef ptrdiff_t difference_type;
RubySequence_InputIterator()
{
}
RubySequence_InputIterator(VALUE seq, int index)
: _seq(seq), _index(index)
{
}
reference operator*() const
{
return reference(_seq, _index);
}
RubySequence_ArrowProxy<T>
operator->() const {
return RubySequence_ArrowProxy<T>(operator*());
}
bool operator==(const self& ri) const
{
return (_index == ri._index) && (_seq == ri._seq);
}
bool operator!=(const self& ri) const
{
return !(operator==(ri));
}
self& operator ++ ()
{
++_index;
return *this;
}
self& operator -- ()
{
--_index;
return *this;
}
self& operator += (difference_type n)
{
_index += n;
return *this;
}
self operator +(difference_type n) const
{
return self(_seq, _index + n);
}
self& operator -= (difference_type n)
{
_index -= n;
return *this;
}
self operator -(difference_type n) const
{
return self(_seq, _index - n);
}
difference_type operator - (const self& ri) const
{
return _index - ri._index;
}
bool operator < (const self& ri) const
{
return _index < ri._index;
}
reference
operator[](difference_type n) const
{
return reference(_seq, _index + n);
}
private:
VALUE _seq;
difference_type _index;
};
/**
* This adaptor class allows you to use a Ruby Array as if it was an STL
* container, giving it begin(), end(), and iterators.
*/
template <class T>
struct RubySequence_Cont
{
typedef RubySequence_Ref<T> reference;
typedef const RubySequence_Ref<T> const_reference;
typedef T value_type;
typedef T* pointer;
typedef int difference_type;
typedef int size_type;
typedef const pointer const_pointer;
typedef RubySequence_InputIterator<T, reference> iterator;
typedef RubySequence_InputIterator<T, const_reference> const_iterator;
RubySequence_Cont(VALUE seq) : _seq(0)
{
if (!rb_obj_is_kind_of(seq, rb_cArray)) {
throw std::invalid_argument("an Array is expected");
}
_seq = seq;
}
~RubySequence_Cont()
{
}
size_type size() const
{
return RARRAY_LEN(_seq);
}
bool empty() const
{
return size() == 0;
}
iterator begin()
{
return iterator(_seq, 0);
}
const_iterator begin() const
{
return const_iterator(_seq, 0);
}
iterator end()
{
return iterator(_seq, size());
}
const_iterator end() const
{
return const_iterator(_seq, size());
}
reference operator[](difference_type n)
{
return reference(_seq, n);
}
const_reference operator[](difference_type n) const
{
return const_reference(_seq, n);
}
bool check(bool set_err = false) const
{
int s = (int) size();
for (int i = 0; i < s; ++i) {
VALUE item = rb_ary_entry(_seq, i );
if (!swig::check<value_type>(item)) {
if (set_err) {
char msg[1024];
sprintf(msg, "in sequence element %d", i);
SWIG_Error(SWIG_RuntimeError, msg);
}
return false;
}
}
return true;
}
private:
VALUE _seq;
};
}
namespace swig {
template <class RubySeq, class Seq>
inline void
assign(const RubySeq& rubyseq, Seq* seq) {
// seq->assign(rubyseq.begin(), rubyseq.end()); // not used as not always implemented
typedef typename RubySeq::value_type value_type;
typename RubySeq::const_iterator it = rubyseq.begin();
for (;it != rubyseq.end(); ++it) {
seq->insert(seq->end(),(value_type)(*it));
}
}
template <class Seq, class T = typename Seq::value_type >
struct traits_asptr_stdseq {
typedef Seq sequence;
typedef T value_type;
static int asptr(VALUE obj, sequence **seq) {
if (rb_obj_is_kind_of(obj, rb_cArray) == Qtrue) {
try {
RubySequence_Cont<value_type> rubyseq(obj);
if (seq) {
sequence *pseq = new sequence();
assign(rubyseq, pseq);
*seq = pseq;
return SWIG_NEWOBJ;
} else {
return rubyseq.check() ? SWIG_OK : SWIG_ERROR;
}
} catch (std::exception& e) {
if (seq) {
VALUE lastErr = rb_gv_get("$!");
if (lastErr == Qnil) {
rb_raise(rb_eTypeError, "%s", e.what());
}
}
return SWIG_ERROR;
}
} else {
sequence *p;
if (SWIG_ConvertPtr(obj,(void**)&p,
swig::type_info<sequence>(),0) == SWIG_OK) {
if (seq) *seq = p;
return SWIG_OLDOBJ;
}
}
return SWIG_ERROR;
}
};
// Partial specialization for GC_VALUE's. No need to typecheck each
// element.
template< class Seq >
struct traits_asptr_stdseq< Seq, swig::GC_VALUE > {
typedef Seq sequence;
typedef swig::GC_VALUE value_type;
static int asptr(VALUE obj, sequence **seq) {
if (rb_obj_is_kind_of(obj, rb_cArray) == Qtrue) {
try {
if (seq) {
RubySequence_Cont<value_type> rubyseq(obj);
sequence *pseq = new sequence();
assign(rubyseq, pseq);
*seq = pseq;
return SWIG_NEWOBJ;
} else {
return true;
}
} catch (std::exception& e) {
if (seq) {
VALUE lastErr = rb_gv_get("$!");
if (lastErr == Qnil) {
rb_raise(rb_eTypeError, "%s", e.what());
}
}
return SWIG_ERROR;
}
} else {
sequence *p;
if (SWIG_ConvertPtr(obj,(void**)&p,
swig::type_info<sequence>(),0) == SWIG_OK) {
if (seq) *seq = p;
return SWIG_OLDOBJ;
}
}
return SWIG_ERROR;
}
};
template <class Seq, class T = typename Seq::value_type >
struct traits_from_stdseq {
typedef Seq sequence;
typedef T value_type;
typedef typename Seq::size_type size_type;
typedef typename sequence::const_iterator const_iterator;
static VALUE from(const sequence& seq) {
size_type size = seq.size();
if (size <= (size_type)INT_MAX) {
VALUE obj = rb_ary_new2((int)size);
int i = 0;
for (const_iterator it = seq.begin();
it != seq.end(); ++it, ++i) {
rb_ary_push(obj, swig::from< value_type >(*it));
}
rb_obj_freeze(obj); // treat as immutable result
return obj;
} else {
rb_raise(rb_eRangeError,"sequence size not valid in ruby");
return Qnil;
}
}
};
}
namespace swig {
template <class T>
struct traits_asptr<std::vector<T> > {
static int asptr(VALUE obj, std::vector<T> **vec) {
return traits_asptr_stdseq<std::vector<T> >::asptr(obj, vec);
}
};
template <class T>
struct traits_from<std::vector<T> > {
static VALUE from(const std::vector<T>& vec) {
return traits_from_stdseq<std::vector<T> >::from(vec);
}
};
}
namespace swig {
template <> struct traits<std::vector< int, std::allocator< int > > > {
typedef pointer_category category;
static const char* type_name() {
return "std::vector<" "int" "," "std::allocator< int >" " >";
}
};
}
SWIGINTERN std::vector< int,std::allocator< int > > *std_vector_Sl_int32_t_Sg__dup(std::vector< int32_t > *self){
return new std::vector< int,std::allocator< int > >(*self);
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg__inspect(std::vector< int32_t > *self){
std::vector< int,std::allocator< int > >::const_iterator i = self->begin();
std::vector< int,std::allocator< int > >::const_iterator e = self->end();
const char *type_name = swig::type_name< std::vector< int,std::allocator< int > > >();
VALUE str = rb_str_new2(type_name);
str = rb_str_cat2( str, " [" );
bool comma = false;
VALUE tmp;
for ( ; i != e; ++i, comma = true )
{
if (comma) str = rb_str_cat2( str, "," );
tmp = swig::from< std::vector< int,std::allocator< int > >::value_type >( *i );
tmp = rb_inspect( tmp );
str = rb_str_buf_append( str, tmp );
}
str = rb_str_cat2( str, "]" );
return str;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg__to_a(std::vector< int32_t > *self){
std::vector< int,std::allocator< int > >::const_iterator i = self->begin();
std::vector< int,std::allocator< int > >::const_iterator e = self->end();
VALUE ary = rb_ary_new2( std::distance( i, e ) );
VALUE tmp;
for ( ; i != e; ++i )
{
tmp = swig::from< std::vector< int,std::allocator< int > >::value_type >( *i );
rb_ary_push( ary, tmp );
}
return ary;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg__to_s(std::vector< int32_t > *self){
std::vector< int,std::allocator< int > >::iterator i = self->begin();
std::vector< int,std::allocator< int > >::iterator e = self->end();
VALUE str = rb_str_new2( "" );
VALUE tmp;
for ( ; i != e; ++i )
{
tmp = swig::from< std::vector< int,std::allocator< int > >::value_type >( *i );
tmp = rb_obj_as_string( tmp );
str = rb_str_buf_append( str, tmp );
}
return str;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg__slice(std::vector< int32_t > *self,std::vector< int >::difference_type i,std::vector< int >::difference_type length){
if ( length < 0 )
return Qnil;
std::size_t len = self->size();
if ( i < 0 ) {
if ( i + static_cast<std::vector< int,std::allocator< int > >::difference_type>(len) < 0 )
return Qnil;
else
i = len + i;
}
std::vector< int,std::allocator< int > >::difference_type j = length + i;
if ( j > static_cast<std::vector< int,std::allocator< int > >::difference_type>(len) )
j = len;
VALUE r = Qnil;
try {
r = swig::from< const std::vector< int,std::allocator< int > >* >( swig::getslice(self, i, j) );
}
catch( std::out_of_range ) {
}
return r;
}
SWIGINTERN std::vector< int,std::allocator< int > > *std_vector_Sl_int32_t_Sg__each(std::vector< int32_t > *self){
if ( !rb_block_given_p() )
rb_raise( rb_eArgError, "no block given");
VALUE r;
std::vector< int,std::allocator< int > >::const_iterator i = self->begin();
std::vector< int,std::allocator< int > >::const_iterator e = self->end();
for ( ; i != e; ++i )
{
r = swig::from< std::vector< int,std::allocator< int > >::value_type >(*i);
rb_yield(r);
}
return self;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg____delete2__(std::vector< int32_t > *self,std::vector< int >::value_type const &i){
VALUE r = Qnil;
return r;
}
SWIGINTERN std::vector< int,std::allocator< int > > *std_vector_Sl_int32_t_Sg__select(std::vector< int32_t > *self){
if ( !rb_block_given_p() )
rb_raise( rb_eArgError, "no block given" );
std::vector< int,std::allocator< int > >* r = new std::vector< int,std::allocator< int > >();
std::vector< int,std::allocator< int > >::const_iterator i = self->begin();
std::vector< int,std::allocator< int > >::const_iterator e = self->end();
for ( ; i != e; ++i )
{
VALUE v = swig::from< std::vector< int,std::allocator< int > >::value_type >(*i);
if ( RTEST( rb_yield(v) ) )
self->insert( r->end(), *i);
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg__delete_at(std::vector< int32_t > *self,std::vector< int >::difference_type i){
VALUE r = Qnil;
try {
std::vector< int,std::allocator< int > >::iterator at = swig::getpos(self, i);
r = swig::from< std::vector< int,std::allocator< int > >::value_type >( *(at) );
self->erase(at);
}
catch (std::out_of_range)
{
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg__at(std::vector< int32_t > const *self,std::vector< int >::difference_type i){
VALUE r = Qnil;
try {
r = swig::from< std::vector< int,std::allocator< int > >::value_type >( *(swig::cgetpos(self, i)) );
}
catch( std::out_of_range ) {
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg____getitem____SWIG_0(std::vector< int32_t > const *self,std::vector< int >::difference_type i,std::vector< int >::difference_type length){
if ( length < 0 )
return Qnil;
std::size_t len = self->size();
if ( i < 0 ) {
if ( i + static_cast<std::vector< int,std::allocator< int > >::difference_type>(len) < 0 )
return Qnil;
else
i = len + i;
}
std::vector< int,std::allocator< int > >::difference_type j = length + i;
if ( j > static_cast<std::vector< int,std::allocator< int > >::difference_type>(len) )
j = len;
VALUE r = Qnil;
try {
r = swig::from< const std::vector< int,std::allocator< int > >* >( swig::getslice(self, i, j) );
}
catch( std::out_of_range ) {
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg____getitem____SWIG_1(std::vector< int32_t > const *self,std::vector< int >::difference_type i){
VALUE r = Qnil;
try {
r = swig::from< std::vector< int,std::allocator< int > >::value_type >( *(swig::cgetpos(self, i)) );
}
catch( std::out_of_range ) {
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg____getitem____SWIG_2(std::vector< int32_t > const *self,VALUE i){
if ( rb_obj_is_kind_of( i, rb_cRange ) == Qfalse ) {
rb_raise( rb_eTypeError, "not a valid index or range" );
}
static ID id_end = rb_intern("end");
static ID id_start = rb_intern("begin");
static ID id_noend = rb_intern("exclude_end?");
VALUE start = rb_funcall( i, id_start, 0 );
VALUE end = rb_funcall( i, id_end, 0 );
bool noend = ( rb_funcall( i, id_noend, 0 ) == Qtrue );
int len = self->size();
int s = NUM2INT( start );
if ( s < 0 ) {
s = len + s;
if ( s < 0 )
return Qnil;
} else if ( s > len )
return Qnil;
int e = NUM2INT( end );
if ( e < 0 ) e = len + e;
if ( noend ) e -= 1;
if ( e < 0 ) e = -1;
if ( e >= len ) e = len - 1;
if ( s == len ) e = len - 1;
return swig::from< std::vector< int,std::allocator< int > >* >( swig::getslice(self, s, e+1) );
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg____setitem____SWIG_0(std::vector< int32_t > *self,std::vector< int >::difference_type i,std::vector< int >::value_type const &x){
if ( i >= static_cast<std::vector< int,std::allocator< int > >::difference_type>( self->size()) )
swig::resize( self, i+1, x );
else
*(swig::getpos(self, i)) = x;
return swig::from< std::vector< int,std::allocator< int > >::value_type >( x );
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg____setitem____SWIG_1(std::vector< int32_t > *self,std::vector< int >::difference_type i,std::vector< int >::difference_type length,std::vector< int,std::allocator< int > > const &v){
if ( length < 0 )
return Qnil;
std::size_t len = self->size();
if ( i < 0 ) {
if ( i + static_cast<std::vector< int,std::allocator< int > >::difference_type>(len) < 0 )
return Qnil;
else
i = len + i;
}
std::vector< int,std::allocator< int > >::difference_type j = length + i;
if ( j > static_cast<std::vector< int,std::allocator< int > >::difference_type>(len) ) {
swig::resize( self, j, *(v.begin()) );
}
VALUE r = Qnil;
swig::setslice(self, i, j, v);
r = swig::from< const std::vector< int,std::allocator< int > >* >( &v );
return r;
}
SWIGINTERN std::vector< int,std::allocator< int > > *std_vector_Sl_int32_t_Sg__reject_bang(std::vector< int32_t > *self){
if ( !rb_block_given_p() )
rb_raise( rb_eArgError, "no block given" );
self->erase( std::remove_if( self->begin(), self->end(),
swig::yield< std::vector< int,std::allocator< int > >::value_type >() ), self->end() );
return self;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg__pop(std::vector< int32_t > *self){
if (self->empty()) return Qnil;
std::vector< int,std::allocator< int > >::value_type x = self->back();
self->pop_back();
return swig::from< std::vector< int,std::allocator< int > >::value_type >( x );
}
SWIGINTERN std::vector< int >::value_type const std_vector_Sl_int32_t_Sg__push(std::vector< int32_t > *self,std::vector< int >::value_type const &e){
self->push_back( e );
return e;
}
SWIGINTERN std::vector< int,std::allocator< int > > *std_vector_Sl_int32_t_Sg__reject(std::vector< int32_t > *self){
if ( !rb_block_given_p() )
rb_raise( rb_eArgError, "no block given" );
std::vector< int,std::allocator< int > >* r = new std::vector< int,std::allocator< int > >();
std::remove_copy_if( self->begin(), self->end(),
std::back_inserter(*r),
swig::yield< std::vector< int,std::allocator< int > >::value_type >() );
return r;
}
SWIGINTERN VALUE std_vector_Sl_int32_t_Sg__shift(std::vector< int32_t > *self){
if (self->empty()) return Qnil;
std::vector< int,std::allocator< int > >::value_type x = self->front();
self->erase( self->begin() );
return swig::from< std::vector< int,std::allocator< int > >::value_type >( x );
}
SWIGINTERN std::vector< int,std::allocator< int > > *std_vector_Sl_int32_t_Sg__insert__SWIG_0(std::vector< int32_t > *self,std::vector< int >::difference_type pos,int argc,VALUE *argv,...){
std::size_t len = self->size();
std::size_t i = swig::check_index( pos, len, true );
std::vector< int,std::allocator< int > >::iterator start;
VALUE elem = argv[0];
int idx = 0;
try {
std::vector< int,std::allocator< int > >::value_type val = swig::as<std::vector< int,std::allocator< int > >::value_type>( elem, true );
if ( i >= len ) {
self->resize(i-1, val);
return self;
}
start = self->begin();
std::advance( start, i );
self->insert( start++, val );
for ( ++idx; idx < argc; ++idx )
{
elem = argv[idx];
val = swig::as<std::vector< int,std::allocator< int > >::value_type>( elem );
self->insert( start++, val );
}
}
catch( std::invalid_argument )
{
rb_raise( rb_eArgError, "%s",
Ruby_Format_TypeError( "",
swig::type_name<std::vector< int,std::allocator< int > >::value_type>(),
__FUNCTION__, idx+2, elem ));
}
return self;
}
SWIGINTERN std::vector< int,std::allocator< int > > *std_vector_Sl_int32_t_Sg__unshift(std::vector< int32_t > *self,int argc,VALUE *argv,...){
for ( int idx = argc-1; idx >= 0; --idx )
{
std::vector< int,std::allocator< int > >::iterator start = self->begin();
VALUE elem = argv[idx];
try {
std::vector< int,std::allocator< int > >::value_type val = swig::as<std::vector< int,std::allocator< int > >::value_type>( elem, true );
self->insert( start, val );
}
catch( std::invalid_argument )
{
rb_raise( rb_eArgError, "%s",
Ruby_Format_TypeError( "",
swig::type_name<std::vector< int,std::allocator< int > >::value_type>(),
__FUNCTION__, idx+2, elem ));
}
}
return self;
}
SWIGINTERNINLINE VALUE
SWIG_From_bool (bool value)
{
return value ? Qtrue : Qfalse;
}
SWIGINTERNINLINE VALUE
SWIG_From_unsigned_SS_long (unsigned long value)
{
return ULONG2NUM(value);
}
#ifdef SWIG_LONG_LONG_AVAILABLE
SWIGINTERNINLINE VALUE
SWIG_From_unsigned_SS_long_SS_long (unsigned long long value)
{
return ULL2NUM(value);
}
#endif
SWIGINTERNINLINE VALUE
SWIG_From_size_t (size_t value)
{
#ifdef SWIG_LONG_LONG_AVAILABLE
if (sizeof(size_t) <= sizeof(unsigned long)) {
#endif
return SWIG_From_unsigned_SS_long (static_cast< unsigned long >(value));
#ifdef SWIG_LONG_LONG_AVAILABLE
} else {
/* assume sizeof(size_t) <= sizeof(unsigned long long) */
return SWIG_From_unsigned_SS_long_SS_long (static_cast< unsigned long long >(value));
}
#endif
}
SWIGINTERN std::vector< int >::iterator std_vector_Sl_int32_t_Sg__erase__SWIG_0(std::vector< int32_t > *self,std::vector< int >::iterator pos){ return self->erase(pos); }
SWIGINTERN std::vector< int >::iterator std_vector_Sl_int32_t_Sg__erase__SWIG_1(std::vector< int32_t > *self,std::vector< int >::iterator first,std::vector< int >::iterator last){ return self->erase(first, last); }
SWIGINTERN std::vector< int >::iterator std_vector_Sl_int32_t_Sg__insert__SWIG_1(std::vector< int32_t > *self,std::vector< int >::iterator pos,std::vector< int >::value_type const &x){ return self->insert(pos, x); }
SWIGINTERN void std_vector_Sl_int32_t_Sg__insert__SWIG_2(std::vector< int32_t > *self,std::vector< int >::iterator pos,std::vector< int >::size_type n,std::vector< int >::value_type const &x){ self->insert(pos, n, x); }
/*@SWIG:/usr/local/share/swig/3.0.10/ruby/rubyprimtypes.swg,19,%ruby_aux_method@*/
SWIGINTERN VALUE SWIG_AUX_NUM2DBL(VALUE *args)
{
VALUE obj = args[0];
VALUE type = TYPE(obj);
double *res = (double *)(args[1]);
*res = NUM2DBL(obj); (void)type;
return obj;
}
/*@SWIG@*/
SWIGINTERN int
SWIG_AsVal_double (VALUE obj, double *val)
{
VALUE type = TYPE(obj);
if ((type == T_FLOAT) || (type == T_FIXNUM) || (type == T_BIGNUM)) {
double v;
VALUE a[2];
a[0] = obj;
a[1] = (VALUE)(&v);
if (rb_rescue(RUBY_METHOD_FUNC(SWIG_AUX_NUM2DBL), (VALUE)a, RUBY_METHOD_FUNC(SWIG_ruby_failed), 0) != Qnil) {
if (val) *val = v;
return SWIG_OK;
}
}
return SWIG_TypeError;
}
#define SWIG_From_double rb_float_new
namespace swig {
template <> struct traits< double > {
typedef value_category category;
static const char* type_name() { return"double"; }
};
template <> struct traits_asval< double > {
typedef double value_type;
static int asval(VALUE obj, value_type *val) {
return SWIG_AsVal_double (obj, val);
}
};
template <> struct traits_from< double > {
typedef double value_type;
static VALUE from(const value_type& val) {
return SWIG_From_double (val);
}
};
}
namespace swig {
template <> struct traits<std::vector< double, std::allocator< double > > > {
typedef pointer_category category;
static const char* type_name() {
return "std::vector<" "double" "," "std::allocator< double >" " >";
}
};
}
SWIGINTERN std::vector< double,std::allocator< double > > *std_vector_Sl_float64_t_Sg__dup(std::vector< float64_t > *self){
return new std::vector< double,std::allocator< double > >(*self);
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg__inspect(std::vector< float64_t > *self){
std::vector< double,std::allocator< double > >::const_iterator i = self->begin();
std::vector< double,std::allocator< double > >::const_iterator e = self->end();
const char *type_name = swig::type_name< std::vector< double,std::allocator< double > > >();
VALUE str = rb_str_new2(type_name);
str = rb_str_cat2( str, " [" );
bool comma = false;
VALUE tmp;
for ( ; i != e; ++i, comma = true )
{
if (comma) str = rb_str_cat2( str, "," );
tmp = swig::from< std::vector< double,std::allocator< double > >::value_type >( *i );
tmp = rb_inspect( tmp );
str = rb_str_buf_append( str, tmp );
}
str = rb_str_cat2( str, "]" );
return str;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg__to_a(std::vector< float64_t > *self){
std::vector< double,std::allocator< double > >::const_iterator i = self->begin();
std::vector< double,std::allocator< double > >::const_iterator e = self->end();
VALUE ary = rb_ary_new2( std::distance( i, e ) );
VALUE tmp;
for ( ; i != e; ++i )
{
tmp = swig::from< std::vector< double,std::allocator< double > >::value_type >( *i );
rb_ary_push( ary, tmp );
}
return ary;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg__to_s(std::vector< float64_t > *self){
std::vector< double,std::allocator< double > >::iterator i = self->begin();
std::vector< double,std::allocator< double > >::iterator e = self->end();
VALUE str = rb_str_new2( "" );
VALUE tmp;
for ( ; i != e; ++i )
{
tmp = swig::from< std::vector< double,std::allocator< double > >::value_type >( *i );
tmp = rb_obj_as_string( tmp );
str = rb_str_buf_append( str, tmp );
}
return str;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg__slice(std::vector< float64_t > *self,std::vector< double >::difference_type i,std::vector< double >::difference_type length){
if ( length < 0 )
return Qnil;
std::size_t len = self->size();
if ( i < 0 ) {
if ( i + static_cast<std::vector< double,std::allocator< double > >::difference_type>(len) < 0 )
return Qnil;
else
i = len + i;
}
std::vector< double,std::allocator< double > >::difference_type j = length + i;
if ( j > static_cast<std::vector< double,std::allocator< double > >::difference_type>(len) )
j = len;
VALUE r = Qnil;
try {
r = swig::from< const std::vector< double,std::allocator< double > >* >( swig::getslice(self, i, j) );
}
catch( std::out_of_range ) {
}
return r;
}
SWIGINTERN std::vector< double,std::allocator< double > > *std_vector_Sl_float64_t_Sg__each(std::vector< float64_t > *self){
if ( !rb_block_given_p() )
rb_raise( rb_eArgError, "no block given");
VALUE r;
std::vector< double,std::allocator< double > >::const_iterator i = self->begin();
std::vector< double,std::allocator< double > >::const_iterator e = self->end();
for ( ; i != e; ++i )
{
r = swig::from< std::vector< double,std::allocator< double > >::value_type >(*i);
rb_yield(r);
}
return self;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg____delete2__(std::vector< float64_t > *self,std::vector< double >::value_type const &i){
VALUE r = Qnil;
return r;
}
SWIGINTERN std::vector< double,std::allocator< double > > *std_vector_Sl_float64_t_Sg__select(std::vector< float64_t > *self){
if ( !rb_block_given_p() )
rb_raise( rb_eArgError, "no block given" );
std::vector< double,std::allocator< double > >* r = new std::vector< double,std::allocator< double > >();
std::vector< double,std::allocator< double > >::const_iterator i = self->begin();
std::vector< double,std::allocator< double > >::const_iterator e = self->end();
for ( ; i != e; ++i )
{
VALUE v = swig::from< std::vector< double,std::allocator< double > >::value_type >(*i);
if ( RTEST( rb_yield(v) ) )
self->insert( r->end(), *i);
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg__delete_at(std::vector< float64_t > *self,std::vector< double >::difference_type i){
VALUE r = Qnil;
try {
std::vector< double,std::allocator< double > >::iterator at = swig::getpos(self, i);
r = swig::from< std::vector< double,std::allocator< double > >::value_type >( *(at) );
self->erase(at);
}
catch (std::out_of_range)
{
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg__at(std::vector< float64_t > const *self,std::vector< double >::difference_type i){
VALUE r = Qnil;
try {
r = swig::from< std::vector< double,std::allocator< double > >::value_type >( *(swig::cgetpos(self, i)) );
}
catch( std::out_of_range ) {
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg____getitem____SWIG_0(std::vector< float64_t > const *self,std::vector< double >::difference_type i,std::vector< double >::difference_type length){
if ( length < 0 )
return Qnil;
std::size_t len = self->size();
if ( i < 0 ) {
if ( i + static_cast<std::vector< double,std::allocator< double > >::difference_type>(len) < 0 )
return Qnil;
else
i = len + i;
}
std::vector< double,std::allocator< double > >::difference_type j = length + i;
if ( j > static_cast<std::vector< double,std::allocator< double > >::difference_type>(len) )
j = len;
VALUE r = Qnil;
try {
r = swig::from< const std::vector< double,std::allocator< double > >* >( swig::getslice(self, i, j) );
}
catch( std::out_of_range ) {
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg____getitem____SWIG_1(std::vector< float64_t > const *self,std::vector< double >::difference_type i){
VALUE r = Qnil;
try {
r = swig::from< std::vector< double,std::allocator< double > >::value_type >( *(swig::cgetpos(self, i)) );
}
catch( std::out_of_range ) {
}
return r;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg____getitem____SWIG_2(std::vector< float64_t > const *self,VALUE i){
if ( rb_obj_is_kind_of( i, rb_cRange ) == Qfalse ) {
rb_raise( rb_eTypeError, "not a valid index or range" );
}
static ID id_end = rb_intern("end");
static ID id_start = rb_intern("begin");
static ID id_noend = rb_intern("exclude_end?");
VALUE start = rb_funcall( i, id_start, 0 );
VALUE end = rb_funcall( i, id_end, 0 );
bool noend = ( rb_funcall( i, id_noend, 0 ) == Qtrue );
int len = self->size();
int s = NUM2INT( start );
if ( s < 0 ) {
s = len + s;
if ( s < 0 )
return Qnil;
} else if ( s > len )
return Qnil;
int e = NUM2INT( end );
if ( e < 0 ) e = len + e;
if ( noend ) e -= 1;
if ( e < 0 ) e = -1;
if ( e >= len ) e = len - 1;
if ( s == len ) e = len - 1;
return swig::from< std::vector< double,std::allocator< double > >* >( swig::getslice(self, s, e+1) );
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg____setitem____SWIG_0(std::vector< float64_t > *self,std::vector< double >::difference_type i,std::vector< double >::value_type const &x){
if ( i >= static_cast<std::vector< double,std::allocator< double > >::difference_type>( self->size()) )
swig::resize( self, i+1, x );
else
*(swig::getpos(self, i)) = x;
return swig::from< std::vector< double,std::allocator< double > >::value_type >( x );
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg____setitem____SWIG_1(std::vector< float64_t > *self,std::vector< double >::difference_type i,std::vector< double >::difference_type length,std::vector< double,std::allocator< double > > const &v){
if ( length < 0 )
return Qnil;
std::size_t len = self->size();
if ( i < 0 ) {
if ( i + static_cast<std::vector< double,std::allocator< double > >::difference_type>(len) < 0 )
return Qnil;
else
i = len + i;
}
std::vector< double,std::allocator< double > >::difference_type j = length + i;
if ( j > static_cast<std::vector< double,std::allocator< double > >::difference_type>(len) ) {
swig::resize( self, j, *(v.begin()) );
}
VALUE r = Qnil;
swig::setslice(self, i, j, v);
r = swig::from< const std::vector< double,std::allocator< double > >* >( &v );
return r;
}
SWIGINTERN std::vector< double,std::allocator< double > > *std_vector_Sl_float64_t_Sg__reject_bang(std::vector< float64_t > *self){
if ( !rb_block_given_p() )
rb_raise( rb_eArgError, "no block given" );
self->erase( std::remove_if( self->begin(), self->end(),
swig::yield< std::vector< double,std::allocator< double > >::value_type >() ), self->end() );
return self;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg__pop(std::vector< float64_t > *self){
if (self->empty()) return Qnil;
std::vector< double,std::allocator< double > >::value_type x = self->back();
self->pop_back();
return swig::from< std::vector< double,std::allocator< double > >::value_type >( x );
}
SWIGINTERN std::vector< double >::value_type const std_vector_Sl_float64_t_Sg__push(std::vector< float64_t > *self,std::vector< double >::value_type const &e){
self->push_back( e );
return e;
}
SWIGINTERN std::vector< double,std::allocator< double > > *std_vector_Sl_float64_t_Sg__reject(std::vector< float64_t > *self){
if ( !rb_block_given_p() )
rb_raise( rb_eArgError, "no block given" );
std::vector< double,std::allocator< double > >* r = new std::vector< double,std::allocator< double > >();
std::remove_copy_if( self->begin(), self->end(),
std::back_inserter(*r),
swig::yield< std::vector< double,std::allocator< double > >::value_type >() );
return r;
}
SWIGINTERN VALUE std_vector_Sl_float64_t_Sg__shift(std::vector< float64_t > *self){
if (self->empty()) return Qnil;
std::vector< double,std::allocator< double > >::value_type x = self->front();
self->erase( self->begin() );
return swig::from< std::vector< double,std::allocator< double > >::value_type >( x );
}
SWIGINTERN std::vector< double,std::allocator< double > > *std_vector_Sl_float64_t_Sg__insert__SWIG_0(std::vector< float64_t > *self,std::vector< double >::difference_type pos,int argc,VALUE *argv,...){
std::size_t len = self->size();
std::size_t i = swig::check_index( pos, len, true );
std::vector< double,std::allocator< double > >::iterator start;
VALUE elem = argv[0];
int idx = 0;
try {
std::vector< double,std::allocator< double > >::value_type val = swig::as<std::vector< double,std::allocator< double > >::value_type>( elem, true );
if ( i >= len ) {
self->resize(i-1, val);
return self;
}
start = self->begin();
std::advance( start, i );
self->insert( start++, val );
for ( ++idx; idx < argc; ++idx )
{
elem = argv[idx];
val = swig::as<std::vector< double,std::allocator< double > >::value_type>( elem );
self->insert( start++, val );
}
}
catch( std::invalid_argument )
{
rb_raise( rb_eArgError, "%s",
Ruby_Format_TypeError( "",
swig::type_name<std::vector< double,std::allocator< double > >::value_type>(),
__FUNCTION__, idx+2, elem ));
}
return self;
}
SWIGINTERN std::vector< double,std::allocator< double > > *std_vector_Sl_float64_t_Sg__unshift(std::vector< float64_t > *self,int argc,VALUE *argv,...){
for ( int idx = argc-1; idx >= 0; --idx )
{
std::vector< double,std::allocator< double > >::iterator start = self->begin();
VALUE elem = argv[idx];
try {
std::vector< double,std::allocator< double > >::value_type val = swig::as<std::vector< double,std::allocator< double > >::value_type>( elem, true );
self->insert( start, val );
}
catch( std::invalid_argument )
{
rb_raise( rb_eArgError, "%s",
Ruby_Format_TypeError( "",
swig::type_name<std::vector< double,std::allocator< double > >::value_type>(),
__FUNCTION__, idx+2, elem ));
}
}
return self;
}
SWIGINTERN std::vector< double >::iterator std_vector_Sl_float64_t_Sg__erase__SWIG_0(std::vector< float64_t > *self,std::vector< double >::iterator pos){ return self->erase(pos); }
SWIGINTERN std::vector< double >::iterator std_vector_Sl_float64_t_Sg__erase__SWIG_1(std::vector< float64_t > *self,std::vector< double >::iterator first,std::vector< double >::iterator last){ return self->erase(first, last); }
SWIGINTERN std::vector< double >::iterator std_vector_Sl_float64_t_Sg__insert__SWIG_1(std::vector< float64_t > *self,std::vector< double >::iterator pos,std::vector< double >::value_type const &x){ return self->insert(pos, x); }
SWIGINTERN void std_vector_Sl_float64_t_Sg__insert__SWIG_2(std::vector< float64_t > *self,std::vector< double >::iterator pos,std::vector< double >::size_type n,std::vector< double >::value_type const &x){ self->insert(pos, n, x); }
SWIGINTERN int
SWIG_AsCharPtrAndSize(VALUE obj, char** cptr, size_t* psize, int *alloc)
{
if (TYPE(obj) == T_STRING) {
char *cstr = StringValuePtr(obj);
size_t size = RSTRING_LEN(obj) + 1;
if (cptr) {
if (alloc) {
if (*alloc == SWIG_NEWOBJ) {
*cptr = reinterpret_cast< char* >(memcpy((new char[size]), cstr, sizeof(char)*(size)));
} else {
*cptr = cstr;
*alloc = SWIG_OLDOBJ;
}
}
}
if (psize) *psize = size;
return SWIG_OK;
} else {
swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
if (pchar_descriptor) {
void* vptr = 0;
if (SWIG_ConvertPtr(obj, &vptr, pchar_descriptor, 0) == SWIG_OK) {
if (cptr) *cptr = (char *)vptr;
if (psize) *psize = vptr ? (strlen((char*)vptr) + 1) : 0;
if (alloc) *alloc = SWIG_OLDOBJ;
return SWIG_OK;
}
}
}
return SWIG_TypeError;
}
SWIGINTERN int
SWIG_AsVal_bool (VALUE obj, bool *val)
{
if (obj == Qtrue) {
if (val) *val = true;
return SWIG_OK;
} else if (obj == Qfalse) {
if (val) *val = false;
return SWIG_OK;
} else {
int res = 0;
if (SWIG_AsVal_int (obj, &res) == SWIG_OK) {
if (val) *val = res ? true : false;
return SWIG_OK;
}
}
return SWIG_TypeError;
}
SWIGINTERN int
SWIG_AsVal_unsigned_SS_int (VALUE obj, unsigned int *val)
{
unsigned long v;
int res = SWIG_AsVal_unsigned_SS_long (obj, &v);
if (SWIG_IsOK(res)) {
if ((v > UINT_MAX)) {
return SWIG_OverflowError;
} else {
if (val) *val = static_cast< unsigned int >(v);
}
}
return res;
}
SWIGINTERNINLINE VALUE
SWIG_From_unsigned_SS_int (unsigned int value)
{
return SWIG_From_unsigned_SS_long (value);
}
SWIGINTERNINLINE VALUE
SWIG_From_float (float value)
{
return SWIG_From_double (value);
}
SWIGINTERN int
SWIG_AsCharArray(VALUE obj, char *val, size_t size)
{
char* cptr = 0; size_t csize = 0; int alloc = SWIG_OLDOBJ;
int res = SWIG_AsCharPtrAndSize(obj, &cptr, &csize, &alloc);
if (SWIG_IsOK(res)) {
/* special case of single char conversion when we don't need space for NUL */
if (size == 1 && csize == 2 && cptr && !cptr[1]) --csize;
if (csize <= size) {
if (val) {
if (csize) memcpy(val, cptr, csize*sizeof(char));
if (csize < size) memset(val + csize, 0, (size - csize)*sizeof(char));
}
if (alloc == SWIG_NEWOBJ) {
delete[] cptr;
res = SWIG_DelNewMask(res);
}
return res;
}
if (alloc == SWIG_NEWOBJ) delete[] cptr;
}
return SWIG_TypeError;
}
SWIGINTERN int
SWIG_AsVal_char (VALUE obj, char *val)
{
int res = SWIG_AsCharArray(obj, val, 1);
if (!SWIG_IsOK(res)) {
long v;
res = SWIG_AddCast(SWIG_AsVal_long (obj, &v));
if (SWIG_IsOK(res)) {
if ((CHAR_MIN <= v) && (v <= CHAR_MAX)) {
if (val) *val = static_cast< char >(v);
} else {
res = SWIG_OverflowError;
}
}
}
return res;
}
SWIGINTERNINLINE VALUE
SWIG_From_char (char c)
{
return SWIG_FromCharPtrAndSize(&c,1);
}
SWIGINTERNINLINE VALUE
SWIG_From_unsigned_SS_char (unsigned char value)
{
return SWIG_From_unsigned_SS_long (value);
}
SWIGINTERN int
SWIG_AsVal_unsigned_SS_char (VALUE obj, unsigned char *val)
{
unsigned long v;
int res = SWIG_AsVal_unsigned_SS_long (obj, &v);
if (SWIG_IsOK(res)) {
if ((v > UCHAR_MAX)) {
return SWIG_OverflowError;
} else {
if (val) *val = static_cast< unsigned char >(v);
}
}
return res;
}
SWIGINTERNINLINE VALUE
SWIG_From_unsigned_SS_short (unsigned short value)
{
return SWIG_From_unsigned_SS_long (value);
}
SWIGINTERN int
SWIG_AsVal_unsigned_SS_short (VALUE obj, unsigned short *val)
{
unsigned long v;
int res = SWIG_AsVal_unsigned_SS_long (obj, &v);
if (SWIG_IsOK(res)) {
if ((v > USHRT_MAX)) {
return SWIG_OverflowError;
} else {
if (val) *val = static_cast< unsigned short >(v);
}
}
return res;
}
#include <float.h>
#include <math.h>
/* Getting isfinite working pre C99 across multiple platforms is non-trivial. Users can provide SWIG_isfinite on older platforms. */
#ifndef SWIG_isfinite
/* isfinite() is a macro for C99, but a function in namespace std for C++11. */
# if defined(isfinite)
# define SWIG_isfinite(X) (isfinite(X))
# elif defined __cplusplus && __cplusplus >= 201103L
# define SWIG_isfinite(X) (std::isfinite(X))
# elif defined(_MSC_VER)
# define SWIG_isfinite(X) (_finite(X))
# elif defined(__sun) && defined(__SVR4)
# include <ieeefp.h>
# define SWIG_isfinite(X) (finite(X))
# endif
#endif
/* Accept infinite as a valid float value unless we are unable to check if a value is finite */
#ifdef SWIG_isfinite
# define SWIG_Float_Overflow_Check(X) ((X < -FLT_MAX || X > FLT_MAX) && SWIG_isfinite(X))
#else
# define SWIG_Float_Overflow_Check(X) ((X < -FLT_MAX || X > FLT_MAX))
#endif
SWIGINTERN int
SWIG_AsVal_float (VALUE obj, float *val)
{
double v;
int res = SWIG_AsVal_double (obj, &v);
if (SWIG_IsOK(res)) {
if (SWIG_Float_Overflow_Check(v)) {
return SWIG_OverflowError;
} else {
if (val) *val = static_cast< float >(v);
}
}
return res;
}
SWIGINTERN shogun::CBinaryLabels *shogun_CKernelMachine_apply__SWIG_0(shogun::CKernelMachine *self,shogun::CFeatures *data=NULL){
return self->apply_binary(data);
}
SWIGINTERN shogun::CMulticlassLabels *shogun_CDistanceMachine_apply__SWIG_0(shogun::CDistanceMachine *self,shogun::CFeatures *data=NULL){
return self->apply_multiclass(data);
}
SWIGINTERN shogun::CBinaryLabels *shogun_CLinearMachine_apply__SWIG_0(shogun::CLinearMachine *self,shogun::CFeatures *data=NULL){
return self->apply_binary(data);
}
SWIGINTERN shogun::CBinaryLabels *shogun_CWDSVMOcas_apply__SWIG_0(shogun::CWDSVMOcas *self,shogun::CFeatures *data=NULL){
return self->apply_binary(data);
}
SWIGINTERN shogun::CBinaryLabels *shogun_CPluginEstimate_apply__SWIG_0(shogun::CPluginEstimate *self,shogun::CFeatures *data=NULL){
return self->apply_binary(data);
}
SWIGINTERN shogun::CRegressionLabels *shogun_CKernelRidgeRegression_apply__SWIG_0(shogun::CKernelRidgeRegression *self,shogun::CFeatures *data=NULL){
return self->apply_regression(data);
}
SWIGINTERN shogun::CRegressionLabels *shogun_CLinearRidgeRegression_apply__SWIG_0(shogun::CLinearRidgeRegression *self,shogun::CFeatures *data=NULL){
return self->apply_regression(data);
}
SWIGINTERN shogun::CRegressionLabels *shogun_CLeastSquaresRegression_apply__SWIG_0(shogun::CLeastSquaresRegression *self,shogun::CFeatures *data=NULL){
return self->apply_regression(data);
}
SWIGINTERN shogun::CRegressionLabels *shogun_CLeastAngleRegression_apply__SWIG_0(shogun::CLeastAngleRegression *self,shogun::CFeatures *data=NULL){
return self->apply_regression(data);
}
SWIGINTERN shogun::CRegressionLabels *shogun_CLibSVR_apply__SWIG_0(shogun::CLibSVR *self,shogun::CFeatures *data=NULL){
return self->apply_regression(data);
}
SWIGINTERN shogun::CRegressionLabels *shogun_CMKLRegression_apply__SWIG_0(shogun::CMKLRegression *self,shogun::CFeatures *data=NULL){
return self->apply_regression(data);
}
SWIGINTERN shogun::CRegressionLabels *shogun_CSVRLight_apply__SWIG_0(shogun::CSVRLight *self,shogun::CFeatures *data=NULL){
return self->apply_regression(data);
}
SWIGINTERN int
SWIG_AsVal_short (VALUE obj, short *val)
{
long v;
int res = SWIG_AsVal_long (obj, &v);
if (SWIG_IsOK(res)) {
if ((v < SHRT_MIN || v > SHRT_MAX)) {
return SWIG_OverflowError;
} else {
if (val) *val = static_cast< short >(v);
}
}
return res;
}
SWIGINTERN int
SWIG_AsVal_signed_SS_char (VALUE obj, signed char *val)
{
long v;
int res = SWIG_AsVal_long (obj, &v);
if (SWIG_IsOK(res)) {
if ((v < SCHAR_MIN || v > SCHAR_MAX)) {
return SWIG_OverflowError;
} else {
if (val) *val = static_cast< signed char >(v);
}
}
return res;
}
SWIGINTERNINLINE VALUE
SWIG_From_signed_SS_char (signed char value)
{
return SWIG_From_long (value);
}
SWIGINTERN shogun::CStructuredLabels *shogun_CStructuredOutputMachine_apply__SWIG_0(shogun::CStructuredOutputMachine *self,shogun::CFeatures *data=NULL){
return self->apply_structured(data);
}
SWIGINTERN shogun::CStructuredLabels *shogun_CLinearStructuredOutputMachine_apply__SWIG_0(shogun::CLinearStructuredOutputMachine *self,shogun::CFeatures *data=NULL){
return self->apply_structured(data);
}
SWIGINTERN shogun::CStructuredLabels *shogun_CKernelStructuredOutputMachine_apply__SWIG_0(shogun::CKernelStructuredOutputMachine *self,shogun::CFeatures *data=NULL){
return self->apply_structured(data);
}
SWIGINTERN shogun::CStructuredLabels *shogun_CDualLibQPBMSOSVM_apply__SWIG_0(shogun::CDualLibQPBMSOSVM *self,shogun::CFeatures *data=NULL){
return self->apply_structured(data);
}
SWIGINTERN shogun::CMulticlassLabels *shogun_CMulticlassMachine_apply__SWIG_0(shogun::CMulticlassMachine *self,shogun::CFeatures *data=NULL){
return self->apply_multiclass(data);
}
SWIGINTERN shogun::CMulticlassLabels *shogun_CLinearMulticlassMachine_apply__SWIG_0(shogun::CLinearMulticlassMachine *self,shogun::CFeatures *data=NULL){
return self->apply_multiclass(data);
}
SWIGINTERN shogun::CMulticlassLabels *shogun_CKernelMulticlassMachine_apply__SWIG_0(shogun::CKernelMulticlassMachine *self,shogun::CFeatures *data=NULL){
return self->apply_multiclass(data);
}
SWIGINTERN shogun::CLatentLabels *shogun_CLatentSVM_apply__SWIG_0(shogun::CLatentSVM *self,shogun::CFeatures *data=NULL){
return self->apply_latent(data);
}
SWIGINTERN shogun::CBinaryLabels *shogun_CGaussianProcessClassification_apply__SWIG_0(shogun::CGaussianProcessClassification *self,shogun::CFeatures *data=NULL){
return self->apply_binary(data);
}
SWIGINTERN shogun::CRegressionLabels *shogun_CGaussianProcessRegression_apply__SWIG_0(shogun::CGaussianProcessRegression *self,shogun::CFeatures *data=NULL){
return self->apply_regression(data);
}
/*
Document-class: Modshogun::GC_VALUE
Proxy of C++ Modshogun::GC_VALUE class
*/
static swig_class SwigClassGC_VALUE;
/*
Document-method: Modshogun::GC_VALUE.inspect
call-seq:
inspect -> VALUE
Inspect class and its contents.
*/
SWIGINTERN VALUE
_wrap_GC_VALUE_inspect(int argc, VALUE *argv, VALUE self) {
swig::GC_VALUE *arg1 = (swig::GC_VALUE *) 0 ;
swig::GC_VALUE r1 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
r1 = self; arg1 = &r1;
{
try
{
result = (VALUE)((swig::GC_VALUE const *)arg1)->inspect();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::GC_VALUE.to_s
call-seq:
to_s -> VALUE
Convert class to a String representation.
*/
SWIGINTERN VALUE
_wrap_GC_VALUE_to_s(int argc, VALUE *argv, VALUE self) {
swig::GC_VALUE *arg1 = (swig::GC_VALUE *) 0 ;
swig::GC_VALUE r1 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
r1 = self; arg1 = &r1;
{
try
{
result = (VALUE)((swig::GC_VALUE const *)arg1)->to_s();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-class: Modshogun::ConstIterator
Proxy of C++ Modshogun::ConstIterator class
*/
static swig_class SwigClassConstIterator;
SWIGINTERN void
free_swig_ConstIterator(void *self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *)self;
delete arg1;
}
/*
Document-method: Modshogun::ConstIterator.value
call-seq:
value -> VALUE
An instance method.
*/
SWIGINTERN VALUE
_wrap_ConstIterator_value(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator const *","value", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
{
try
{
try {
result = (VALUE)((swig::ConstIterator const *)arg1)->value();
}
catch(swig::stop_iteration &_e) {
{
(void)_e;
SWIG_Ruby_ExceptionType(NULL, Qnil);
SWIG_fail;
}
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::ConstIterator.dup
call-seq:
dup -> ConstIterator
Create a duplicate of the class and unfreeze it if needed.
*/
SWIGINTERN VALUE
_wrap_ConstIterator_dup(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::ConstIterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator const *","dup", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
{
try
{
result = (swig::ConstIterator *)((swig::ConstIterator const *)arg1)->dup();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__ConstIterator, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::ConstIterator.inspect
call-seq:
inspect -> VALUE
Inspect class and its contents.
*/
SWIGINTERN VALUE
_wrap_ConstIterator_inspect(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator const *","inspect", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
{
try
{
result = (VALUE)((swig::ConstIterator const *)arg1)->inspect();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::ConstIterator.to_s
call-seq:
to_s -> VALUE
Convert class to a String representation.
*/
SWIGINTERN VALUE
_wrap_ConstIterator_to_s(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator const *","to_s", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
{
try
{
result = (VALUE)((swig::ConstIterator const *)arg1)->to_s();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::ConstIterator.next
call-seq:
next(n=1) -> ConstIterator
next -> ConstIterator
An instance method.
*/
SWIGINTERN VALUE
_wrap_ConstIterator_next__SWIG_0(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
size_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
swig::ConstIterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator *","next", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "size_t","next", 2, argv[0] ));
}
arg2 = static_cast< size_t >(val2);
{
try
{
result = (swig::ConstIterator *)(arg1)->next(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_ConstIterator_next__SWIG_1(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::ConstIterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator *","next", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
{
try
{
try {
result = (swig::ConstIterator *)(arg1)->next();
}
catch(swig::stop_iteration &_e) {
{
(void)_e;
SWIG_Ruby_ExceptionType(NULL, Qnil);
SWIG_fail;
}
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_ConstIterator_next(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[3];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 3) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__ConstIterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_ConstIterator_next__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__ConstIterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_ConstIterator_next__SWIG_0(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "ConstIterator.next",
" swig::ConstIterator ConstIterator.next(size_t n)\n"
" swig::ConstIterator * ConstIterator.next()\n");
return Qnil;
}
/*
Document-method: Modshogun::ConstIterator.previous
call-seq:
previous(n=1) -> ConstIterator
previous -> ConstIterator
An instance method.
*/
SWIGINTERN VALUE
_wrap_ConstIterator_previous__SWIG_0(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
size_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
swig::ConstIterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator *","previous", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "size_t","previous", 2, argv[0] ));
}
arg2 = static_cast< size_t >(val2);
{
try
{
result = (swig::ConstIterator *)(arg1)->previous(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_ConstIterator_previous__SWIG_1(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::ConstIterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator *","previous", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
{
try
{
try {
result = (swig::ConstIterator *)(arg1)->previous();
}
catch(swig::stop_iteration &_e) {
{
(void)_e;
SWIG_Ruby_ExceptionType(NULL, Qnil);
SWIG_fail;
}
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_ConstIterator_previous(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[3];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 3) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__ConstIterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_ConstIterator_previous__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__ConstIterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_ConstIterator_previous__SWIG_0(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "ConstIterator.previous",
" swig::ConstIterator ConstIterator.previous(size_t n)\n"
" swig::ConstIterator * ConstIterator.previous()\n");
return Qnil;
}
/*
Document-method: Modshogun::ConstIterator.+
call-seq:
+(n) -> ConstIterator
Add operator.
*/
SWIGINTERN VALUE
_wrap_ConstIterator___add__(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
ptrdiff_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
swig::ConstIterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator const *","operator +", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "ptrdiff_t","operator +", 2, argv[0] ));
}
arg2 = static_cast< ptrdiff_t >(val2);
{
try
{
try {
result = (swig::ConstIterator *)((swig::ConstIterator const *)arg1)->operator +(arg2);
}
catch(swig::stop_iteration &_e) {
{
(void)_e;
SWIG_Ruby_ExceptionType(NULL, Qnil);
SWIG_fail;
}
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__ConstIterator, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::ConstIterator.-
call-seq:
-(n) -> ConstIterator
-(x) -> ptrdiff_t
Substraction operator.
*/
SWIGINTERN VALUE
_wrap_ConstIterator___sub____SWIG_0(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
ptrdiff_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
swig::ConstIterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator const *","operator -", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "ptrdiff_t","operator -", 2, argv[0] ));
}
arg2 = static_cast< ptrdiff_t >(val2);
{
try
{
try {
result = (swig::ConstIterator *)((swig::ConstIterator const *)arg1)->operator -(arg2);
}
catch(swig::stop_iteration &_e) {
{
(void)_e;
SWIG_Ruby_ExceptionType(NULL, Qnil);
SWIG_fail;
}
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__ConstIterator, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_ConstIterator___sub____SWIG_1(int argc, VALUE *argv, VALUE self) {
swig::ConstIterator *arg1 = (swig::ConstIterator *) 0 ;
swig::ConstIterator *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 ;
int res2 = 0 ;
ptrdiff_t result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__ConstIterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::ConstIterator const *","operator -", 1, self ));
}
arg1 = reinterpret_cast< swig::ConstIterator * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_swig__ConstIterator, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "swig::ConstIterator const &","operator -", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "swig::ConstIterator const &","operator -", 2, argv[0]));
}
arg2 = reinterpret_cast< swig::ConstIterator * >(argp2);
{
try
{
result = ((swig::ConstIterator const *)arg1)->operator -((swig::ConstIterator const &)*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_ptrdiff_t(static_cast< ptrdiff_t >(result));
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_ConstIterator___sub__(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[3];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 3) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__ConstIterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_swig__ConstIterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_ConstIterator___sub____SWIG_1(nargs, args, self);
}
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__ConstIterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_ConstIterator___sub____SWIG_0(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "ConstIterator.__sub__",
" swig::ConstIterator ConstIterator.__sub__(ptrdiff_t n)\n"
" ptrdiff_t ConstIterator.__sub__(swig::ConstIterator const &x)\n");
return Qnil;
}
/*
Document-class: Modshogun::Iterator < Modshogun::swig::ConstIterator
Proxy of C++ Modshogun::Iterator class
*/
static swig_class SwigClassIterator;
/*
Document-method: Modshogun::Iterator.value=
call-seq:
value=(v) -> VALUE
An instance method.
*/
SWIGINTERN VALUE
_wrap_Iterator_valuee___(int argc, VALUE *argv, VALUE self) {
swig::Iterator *arg1 = (swig::Iterator *) 0 ;
VALUE *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE temp2 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__Iterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::Iterator *","setValue", 1, self ));
}
arg1 = reinterpret_cast< swig::Iterator * >(argp1);
temp2 = static_cast< VALUE >(argv[0]);
arg2 = &temp2;
{
try
{
result = (VALUE)(arg1)->setValue((VALUE const &)*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Iterator.dup
call-seq:
dup -> Iterator
Create a duplicate of the class and unfreeze it if needed.
*/
SWIGINTERN VALUE
_wrap_Iterator_dup(int argc, VALUE *argv, VALUE self) {
swig::Iterator *arg1 = (swig::Iterator *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__Iterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::Iterator const *","dup", 1, self ));
}
arg1 = reinterpret_cast< swig::Iterator * >(argp1);
{
try
{
result = (swig::Iterator *)((swig::Iterator const *)arg1)->dup();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__Iterator, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Iterator.next
call-seq:
next(n=1) -> Iterator
next -> Iterator
An instance method.
*/
SWIGINTERN VALUE
_wrap_Iterator_next__SWIG_0(int argc, VALUE *argv, VALUE self) {
swig::Iterator *arg1 = (swig::Iterator *) 0 ;
size_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
swig::Iterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__Iterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::Iterator *","next", 1, self ));
}
arg1 = reinterpret_cast< swig::Iterator * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "size_t","next", 2, argv[0] ));
}
arg2 = static_cast< size_t >(val2);
{
try
{
result = (swig::Iterator *)(arg1)->next(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__Iterator, 0 | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_Iterator_next__SWIG_1(int argc, VALUE *argv, VALUE self) {
swig::Iterator *arg1 = (swig::Iterator *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__Iterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::Iterator *","next", 1, self ));
}
arg1 = reinterpret_cast< swig::Iterator * >(argp1);
{
try
{
try {
result = (swig::Iterator *)(arg1)->next();
}
catch(swig::stop_iteration &_e) {
{
(void)_e;
SWIG_Ruby_ExceptionType(NULL, Qnil);
SWIG_fail;
}
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__Iterator, 0 | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_Iterator_next(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[3];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 3) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__Iterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_Iterator_next__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__Iterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_Iterator_next__SWIG_0(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "Iterator.next",
" swig::Iterator Iterator.next(size_t n)\n"
" swig::Iterator * Iterator.next()\n");
return Qnil;
}
/*
Document-method: Modshogun::Iterator.previous
call-seq:
previous(n=1) -> Iterator
previous -> Iterator
An instance method.
*/
SWIGINTERN VALUE
_wrap_Iterator_previous__SWIG_0(int argc, VALUE *argv, VALUE self) {
swig::Iterator *arg1 = (swig::Iterator *) 0 ;
size_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
swig::Iterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__Iterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::Iterator *","previous", 1, self ));
}
arg1 = reinterpret_cast< swig::Iterator * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "size_t","previous", 2, argv[0] ));
}
arg2 = static_cast< size_t >(val2);
{
try
{
result = (swig::Iterator *)(arg1)->previous(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__Iterator, 0 | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_Iterator_previous__SWIG_1(int argc, VALUE *argv, VALUE self) {
swig::Iterator *arg1 = (swig::Iterator *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__Iterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::Iterator *","previous", 1, self ));
}
arg1 = reinterpret_cast< swig::Iterator * >(argp1);
{
try
{
try {
result = (swig::Iterator *)(arg1)->previous();
}
catch(swig::stop_iteration &_e) {
{
(void)_e;
SWIG_Ruby_ExceptionType(NULL, Qnil);
SWIG_fail;
}
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__Iterator, 0 | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_Iterator_previous(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[3];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 3) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__Iterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_Iterator_previous__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__Iterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_Iterator_previous__SWIG_0(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "Iterator.previous",
" swig::Iterator Iterator.previous(size_t n)\n"
" swig::Iterator * Iterator.previous()\n");
return Qnil;
}
/*
Document-method: Modshogun::Iterator.+
call-seq:
+(n) -> Iterator
Add operator.
*/
SWIGINTERN VALUE
_wrap_Iterator___add__(int argc, VALUE *argv, VALUE self) {
swig::Iterator *arg1 = (swig::Iterator *) 0 ;
ptrdiff_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
swig::Iterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__Iterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::Iterator const *","operator +", 1, self ));
}
arg1 = reinterpret_cast< swig::Iterator * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "ptrdiff_t","operator +", 2, argv[0] ));
}
arg2 = static_cast< ptrdiff_t >(val2);
{
try
{
try {
result = (swig::Iterator *)((swig::Iterator const *)arg1)->operator +(arg2);
}
catch(swig::stop_iteration &_e) {
{
(void)_e;
SWIG_Ruby_ExceptionType(NULL, Qnil);
SWIG_fail;
}
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__Iterator, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Iterator.-
call-seq:
-(n) -> Iterator
-(x) -> ptrdiff_t
Substraction operator.
*/
SWIGINTERN VALUE
_wrap_Iterator___sub____SWIG_0(int argc, VALUE *argv, VALUE self) {
swig::Iterator *arg1 = (swig::Iterator *) 0 ;
ptrdiff_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
swig::Iterator *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__Iterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::Iterator const *","operator -", 1, self ));
}
arg1 = reinterpret_cast< swig::Iterator * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "ptrdiff_t","operator -", 2, argv[0] ));
}
arg2 = static_cast< ptrdiff_t >(val2);
{
try
{
try {
result = (swig::Iterator *)((swig::Iterator const *)arg1)->operator -(arg2);
}
catch(swig::stop_iteration &_e) {
{
(void)_e;
SWIG_Ruby_ExceptionType(NULL, Qnil);
SWIG_fail;
}
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__Iterator, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_Iterator___sub____SWIG_1(int argc, VALUE *argv, VALUE self) {
swig::Iterator *arg1 = (swig::Iterator *) 0 ;
swig::Iterator *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 ;
int res2 = 0 ;
ptrdiff_t result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_swig__Iterator, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "swig::Iterator const *","operator -", 1, self ));
}
arg1 = reinterpret_cast< swig::Iterator * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_swig__Iterator, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "swig::Iterator const &","operator -", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "swig::Iterator const &","operator -", 2, argv[0]));
}
arg2 = reinterpret_cast< swig::Iterator * >(argp2);
{
try
{
result = ((swig::Iterator const *)arg1)->operator -((swig::Iterator const &)*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_ptrdiff_t(static_cast< ptrdiff_t >(result));
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_Iterator___sub__(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[3];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 3) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__Iterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_swig__Iterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_Iterator___sub____SWIG_1(nargs, args, self);
}
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__Iterator, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_Iterator___sub____SWIG_0(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "Iterator.__sub__",
" swig::Iterator Iterator.__sub__(ptrdiff_t n)\n"
" ptrdiff_t Iterator.__sub__(swig::Iterator const &x)\n");
return Qnil;
}
SWIGINTERN void
free_swig_Iterator(void *self) {
swig::Iterator *arg1 = (swig::Iterator *)self;
delete arg1;
}
/*
Document-class: Modshogun::IntStdVector
Proxy of C++ Modshogun::IntStdVector class
*/
static swig_class SwigClassIntStdVector;
/*
Document-method: Modshogun::IntStdVector.dup
call-seq:
dup -> IntStdVector
Create a duplicate of the class and unfreeze it if needed.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_dup(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int,std::allocator< int > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","dup", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (std::vector< int,std::allocator< int > > *)std_vector_Sl_int32_t_Sg__dup(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.inspect
call-seq:
inspect -> VALUE
Inspect class and its contents.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_inspect(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","inspect", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_int32_t_Sg__inspect(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.to_a
call-seq:
to_a -> VALUE
Convert IntStdVector to an Array.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_to_a(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","to_a", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_int32_t_Sg__to_a(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.to_s
call-seq:
to_s -> VALUE
Convert class to a String representation.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_to_s(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","to_s", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_int32_t_Sg__to_s(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.slice
call-seq:
slice(i, length) -> VALUE
Return a slice (portion of) the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_slice(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::difference_type arg2 ;
std::vector< int >::difference_type arg3 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
ptrdiff_t val3 ;
int ecode3 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","slice", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","slice", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::difference_type >(val2);
ecode3 = SWIG_AsVal_ptrdiff_t(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","slice", 3, argv[1] ));
}
arg3 = static_cast< std::vector< int >::difference_type >(val3);
{
try
{
try {
result = (VALUE)std_vector_Sl_int32_t_Sg__slice(arg1,arg2,arg3);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.each
call-seq:
each -> IntStdVector
Iterate thru each element in the IntStdVector. A block must be provided.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_each(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int,std::allocator< int > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","each", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (std::vector< int,std::allocator< int > > *)std_vector_Sl_int32_t_Sg__each(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.__delete2__
call-seq:
__delete2__(i) -> VALUE
An instance method.
*/
SWIGINTERN VALUE
_wrap_IntStdVector___delete2__(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::value_type *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int >::value_type temp2 ;
int val2 ;
int ecode2 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","__delete2__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::value_type","__delete2__", 2, argv[0] ));
}
temp2 = static_cast< std::vector< int >::value_type >(val2);
arg2 = &temp2;
{
try
{
result = (VALUE)std_vector_Sl_int32_t_Sg____delete2__(arg1,(int const &)*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.select
call-seq:
select -> IntStdVector
Iterate thru each element in the IntStdVector and select those that match a condition. A block must be provided.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_select(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int,std::allocator< int > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","select", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (std::vector< int,std::allocator< int > > *)std_vector_Sl_int32_t_Sg__select(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.delete_at
call-seq:
delete_at(i) -> VALUE
Delete an element at a certain index.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_delete_at(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::difference_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","delete_at", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","delete_at", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::difference_type >(val2);
{
try
{
result = (VALUE)std_vector_Sl_int32_t_Sg__delete_at(arg1,arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.at
call-seq:
at(i) -> VALUE
Return element at a certain index.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_at(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::difference_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","at", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","at", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::difference_type >(val2);
{
try
{
result = (VALUE)std_vector_Sl_int32_t_Sg__at((std::vector< int > const *)arg1,arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.[]
call-seq:
[](i, length) -> VALUE
[](i) -> VALUE
[](i) -> VALUE
Element accessor/slicing.
*/
SWIGINTERN VALUE
_wrap_IntStdVector___getitem____SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::difference_type arg2 ;
std::vector< int >::difference_type arg3 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
ptrdiff_t val3 ;
int ecode3 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","__getitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","__getitem__", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::difference_type >(val2);
ecode3 = SWIG_AsVal_ptrdiff_t(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","__getitem__", 3, argv[1] ));
}
arg3 = static_cast< std::vector< int >::difference_type >(val3);
{
try
{
try {
result = (VALUE)std_vector_Sl_int32_t_Sg____getitem____SWIG_0((std::vector< int > const *)arg1,arg2,arg3);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_IntStdVector___getitem____SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::difference_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","__getitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","__getitem__", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::difference_type >(val2);
{
try
{
result = (VALUE)std_vector_Sl_int32_t_Sg____getitem____SWIG_1((std::vector< int > const *)arg1,arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_IntStdVector___getitem____SWIG_2(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
VALUE arg2 = (VALUE) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","__getitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
arg2 = argv[0];
{
try
{
try {
result = (VALUE)std_vector_Sl_int32_t_Sg____getitem____SWIG_2((std::vector< int > const *)arg1,arg2);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_IntStdVector___getitem__(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[4];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 4) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_IntStdVector___getitem____SWIG_1(nargs, args, self);
}
}
}
if (argc == 2) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
_v = (argv[1] != 0);
if (_v) {
return _wrap_IntStdVector___getitem____SWIG_2(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_IntStdVector___getitem____SWIG_0(nargs, args, self);
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 4, "__getitem__",
" VALUE __getitem__(std::vector< int >::difference_type i, std::vector< int >::difference_type length)\n"
" VALUE __getitem__(std::vector< int >::difference_type i)\n"
" VALUE __getitem__(VALUE i)\n");
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.[]=
call-seq:
[]=(i, x) -> VALUE
[]=(i, length, v) -> VALUE
Element setter/slicing.
*/
SWIGINTERN VALUE
_wrap_IntStdVector___setitem____SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::difference_type arg2 ;
std::vector< int >::value_type *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
std::vector< int >::value_type temp3 ;
int val3 ;
int ecode3 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","__setitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","__setitem__", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::difference_type >(val2);
ecode3 = SWIG_AsVal_int(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< int >::value_type","__setitem__", 3, argv[1] ));
}
temp3 = static_cast< std::vector< int >::value_type >(val3);
arg3 = &temp3;
{
try
{
try {
result = (VALUE)std_vector_Sl_int32_t_Sg____setitem____SWIG_0(arg1,arg2,(int const &)*arg3);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
catch(std::out_of_range &_e) {
SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_IntStdVector___setitem____SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::difference_type arg2 ;
std::vector< int >::difference_type arg3 ;
std::vector< int,std::allocator< int > > *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
ptrdiff_t val3 ;
int ecode3 = 0 ;
int res4 = SWIG_OLDOBJ ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","__setitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","__setitem__", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::difference_type >(val2);
ecode3 = SWIG_AsVal_ptrdiff_t(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","__setitem__", 3, argv[1] ));
}
arg3 = static_cast< std::vector< int >::difference_type >(val3);
{
std::vector< int,std::allocator< int > > *ptr = (std::vector< int,std::allocator< int > > *)0;
res4 = swig::asptr(argv[2], &ptr);
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "std::vector< int,std::allocator< int > > const &","__setitem__", 4, argv[2] ));
}
if (!ptr) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "std::vector< int,std::allocator< int > > const &","__setitem__", 4, argv[2]));
}
arg4 = ptr;
}
{
try
{
try {
result = (VALUE)std_vector_Sl_int32_t_Sg____setitem____SWIG_1(arg1,arg2,arg3,(std::vector< int,std::allocator< int > > const &)*arg4);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
if (SWIG_IsNewObj(res4)) delete arg4;
return vresult;
fail:
if (SWIG_IsNewObj(res4)) delete arg4;
return Qnil;
}
SWIGINTERN VALUE _wrap_IntStdVector___setitem__(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[5];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 5) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_IntStdVector___setitem____SWIG_0(nargs, args, self);
}
}
}
}
if (argc == 4) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
int res = swig::asptr(argv[3], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_IntStdVector___setitem____SWIG_1(nargs, args, self);
}
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 5, "__setitem__",
" VALUE __setitem__(std::vector< int >::difference_type i, std::vector< int >::value_type const &x)\n"
" VALUE __setitem__(std::vector< int >::difference_type i, std::vector< int >::difference_type length, std::vector< int,std::allocator< int > > const &v)\n");
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.reject!
call-seq:
reject! -> IntStdVector
Iterate thru each element in the IntStdVector and reject those that fail a condition. A block must be provided. IntStdVector is modified in place.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_rejectN___(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int,std::allocator< int > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","reject_bang", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (std::vector< int,std::allocator< int > > *)std_vector_Sl_int32_t_Sg__reject_bang(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.pop
call-seq:
pop -> VALUE
Remove and return element at the end of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_pop(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","pop", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_int32_t_Sg__pop(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.push
call-seq:
push(e) -> std::vector< int >::value_type const
Add an element at the end of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_push(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::value_type *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int >::value_type temp2 ;
int val2 ;
int ecode2 = 0 ;
std::vector< int >::value_type result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","push", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::value_type","push", 2, argv[0] ));
}
temp2 = static_cast< std::vector< int >::value_type >(val2);
arg2 = &temp2;
{
try
{
result = (std::vector< int >::value_type)std_vector_Sl_int32_t_Sg__push(arg1,(int const &)*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.reject
call-seq:
reject -> IntStdVector
Iterate thru each element in the IntStdVector and reject those that fail a condition returning a new IntStdVector. A block must be provided.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_reject(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int,std::allocator< int > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","reject", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (std::vector< int,std::allocator< int > > *)std_vector_Sl_int32_t_Sg__reject(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.shift
call-seq:
shift -> VALUE
Remove and return element at the beginning of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_shift(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","shift", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_int32_t_Sg__shift(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.insert
call-seq:
insert(pos, argc) -> IntStdVector
insert(pos, x) -> std::vector< int >::iterator
insert(pos, n, x)
Insert one or more new elements in the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_insert__SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::difference_type arg2 ;
int arg3 ;
VALUE *arg4 = (VALUE *) 0 ;
void *arg5 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
std::vector< int,std::allocator< int > > *result = 0 ;
VALUE vresult = Qnil;
if (argc < 2) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","insert", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::difference_type","insert", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::difference_type >(val2);
{
arg3 = argc - 1;
arg4 = argv + 1;
}
{
try
{
result = (std::vector< int,std::allocator< int > > *)std_vector_Sl_int32_t_Sg__insert__SWIG_0(arg1,arg2,arg3,arg4,arg5);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.unshift
call-seq:
unshift(argc) -> IntStdVector
Add one or more elements at the beginning of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_unshift(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
int arg2 ;
VALUE *arg3 = (VALUE *) 0 ;
void *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int,std::allocator< int > > *result = 0 ;
VALUE vresult = Qnil;
if (argc < 1) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","unshift", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
arg2 = argc;
arg3 = argv;
}
{
try
{
result = (std::vector< int,std::allocator< int > > *)std_vector_Sl_int32_t_Sg__unshift(arg1,arg2,arg3,arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.new
call-seq:
IntStdVector.new
IntStdVector.new(arg2)
IntStdVector.new(size)
IntStdVector.new(size, value)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_IntStdVector__SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (std::vector< int32_t > *)new std::vector< int32_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_IntStdVector__SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = 0 ;
int res1 = SWIG_OLDOBJ ;
std::vector< int32_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
std::vector< int,std::allocator< int > > *ptr = (std::vector< int,std::allocator< int > > *)0;
res1 = swig::asptr(argv[0], &ptr);
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const &","vector<(int32_t)>", 1, argv[0] ));
}
if (!ptr) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "std::vector< int32_t > const &","vector<(int32_t)>", 1, argv[0]));
}
arg1 = ptr;
}
{
try
{
result = (std::vector< int32_t > *)new std::vector< int32_t >((std::vector< int32_t > const &)*arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (SWIG_IsNewObj(res1)) delete arg1;
return self;
fail:
if (SWIG_IsNewObj(res1)) delete arg1;
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.empty?
call-seq:
empty? -> bool
Check if the IntStdVector is empty or not.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_emptyq___(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","empty", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (bool)((std::vector< int32_t > const *)arg1)->empty();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.size
call-seq:
size -> std::vector< int >::size_type
Size or Length of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_size(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int >::size_type result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","size", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = ((std::vector< int32_t > const *)arg1)->size();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_size_t(static_cast< size_t >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.swap
call-seq:
swap(v)
An instance method.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_swap(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int32_t > *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","swap", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "std::vector< int32_t > &","swap", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "std::vector< int32_t > &","swap", 2, argv[0]));
}
arg2 = reinterpret_cast< std::vector< int32_t > * >(argp2);
{
try
{
(arg1)->swap(*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.begin
call-seq:
begin -> std::vector< int >::iterator
Return an iterator to the beginning of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_begin(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::vector< int >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","begin", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (arg1)->begin();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< int >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.end
call-seq:
end -> std::vector< int >::iterator
Return an iterator to past the end of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_end(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::vector< int >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","end", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (arg1)->end();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< int >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.rbegin
call-seq:
rbegin -> std::vector< int >::reverse_iterator
Return a reverse iterator to the beginning (the end) of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_rbegin(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::vector< int >::reverse_iterator > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","rbegin", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (arg1)->rbegin();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< int >::reverse_iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.rend
call-seq:
rend -> std::vector< int >::reverse_iterator
Return a reverse iterator to past the end (past the beginning) of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_rend(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::vector< int >::reverse_iterator > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","rend", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (arg1)->rend();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< int >::reverse_iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.clear
call-seq:
clear
Clear IntStdVector contents.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_clear(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","clear", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
(arg1)->clear();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.get_allocator
call-seq:
get_allocator -> std::vector< int >::allocator_type
An instance method.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_get_allocator(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::allocator< int > > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","get_allocator", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = ((std::vector< int32_t > const *)arg1)->get_allocator();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj((new std::vector< int >::allocator_type(static_cast< const std::vector< int >::allocator_type& >(result))), SWIGTYPE_p_std__allocatorT_int_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.new
call-seq:
IntStdVector.new
IntStdVector.new(arg2)
IntStdVector.new(size)
IntStdVector.new(size, value)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_IntStdVector__SWIG_2(int argc, VALUE *argv, VALUE self) {
std::vector< int >::size_type arg1 ;
size_t val1 ;
int ecode1 = 0 ;
std::vector< int32_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
ecode1 = SWIG_AsVal_size_t(argv[0], &val1);
if (!SWIG_IsOK(ecode1)) {
SWIG_exception_fail(SWIG_ArgError(ecode1), Ruby_Format_TypeError( "", "std::vector< int >::size_type","vector<(int32_t)>", 1, argv[0] ));
}
arg1 = static_cast< std::vector< int >::size_type >(val1);
{
try
{
result = (std::vector< int32_t > *)new std::vector< int32_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.resize
call-seq:
resize(new_size)
resize(new_size, x)
Resize the size of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_resize__SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::size_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","resize", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::size_type","resize", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::size_type >(val2);
{
try
{
(arg1)->resize(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.erase
call-seq:
erase(pos) -> std::vector< int >::iterator
erase(first, last) -> std::vector< int >::iterator
Delete a portion of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_erase__SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
SwigValueWrapper< std::vector< int >::iterator > arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *iter2 = 0 ;
int res2 ;
SwigValueWrapper< std::vector< int >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","erase", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], SWIG_as_voidptrptr(&iter2), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res2) || !iter2) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","erase", 2, argv[0] ));
} else {
swig::Iterator_T<std::vector< int >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter2);
if (iter_t) {
arg2 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","erase", 2, argv[0] ));
}
}
{
try
{
result = std_vector_Sl_int32_t_Sg__erase__SWIG_0(arg1,arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< int >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_IntStdVector_erase__SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
SwigValueWrapper< std::vector< int >::iterator > arg2 ;
SwigValueWrapper< std::vector< int >::iterator > arg3 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *iter2 = 0 ;
int res2 ;
swig::Iterator *iter3 = 0 ;
int res3 ;
SwigValueWrapper< std::vector< int >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","erase", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], SWIG_as_voidptrptr(&iter2), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res2) || !iter2) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","erase", 2, argv[0] ));
} else {
swig::Iterator_T<std::vector< int >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter2);
if (iter_t) {
arg2 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","erase", 2, argv[0] ));
}
}
res3 = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter3), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res3) || !iter3) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","erase", 3, argv[1] ));
} else {
swig::Iterator_T<std::vector< int >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter3);
if (iter_t) {
arg3 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","erase", 3, argv[1] ));
}
}
{
try
{
result = std_vector_Sl_int32_t_Sg__erase__SWIG_1(arg1,arg2,arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< int >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_IntStdVector_erase(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[4];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 4) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter) != 0));
if (_v) {
return _wrap_IntStdVector_erase__SWIG_0(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter) != 0));
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[2], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter) != 0));
if (_v) {
return _wrap_IntStdVector_erase__SWIG_1(nargs, args, self);
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 4, "erase",
" std::vector< int >::iterator erase(std::vector< int >::iterator pos)\n"
" std::vector< int >::iterator erase(std::vector< int >::iterator first, std::vector< int >::iterator last)\n");
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_IntStdVector_allocate(VALUE self)
#else
_wrap_IntStdVector_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
/*
Document-method: Modshogun::IntStdVector.new
call-seq:
IntStdVector.new
IntStdVector.new(arg2)
IntStdVector.new(size)
IntStdVector.new(size, value)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_IntStdVector__SWIG_3(int argc, VALUE *argv, VALUE self) {
std::vector< int >::size_type arg1 ;
std::vector< int >::value_type *arg2 = 0 ;
size_t val1 ;
int ecode1 = 0 ;
std::vector< int >::value_type temp2 ;
int val2 ;
int ecode2 = 0 ;
std::vector< int32_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
ecode1 = SWIG_AsVal_size_t(argv[0], &val1);
if (!SWIG_IsOK(ecode1)) {
SWIG_exception_fail(SWIG_ArgError(ecode1), Ruby_Format_TypeError( "", "std::vector< int >::size_type","vector<(int32_t)>", 1, argv[0] ));
}
arg1 = static_cast< std::vector< int >::size_type >(val1);
ecode2 = SWIG_AsVal_int(argv[1], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::value_type","vector<(int32_t)>", 2, argv[1] ));
}
temp2 = static_cast< std::vector< int >::value_type >(val2);
arg2 = &temp2;
{
try
{
result = (std::vector< int32_t > *)new std::vector< int32_t >(arg1,(std::vector< int >::value_type const &)*arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_IntStdVector(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_IntStdVector__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
{
int res = SWIG_AsVal_size_t(argv[0], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_new_IntStdVector__SWIG_2(nargs, args, self);
}
}
if (argc == 1) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_IntStdVector__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
{
int res = SWIG_AsVal_size_t(argv[0], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_new_IntStdVector__SWIG_3(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "IntStdVector.new",
" IntStdVector.new()\n"
" IntStdVector.new(std::vector< int32_t > const &)\n"
" IntStdVector.new(std::vector< int >::size_type size)\n"
" IntStdVector.new(std::vector< int >::size_type size, std::vector< int >::value_type const &value)\n");
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.front
call-seq:
front -> std::vector< int >::value_type const &
Return the first element in IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_front(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int >::value_type *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","front", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (std::vector< int >::value_type *) &((std::vector< int32_t > const *)arg1)->front();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(*result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.back
call-seq:
back -> std::vector< int >::value_type const &
Return the last element in IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_back(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int >::value_type *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","back", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = (std::vector< int >::value_type *) &((std::vector< int32_t > const *)arg1)->back();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(*result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.assign
call-seq:
assign(n, x)
Assign a new IntStdVector or portion of it.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_assign(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::size_type arg2 ;
std::vector< int >::value_type *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
std::vector< int >::value_type temp3 ;
int val3 ;
int ecode3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","assign", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::size_type","assign", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::size_type >(val2);
ecode3 = SWIG_AsVal_int(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< int >::value_type","assign", 3, argv[1] ));
}
temp3 = static_cast< std::vector< int >::value_type >(val3);
arg3 = &temp3;
{
try
{
(arg1)->assign(arg2,(std::vector< int >::value_type const &)*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.resize
call-seq:
resize(new_size)
resize(new_size, x)
Resize the size of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_resize__SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::size_type arg2 ;
std::vector< int >::value_type *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
std::vector< int >::value_type temp3 ;
int val3 ;
int ecode3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","resize", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::size_type","resize", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::size_type >(val2);
ecode3 = SWIG_AsVal_int(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< int >::value_type","resize", 3, argv[1] ));
}
temp3 = static_cast< std::vector< int >::value_type >(val3);
arg3 = &temp3;
{
try
{
(arg1)->resize(arg2,(std::vector< int >::value_type const &)*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_IntStdVector_resize(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[4];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 4) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_IntStdVector_resize__SWIG_0(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_IntStdVector_resize__SWIG_1(nargs, args, self);
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 4, "IntStdVector.resize",
" void IntStdVector.resize(std::vector< int >::size_type new_size)\n"
" void IntStdVector.resize(std::vector< int >::size_type new_size, std::vector< int >::value_type const &x)\n");
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.insert
call-seq:
insert(pos, argc) -> IntStdVector
insert(pos, x) -> std::vector< int >::iterator
insert(pos, n, x)
Insert one or more new elements in the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_insert__SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
SwigValueWrapper< std::vector< int >::iterator > arg2 ;
std::vector< int >::value_type *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *iter2 = 0 ;
int res2 ;
std::vector< int >::value_type temp3 ;
int val3 ;
int ecode3 = 0 ;
SwigValueWrapper< std::vector< int >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","insert", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], SWIG_as_voidptrptr(&iter2), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res2) || !iter2) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","insert", 2, argv[0] ));
} else {
swig::Iterator_T<std::vector< int >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter2);
if (iter_t) {
arg2 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","insert", 2, argv[0] ));
}
}
ecode3 = SWIG_AsVal_int(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< int >::value_type","insert", 3, argv[1] ));
}
temp3 = static_cast< std::vector< int >::value_type >(val3);
arg3 = &temp3;
{
try
{
result = std_vector_Sl_int32_t_Sg__insert__SWIG_1(arg1,arg2,(int const &)*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< int >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_IntStdVector_insert__SWIG_2(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
SwigValueWrapper< std::vector< int >::iterator > arg2 ;
std::vector< int >::size_type arg3 ;
std::vector< int >::value_type *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *iter2 = 0 ;
int res2 ;
size_t val3 ;
int ecode3 = 0 ;
std::vector< int >::value_type temp4 ;
int val4 ;
int ecode4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","insert", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], SWIG_as_voidptrptr(&iter2), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res2) || !iter2) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","insert", 2, argv[0] ));
} else {
swig::Iterator_T<std::vector< int >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter2);
if (iter_t) {
arg2 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< int >::iterator","insert", 2, argv[0] ));
}
}
ecode3 = SWIG_AsVal_size_t(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< int >::size_type","insert", 3, argv[1] ));
}
arg3 = static_cast< std::vector< int >::size_type >(val3);
ecode4 = SWIG_AsVal_int(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "std::vector< int >::value_type","insert", 4, argv[2] ));
}
temp4 = static_cast< std::vector< int >::value_type >(val4);
arg4 = &temp4;
{
try
{
std_vector_Sl_int32_t_Sg__insert__SWIG_2(arg1,arg2,arg3,(int const &)*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_IntStdVector_insert(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[5];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 5) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter) != 0));
if (_v) {
{
int res = SWIG_AsVal_int(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_IntStdVector_insert__SWIG_1(nargs, args, self);
}
}
}
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
if (argc <= 3) {
return _wrap_IntStdVector_insert__SWIG_0(nargs, args, self);
}
return _wrap_IntStdVector_insert__SWIG_0(nargs, args, self);
}
}
}
}
if (argc == 4) {
int _v;
int res = swig::asptr(argv[0], (std::vector< int,std::allocator< int > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< int >::iterator > *>(iter) != 0));
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_IntStdVector_insert__SWIG_2(nargs, args, self);
}
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 5, "insert",
" std::vector< int,std::allocator< int > > insert(std::vector< int >::difference_type pos, int argc, VALUE *argv, ...)\n"
" std::vector< int >::iterator insert(std::vector< int >::iterator pos, std::vector< int >::value_type const &x)\n"
" void insert(std::vector< int >::iterator pos, std::vector< int >::size_type n, std::vector< int >::value_type const &x)\n");
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.reserve
call-seq:
reserve(n)
Reserve memory in the IntStdVector for a number of elements.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_reserve(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
std::vector< int >::size_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > *","reserve", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< int >::size_type","reserve", 2, argv[0] ));
}
arg2 = static_cast< std::vector< int >::size_type >(val2);
{
try
{
(arg1)->reserve(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::IntStdVector.capacity
call-seq:
capacity -> std::vector< int >::size_type
Reserved capacity of the IntStdVector.
*/
SWIGINTERN VALUE
_wrap_IntStdVector_capacity(int argc, VALUE *argv, VALUE self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< int >::size_type result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< int32_t > const *","capacity", 1, self ));
}
arg1 = reinterpret_cast< std::vector< int32_t > * >(argp1);
{
try
{
result = ((std::vector< int32_t > const *)arg1)->capacity();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_size_t(static_cast< size_t >(result));
return vresult;
fail:
return Qnil;
}
SWIGINTERN void
free_std_vector_Sl_int32_t_Sg_(void *self) {
std::vector< int32_t > *arg1 = (std::vector< int32_t > *)self;
delete arg1;
}
/*
Document-class: Modshogun::DoubleStdVector
Proxy of C++ Modshogun::DoubleStdVector class
*/
static swig_class SwigClassDoubleStdVector;
/*
Document-method: Modshogun::DoubleStdVector.dup
call-seq:
dup -> DoubleStdVector
Create a duplicate of the class and unfreeze it if needed.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_dup(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double,std::allocator< double > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","dup", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (std::vector< double,std::allocator< double > > *)std_vector_Sl_float64_t_Sg__dup(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.inspect
call-seq:
inspect -> VALUE
Inspect class and its contents.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_inspect(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","inspect", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_float64_t_Sg__inspect(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.to_a
call-seq:
to_a -> VALUE
Convert DoubleStdVector to an Array.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_to_a(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","to_a", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_float64_t_Sg__to_a(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.to_s
call-seq:
to_s -> VALUE
Convert class to a String representation.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_to_s(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","to_s", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_float64_t_Sg__to_s(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.slice
call-seq:
slice(i, length) -> VALUE
Return a slice (portion of) the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_slice(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::difference_type arg2 ;
std::vector< double >::difference_type arg3 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
ptrdiff_t val3 ;
int ecode3 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","slice", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","slice", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::difference_type >(val2);
ecode3 = SWIG_AsVal_ptrdiff_t(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","slice", 3, argv[1] ));
}
arg3 = static_cast< std::vector< double >::difference_type >(val3);
{
try
{
try {
result = (VALUE)std_vector_Sl_float64_t_Sg__slice(arg1,arg2,arg3);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.each
call-seq:
each -> DoubleStdVector
Iterate thru each element in the DoubleStdVector. A block must be provided.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_each(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double,std::allocator< double > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","each", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (std::vector< double,std::allocator< double > > *)std_vector_Sl_float64_t_Sg__each(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.__delete2__
call-seq:
__delete2__(i) -> VALUE
An instance method.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector___delete2__(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::value_type *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double >::value_type temp2 ;
double val2 ;
int ecode2 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","__delete2__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::value_type","__delete2__", 2, argv[0] ));
}
temp2 = static_cast< std::vector< double >::value_type >(val2);
arg2 = &temp2;
{
try
{
result = (VALUE)std_vector_Sl_float64_t_Sg____delete2__(arg1,(double const &)*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.select
call-seq:
select -> DoubleStdVector
Iterate thru each element in the DoubleStdVector and select those that match a condition. A block must be provided.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_select(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double,std::allocator< double > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","select", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (std::vector< double,std::allocator< double > > *)std_vector_Sl_float64_t_Sg__select(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.delete_at
call-seq:
delete_at(i) -> VALUE
Delete an element at a certain index.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_delete_at(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::difference_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","delete_at", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","delete_at", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::difference_type >(val2);
{
try
{
result = (VALUE)std_vector_Sl_float64_t_Sg__delete_at(arg1,arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.at
call-seq:
at(i) -> VALUE
Return element at a certain index.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_at(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::difference_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","at", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","at", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::difference_type >(val2);
{
try
{
result = (VALUE)std_vector_Sl_float64_t_Sg__at((std::vector< double > const *)arg1,arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.[]
call-seq:
[](i, length) -> VALUE
[](i) -> VALUE
[](i) -> VALUE
Element accessor/slicing.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector___getitem____SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::difference_type arg2 ;
std::vector< double >::difference_type arg3 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
ptrdiff_t val3 ;
int ecode3 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","__getitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","__getitem__", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::difference_type >(val2);
ecode3 = SWIG_AsVal_ptrdiff_t(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","__getitem__", 3, argv[1] ));
}
arg3 = static_cast< std::vector< double >::difference_type >(val3);
{
try
{
try {
result = (VALUE)std_vector_Sl_float64_t_Sg____getitem____SWIG_0((std::vector< double > const *)arg1,arg2,arg3);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_DoubleStdVector___getitem____SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::difference_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","__getitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","__getitem__", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::difference_type >(val2);
{
try
{
result = (VALUE)std_vector_Sl_float64_t_Sg____getitem____SWIG_1((std::vector< double > const *)arg1,arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_DoubleStdVector___getitem____SWIG_2(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
VALUE arg2 = (VALUE) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","__getitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
arg2 = argv[0];
{
try
{
try {
result = (VALUE)std_vector_Sl_float64_t_Sg____getitem____SWIG_2((std::vector< double > const *)arg1,arg2);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_DoubleStdVector___getitem__(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[4];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 4) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_DoubleStdVector___getitem____SWIG_1(nargs, args, self);
}
}
}
if (argc == 2) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
_v = (argv[1] != 0);
if (_v) {
return _wrap_DoubleStdVector___getitem____SWIG_2(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_DoubleStdVector___getitem____SWIG_0(nargs, args, self);
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 4, "__getitem__",
" VALUE __getitem__(std::vector< double >::difference_type i, std::vector< double >::difference_type length)\n"
" VALUE __getitem__(std::vector< double >::difference_type i)\n"
" VALUE __getitem__(VALUE i)\n");
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.[]=
call-seq:
[]=(i, x) -> VALUE
[]=(i, length, v) -> VALUE
Element setter/slicing.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector___setitem____SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::difference_type arg2 ;
std::vector< double >::value_type *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
std::vector< double >::value_type temp3 ;
double val3 ;
int ecode3 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","__setitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","__setitem__", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::difference_type >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< double >::value_type","__setitem__", 3, argv[1] ));
}
temp3 = static_cast< std::vector< double >::value_type >(val3);
arg3 = &temp3;
{
try
{
try {
result = (VALUE)std_vector_Sl_float64_t_Sg____setitem____SWIG_0(arg1,arg2,(double const &)*arg3);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
catch(std::out_of_range &_e) {
SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_DoubleStdVector___setitem____SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::difference_type arg2 ;
std::vector< double >::difference_type arg3 ;
std::vector< double,std::allocator< double > > *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
ptrdiff_t val3 ;
int ecode3 = 0 ;
int res4 = SWIG_OLDOBJ ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","__setitem__", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","__setitem__", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::difference_type >(val2);
ecode3 = SWIG_AsVal_ptrdiff_t(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","__setitem__", 3, argv[1] ));
}
arg3 = static_cast< std::vector< double >::difference_type >(val3);
{
std::vector< double,std::allocator< double > > *ptr = (std::vector< double,std::allocator< double > > *)0;
res4 = swig::asptr(argv[2], &ptr);
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "std::vector< double,std::allocator< double > > const &","__setitem__", 4, argv[2] ));
}
if (!ptr) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "std::vector< double,std::allocator< double > > const &","__setitem__", 4, argv[2]));
}
arg4 = ptr;
}
{
try
{
try {
result = (VALUE)std_vector_Sl_float64_t_Sg____setitem____SWIG_1(arg1,arg2,arg3,(std::vector< double,std::allocator< double > > const &)*arg4);
}
catch(std::invalid_argument &_e) {
SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
}
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
if (SWIG_IsNewObj(res4)) delete arg4;
return vresult;
fail:
if (SWIG_IsNewObj(res4)) delete arg4;
return Qnil;
}
SWIGINTERN VALUE _wrap_DoubleStdVector___setitem__(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[5];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 5) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_DoubleStdVector___setitem____SWIG_0(nargs, args, self);
}
}
}
}
if (argc == 4) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
int res = swig::asptr(argv[3], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_DoubleStdVector___setitem____SWIG_1(nargs, args, self);
}
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 5, "__setitem__",
" VALUE __setitem__(std::vector< double >::difference_type i, std::vector< double >::value_type const &x)\n"
" VALUE __setitem__(std::vector< double >::difference_type i, std::vector< double >::difference_type length, std::vector< double,std::allocator< double > > const &v)\n");
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.reject!
call-seq:
reject! -> DoubleStdVector
Iterate thru each element in the DoubleStdVector and reject those that fail a condition. A block must be provided. DoubleStdVector is modified in place.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_rejectN___(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double,std::allocator< double > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","reject_bang", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (std::vector< double,std::allocator< double > > *)std_vector_Sl_float64_t_Sg__reject_bang(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.pop
call-seq:
pop -> VALUE
Remove and return element at the end of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_pop(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","pop", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_float64_t_Sg__pop(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.push
call-seq:
push(e) -> std::vector< double >::value_type const
Add an element at the end of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_push(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::value_type *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double >::value_type temp2 ;
double val2 ;
int ecode2 = 0 ;
std::vector< double >::value_type result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","push", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::value_type","push", 2, argv[0] ));
}
temp2 = static_cast< std::vector< double >::value_type >(val2);
arg2 = &temp2;
{
try
{
result = (std::vector< double >::value_type)std_vector_Sl_float64_t_Sg__push(arg1,(double const &)*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_double(static_cast< double >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.reject
call-seq:
reject -> DoubleStdVector
Iterate thru each element in the DoubleStdVector and reject those that fail a condition returning a new DoubleStdVector. A block must be provided.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_reject(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double,std::allocator< double > > *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","reject", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (std::vector< double,std::allocator< double > > *)std_vector_Sl_float64_t_Sg__reject(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.shift
call-seq:
shift -> VALUE
Remove and return element at the beginning of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_shift(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
VALUE result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","shift", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (VALUE)std_vector_Sl_float64_t_Sg__shift(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = result;
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.insert
call-seq:
insert(pos, argc) -> DoubleStdVector
insert(pos, x) -> std::vector< double >::iterator
insert(pos, n, x)
Insert one or more new elements in the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_insert__SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::difference_type arg2 ;
int arg3 ;
VALUE *arg4 = (VALUE *) 0 ;
void *arg5 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
ptrdiff_t val2 ;
int ecode2 = 0 ;
std::vector< double,std::allocator< double > > *result = 0 ;
VALUE vresult = Qnil;
if (argc < 2) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","insert", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_ptrdiff_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::difference_type","insert", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::difference_type >(val2);
{
arg3 = argc - 1;
arg4 = argv + 1;
}
{
try
{
result = (std::vector< double,std::allocator< double > > *)std_vector_Sl_float64_t_Sg__insert__SWIG_0(arg1,arg2,arg3,arg4,arg5);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.unshift
call-seq:
unshift(argc) -> DoubleStdVector
Add one or more elements at the beginning of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_unshift(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
int arg2 ;
VALUE *arg3 = (VALUE *) 0 ;
void *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double,std::allocator< double > > *result = 0 ;
VALUE vresult = Qnil;
if (argc < 1) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","unshift", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
arg2 = argc;
arg3 = argv;
}
{
try
{
result = (std::vector< double,std::allocator< double > > *)std_vector_Sl_float64_t_Sg__unshift(arg1,arg2,arg3,arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.new
call-seq:
DoubleStdVector.new
DoubleStdVector.new(arg2)
DoubleStdVector.new(size)
DoubleStdVector.new(size, value)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_DoubleStdVector__SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (std::vector< float64_t > *)new std::vector< float64_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_DoubleStdVector__SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = 0 ;
int res1 = SWIG_OLDOBJ ;
std::vector< float64_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
std::vector< double,std::allocator< double > > *ptr = (std::vector< double,std::allocator< double > > *)0;
res1 = swig::asptr(argv[0], &ptr);
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const &","vector<(float64_t)>", 1, argv[0] ));
}
if (!ptr) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "std::vector< float64_t > const &","vector<(float64_t)>", 1, argv[0]));
}
arg1 = ptr;
}
{
try
{
result = (std::vector< float64_t > *)new std::vector< float64_t >((std::vector< float64_t > const &)*arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (SWIG_IsNewObj(res1)) delete arg1;
return self;
fail:
if (SWIG_IsNewObj(res1)) delete arg1;
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.empty?
call-seq:
empty? -> bool
Check if the DoubleStdVector is empty or not.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_emptyq___(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","empty", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (bool)((std::vector< float64_t > const *)arg1)->empty();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.size
call-seq:
size -> std::vector< double >::size_type
Size or Length of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_size(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double >::size_type result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","size", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = ((std::vector< float64_t > const *)arg1)->size();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_size_t(static_cast< size_t >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.swap
call-seq:
swap(v)
An instance method.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_swap(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< float64_t > *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","swap", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "std::vector< float64_t > &","swap", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "std::vector< float64_t > &","swap", 2, argv[0]));
}
arg2 = reinterpret_cast< std::vector< float64_t > * >(argp2);
{
try
{
(arg1)->swap(*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.begin
call-seq:
begin -> std::vector< double >::iterator
Return an iterator to the beginning of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_begin(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::vector< double >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","begin", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (arg1)->begin();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< double >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.end
call-seq:
end -> std::vector< double >::iterator
Return an iterator to past the end of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_end(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::vector< double >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","end", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (arg1)->end();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< double >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.rbegin
call-seq:
rbegin -> std::vector< double >::reverse_iterator
Return a reverse iterator to the beginning (the end) of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_rbegin(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::vector< double >::reverse_iterator > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","rbegin", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (arg1)->rbegin();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< double >::reverse_iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.rend
call-seq:
rend -> std::vector< double >::reverse_iterator
Return a reverse iterator to past the end (past the beginning) of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_rend(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::vector< double >::reverse_iterator > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","rend", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (arg1)->rend();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< double >::reverse_iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.clear
call-seq:
clear
Clear DoubleStdVector contents.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_clear(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","clear", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
(arg1)->clear();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.get_allocator
call-seq:
get_allocator -> std::vector< double >::allocator_type
An instance method.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_get_allocator(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
SwigValueWrapper< std::allocator< double > > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","get_allocator", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = ((std::vector< float64_t > const *)arg1)->get_allocator();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj((new std::vector< double >::allocator_type(static_cast< const std::vector< double >::allocator_type& >(result))), SWIGTYPE_p_std__allocatorT_double_t, SWIG_POINTER_OWN | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.new
call-seq:
DoubleStdVector.new
DoubleStdVector.new(arg2)
DoubleStdVector.new(size)
DoubleStdVector.new(size, value)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_DoubleStdVector__SWIG_2(int argc, VALUE *argv, VALUE self) {
std::vector< double >::size_type arg1 ;
size_t val1 ;
int ecode1 = 0 ;
std::vector< float64_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
ecode1 = SWIG_AsVal_size_t(argv[0], &val1);
if (!SWIG_IsOK(ecode1)) {
SWIG_exception_fail(SWIG_ArgError(ecode1), Ruby_Format_TypeError( "", "std::vector< double >::size_type","vector<(float64_t)>", 1, argv[0] ));
}
arg1 = static_cast< std::vector< double >::size_type >(val1);
{
try
{
result = (std::vector< float64_t > *)new std::vector< float64_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.resize
call-seq:
resize(new_size)
resize(new_size, x)
Resize the size of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_resize__SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::size_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","resize", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::size_type","resize", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::size_type >(val2);
{
try
{
(arg1)->resize(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.erase
call-seq:
erase(pos) -> std::vector< double >::iterator
erase(first, last) -> std::vector< double >::iterator
Delete a portion of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_erase__SWIG_0(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
SwigValueWrapper< std::vector< double >::iterator > arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *iter2 = 0 ;
int res2 ;
SwigValueWrapper< std::vector< double >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","erase", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], SWIG_as_voidptrptr(&iter2), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res2) || !iter2) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","erase", 2, argv[0] ));
} else {
swig::Iterator_T<std::vector< double >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter2);
if (iter_t) {
arg2 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","erase", 2, argv[0] ));
}
}
{
try
{
result = std_vector_Sl_float64_t_Sg__erase__SWIG_0(arg1,arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< double >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_DoubleStdVector_erase__SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
SwigValueWrapper< std::vector< double >::iterator > arg2 ;
SwigValueWrapper< std::vector< double >::iterator > arg3 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *iter2 = 0 ;
int res2 ;
swig::Iterator *iter3 = 0 ;
int res3 ;
SwigValueWrapper< std::vector< double >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","erase", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], SWIG_as_voidptrptr(&iter2), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res2) || !iter2) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","erase", 2, argv[0] ));
} else {
swig::Iterator_T<std::vector< double >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter2);
if (iter_t) {
arg2 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","erase", 2, argv[0] ));
}
}
res3 = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter3), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res3) || !iter3) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","erase", 3, argv[1] ));
} else {
swig::Iterator_T<std::vector< double >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter3);
if (iter_t) {
arg3 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","erase", 3, argv[1] ));
}
}
{
try
{
result = std_vector_Sl_float64_t_Sg__erase__SWIG_1(arg1,arg2,arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< double >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_DoubleStdVector_erase(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[4];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 4) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter) != 0));
if (_v) {
return _wrap_DoubleStdVector_erase__SWIG_0(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter) != 0));
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[2], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter) != 0));
if (_v) {
return _wrap_DoubleStdVector_erase__SWIG_1(nargs, args, self);
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 4, "erase",
" std::vector< double >::iterator erase(std::vector< double >::iterator pos)\n"
" std::vector< double >::iterator erase(std::vector< double >::iterator first, std::vector< double >::iterator last)\n");
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_DoubleStdVector_allocate(VALUE self)
#else
_wrap_DoubleStdVector_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
/*
Document-method: Modshogun::DoubleStdVector.new
call-seq:
DoubleStdVector.new
DoubleStdVector.new(arg2)
DoubleStdVector.new(size)
DoubleStdVector.new(size, value)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_DoubleStdVector__SWIG_3(int argc, VALUE *argv, VALUE self) {
std::vector< double >::size_type arg1 ;
std::vector< double >::value_type *arg2 = 0 ;
size_t val1 ;
int ecode1 = 0 ;
std::vector< double >::value_type temp2 ;
double val2 ;
int ecode2 = 0 ;
std::vector< float64_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
ecode1 = SWIG_AsVal_size_t(argv[0], &val1);
if (!SWIG_IsOK(ecode1)) {
SWIG_exception_fail(SWIG_ArgError(ecode1), Ruby_Format_TypeError( "", "std::vector< double >::size_type","vector<(float64_t)>", 1, argv[0] ));
}
arg1 = static_cast< std::vector< double >::size_type >(val1);
ecode2 = SWIG_AsVal_double(argv[1], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::value_type","vector<(float64_t)>", 2, argv[1] ));
}
temp2 = static_cast< std::vector< double >::value_type >(val2);
arg2 = &temp2;
{
try
{
result = (std::vector< float64_t > *)new std::vector< float64_t >(arg1,(std::vector< double >::value_type const &)*arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_DoubleStdVector(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_DoubleStdVector__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
{
int res = SWIG_AsVal_size_t(argv[0], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_new_DoubleStdVector__SWIG_2(nargs, args, self);
}
}
if (argc == 1) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_DoubleStdVector__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
{
int res = SWIG_AsVal_size_t(argv[0], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_new_DoubleStdVector__SWIG_3(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "DoubleStdVector.new",
" DoubleStdVector.new()\n"
" DoubleStdVector.new(std::vector< float64_t > const &)\n"
" DoubleStdVector.new(std::vector< double >::size_type size)\n"
" DoubleStdVector.new(std::vector< double >::size_type size, std::vector< double >::value_type const &value)\n");
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.front
call-seq:
front -> std::vector< double >::value_type const &
Return the first element in DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_front(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double >::value_type *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","front", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (std::vector< double >::value_type *) &((std::vector< float64_t > const *)arg1)->front();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_double(static_cast< double >(*result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.back
call-seq:
back -> std::vector< double >::value_type const &
Return the last element in DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_back(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double >::value_type *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","back", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = (std::vector< double >::value_type *) &((std::vector< float64_t > const *)arg1)->back();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_double(static_cast< double >(*result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.assign
call-seq:
assign(n, x)
Assign a new DoubleStdVector or portion of it.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_assign(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::size_type arg2 ;
std::vector< double >::value_type *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
std::vector< double >::value_type temp3 ;
double val3 ;
int ecode3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","assign", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::size_type","assign", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::size_type >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< double >::value_type","assign", 3, argv[1] ));
}
temp3 = static_cast< std::vector< double >::value_type >(val3);
arg3 = &temp3;
{
try
{
(arg1)->assign(arg2,(std::vector< double >::value_type const &)*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.resize
call-seq:
resize(new_size)
resize(new_size, x)
Resize the size of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_resize__SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::size_type arg2 ;
std::vector< double >::value_type *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
std::vector< double >::value_type temp3 ;
double val3 ;
int ecode3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","resize", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::size_type","resize", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::size_type >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< double >::value_type","resize", 3, argv[1] ));
}
temp3 = static_cast< std::vector< double >::value_type >(val3);
arg3 = &temp3;
{
try
{
(arg1)->resize(arg2,(std::vector< double >::value_type const &)*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_DoubleStdVector_resize(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[4];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 4) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_DoubleStdVector_resize__SWIG_0(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_DoubleStdVector_resize__SWIG_1(nargs, args, self);
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 4, "DoubleStdVector.resize",
" void DoubleStdVector.resize(std::vector< double >::size_type new_size)\n"
" void DoubleStdVector.resize(std::vector< double >::size_type new_size, std::vector< double >::value_type const &x)\n");
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.insert
call-seq:
insert(pos, argc) -> DoubleStdVector
insert(pos, x) -> std::vector< double >::iterator
insert(pos, n, x)
Insert one or more new elements in the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_insert__SWIG_1(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
SwigValueWrapper< std::vector< double >::iterator > arg2 ;
std::vector< double >::value_type *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *iter2 = 0 ;
int res2 ;
std::vector< double >::value_type temp3 ;
double val3 ;
int ecode3 = 0 ;
SwigValueWrapper< std::vector< double >::iterator > result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","insert", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], SWIG_as_voidptrptr(&iter2), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res2) || !iter2) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","insert", 2, argv[0] ));
} else {
swig::Iterator_T<std::vector< double >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter2);
if (iter_t) {
arg2 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","insert", 2, argv[0] ));
}
}
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< double >::value_type","insert", 3, argv[1] ));
}
temp3 = static_cast< std::vector< double >::value_type >(val3);
arg3 = &temp3;
{
try
{
result = std_vector_Sl_float64_t_Sg__insert__SWIG_1(arg1,arg2,(double const &)*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(swig::make_nonconst_iterator(static_cast< const std::vector< double >::iterator & >(result),
self),
swig::Iterator::descriptor(),SWIG_POINTER_OWN);
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_DoubleStdVector_insert__SWIG_2(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
SwigValueWrapper< std::vector< double >::iterator > arg2 ;
std::vector< double >::size_type arg3 ;
std::vector< double >::value_type *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
swig::Iterator *iter2 = 0 ;
int res2 ;
size_t val3 ;
int ecode3 = 0 ;
std::vector< double >::value_type temp4 ;
double val4 ;
int ecode4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","insert", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], SWIG_as_voidptrptr(&iter2), swig::Iterator::descriptor(), 0);
if (!SWIG_IsOK(res2) || !iter2) {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","insert", 2, argv[0] ));
} else {
swig::Iterator_T<std::vector< double >::iterator > *iter_t = dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter2);
if (iter_t) {
arg2 = iter_t->get_current();
} else {
SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), Ruby_Format_TypeError( "", "std::vector< double >::iterator","insert", 2, argv[0] ));
}
}
ecode3 = SWIG_AsVal_size_t(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "std::vector< double >::size_type","insert", 3, argv[1] ));
}
arg3 = static_cast< std::vector< double >::size_type >(val3);
ecode4 = SWIG_AsVal_double(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "std::vector< double >::value_type","insert", 4, argv[2] ));
}
temp4 = static_cast< std::vector< double >::value_type >(val4);
arg4 = &temp4;
{
try
{
std_vector_Sl_float64_t_Sg__insert__SWIG_2(arg1,arg2,arg3,(double const &)*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_DoubleStdVector_insert(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[5];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 5) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter) != 0));
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_DoubleStdVector_insert__SWIG_1(nargs, args, self);
}
}
}
}
if (argc == 3) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
if (argc <= 3) {
return _wrap_DoubleStdVector_insert__SWIG_0(nargs, args, self);
}
return _wrap_DoubleStdVector_insert__SWIG_0(nargs, args, self);
}
}
}
}
if (argc == 4) {
int _v;
int res = swig::asptr(argv[0], (std::vector< double,std::allocator< double > >**)(0));
_v = SWIG_CheckState(res);
if (_v) {
swig::ConstIterator *iter = 0;
int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter),
swig::Iterator::descriptor(), 0);
_v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::Iterator_T<std::vector< double >::iterator > *>(iter) != 0));
if (_v) {
{
int res = SWIG_AsVal_size_t(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_DoubleStdVector_insert__SWIG_2(nargs, args, self);
}
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 5, "insert",
" std::vector< double,std::allocator< double > > insert(std::vector< double >::difference_type pos, int argc, VALUE *argv, ...)\n"
" std::vector< double >::iterator insert(std::vector< double >::iterator pos, std::vector< double >::value_type const &x)\n"
" void insert(std::vector< double >::iterator pos, std::vector< double >::size_type n, std::vector< double >::value_type const &x)\n");
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.reserve
call-seq:
reserve(n)
Reserve memory in the DoubleStdVector for a number of elements.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_reserve(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
std::vector< double >::size_type arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
size_t val2 ;
int ecode2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > *","reserve", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
ecode2 = SWIG_AsVal_size_t(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "std::vector< double >::size_type","reserve", 2, argv[0] ));
}
arg2 = static_cast< std::vector< double >::size_type >(val2);
{
try
{
(arg1)->reserve(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::DoubleStdVector.capacity
call-seq:
capacity -> std::vector< double >::size_type
Reserved capacity of the DoubleStdVector.
*/
SWIGINTERN VALUE
_wrap_DoubleStdVector_capacity(int argc, VALUE *argv, VALUE self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
std::vector< double >::size_type result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "std::vector< float64_t > const *","capacity", 1, self ));
}
arg1 = reinterpret_cast< std::vector< float64_t > * >(argp1);
{
try
{
result = ((std::vector< float64_t > const *)arg1)->capacity();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_size_t(static_cast< size_t >(result));
return vresult;
fail:
return Qnil;
}
SWIGINTERN void
free_std_vector_Sl_float64_t_Sg_(void *self) {
std::vector< float64_t > *arg1 = (std::vector< float64_t > *)self;
delete arg1;
}
/*
Document-method: Modshogun::shogun.init_shogun
call-seq:
init_shogun(print_message=nil, print_warning=nil, print_error=nil, cancel_computations=nil)
init_shogun(print_message=nil, print_warning=nil, print_error=nil)
init_shogun(print_message=nil, print_warning=nil)
init_shogun(print_message=nil)
init_shogun
A module function.
*/
SWIGINTERN VALUE
_wrap_init_shogun__SWIG_0(int argc, VALUE *argv, VALUE self) {
void (*arg1)(FILE *,char const *) = (void (*)(FILE *,char const *)) 0 ;
void (*arg2)(FILE *,char const *) = (void (*)(FILE *,char const *)) 0 ;
void (*arg3)(FILE *,char const *) = (void (*)(FILE *,char const *)) 0 ;
void (*arg4)(bool &,bool &) = (void (*)(bool &,bool &)) 0 ;
if ((argc < 4) || (argc > 4)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 4)",argc); SWIG_fail;
}
{
int res = SWIG_ConvertFunctionPtr(argv[0], (void**)(&arg1), SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(FILE *,char const *)","shogun::init_shogun", 1, argv[0] ));
}
}
{
int res = SWIG_ConvertFunctionPtr(argv[1], (void**)(&arg2), SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(FILE *,char const *)","shogun::init_shogun", 2, argv[1] ));
}
}
{
int res = SWIG_ConvertFunctionPtr(argv[2], (void**)(&arg3), SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(FILE *,char const *)","shogun::init_shogun", 3, argv[2] ));
}
}
{
int res = SWIG_ConvertFunctionPtr(argv[3], (void**)(&arg4), SWIGTYPE_p_f_r_bool_r_bool__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(bool &,bool &)","shogun::init_shogun", 4, argv[3] ));
}
}
{
try
{
shogun::init_shogun(arg1,arg2,arg3,arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_init_shogun__SWIG_1(int argc, VALUE *argv, VALUE self) {
void (*arg1)(FILE *,char const *) = (void (*)(FILE *,char const *)) 0 ;
void (*arg2)(FILE *,char const *) = (void (*)(FILE *,char const *)) 0 ;
void (*arg3)(FILE *,char const *) = (void (*)(FILE *,char const *)) 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
{
int res = SWIG_ConvertFunctionPtr(argv[0], (void**)(&arg1), SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(FILE *,char const *)","shogun::init_shogun", 1, argv[0] ));
}
}
{
int res = SWIG_ConvertFunctionPtr(argv[1], (void**)(&arg2), SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(FILE *,char const *)","shogun::init_shogun", 2, argv[1] ));
}
}
{
int res = SWIG_ConvertFunctionPtr(argv[2], (void**)(&arg3), SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(FILE *,char const *)","shogun::init_shogun", 3, argv[2] ));
}
}
{
try
{
shogun::init_shogun(arg1,arg2,arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_init_shogun__SWIG_2(int argc, VALUE *argv, VALUE self) {
void (*arg1)(FILE *,char const *) = (void (*)(FILE *,char const *)) 0 ;
void (*arg2)(FILE *,char const *) = (void (*)(FILE *,char const *)) 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
{
int res = SWIG_ConvertFunctionPtr(argv[0], (void**)(&arg1), SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(FILE *,char const *)","shogun::init_shogun", 1, argv[0] ));
}
}
{
int res = SWIG_ConvertFunctionPtr(argv[1], (void**)(&arg2), SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(FILE *,char const *)","shogun::init_shogun", 2, argv[1] ));
}
}
{
try
{
shogun::init_shogun(arg1,arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_init_shogun__SWIG_3(int argc, VALUE *argv, VALUE self) {
void (*arg1)(FILE *,char const *) = (void (*)(FILE *,char const *)) 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
int res = SWIG_ConvertFunctionPtr(argv[0], (void**)(&arg1), SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), Ruby_Format_TypeError( "", "void (*)(FILE *,char const *)","shogun::init_shogun", 1, argv[0] ));
}
}
{
try
{
shogun::init_shogun(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_init_shogun__SWIG_4(int argc, VALUE *argv, VALUE self) {
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
shogun::init_shogun();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_init_shogun(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[4];
int ii;
argc = nargs;
if (argc > 4) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_init_shogun__SWIG_4(nargs, args, self);
}
if (argc == 1) {
int _v;
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[0], &ptr, SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_init_shogun__SWIG_3(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[0], &ptr, SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
_v = SWIG_CheckState(res);
if (_v) {
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[1], &ptr, SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_init_shogun__SWIG_2(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[0], &ptr, SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
_v = SWIG_CheckState(res);
if (_v) {
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[1], &ptr, SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
_v = SWIG_CheckState(res);
if (_v) {
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[2], &ptr, SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_init_shogun__SWIG_1(nargs, args, self);
}
}
}
}
if (argc == 4) {
int _v;
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[0], &ptr, SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
_v = SWIG_CheckState(res);
if (_v) {
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[1], &ptr, SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
_v = SWIG_CheckState(res);
if (_v) {
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[2], &ptr, SWIGTYPE_p_f_p_FILE_p_q_const__char__void);
_v = SWIG_CheckState(res);
if (_v) {
void *ptr = 0;
int res = SWIG_ConvertFunctionPtr(argv[3], &ptr, SWIGTYPE_p_f_r_bool_r_bool__void);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_init_shogun__SWIG_0(nargs, args, self);
}
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 4, "init_shogun",
" void init_shogun(void (*print_message)(FILE *,char const *), void (*print_warning)(FILE *,char const *), void (*print_error)(FILE *,char const *), void (*cancel_computations)(bool &,bool &))\n"
" void init_shogun(void (*print_message)(FILE *,char const *), void (*print_warning)(FILE *,char const *), void (*print_error)(FILE *,char const *))\n"
" void init_shogun(void (*print_message)(FILE *,char const *), void (*print_warning)(FILE *,char const *))\n"
" void init_shogun(void (*print_message)(FILE *,char const *))\n"
" void init_shogun()\n");
return Qnil;
}
/*
Document-method: Modshogun::shogun.init_shogun_with_defaults
call-seq:
init_shogun_with_defaults
A module function.
*/
SWIGINTERN VALUE
_wrap_init_shogun_with_defaults(int argc, VALUE *argv, VALUE self) {
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
shogun::init_shogun_with_defaults();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.exit_shogun
call-seq:
exit_shogun
A module function.
*/
SWIGINTERN VALUE
_wrap_exit_shogun(int argc, VALUE *argv, VALUE self) {
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
shogun::exit_shogun();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.set_global_io
call-seq:
set_global_io(io)
A module function.
*/
SWIGINTERN VALUE
_wrap_set_global_io(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","shogun::set_global_io", 1, argv[0] ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
shogun::set_global_io(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.get_global_io
call-seq:
get_global_io -> SGIO
A module function.
*/
SWIGINTERN VALUE
_wrap_get_global_io(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::SGIO *)shogun::get_global_io();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__SGIO, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.set_global_parallel
call-seq:
set_global_parallel(parallel)
A module function.
*/
SWIGINTERN VALUE
_wrap_set_global_parallel(int argc, VALUE *argv, VALUE self) {
shogun::Parallel *arg1 = (shogun::Parallel *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_shogun__Parallel, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::Parallel *","shogun::set_global_parallel", 1, argv[0] ));
}
arg1 = reinterpret_cast< shogun::Parallel * >(argp1);
{
try
{
shogun::set_global_parallel(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.get_global_parallel
call-seq:
get_global_parallel -> Parallel
A module function.
*/
SWIGINTERN VALUE
_wrap_get_global_parallel(int argc, VALUE *argv, VALUE self) {
shogun::Parallel *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::Parallel *)shogun::get_global_parallel();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__Parallel, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.set_global_version
call-seq:
set_global_version(version)
A module function.
*/
SWIGINTERN VALUE
_wrap_set_global_version(int argc, VALUE *argv, VALUE self) {
shogun::Version *arg1 = (shogun::Version *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_shogun__Version, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::Version *","shogun::set_global_version", 1, argv[0] ));
}
arg1 = reinterpret_cast< shogun::Version * >(argp1);
{
try
{
shogun::set_global_version(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.get_global_version
call-seq:
get_global_version -> Version
A module function.
*/
SWIGINTERN VALUE
_wrap_get_global_version(int argc, VALUE *argv, VALUE self) {
shogun::Version *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::Version *)shogun::get_global_version();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__Version, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.set_global_math
call-seq:
set_global_math(math)
A module function.
*/
SWIGINTERN VALUE
_wrap_set_global_math(int argc, VALUE *argv, VALUE self) {
shogun::CMath *arg1 = (shogun::CMath *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_shogun__CMath, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CMath *","shogun::set_global_math", 1, argv[0] ));
}
arg1 = reinterpret_cast< shogun::CMath * >(argp1);
{
try
{
shogun::set_global_math(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.get_global_math
call-seq:
get_global_math -> Math
A module function.
*/
SWIGINTERN VALUE
_wrap_get_global_math(int argc, VALUE *argv, VALUE self) {
shogun::CMath *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CMath *)shogun::get_global_math();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__CMath, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.set_global_rand
call-seq:
set_global_rand(rand)
A module function.
*/
SWIGINTERN VALUE
_wrap_set_global_rand(int argc, VALUE *argv, VALUE self) {
shogun::CRandom *arg1 = (shogun::CRandom *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_shogun__CRandom, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CRandom *","shogun::set_global_rand", 1, argv[0] ));
}
arg1 = reinterpret_cast< shogun::CRandom * >(argp1);
{
try
{
shogun::set_global_rand(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.get_global_rand
call-seq:
get_global_rand -> shogun::CRandom *
A module function.
*/
SWIGINTERN VALUE
_wrap_get_global_rand(int argc, VALUE *argv, VALUE self) {
shogun::CRandom *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CRandom *)shogun::get_global_rand();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__CRandom, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.init_from_env
call-seq:
init_from_env
A module function.
*/
SWIGINTERN VALUE
_wrap_init_from_env(int argc, VALUE *argv, VALUE self) {
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
shogun::init_from_env();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::SGObject
Proxy of C++ Modshogun::SGObject class
*/
static swig_class SwigClassSGObject;
SWIGINTERN void
free_shogun_CSGObject(void *self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::SGObject.ref_count
call-seq:
ref_count -> int32_t
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_ref_count(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","ref_count", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (int32_t)(arg1)->ref_count();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.shallow_copy
call-seq:
shallow_copy -> SGObject
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_shallow_copy(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CSGObject *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject const *","shallow_copy", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (shogun::CSGObject *)((shogun::CSGObject const *)arg1)->shallow_copy();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.deep_copy
call-seq:
deep_copy -> SGObject
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_deep_copy(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CSGObject *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject const *","deep_copy", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (shogun::CSGObject *)((shogun::CSGObject const *)arg1)->deep_copy();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.get_name
call-seq:
get_name -> char const *
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_get_name(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
char *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject const *","get_name", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (char *)((shogun::CSGObject const *)arg1)->get_name();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_FromCharPtr((const char *)result);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.is_generic
call-seq:
is_generic(generic) -> bool
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_is_generic(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
EPrimitiveType *arg2 = (EPrimitiveType *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject const *","is_generic", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_EPrimitiveType, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "EPrimitiveType *","is_generic", 2, argv[0] ));
}
arg2 = reinterpret_cast< EPrimitiveType * >(argp2);
{
try
{
result = (bool)((shogun::CSGObject const *)arg1)->is_generic(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.unset_generic
call-seq:
unset_generic
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_unset_generic(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","unset_generic", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
(arg1)->unset_generic();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.print_serializable
call-seq:
print_serializable(prefix="")
print_serializable
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_print_serializable__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
char *arg2 = (char *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","print_serializable", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_AsCharPtrAndSize(argv[0], &buf2, NULL, &alloc2);
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","print_serializable", 2, argv[0] ));
}
arg2 = reinterpret_cast< char * >(buf2);
{
try
{
(arg1)->print_serializable((char const *)arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
return Qnil;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_print_serializable__SWIG_1(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","print_serializable", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
(arg1)->print_serializable();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_SGObject_print_serializable(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[3];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 3) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_SGObject_print_serializable__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
int res = SWIG_AsCharPtrAndSize(argv[1], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_SGObject_print_serializable__SWIG_0(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 3, "SGObject.print_serializable",
" void SGObject.print_serializable(char const *prefix)\n"
" void SGObject.print_serializable()\n");
return Qnil;
}
/*
Document-method: Modshogun::SGObject.save_serializable
call-seq:
save_serializable(file, prefix="") -> bool
save_serializable(file) -> bool
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_save_serializable__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::CSerializableFile *arg2 = (shogun::CSerializableFile *) 0 ;
char *arg3 = (char *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
int res3 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","save_serializable", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__CSerializableFile, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::CSerializableFile *","save_serializable", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::CSerializableFile * >(argp2);
res3 = SWIG_AsCharPtrAndSize(argv[1], &buf3, NULL, &alloc3);
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "char const *","save_serializable", 3, argv[1] ));
}
arg3 = reinterpret_cast< char * >(buf3);
{
try
{
result = (bool)(arg1)->save_serializable(arg2,(char const *)arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return vresult;
fail:
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_save_serializable__SWIG_1(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::CSerializableFile *arg2 = (shogun::CSerializableFile *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","save_serializable", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__CSerializableFile, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::CSerializableFile *","save_serializable", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::CSerializableFile * >(argp2);
{
try
{
result = (bool)(arg1)->save_serializable(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_SGObject_save_serializable(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[4];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 4) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_shogun__CSerializableFile, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_SGObject_save_serializable__SWIG_1(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_shogun__CSerializableFile, 0);
_v = SWIG_CheckState(res);
if (_v) {
int res = SWIG_AsCharPtrAndSize(argv[2], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_SGObject_save_serializable__SWIG_0(nargs, args, self);
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 4, "SGObject.save_serializable",
" bool SGObject.save_serializable(shogun::CSerializableFile *file, char const *prefix)\n"
" bool SGObject.save_serializable(shogun::CSerializableFile *file)\n");
return Qnil;
}
/*
Document-method: Modshogun::SGObject.load_serializable
call-seq:
load_serializable(file, prefix="") -> bool
load_serializable(file) -> bool
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_load_serializable__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::CSerializableFile *arg2 = (shogun::CSerializableFile *) 0 ;
char *arg3 = (char *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
int res3 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","load_serializable", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__CSerializableFile, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::CSerializableFile *","load_serializable", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::CSerializableFile * >(argp2);
res3 = SWIG_AsCharPtrAndSize(argv[1], &buf3, NULL, &alloc3);
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "char const *","load_serializable", 3, argv[1] ));
}
arg3 = reinterpret_cast< char * >(buf3);
{
try
{
result = (bool)(arg1)->load_serializable(arg2,(char const *)arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return vresult;
fail:
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_load_serializable__SWIG_1(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::CSerializableFile *arg2 = (shogun::CSerializableFile *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","load_serializable", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__CSerializableFile, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::CSerializableFile *","load_serializable", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::CSerializableFile * >(argp2);
{
try
{
result = (bool)(arg1)->load_serializable(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_SGObject_load_serializable(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[4];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 4) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_shogun__CSerializableFile, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_SGObject_load_serializable__SWIG_1(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_shogun__CSerializableFile, 0);
_v = SWIG_CheckState(res);
if (_v) {
int res = SWIG_AsCharPtrAndSize(argv[2], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_SGObject_load_serializable__SWIG_0(nargs, args, self);
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 4, "SGObject.load_serializable",
" bool SGObject.load_serializable(shogun::CSerializableFile *file, char const *prefix)\n"
" bool SGObject.load_serializable(shogun::CSerializableFile *file)\n");
return Qnil;
}
/*
Document-method: Modshogun::SGObject.set_global_io
call-seq:
set_global_io(io)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_set_global_io(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::SGIO *arg2 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","set_global_io", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGIO *","set_global_io", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::SGIO * >(argp2);
{
try
{
(arg1)->set_global_io(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.get_global_io
call-seq:
get_global_io -> SGIO
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_get_global_io(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::SGIO *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","get_global_io", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (shogun::SGIO *)(arg1)->get_global_io();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__SGIO, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.set_global_parallel
call-seq:
set_global_parallel(parallel)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_set_global_parallel(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::Parallel *arg2 = (shogun::Parallel *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","set_global_parallel", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__Parallel, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::Parallel *","set_global_parallel", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::Parallel * >(argp2);
{
try
{
(arg1)->set_global_parallel(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.get_global_parallel
call-seq:
get_global_parallel -> Parallel
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_get_global_parallel(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::Parallel *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","get_global_parallel", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (shogun::Parallel *)(arg1)->get_global_parallel();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__Parallel, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.set_global_version
call-seq:
set_global_version(version)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_set_global_version(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::Version *arg2 = (shogun::Version *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","set_global_version", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__Version, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::Version *","set_global_version", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::Version * >(argp2);
{
try
{
(arg1)->set_global_version(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.get_global_version
call-seq:
get_global_version -> Version
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_get_global_version(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::Version *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","get_global_version", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (shogun::Version *)(arg1)->get_global_version();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__Version, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.get_modelsel_names
call-seq:
get_modelsel_names -> CharStringList
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_get_modelsel_names(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::SGStringList< char > result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","get_modelsel_names", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (arg1)->get_modelsel_names();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
{
shogun::SGString<char>* str = (&result)->strings;
int32_t i, j, num = (&result)->num_strings;
VALUE arr;
arr = rb_ary_new2(num);
for (i = 0; i < num; i++) {
if (strcmp("String[]", "String[]")==0) {
VALUE vec = rb_str_new2((char *)str[i].string);
rb_ary_push(arr, vec);
}
else {
char* data = SG_MALLOC(char, str[i].slen);
memcpy(data, str[i].string, str[i].slen * sizeof(char));
VALUE vec = rb_ary_new2(str[i].slen);
for (j = 0; j < str[i].slen; j++) {
rb_ary_push(vec, CHR2FIX(data[j]));
}
rb_ary_push(arr, vec);
}
}
vresult = arr;
}
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.print_modsel_params
call-seq:
print_modsel_params
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_print_modsel_params(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","print_modsel_params", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
(arg1)->print_modsel_params();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.get_modsel_param_descr
call-seq:
get_modsel_param_descr(param_name) -> char *
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_get_modsel_param_descr(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
char *arg2 = (char *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
char *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","get_modsel_param_descr", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_AsCharPtrAndSize(argv[0], &buf2, NULL, &alloc2);
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","get_modsel_param_descr", 2, argv[0] ));
}
arg2 = reinterpret_cast< char * >(buf2);
{
try
{
result = (char *)(arg1)->get_modsel_param_descr((char const *)arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_FromCharPtr((const char *)result);
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
return vresult;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
return Qnil;
}
/*
Document-method: Modshogun::SGObject.get_modsel_param_index
call-seq:
get_modsel_param_index(param_name) -> index_t
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_get_modsel_param_index(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
char *arg2 = (char *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
index_t result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","get_modsel_param_index", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_AsCharPtrAndSize(argv[0], &buf2, NULL, &alloc2);
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","get_modsel_param_index", 2, argv[0] ));
}
arg2 = reinterpret_cast< char * >(buf2);
{
try
{
result = (index_t)(arg1)->get_modsel_param_index((char const *)arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
return vresult;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
return Qnil;
}
/*
Document-method: Modshogun::SGObject.build_gradient_parameter_dictionary
call-seq:
build_gradient_parameter_dictionary(dict)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_build_gradient_parameter_dictionary(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::CMap< shogun::TParameter *,shogun::CSGObject * > *arg2 = (shogun::CMap< shogun::TParameter *,shogun::CSGObject * > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","build_gradient_parameter_dictionary", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__CMapT_shogun__TParameter_p_shogun__CSGObject_p_t, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::CMap< shogun::TParameter *,shogun::CSGObject * > *","build_gradient_parameter_dictionary", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::CMap< shogun::TParameter *,shogun::CSGObject * > * >(argp2);
{
try
{
(arg1)->build_gradient_parameter_dictionary(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.has
call-seq:
has(name) -> bool
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_has(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
std::string *arg2 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 ;
int res2 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject const *","has", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_std__string, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "std::string const &","has", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "std::string const &","has", 2, argv[0]));
}
arg2 = reinterpret_cast< std::string * >(argp2);
{
try
{
result = (bool)((shogun::CSGObject const *)arg1)->has((std::string const &)*arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.update_parameter_hash
call-seq:
update_parameter_hash
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_update_parameter_hash(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","update_parameter_hash", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
(arg1)->update_parameter_hash();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.parameter_hash_changed
call-seq:
parameter_hash_changed -> bool
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_parameter_hash_changed(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","parameter_hash_changed", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (bool)(arg1)->parameter_hash_changed();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.equals
call-seq:
equals(other, accuracy=0.0, tolerant=False) -> bool
equals(other, accuracy=0.0) -> bool
equals(other) -> bool
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGObject_equals__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::CSGObject *arg2 = (shogun::CSGObject *) 0 ;
float64_t arg3 ;
bool arg4 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
double val3 ;
int ecode3 = 0 ;
bool val4 ;
int ecode4 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","equals", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::CSGObject *","equals", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::CSGObject * >(argp2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","equals", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
ecode4 = SWIG_AsVal_bool(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "bool","equals", 4, argv[2] ));
}
arg4 = static_cast< bool >(val4);
{
try
{
result = (bool)(arg1)->equals(arg2,arg3,arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_equals__SWIG_1(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::CSGObject *arg2 = (shogun::CSGObject *) 0 ;
float64_t arg3 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
double val3 ;
int ecode3 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","equals", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::CSGObject *","equals", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::CSGObject * >(argp2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","equals", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
{
try
{
result = (bool)(arg1)->equals(arg2,arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_equals__SWIG_2(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::CSGObject *arg2 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","equals", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::CSGObject *","equals", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::CSGObject * >(argp2);
{
try
{
result = (bool)(arg1)->equals(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_SGObject_equals(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[5];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 5) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_SGObject_equals__SWIG_2(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGObject_equals__SWIG_1(nargs, args, self);
}
}
}
}
if (argc == 4) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_shogun__CSGObject, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_bool(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGObject_equals__SWIG_0(nargs, args, self);
}
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 5, "SGObject.equals",
" bool SGObject.equals(shogun::CSGObject *other, float64_t accuracy, bool tolerant)\n"
" bool SGObject.equals(shogun::CSGObject *other, float64_t accuracy)\n"
" bool SGObject.equals(shogun::CSGObject *other)\n");
return Qnil;
}
/*
Document-method: Modshogun::SGObject.clone
call-seq:
clone -> SGObject
Create a duplicate of the class.
*/
SWIGINTERN VALUE
_wrap_SGObject_clone(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CSGObject *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","clone", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
{
try
{
result = (shogun::CSGObject *)(arg1)->clone();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.io
call-seq:
io -> SGIO
Get value of attribute.
*/
/*
Document-method: Modshogun::SGObject.io=
call-seq:
io=(x) -> SGIO
Set new value for attribute.
*/
SWIGINTERN VALUE
_wrap_SGObject_io_set(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::SGIO *arg2 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","io", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__SGIO, SWIG_POINTER_DISOWN | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGIO *","io", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::SGIO * >(argp2);
if (arg1) (arg1)->io = arg2;
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_io_get(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::SGIO *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","io", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
result = (shogun::SGIO *) ((arg1)->io);
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__SGIO, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.parallel
call-seq:
parallel -> Parallel
Get value of attribute.
*/
/*
Document-method: Modshogun::SGObject.parallel=
call-seq:
parallel=(x) -> Parallel
Set new value for attribute.
*/
SWIGINTERN VALUE
_wrap_SGObject_parallel_set(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::Parallel *arg2 = (shogun::Parallel *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","parallel", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__Parallel, SWIG_POINTER_DISOWN | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::Parallel *","parallel", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::Parallel * >(argp2);
if (arg1) (arg1)->parallel = arg2;
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_parallel_get(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::Parallel *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","parallel", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
result = (shogun::Parallel *) ((arg1)->parallel);
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__Parallel, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.version
call-seq:
version -> Version
Get value of attribute.
*/
/*
Document-method: Modshogun::SGObject.version=
call-seq:
version=(x) -> Version
Set new value for attribute.
*/
SWIGINTERN VALUE
_wrap_SGObject_version_set(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::Version *arg2 = (shogun::Version *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","version", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__Version, SWIG_POINTER_DISOWN | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::Version *","version", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::Version * >(argp2);
if (arg1) (arg1)->version = arg2;
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_version_get(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::Version *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","version", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
result = (shogun::Version *) ((arg1)->version);
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__Version, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.m_parameters
call-seq:
m_parameters -> shogun::Parameter *
Get value of attribute.
*/
/*
Document-method: Modshogun::SGObject.m_parameters=
call-seq:
m_parameters=(x) -> shogun::Parameter *
Set new value for attribute.
*/
SWIGINTERN VALUE
_wrap_SGObject_m_parameters_set(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::Parameter *arg2 = (shogun::Parameter *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","m_parameters", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__Parameter, SWIG_POINTER_DISOWN | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::Parameter *","m_parameters", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::Parameter * >(argp2);
if (arg1) (arg1)->m_parameters = arg2;
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_m_parameters_get(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::Parameter *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","m_parameters", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
result = (shogun::Parameter *) ((arg1)->m_parameters);
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__Parameter, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.m_model_selection_parameters
call-seq:
m_model_selection_parameters -> shogun::Parameter *
Get value of attribute.
*/
/*
Document-method: Modshogun::SGObject.m_model_selection_parameters=
call-seq:
m_model_selection_parameters=(x) -> shogun::Parameter *
Set new value for attribute.
*/
SWIGINTERN VALUE
_wrap_SGObject_m_model_selection_parameters_set(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::Parameter *arg2 = (shogun::Parameter *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","m_model_selection_parameters", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__Parameter, SWIG_POINTER_DISOWN | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::Parameter *","m_model_selection_parameters", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::Parameter * >(argp2);
if (arg1) (arg1)->m_model_selection_parameters = arg2;
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_m_model_selection_parameters_get(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::Parameter *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","m_model_selection_parameters", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
result = (shogun::Parameter *) ((arg1)->m_model_selection_parameters);
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__Parameter, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.m_gradient_parameters
call-seq:
m_gradient_parameters -> shogun::Parameter *
Get value of attribute.
*/
/*
Document-method: Modshogun::SGObject.m_gradient_parameters=
call-seq:
m_gradient_parameters=(x) -> shogun::Parameter *
Set new value for attribute.
*/
SWIGINTERN VALUE
_wrap_SGObject_m_gradient_parameters_set(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
shogun::Parameter *arg2 = (shogun::Parameter *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","m_gradient_parameters", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__Parameter, SWIG_POINTER_DISOWN | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::Parameter *","m_gradient_parameters", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::Parameter * >(argp2);
if (arg1) (arg1)->m_gradient_parameters = arg2;
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_m_gradient_parameters_get(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::Parameter *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","m_gradient_parameters", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
result = (shogun::Parameter *) ((arg1)->m_gradient_parameters);
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_shogun__Parameter, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGObject.m_hash
call-seq:
m_hash -> uint32_t
Get value of attribute.
*/
/*
Document-method: Modshogun::SGObject.m_hash=
call-seq:
m_hash=(x) -> uint32_t
Set new value for attribute.
*/
SWIGINTERN VALUE
_wrap_SGObject_m_hash_set(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
uint32_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
unsigned int val2 ;
int ecode2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","m_hash", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
ecode2 = SWIG_AsVal_unsigned_SS_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "uint32_t","m_hash", 2, argv[0] ));
}
arg2 = static_cast< uint32_t >(val2);
if (arg1) (arg1)->m_hash = arg2;
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGObject_m_hash_get(int argc, VALUE *argv, VALUE self) {
shogun::CSGObject *arg1 = (shogun::CSGObject *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
uint32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CSGObject, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CSGObject *","m_hash", 1, self ));
}
arg1 = reinterpret_cast< shogun::CSGObject * >(argp1);
result = (uint32_t) ((arg1)->m_hash);
vresult = SWIG_From_unsigned_SS_int(static_cast< unsigned int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::shogun.sg_io
call-seq:
sg_io -> SGIO
Get value of attribute.
*/
SWIGINTERN VALUE
_wrap_sg_io_get(VALUE self) {
VALUE _val;
_val = SWIG_NewPointerObj(SWIG_as_voidptr(shogun::sg_io), SWIGTYPE_p_shogun__SGIO, 0 );
return _val;
}
/*
Document-method: Modshogun::shogun.sg_io=
call-seq:
sg_io=(x) -> SGIO
Set new value for attribute.
*/
SWIGINTERN VALUE
_wrap_sg_io_set(VALUE self, VALUE _val) {
{
void *argp = 0;
int res = SWIG_ConvertPtr(_val, &argp, SWIGTYPE_p_shogun__SGIO, 0 );
if (!SWIG_IsOK(res)) {
SWIG_exception_fail(SWIG_ArgError(res), "in variable '""shogun::sg_io""' of type '""shogun::SGIO *""'");
}
shogun::sg_io = reinterpret_cast< shogun::SGIO * >(argp);
}
return _val;
fail:
return Qnil;
}
/*
Document-class: Modshogun::SGIO
Proxy of C++ Modshogun::SGIO class
*/
static swig_class SwigClassSGIO;
/*
Document-method: Modshogun::SGIO.new
call-seq:
SGIO.new
SGIO.new(orig)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_SGIO__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::SGIO *)new shogun::SGIO();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_SGIO_allocate(VALUE self)
#else
_wrap_SGIO_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__SGIO);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_SGIO__SWIG_1(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = 0 ;
void *argp1 ;
int res1 = 0 ;
shogun::SGIO *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_shogun__SGIO, 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const &","SGIO", 1, argv[0] ));
}
if (!argp1) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGIO const &","SGIO", 1, argv[0]));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
result = (shogun::SGIO *)new shogun::SGIO((shogun::SGIO const &)*arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_SGIO(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[1];
int ii;
argc = nargs;
if (argc > 1) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_SGIO__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_SGIO__SWIG_1(nargs, args, self);
}
}
fail:
Ruby_Format_OverloadedError( argc, 1, "SGIO.new",
" SGIO.new()\n"
" SGIO.new(shogun::SGIO const &orig)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_SGIO(void *self) {
shogun::SGIO *arg1 = (shogun::SGIO *)self;
delete arg1;
}
/*
Document-method: Modshogun::SGIO.set_loglevel
call-seq:
set_loglevel(level)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_set_loglevel(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
shogun::EMessageType arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","set_loglevel", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "shogun::EMessageType","set_loglevel", 2, argv[0] ));
}
arg2 = static_cast< shogun::EMessageType >(val2);
{
try
{
(arg1)->set_loglevel(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.get_loglevel
call-seq:
get_loglevel -> int
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_get_loglevel(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::EMessageType result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","get_loglevel", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
result = (shogun::EMessageType)((shogun::SGIO const *)arg1)->get_loglevel();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.loglevel_above
call-seq:
loglevel_above(type) -> bool
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_loglevel_above(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
shogun::EMessageType arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","loglevel_above", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "shogun::EMessageType","loglevel_above", 2, argv[0] ));
}
arg2 = static_cast< shogun::EMessageType >(val2);
{
try
{
result = (bool)((shogun::SGIO const *)arg1)->loglevel_above(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.get_show_progress
call-seq:
get_show_progress -> bool
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_get_show_progress(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","get_show_progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
result = (bool)((shogun::SGIO const *)arg1)->get_show_progress();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.get_location_info
call-seq:
get_location_info -> int
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_get_location_info(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::EMessageLocation result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","get_location_info", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
result = (shogun::EMessageLocation)((shogun::SGIO const *)arg1)->get_location_info();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.get_syntax_highlight
call-seq:
get_syntax_highlight -> bool
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_get_syntax_highlight(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
bool result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","get_syntax_highlight", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
result = (bool)((shogun::SGIO const *)arg1)->get_syntax_highlight();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_bool(static_cast< bool >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.message
call-seq:
message(prio, function, file, line, fmt)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_message(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
shogun::EMessageType arg2 ;
char *arg3 = (char *) 0 ;
char *arg4 = (char *) 0 ;
int32_t arg5 ;
char *arg6 = (char *) 0 ;
void *arg7 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
int res3 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int res4 ;
char *buf4 = 0 ;
int alloc4 = 0 ;
int val5 ;
int ecode5 = 0 ;
int res6 ;
char *buf6 = 0 ;
int alloc6 = 0 ;
if (argc < 5) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 5)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","message", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "shogun::EMessageType","message", 2, argv[0] ));
}
arg2 = static_cast< shogun::EMessageType >(val2);
res3 = SWIG_AsCharPtrAndSize(argv[1], &buf3, NULL, &alloc3);
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "char const *","message", 3, argv[1] ));
}
arg3 = reinterpret_cast< char * >(buf3);
res4 = SWIG_AsCharPtrAndSize(argv[2], &buf4, NULL, &alloc4);
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "char const *","message", 4, argv[2] ));
}
arg4 = reinterpret_cast< char * >(buf4);
ecode5 = SWIG_AsVal_int(argv[3], &val5);
if (!SWIG_IsOK(ecode5)) {
SWIG_exception_fail(SWIG_ArgError(ecode5), Ruby_Format_TypeError( "", "int32_t","message", 5, argv[3] ));
}
arg5 = static_cast< int32_t >(val5);
res6 = SWIG_AsCharPtrAndSize(argv[4], &buf6, NULL, &alloc6);
if (!SWIG_IsOK(res6)) {
SWIG_exception_fail(SWIG_ArgError(res6), Ruby_Format_TypeError( "", "char const *","message", 6, argv[4] ));
}
arg6 = reinterpret_cast< char * >(buf6);
{
try
{
((shogun::SGIO const *)arg1)->message(arg2,(char const *)arg3,(char const *)arg4,arg5,(char const *)arg6,arg7);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
if (alloc6 == SWIG_NEWOBJ) delete[] buf6;
return Qnil;
fail:
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
if (alloc4 == SWIG_NEWOBJ) delete[] buf4;
if (alloc6 == SWIG_NEWOBJ) delete[] buf6;
return Qnil;
}
/*
Document-method: Modshogun::SGIO.progress
call-seq:
progress(current_val, min_val=0.0, max_val=1.0, decimals=1, prefix="PROGRESS:\t")
progress(current_val, min_val=0.0, max_val=1.0, decimals=1)
progress(current_val, min_val=0.0, max_val=1.0)
progress(current_val, min_val=0.0)
progress(current_val)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_progress__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
float64_t arg3 ;
float64_t arg4 ;
int32_t arg5 ;
char *arg6 = (char *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
double val3 ;
int ecode3 = 0 ;
double val4 ;
int ecode4 = 0 ;
int val5 ;
int ecode5 = 0 ;
int res6 ;
char *buf6 = 0 ;
int alloc6 = 0 ;
if ((argc < 5) || (argc > 5)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 5)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","progress", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
ecode4 = SWIG_AsVal_double(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "float64_t","progress", 4, argv[2] ));
}
arg4 = static_cast< float64_t >(val4);
ecode5 = SWIG_AsVal_int(argv[3], &val5);
if (!SWIG_IsOK(ecode5)) {
SWIG_exception_fail(SWIG_ArgError(ecode5), Ruby_Format_TypeError( "", "int32_t","progress", 5, argv[3] ));
}
arg5 = static_cast< int32_t >(val5);
res6 = SWIG_AsCharPtrAndSize(argv[4], &buf6, NULL, &alloc6);
if (!SWIG_IsOK(res6)) {
SWIG_exception_fail(SWIG_ArgError(res6), Ruby_Format_TypeError( "", "char const *","progress", 6, argv[4] ));
}
arg6 = reinterpret_cast< char * >(buf6);
{
try
{
(arg1)->progress(arg2,arg3,arg4,arg5,(char const *)arg6);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc6 == SWIG_NEWOBJ) delete[] buf6;
return Qnil;
fail:
if (alloc6 == SWIG_NEWOBJ) delete[] buf6;
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGIO_progress__SWIG_1(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
float64_t arg3 ;
float64_t arg4 ;
int32_t arg5 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
double val3 ;
int ecode3 = 0 ;
double val4 ;
int ecode4 = 0 ;
int val5 ;
int ecode5 = 0 ;
if ((argc < 4) || (argc > 4)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 4)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","progress", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
ecode4 = SWIG_AsVal_double(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "float64_t","progress", 4, argv[2] ));
}
arg4 = static_cast< float64_t >(val4);
ecode5 = SWIG_AsVal_int(argv[3], &val5);
if (!SWIG_IsOK(ecode5)) {
SWIG_exception_fail(SWIG_ArgError(ecode5), Ruby_Format_TypeError( "", "int32_t","progress", 5, argv[3] ));
}
arg5 = static_cast< int32_t >(val5);
{
try
{
(arg1)->progress(arg2,arg3,arg4,arg5);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGIO_progress__SWIG_2(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
float64_t arg3 ;
float64_t arg4 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
double val3 ;
int ecode3 = 0 ;
double val4 ;
int ecode4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","progress", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
ecode4 = SWIG_AsVal_double(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "float64_t","progress", 4, argv[2] ));
}
arg4 = static_cast< float64_t >(val4);
{
try
{
(arg1)->progress(arg2,arg3,arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGIO_progress__SWIG_3(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
float64_t arg3 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
double val3 ;
int ecode3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","progress", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
{
try
{
(arg1)->progress(arg2,arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGIO_progress__SWIG_4(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
{
try
{
(arg1)->progress(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_SGIO_progress(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[7];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 7) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGIO_progress__SWIG_4(nargs, args, self);
}
}
}
if (argc == 3) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGIO_progress__SWIG_3(nargs, args, self);
}
}
}
}
if (argc == 4) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGIO_progress__SWIG_2(nargs, args, self);
}
}
}
}
}
if (argc == 5) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[4], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGIO_progress__SWIG_1(nargs, args, self);
}
}
}
}
}
}
if (argc == 6) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[4], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
int res = SWIG_AsCharPtrAndSize(argv[5], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_SGIO_progress__SWIG_0(nargs, args, self);
}
}
}
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 7, "SGIO.progress",
" void SGIO.progress(float64_t current_val, float64_t min_val, float64_t max_val, int32_t decimals, char const *prefix)\n"
" void SGIO.progress(float64_t current_val, float64_t min_val, float64_t max_val, int32_t decimals)\n"
" void SGIO.progress(float64_t current_val, float64_t min_val, float64_t max_val)\n"
" void SGIO.progress(float64_t current_val, float64_t min_val)\n"
" void SGIO.progress(float64_t current_val)\n");
return Qnil;
}
/*
Document-method: Modshogun::SGIO.absolute_progress
call-seq:
absolute_progress(current_val, val, min_val=0.0, max_val=1.0, decimals=1, prefix="PROGRESS:\t")
absolute_progress(current_val, val, min_val=0.0, max_val=1.0, decimals=1)
absolute_progress(current_val, val, min_val=0.0, max_val=1.0)
absolute_progress(current_val, val, min_val=0.0)
absolute_progress(current_val, val)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_absolute_progress__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
float64_t arg3 ;
float64_t arg4 ;
float64_t arg5 ;
int32_t arg6 ;
char *arg7 = (char *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
double val3 ;
int ecode3 = 0 ;
double val4 ;
int ecode4 = 0 ;
double val5 ;
int ecode5 = 0 ;
int val6 ;
int ecode6 = 0 ;
int res7 ;
char *buf7 = 0 ;
int alloc7 = 0 ;
if ((argc < 6) || (argc > 6)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 6)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","absolute_progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
ecode4 = SWIG_AsVal_double(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 4, argv[2] ));
}
arg4 = static_cast< float64_t >(val4);
ecode5 = SWIG_AsVal_double(argv[3], &val5);
if (!SWIG_IsOK(ecode5)) {
SWIG_exception_fail(SWIG_ArgError(ecode5), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 5, argv[3] ));
}
arg5 = static_cast< float64_t >(val5);
ecode6 = SWIG_AsVal_int(argv[4], &val6);
if (!SWIG_IsOK(ecode6)) {
SWIG_exception_fail(SWIG_ArgError(ecode6), Ruby_Format_TypeError( "", "int32_t","absolute_progress", 6, argv[4] ));
}
arg6 = static_cast< int32_t >(val6);
res7 = SWIG_AsCharPtrAndSize(argv[5], &buf7, NULL, &alloc7);
if (!SWIG_IsOK(res7)) {
SWIG_exception_fail(SWIG_ArgError(res7), Ruby_Format_TypeError( "", "char const *","absolute_progress", 7, argv[5] ));
}
arg7 = reinterpret_cast< char * >(buf7);
{
try
{
(arg1)->absolute_progress(arg2,arg3,arg4,arg5,arg6,(char const *)arg7);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc7 == SWIG_NEWOBJ) delete[] buf7;
return Qnil;
fail:
if (alloc7 == SWIG_NEWOBJ) delete[] buf7;
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGIO_absolute_progress__SWIG_1(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
float64_t arg3 ;
float64_t arg4 ;
float64_t arg5 ;
int32_t arg6 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
double val3 ;
int ecode3 = 0 ;
double val4 ;
int ecode4 = 0 ;
double val5 ;
int ecode5 = 0 ;
int val6 ;
int ecode6 = 0 ;
if ((argc < 5) || (argc > 5)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 5)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","absolute_progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
ecode4 = SWIG_AsVal_double(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 4, argv[2] ));
}
arg4 = static_cast< float64_t >(val4);
ecode5 = SWIG_AsVal_double(argv[3], &val5);
if (!SWIG_IsOK(ecode5)) {
SWIG_exception_fail(SWIG_ArgError(ecode5), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 5, argv[3] ));
}
arg5 = static_cast< float64_t >(val5);
ecode6 = SWIG_AsVal_int(argv[4], &val6);
if (!SWIG_IsOK(ecode6)) {
SWIG_exception_fail(SWIG_ArgError(ecode6), Ruby_Format_TypeError( "", "int32_t","absolute_progress", 6, argv[4] ));
}
arg6 = static_cast< int32_t >(val6);
{
try
{
(arg1)->absolute_progress(arg2,arg3,arg4,arg5,arg6);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGIO_absolute_progress__SWIG_2(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
float64_t arg3 ;
float64_t arg4 ;
float64_t arg5 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
double val3 ;
int ecode3 = 0 ;
double val4 ;
int ecode4 = 0 ;
double val5 ;
int ecode5 = 0 ;
if ((argc < 4) || (argc > 4)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 4)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","absolute_progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
ecode4 = SWIG_AsVal_double(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 4, argv[2] ));
}
arg4 = static_cast< float64_t >(val4);
ecode5 = SWIG_AsVal_double(argv[3], &val5);
if (!SWIG_IsOK(ecode5)) {
SWIG_exception_fail(SWIG_ArgError(ecode5), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 5, argv[3] ));
}
arg5 = static_cast< float64_t >(val5);
{
try
{
(arg1)->absolute_progress(arg2,arg3,arg4,arg5);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGIO_absolute_progress__SWIG_3(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
float64_t arg3 ;
float64_t arg4 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
double val3 ;
int ecode3 = 0 ;
double val4 ;
int ecode4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","absolute_progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
ecode4 = SWIG_AsVal_double(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 4, argv[2] ));
}
arg4 = static_cast< float64_t >(val4);
{
try
{
(arg1)->absolute_progress(arg2,arg3,arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_SGIO_absolute_progress__SWIG_4(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
float64_t arg2 ;
float64_t arg3 ;
void *argp1 = 0 ;
int res1 = 0 ;
double val2 ;
int ecode2 = 0 ;
double val3 ;
int ecode3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","absolute_progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_double(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 2, argv[0] ));
}
arg2 = static_cast< float64_t >(val2);
ecode3 = SWIG_AsVal_double(argv[1], &val3);
if (!SWIG_IsOK(ecode3)) {
SWIG_exception_fail(SWIG_ArgError(ecode3), Ruby_Format_TypeError( "", "float64_t","absolute_progress", 3, argv[1] ));
}
arg3 = static_cast< float64_t >(val3);
{
try
{
(arg1)->absolute_progress(arg2,arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_SGIO_absolute_progress(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[8];
int ii;
argc = nargs + 1;
argv[0] = self;
if (argc > 8) SWIG_fail;
for (ii = 1; (ii < argc); ++ii) {
argv[ii] = args[ii-1];
}
if (argc == 3) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGIO_absolute_progress__SWIG_4(nargs, args, self);
}
}
}
}
if (argc == 4) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGIO_absolute_progress__SWIG_3(nargs, args, self);
}
}
}
}
}
if (argc == 5) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[4], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGIO_absolute_progress__SWIG_2(nargs, args, self);
}
}
}
}
}
}
if (argc == 6) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[4], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[5], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_SGIO_absolute_progress__SWIG_1(nargs, args, self);
}
}
}
}
}
}
}
if (argc == 7) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__SGIO, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_double(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[2], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[3], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_double(argv[4], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
{
int res = SWIG_AsVal_int(argv[5], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
int res = SWIG_AsCharPtrAndSize(argv[6], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_SGIO_absolute_progress__SWIG_0(nargs, args, self);
}
}
}
}
}
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 8, "SGIO.absolute_progress",
" void SGIO.absolute_progress(float64_t current_val, float64_t val, float64_t min_val, float64_t max_val, int32_t decimals, char const *prefix)\n"
" void SGIO.absolute_progress(float64_t current_val, float64_t val, float64_t min_val, float64_t max_val, int32_t decimals)\n"
" void SGIO.absolute_progress(float64_t current_val, float64_t val, float64_t min_val, float64_t max_val)\n"
" void SGIO.absolute_progress(float64_t current_val, float64_t val, float64_t min_val)\n"
" void SGIO.absolute_progress(float64_t current_val, float64_t val)\n");
return Qnil;
}
/*
Document-method: Modshogun::SGIO.done
call-seq:
done
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_done(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","done", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
(arg1)->done();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.not_implemented
call-seq:
not_implemented(function, file, line)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_not_implemented(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
int32_t arg4 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int res3 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int val4 ;
int ecode4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","not_implemented", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
res2 = SWIG_AsCharPtrAndSize(argv[0], &buf2, NULL, &alloc2);
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","not_implemented", 2, argv[0] ));
}
arg2 = reinterpret_cast< char * >(buf2);
res3 = SWIG_AsCharPtrAndSize(argv[1], &buf3, NULL, &alloc3);
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "char const *","not_implemented", 3, argv[1] ));
}
arg3 = reinterpret_cast< char * >(buf3);
ecode4 = SWIG_AsVal_int(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "int32_t","not_implemented", 4, argv[2] ));
}
arg4 = static_cast< int32_t >(val4);
{
try
{
((shogun::SGIO const *)arg1)->not_implemented((char const *)arg2,(char const *)arg3,arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return Qnil;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return Qnil;
}
/*
Document-method: Modshogun::SGIO.deprecated
call-seq:
deprecated(function, file, line)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_deprecated(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
char *arg2 = (char *) 0 ;
char *arg3 = (char *) 0 ;
int32_t arg4 ;
void *argp1 = 0 ;
int res1 = 0 ;
int res2 ;
char *buf2 = 0 ;
int alloc2 = 0 ;
int res3 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
int val4 ;
int ecode4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","deprecated", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
res2 = SWIG_AsCharPtrAndSize(argv[0], &buf2, NULL, &alloc2);
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char const *","deprecated", 2, argv[0] ));
}
arg2 = reinterpret_cast< char * >(buf2);
res3 = SWIG_AsCharPtrAndSize(argv[1], &buf3, NULL, &alloc3);
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "char const *","deprecated", 3, argv[1] ));
}
arg3 = reinterpret_cast< char * >(buf3);
ecode4 = SWIG_AsVal_int(argv[2], &val4);
if (!SWIG_IsOK(ecode4)) {
SWIG_exception_fail(SWIG_ArgError(ecode4), Ruby_Format_TypeError( "", "int32_t","deprecated", 4, argv[2] ));
}
arg4 = static_cast< int32_t >(val4);
{
try
{
((shogun::SGIO const *)arg1)->deprecated((char const *)arg2,(char const *)arg3,arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return Qnil;
fail:
if (alloc2 == SWIG_NEWOBJ) delete[] buf2;
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return Qnil;
}
/*
Document-method: Modshogun::SGIO.buffered_message
call-seq:
buffered_message(prio, fmt)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_buffered_message(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
shogun::EMessageType arg2 ;
char *arg3 = (char *) 0 ;
void *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
int res3 ;
char *buf3 = 0 ;
int alloc3 = 0 ;
if (argc < 2) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","buffered_message", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "shogun::EMessageType","buffered_message", 2, argv[0] ));
}
arg2 = static_cast< shogun::EMessageType >(val2);
res3 = SWIG_AsCharPtrAndSize(argv[1], &buf3, NULL, &alloc3);
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "char const *","buffered_message", 3, argv[1] ));
}
arg3 = reinterpret_cast< char * >(buf3);
{
try
{
((shogun::SGIO const *)arg1)->buffered_message(arg2,(char const *)arg3,arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return Qnil;
fail:
if (alloc3 == SWIG_NEWOBJ) delete[] buf3;
return Qnil;
}
/*
Document-method: Modshogun::SGIO.skip_spaces
call-seq:
skip_spaces(str) -> char *
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_skip_spaces(int argc, VALUE *argv, VALUE self) {
char *arg1 = (char *) 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
char *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_AsCharPtrAndSize(argv[0], &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "char *","shogun::SGIO::skip_spaces", 1, argv[0] ));
}
arg1 = reinterpret_cast< char * >(buf1);
{
try
{
result = (char *)shogun::SGIO::skip_spaces(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_FromCharPtr((const char *)result);
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return vresult;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return Qnil;
}
/*
Document-method: Modshogun::SGIO.skip_blanks
call-seq:
skip_blanks(str) -> char *
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_skip_blanks(int argc, VALUE *argv, VALUE self) {
char *arg1 = (char *) 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
char *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_AsCharPtrAndSize(argv[0], &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "char *","shogun::SGIO::skip_blanks", 1, argv[0] ));
}
arg1 = reinterpret_cast< char * >(buf1);
{
try
{
result = (char *)shogun::SGIO::skip_blanks(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_FromCharPtr((const char *)result);
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return vresult;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return Qnil;
}
/*
Document-method: Modshogun::SGIO.get_target
call-seq:
get_target -> FILE *
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_get_target(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
FILE *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","get_target", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
result = (FILE *)((shogun::SGIO const *)arg1)->get_target();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_FILE, 0 | 0 );
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.set_target
call-seq:
set_target(target)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_set_target(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
FILE *arg2 = (FILE *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","set_target", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_FILE, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "FILE *","set_target", 2, argv[0] ));
}
arg2 = reinterpret_cast< FILE * >(argp2);
{
try
{
(arg1)->set_target(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.set_target_to_stderr
call-seq:
set_target_to_stderr
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_set_target_to_stderr(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","set_target_to_stderr", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
(arg1)->set_target_to_stderr();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.set_target_to_stdout
call-seq:
set_target_to_stdout
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_set_target_to_stdout(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","set_target_to_stdout", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
(arg1)->set_target_to_stdout();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.enable_progress
call-seq:
enable_progress
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_enable_progress(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","enable_progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
(arg1)->enable_progress();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.disable_progress
call-seq:
disable_progress
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_disable_progress(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","disable_progress", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
(arg1)->disable_progress();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.set_location_info
call-seq:
set_location_info(location)
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_set_location_info(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
shogun::EMessageLocation arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","set_location_info", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
ecode2 = SWIG_AsVal_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "shogun::EMessageLocation","set_location_info", 2, argv[0] ));
}
arg2 = static_cast< shogun::EMessageLocation >(val2);
{
try
{
(arg1)->set_location_info(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.enable_syntax_highlighting
call-seq:
enable_syntax_highlighting
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_enable_syntax_highlighting(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","enable_syntax_highlighting", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
(arg1)->enable_syntax_highlighting();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.disable_syntax_highlighting
call-seq:
disable_syntax_highlighting
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_disable_syntax_highlighting(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","disable_syntax_highlighting", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
(arg1)->disable_syntax_highlighting();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.set_dirname
call-seq:
set_dirname(dirname)
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_set_dirname(int argc, VALUE *argv, VALUE self) {
char *arg1 = (char *) 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_AsCharPtrAndSize(argv[0], &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "char const *","shogun::SGIO::set_dirname", 1, argv[0] ));
}
arg1 = reinterpret_cast< char * >(buf1);
{
try
{
shogun::SGIO::set_dirname((char const *)arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return Qnil;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return Qnil;
}
/*
Document-method: Modshogun::SGIO.concat_filename
call-seq:
concat_filename(filename) -> char *
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_concat_filename(int argc, VALUE *argv, VALUE self) {
char *arg1 = (char *) 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
char *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_AsCharPtrAndSize(argv[0], &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "char const *","shogun::SGIO::concat_filename", 1, argv[0] ));
}
arg1 = reinterpret_cast< char * >(buf1);
{
try
{
result = (char *)shogun::SGIO::concat_filename((char const *)arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_FromCharPtr((const char *)result);
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return vresult;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return Qnil;
}
/*
Document-method: Modshogun::SGIO.filter
call-seq:
filter(d) -> int
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_filter(int argc, VALUE *argv, VALUE self) {
dirent *arg1 = (dirent *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_dirent, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "dirent const *","shogun::SGIO::filter", 1, argv[0] ));
}
arg1 = reinterpret_cast< dirent * >(argp1);
{
try
{
result = (int)shogun::SGIO::filter((dirent const *)arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.c_string_of_substring
call-seq:
c_string_of_substring(s) -> char *
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_c_string_of_substring(int argc, VALUE *argv, VALUE self) {
shogun::substring arg1 ;
void *argp1 ;
int res1 = 0 ;
char *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_shogun__substring, 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::substring","shogun::SGIO::c_string_of_substring", 1, argv[0] ));
}
if (!argp1) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::substring","shogun::SGIO::c_string_of_substring", 1, argv[0]));
} else {
arg1 = *(reinterpret_cast< shogun::substring * >(argp1));
}
}
{
try
{
result = (char *)shogun::SGIO::c_string_of_substring(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_FromCharPtr((const char *)result);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.print_substring
call-seq:
print_substring(s)
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_print_substring(int argc, VALUE *argv, VALUE self) {
shogun::substring arg1 ;
void *argp1 ;
int res1 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_shogun__substring, 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::substring","shogun::SGIO::print_substring", 1, argv[0] ));
}
if (!argp1) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::substring","shogun::SGIO::print_substring", 1, argv[0]));
} else {
arg1 = *(reinterpret_cast< shogun::substring * >(argp1));
}
}
{
try
{
shogun::SGIO::print_substring(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.float_of_substring
call-seq:
float_of_substring(s) -> float32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_float_of_substring(int argc, VALUE *argv, VALUE self) {
shogun::substring arg1 ;
void *argp1 ;
int res1 = 0 ;
float32_t result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_shogun__substring, 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::substring","shogun::SGIO::float_of_substring", 1, argv[0] ));
}
if (!argp1) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::substring","shogun::SGIO::float_of_substring", 1, argv[0]));
} else {
arg1 = *(reinterpret_cast< shogun::substring * >(argp1));
}
}
{
try
{
result = (float32_t)shogun::SGIO::float_of_substring(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_float(static_cast< float >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.double_of_substring
call-seq:
double_of_substring(s) -> float64_t
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_double_of_substring(int argc, VALUE *argv, VALUE self) {
shogun::substring arg1 ;
void *argp1 ;
int res1 = 0 ;
float64_t result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_shogun__substring, 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::substring","shogun::SGIO::double_of_substring", 1, argv[0] ));
}
if (!argp1) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::substring","shogun::SGIO::double_of_substring", 1, argv[0]));
} else {
arg1 = *(reinterpret_cast< shogun::substring * >(argp1));
}
}
{
try
{
result = (float64_t)shogun::SGIO::double_of_substring(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_double(static_cast< double >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.int_of_substring
call-seq:
int_of_substring(s) -> int32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_int_of_substring(int argc, VALUE *argv, VALUE self) {
shogun::substring arg1 ;
void *argp1 ;
int res1 = 0 ;
int32_t result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_shogun__substring, 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::substring","shogun::SGIO::int_of_substring", 1, argv[0] ));
}
if (!argp1) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::substring","shogun::SGIO::int_of_substring", 1, argv[0]));
} else {
arg1 = *(reinterpret_cast< shogun::substring * >(argp1));
}
}
{
try
{
result = (int32_t)shogun::SGIO::int_of_substring(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.ulong_of_substring
call-seq:
ulong_of_substring(s) -> uint32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_ulong_of_substring(int argc, VALUE *argv, VALUE self) {
shogun::substring arg1 ;
void *argp1 ;
int res1 = 0 ;
uint32_t result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_shogun__substring, 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::substring","shogun::SGIO::ulong_of_substring", 1, argv[0] ));
}
if (!argp1) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::substring","shogun::SGIO::ulong_of_substring", 1, argv[0]));
} else {
arg1 = *(reinterpret_cast< shogun::substring * >(argp1));
}
}
{
try
{
result = (uint32_t)shogun::SGIO::ulong_of_substring(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_unsigned_SS_int(static_cast< unsigned int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.ss_length
call-seq:
ss_length(s) -> uint32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_SGIO_ss_length(int argc, VALUE *argv, VALUE self) {
shogun::substring arg1 ;
void *argp1 ;
int res1 = 0 ;
uint32_t result;
VALUE vresult = Qnil;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
{
res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_shogun__substring, 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::substring","shogun::SGIO::ss_length", 1, argv[0] ));
}
if (!argp1) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::substring","shogun::SGIO::ss_length", 1, argv[0]));
} else {
arg1 = *(reinterpret_cast< shogun::substring * >(argp1));
}
}
{
try
{
result = (uint32_t)shogun::SGIO::ss_length(arg1);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_unsigned_SS_int(static_cast< unsigned int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.ref_count
call-seq:
ref_count -> int32_t
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_ref_count(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO const *","ref_count", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
result = (int32_t)((shogun::SGIO const *)arg1)->ref_count();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::SGIO.get_name
call-seq:
get_name -> char const *
An instance method.
*/
SWIGINTERN VALUE
_wrap_SGIO_get_name(int argc, VALUE *argv, VALUE self) {
shogun::SGIO *arg1 = (shogun::SGIO *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
char *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__SGIO, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::SGIO *","get_name", 1, self ));
}
arg1 = reinterpret_cast< shogun::SGIO * >(argp1);
{
try
{
result = (char *)(arg1)->get_name();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_FromCharPtr((const char *)result);
return vresult;
fail:
return Qnil;
}
/*
Document-class: Modshogun::Version
Proxy of C++ Modshogun::Version class
*/
static swig_class SwigClassVersion;
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_Version_allocate(VALUE self)
#else
_wrap_Version_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__Version);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
/*
Document-method: Modshogun::Version.new
call-seq:
Version.new
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_Version(int argc, VALUE *argv, VALUE self) {
shogun::Version *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::Version *)new shogun::Version();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
SWIGINTERN void
free_shogun_Version(void *self) {
shogun::Version *arg1 = (shogun::Version *)self;
delete arg1;
}
/*
Document-method: Modshogun::Version.print_version
call-seq:
print_version
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_print_version(int argc, VALUE *argv, VALUE self) {
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
shogun::Version::print_version();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_extra
call-seq:
get_version_extra -> char const *
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_extra(int argc, VALUE *argv, VALUE self) {
char *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (char *)shogun::Version::get_version_extra();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_FromCharPtr((const char *)result);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_release
call-seq:
get_version_release -> char const *
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_release(int argc, VALUE *argv, VALUE self) {
char *result = 0 ;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (char *)shogun::Version::get_version_release();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_FromCharPtr((const char *)result);
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_revision
call-seq:
get_version_revision -> int32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_revision(int argc, VALUE *argv, VALUE self) {
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (int32_t)shogun::Version::get_version_revision();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_year
call-seq:
get_version_year -> int32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_year(int argc, VALUE *argv, VALUE self) {
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (int32_t)shogun::Version::get_version_year();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_month
call-seq:
get_version_month -> int32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_month(int argc, VALUE *argv, VALUE self) {
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (int32_t)shogun::Version::get_version_month();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_day
call-seq:
get_version_day -> int32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_day(int argc, VALUE *argv, VALUE self) {
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (int32_t)shogun::Version::get_version_day();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_hour
call-seq:
get_version_hour -> int32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_hour(int argc, VALUE *argv, VALUE self) {
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (int32_t)shogun::Version::get_version_hour();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_minute
call-seq:
get_version_minute -> int32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_minute(int argc, VALUE *argv, VALUE self) {
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (int32_t)shogun::Version::get_version_minute();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_parameter
call-seq:
get_version_parameter -> int32_t
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_parameter(int argc, VALUE *argv, VALUE self) {
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (int32_t)shogun::Version::get_version_parameter();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.get_version_in_minutes
call-seq:
get_version_in_minutes -> int64_t
A class method.
*/
SWIGINTERN VALUE
_wrap_Version_get_version_in_minutes(int argc, VALUE *argv, VALUE self) {
int64_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (int64_t)shogun::Version::get_version_in_minutes();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_long(static_cast< long >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Version.ref_count
call-seq:
ref_count -> int32_t
An instance method.
*/
SWIGINTERN VALUE
_wrap_Version_ref_count(int argc, VALUE *argv, VALUE self) {
shogun::Version *arg1 = (shogun::Version *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__Version, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::Version const *","ref_count", 1, self ));
}
arg1 = reinterpret_cast< shogun::Version * >(argp1);
{
try
{
result = (int32_t)((shogun::Version const *)arg1)->ref_count();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-class: Modshogun::Parallel
Proxy of C++ Modshogun::Parallel class
*/
static swig_class SwigClassParallel;
/*
Document-method: Modshogun::Parallel.new
call-seq:
Parallel.new
Parallel.new(orig)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_Parallel__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::Parallel *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::Parallel *)new shogun::Parallel();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_Parallel_allocate(VALUE self)
#else
_wrap_Parallel_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__Parallel);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_Parallel__SWIG_1(int argc, VALUE *argv, VALUE self) {
shogun::Parallel *arg1 = 0 ;
void *argp1 ;
int res1 = 0 ;
shogun::Parallel *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1, SWIGTYPE_p_shogun__Parallel, 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::Parallel const &","Parallel", 1, argv[0] ));
}
if (!argp1) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::Parallel const &","Parallel", 1, argv[0]));
}
arg1 = reinterpret_cast< shogun::Parallel * >(argp1);
{
try
{
result = (shogun::Parallel *)new shogun::Parallel((shogun::Parallel const &)*arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_Parallel(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[1];
int ii;
argc = nargs;
if (argc > 1) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_Parallel__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__Parallel, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_Parallel__SWIG_1(nargs, args, self);
}
}
fail:
Ruby_Format_OverloadedError( argc, 1, "Parallel.new",
" Parallel.new()\n"
" Parallel.new(shogun::Parallel const &orig)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_Parallel(void *self) {
shogun::Parallel *arg1 = (shogun::Parallel *)self;
delete arg1;
}
/*
Document-method: Modshogun::Parallel.get_num_cpus
call-seq:
get_num_cpus -> int32_t
An instance method.
*/
SWIGINTERN VALUE
_wrap_Parallel_get_num_cpus(int argc, VALUE *argv, VALUE self) {
shogun::Parallel *arg1 = (shogun::Parallel *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__Parallel, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::Parallel const *","get_num_cpus", 1, self ));
}
arg1 = reinterpret_cast< shogun::Parallel * >(argp1);
{
try
{
result = (int32_t)((shogun::Parallel const *)arg1)->get_num_cpus();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Parallel.set_num_threads
call-seq:
set_num_threads(n)
An instance method.
*/
SWIGINTERN VALUE
_wrap_Parallel_set_num_threads(int argc, VALUE *argv, VALUE self) {
shogun::Parallel *arg1 = (shogun::Parallel *) 0 ;
int32_t arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
int val2 ;
int ecode2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__Parallel, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::Parallel *","set_num_threads", 1, self ));
}
arg1 = reinterpret_cast< shogun::Parallel * >(argp1);
ecode2 = SWIG_AsVal_int(argv[0], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "int32_t","set_num_threads", 2, argv[0] ));
}
arg2 = static_cast< int32_t >(val2);
{
try
{
(arg1)->set_num_threads(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Parallel.get_num_threads
call-seq:
get_num_threads -> int32_t
An instance method.
*/
SWIGINTERN VALUE
_wrap_Parallel_get_num_threads(int argc, VALUE *argv, VALUE self) {
shogun::Parallel *arg1 = (shogun::Parallel *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__Parallel, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::Parallel const *","get_num_threads", 1, self ));
}
arg1 = reinterpret_cast< shogun::Parallel * >(argp1);
{
try
{
result = (int32_t)((shogun::Parallel const *)arg1)->get_num_threads();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-method: Modshogun::Parallel.ref_count
call-seq:
ref_count -> int32_t
An instance method.
*/
SWIGINTERN VALUE
_wrap_Parallel_ref_count(int argc, VALUE *argv, VALUE self) {
shogun::Parallel *arg1 = (shogun::Parallel *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
int32_t result;
VALUE vresult = Qnil;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__Parallel, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::Parallel const *","ref_count", 1, self ));
}
arg1 = reinterpret_cast< shogun::Parallel * >(argp1);
{
try
{
result = (int32_t)((shogun::Parallel const *)arg1)->ref_count();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
vresult = SWIG_From_int(static_cast< int >(result));
return vresult;
fail:
return Qnil;
}
/*
Document-class: Modshogun::File < Modshogun::shogun::SGObject
Proxy of C++ Modshogun::File class
*/
static swig_class SwigClassFile;
SWIGINTERN void
free_shogun_CFile(void *self) {
shogun::CFile *arg1 = (shogun::CFile *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::File.close
call-seq:
close
An instance method.
*/
SWIGINTERN VALUE
_wrap_File_close(int argc, VALUE *argv, VALUE self) {
shogun::CFile *arg1 = (shogun::CFile *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CFile, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CFile *","close", 1, self ));
}
arg1 = reinterpret_cast< shogun::CFile * >(argp1);
{
try
{
(arg1)->close();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFile < Modshogun::shogun::SGObject
Proxy of C++ Modshogun::StreamingFile class
*/
static swig_class SwigClassStreamingFile;
/*
Document-method: Modshogun::StreamingFile.new
call-seq:
StreamingFile.new
StreamingFile.new(fname, rw='r')
StreamingFile.new(fname)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFile__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFile *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFile *)new shogun::CStreamingFile();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFile__SWIG_1(int argc, VALUE *argv, VALUE self) {
char *arg1 = (char *) 0 ;
char arg2 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
char val2 ;
int ecode2 = 0 ;
shogun::CStreamingFile *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_AsCharPtrAndSize(argv[0], &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "char const *","CStreamingFile", 1, argv[0] ));
}
arg1 = reinterpret_cast< char * >(buf1);
ecode2 = SWIG_AsVal_char(argv[1], &val2);
if (!SWIG_IsOK(ecode2)) {
SWIG_exception_fail(SWIG_ArgError(ecode2), Ruby_Format_TypeError( "", "char","CStreamingFile", 2, argv[1] ));
}
arg2 = static_cast< char >(val2);
{
try
{
result = (shogun::CStreamingFile *)new shogun::CStreamingFile((char const *)arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
SG_REF(result);
return self;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFile_allocate(VALUE self)
#else
_wrap_StreamingFile_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFile);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFile__SWIG_2(int argc, VALUE *argv, VALUE self) {
char *arg1 = (char *) 0 ;
int res1 ;
char *buf1 = 0 ;
int alloc1 = 0 ;
shogun::CStreamingFile *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_AsCharPtrAndSize(argv[0], &buf1, NULL, &alloc1);
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "char const *","CStreamingFile", 1, argv[0] ));
}
arg1 = reinterpret_cast< char * >(buf1);
{
try
{
result = (shogun::CStreamingFile *)new shogun::CStreamingFile((char const *)arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
SG_REF(result);
return self;
fail:
if (alloc1 == SWIG_NEWOBJ) delete[] buf1;
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFile(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFile__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
int res = SWIG_AsCharPtrAndSize(argv[0], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFile__SWIG_2(nargs, args, self);
}
}
if (argc == 2) {
int _v;
int res = SWIG_AsCharPtrAndSize(argv[0], 0, NULL, 0);
_v = SWIG_CheckState(res);
if (_v) {
{
int res = SWIG_AsVal_char(argv[1], NULL);
_v = SWIG_CheckState(res);
}
if (_v) {
return _wrap_new_StreamingFile__SWIG_1(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFile.new",
" StreamingFile.new()\n"
" StreamingFile.new(char const *fname, char rw)\n"
" StreamingFile.new(char const *fname)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFile(void *self) {
shogun::CStreamingFile *arg1 = (shogun::CStreamingFile *)self;
SG_UNREF(arg1);
}
/*
Document-class: Modshogun::StreamingFileFromFeatures < Modshogun::shogun::StreamingFile
Proxy of C++ Modshogun::StreamingFileFromFeatures class
*/
static swig_class SwigClassStreamingFileFromFeatures;
/*
Document-method: Modshogun::StreamingFileFromFeatures.new
call-seq:
StreamingFileFromFeatures.new
StreamingFileFromFeatures.new(feat)
StreamingFileFromFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromFeatures *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromFeatures *)new shogun::CStreamingFileFromFeatures();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
shogun::CFeatures *arg1 = (shogun::CFeatures *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromFeatures *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_shogun__CFeatures, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CFeatures *","CStreamingFileFromFeatures", 1, argv[0] ));
}
arg1 = reinterpret_cast< shogun::CFeatures * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromFeatures *)new shogun::CStreamingFileFromFeatures(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromFeatures);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
shogun::CFeatures *arg1 = (shogun::CFeatures *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromFeatures *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_shogun__CFeatures, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CFeatures *","CStreamingFileFromFeatures", 1, argv[0] ));
}
arg1 = reinterpret_cast< shogun::CFeatures * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromFeatures", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromFeatures *)new shogun::CStreamingFileFromFeatures(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CFeatures, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_shogun__CFeatures, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromFeatures.new",
" StreamingFileFromFeatures.new()\n"
" StreamingFileFromFeatures.new(shogun::CFeatures *feat)\n"
" StreamingFileFromFeatures.new(shogun::CFeatures *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromFeatures(void *self) {
shogun::CStreamingFileFromFeatures *arg1 = (shogun::CStreamingFileFromFeatures *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromFeatures.set_features
call-seq:
set_features(feat)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromFeatures_set_features(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromFeatures *arg1 = (shogun::CStreamingFileFromFeatures *) 0 ;
shogun::CFeatures *arg2 = (shogun::CFeatures *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromFeatures, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromFeatures *","set_features", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromFeatures * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_shogun__CFeatures, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::CFeatures *","set_features", 2, argv[0] ));
}
arg2 = reinterpret_cast< shogun::CFeatures * >(argp2);
{
try
{
(arg1)->set_features(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromFeatures.set_labels
call-seq:
set_labels(lab)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromFeatures_set_labels(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromFeatures *arg1 = (shogun::CStreamingFileFromFeatures *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromFeatures, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromFeatures *","set_labels", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromFeatures * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","set_labels", 2, argv[0] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
(arg1)->set_labels(arg2);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromSparseBoolFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromSparseBoolFeatures class
*/
static swig_class SwigClassStreamingFileFromSparseBoolFeatures;
/*
Document-method: Modshogun::StreamingFileFromSparseBoolFeatures.new
call-seq:
StreamingFileFromSparseBoolFeatures.new
StreamingFileFromSparseBoolFeatures.new(feat)
StreamingFileFromSparseBoolFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseBoolFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< bool > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< bool > *)new shogun::CStreamingFileFromSparseFeatures< bool >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseBoolFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< bool > *arg1 = (CSparseFeatures< bool > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromSparseFeatures< bool > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< bool > *","CStreamingFileFromSparseFeatures<(bool)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< bool > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< bool > *)new shogun::CStreamingFileFromSparseFeatures< bool >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromSparseBoolFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromSparseBoolFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_bool_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseBoolFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< bool > *arg1 = (CSparseFeatures< bool > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromSparseFeatures< bool > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< bool > *","CStreamingFileFromSparseFeatures<(bool)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< bool > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromSparseFeatures<(bool)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< bool > *)new shogun::CStreamingFileFromSparseFeatures< bool >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromSparseBoolFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromSparseBoolFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_bool_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseBoolFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_bool_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseBoolFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromSparseBoolFeatures.new",
" StreamingFileFromSparseBoolFeatures.new()\n"
" StreamingFileFromSparseBoolFeatures.new(CSparseFeatures< bool > *feat)\n"
" StreamingFileFromSparseBoolFeatures.new(CSparseFeatures< bool > *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromSparseFeatures_Sl_bool_Sg_(void *self) {
shogun::CStreamingFileFromSparseFeatures< bool > *arg1 = (shogun::CStreamingFileFromSparseFeatures< bool > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromSparseBoolFeatures.get_sparse_vector
call-seq:
get_sparse_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseBoolFeatures_get_sparse_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< bool > *arg1 = (shogun::CStreamingFileFromSparseFeatures< bool > *) 0 ;
shogun::SGSparseVectorEntry< bool > **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< bool > *","get_sparse_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< bool > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_bool_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< bool > *&","get_sparse_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< bool > *&","get_sparse_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< bool > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_sparse_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseBoolFeatures.get_sparse_vector_and_label
call-seq:
get_sparse_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseBoolFeatures_get_sparse_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< bool > *arg1 = (shogun::CStreamingFileFromSparseFeatures< bool > *) 0 ;
shogun::SGSparseVectorEntry< bool > **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< bool > *","get_sparse_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< bool > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_bool_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< bool > *&","get_sparse_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< bool > *&","get_sparse_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< bool > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_sparse_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_sparse_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_sparse_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseBoolFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseBoolFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< bool > *arg1 = (shogun::CStreamingFileFromSparseFeatures< bool > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< bool > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< bool > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromSparseCharFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromSparseCharFeatures class
*/
static swig_class SwigClassStreamingFileFromSparseCharFeatures;
/*
Document-method: Modshogun::StreamingFileFromSparseCharFeatures.new
call-seq:
StreamingFileFromSparseCharFeatures.new
StreamingFileFromSparseCharFeatures.new(feat)
StreamingFileFromSparseCharFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseCharFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< char > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< char > *)new shogun::CStreamingFileFromSparseFeatures< char >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseCharFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< char > *arg1 = (CSparseFeatures< char > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromSparseFeatures< char > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< char > *","CStreamingFileFromSparseFeatures<(char)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< char > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< char > *)new shogun::CStreamingFileFromSparseFeatures< char >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromSparseCharFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromSparseCharFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_char_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseCharFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< char > *arg1 = (CSparseFeatures< char > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromSparseFeatures< char > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< char > *","CStreamingFileFromSparseFeatures<(char)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< char > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromSparseFeatures<(char)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< char > *)new shogun::CStreamingFileFromSparseFeatures< char >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromSparseCharFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromSparseCharFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_char_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseCharFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_char_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseCharFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromSparseCharFeatures.new",
" StreamingFileFromSparseCharFeatures.new()\n"
" StreamingFileFromSparseCharFeatures.new(CSparseFeatures< char > *feat)\n"
" StreamingFileFromSparseCharFeatures.new(CSparseFeatures< char > *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromSparseFeatures_Sl_char_Sg_(void *self) {
shogun::CStreamingFileFromSparseFeatures< char > *arg1 = (shogun::CStreamingFileFromSparseFeatures< char > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromSparseCharFeatures.get_sparse_vector
call-seq:
get_sparse_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseCharFeatures_get_sparse_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< char > *arg1 = (shogun::CStreamingFileFromSparseFeatures< char > *) 0 ;
shogun::SGSparseVectorEntry< char > **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< char > *","get_sparse_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< char > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_char_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< char > *&","get_sparse_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< char > *&","get_sparse_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< char > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_sparse_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseCharFeatures.get_sparse_vector_and_label
call-seq:
get_sparse_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseCharFeatures_get_sparse_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< char > *arg1 = (shogun::CStreamingFileFromSparseFeatures< char > *) 0 ;
shogun::SGSparseVectorEntry< char > **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< char > *","get_sparse_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< char > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_char_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< char > *&","get_sparse_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< char > *&","get_sparse_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< char > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_sparse_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_sparse_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_sparse_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseCharFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseCharFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< char > *arg1 = (shogun::CStreamingFileFromSparseFeatures< char > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< char > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< char > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromSparseByteFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromSparseByteFeatures class
*/
static swig_class SwigClassStreamingFileFromSparseByteFeatures;
/*
Document-method: Modshogun::StreamingFileFromSparseByteFeatures.new
call-seq:
StreamingFileFromSparseByteFeatures.new
StreamingFileFromSparseByteFeatures.new(feat)
StreamingFileFromSparseByteFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseByteFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint8_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< uint8_t > *)new shogun::CStreamingFileFromSparseFeatures< uint8_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseByteFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< unsigned char > *arg1 = (CSparseFeatures< unsigned char > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromSparseFeatures< uint8_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< unsigned char > *","CStreamingFileFromSparseFeatures<(uint8_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< unsigned char > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< uint8_t > *)new shogun::CStreamingFileFromSparseFeatures< uint8_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromSparseByteFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromSparseByteFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_char_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseByteFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< unsigned char > *arg1 = (CSparseFeatures< unsigned char > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromSparseFeatures< uint8_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< unsigned char > *","CStreamingFileFromSparseFeatures<(uint8_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< unsigned char > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromSparseFeatures<(uint8_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< uint8_t > *)new shogun::CStreamingFileFromSparseFeatures< uint8_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromSparseByteFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromSparseByteFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_unsigned_char_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseByteFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_unsigned_char_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseByteFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromSparseByteFeatures.new",
" StreamingFileFromSparseByteFeatures.new()\n"
" StreamingFileFromSparseByteFeatures.new(CSparseFeatures< unsigned char > *feat)\n"
" StreamingFileFromSparseByteFeatures.new(CSparseFeatures< unsigned char > *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromSparseFeatures_Sl_uint8_t_Sg_(void *self) {
shogun::CStreamingFileFromSparseFeatures< uint8_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint8_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromSparseByteFeatures.get_sparse_vector
call-seq:
get_sparse_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseByteFeatures_get_sparse_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint8_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint8_t > *) 0 ;
shogun::SGSparseVectorEntry< unsigned char > **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< uint8_t > *","get_sparse_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< uint8_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_unsigned_char_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< unsigned char > *&","get_sparse_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< unsigned char > *&","get_sparse_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< unsigned char > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_sparse_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseByteFeatures.get_sparse_vector_and_label
call-seq:
get_sparse_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseByteFeatures_get_sparse_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint8_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint8_t > *) 0 ;
shogun::SGSparseVectorEntry< unsigned char > **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< uint8_t > *","get_sparse_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< uint8_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_unsigned_char_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< unsigned char > *&","get_sparse_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< unsigned char > *&","get_sparse_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< unsigned char > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_sparse_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_sparse_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_sparse_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseByteFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseByteFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint8_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint8_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< uint8_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< uint8_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromSparseWordFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromSparseWordFeatures class
*/
static swig_class SwigClassStreamingFileFromSparseWordFeatures;
/*
Document-method: Modshogun::StreamingFileFromSparseWordFeatures.new
call-seq:
StreamingFileFromSparseWordFeatures.new
StreamingFileFromSparseWordFeatures.new(feat)
StreamingFileFromSparseWordFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseWordFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint16_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< uint16_t > *)new shogun::CStreamingFileFromSparseFeatures< uint16_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseWordFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< unsigned short > *arg1 = (CSparseFeatures< unsigned short > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromSparseFeatures< uint16_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< unsigned short > *","CStreamingFileFromSparseFeatures<(uint16_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< unsigned short > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< uint16_t > *)new shogun::CStreamingFileFromSparseFeatures< uint16_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromSparseWordFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromSparseWordFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_short_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseWordFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< unsigned short > *arg1 = (CSparseFeatures< unsigned short > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromSparseFeatures< uint16_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< unsigned short > *","CStreamingFileFromSparseFeatures<(uint16_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< unsigned short > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromSparseFeatures<(uint16_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< uint16_t > *)new shogun::CStreamingFileFromSparseFeatures< uint16_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromSparseWordFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromSparseWordFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_unsigned_short_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseWordFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_unsigned_short_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseWordFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromSparseWordFeatures.new",
" StreamingFileFromSparseWordFeatures.new()\n"
" StreamingFileFromSparseWordFeatures.new(CSparseFeatures< unsigned short > *feat)\n"
" StreamingFileFromSparseWordFeatures.new(CSparseFeatures< unsigned short > *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromSparseFeatures_Sl_uint16_t_Sg_(void *self) {
shogun::CStreamingFileFromSparseFeatures< uint16_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint16_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromSparseWordFeatures.get_sparse_vector
call-seq:
get_sparse_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseWordFeatures_get_sparse_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint16_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint16_t > *) 0 ;
shogun::SGSparseVectorEntry< unsigned short > **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< uint16_t > *","get_sparse_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< uint16_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_unsigned_short_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< unsigned short > *&","get_sparse_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< unsigned short > *&","get_sparse_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< unsigned short > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_sparse_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseWordFeatures.get_sparse_vector_and_label
call-seq:
get_sparse_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseWordFeatures_get_sparse_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint16_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint16_t > *) 0 ;
shogun::SGSparseVectorEntry< unsigned short > **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< uint16_t > *","get_sparse_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< uint16_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_unsigned_short_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< unsigned short > *&","get_sparse_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< unsigned short > *&","get_sparse_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< unsigned short > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_sparse_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_sparse_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_sparse_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseWordFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseWordFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint16_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint16_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< uint16_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< uint16_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromSparseIntFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromSparseIntFeatures class
*/
static swig_class SwigClassStreamingFileFromSparseIntFeatures;
/*
Document-method: Modshogun::StreamingFileFromSparseIntFeatures.new
call-seq:
StreamingFileFromSparseIntFeatures.new
StreamingFileFromSparseIntFeatures.new(feat)
StreamingFileFromSparseIntFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseIntFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< int32_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< int32_t > *)new shogun::CStreamingFileFromSparseFeatures< int32_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseIntFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< int > *arg1 = (CSparseFeatures< int > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromSparseFeatures< int32_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< int > *","CStreamingFileFromSparseFeatures<(int32_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< int > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< int32_t > *)new shogun::CStreamingFileFromSparseFeatures< int32_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromSparseIntFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromSparseIntFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_int_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseIntFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< int > *arg1 = (CSparseFeatures< int > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromSparseFeatures< int32_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< int > *","CStreamingFileFromSparseFeatures<(int32_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< int > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromSparseFeatures<(int32_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< int32_t > *)new shogun::CStreamingFileFromSparseFeatures< int32_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromSparseIntFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromSparseIntFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_int_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseIntFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_int_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseIntFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromSparseIntFeatures.new",
" StreamingFileFromSparseIntFeatures.new()\n"
" StreamingFileFromSparseIntFeatures.new(CSparseFeatures< int > *feat)\n"
" StreamingFileFromSparseIntFeatures.new(CSparseFeatures< int > *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromSparseFeatures_Sl_int32_t_Sg_(void *self) {
shogun::CStreamingFileFromSparseFeatures< int32_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< int32_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromSparseIntFeatures.get_sparse_vector
call-seq:
get_sparse_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseIntFeatures_get_sparse_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< int32_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< int32_t > *) 0 ;
shogun::SGSparseVectorEntry< int > **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< int32_t > *","get_sparse_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< int32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_int_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< int > *&","get_sparse_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< int > *&","get_sparse_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< int > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_sparse_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseIntFeatures.get_sparse_vector_and_label
call-seq:
get_sparse_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseIntFeatures_get_sparse_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< int32_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< int32_t > *) 0 ;
shogun::SGSparseVectorEntry< int > **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< int32_t > *","get_sparse_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< int32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_int_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< int > *&","get_sparse_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< int > *&","get_sparse_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< int > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_sparse_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_sparse_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_sparse_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseIntFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseIntFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< int32_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< int32_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< int32_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromSparseLongFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromSparseLongFeatures class
*/
static swig_class SwigClassStreamingFileFromSparseLongFeatures;
/*
Document-method: Modshogun::StreamingFileFromSparseLongFeatures.new
call-seq:
StreamingFileFromSparseLongFeatures.new
StreamingFileFromSparseLongFeatures.new(feat)
StreamingFileFromSparseLongFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseLongFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< int64_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< int64_t > *)new shogun::CStreamingFileFromSparseFeatures< int64_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseLongFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< long > *arg1 = (CSparseFeatures< long > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromSparseFeatures< int64_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< long > *","CStreamingFileFromSparseFeatures<(int64_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< long > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< int64_t > *)new shogun::CStreamingFileFromSparseFeatures< int64_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromSparseLongFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromSparseLongFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_long_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseLongFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< long > *arg1 = (CSparseFeatures< long > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromSparseFeatures< int64_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< long > *","CStreamingFileFromSparseFeatures<(int64_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< long > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromSparseFeatures<(int64_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< int64_t > *)new shogun::CStreamingFileFromSparseFeatures< int64_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromSparseLongFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromSparseLongFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_long_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseLongFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_long_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseLongFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromSparseLongFeatures.new",
" StreamingFileFromSparseLongFeatures.new()\n"
" StreamingFileFromSparseLongFeatures.new(CSparseFeatures< long > *feat)\n"
" StreamingFileFromSparseLongFeatures.new(CSparseFeatures< long > *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromSparseFeatures_Sl_int64_t_Sg_(void *self) {
shogun::CStreamingFileFromSparseFeatures< int64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< int64_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromSparseLongFeatures.get_sparse_vector
call-seq:
get_sparse_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseLongFeatures_get_sparse_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< int64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< int64_t > *) 0 ;
shogun::SGSparseVectorEntry< long > **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< int64_t > *","get_sparse_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< int64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_long_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< long > *&","get_sparse_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< long > *&","get_sparse_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< long > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_sparse_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseLongFeatures.get_sparse_vector_and_label
call-seq:
get_sparse_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseLongFeatures_get_sparse_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< int64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< int64_t > *) 0 ;
shogun::SGSparseVectorEntry< long > **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< int64_t > *","get_sparse_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< int64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_long_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< long > *&","get_sparse_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< long > *&","get_sparse_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< long > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_sparse_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_sparse_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_sparse_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseLongFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseLongFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< int64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< int64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< int64_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< int64_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromSparseUlongFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromSparseUlongFeatures class
*/
static swig_class SwigClassStreamingFileFromSparseUlongFeatures;
/*
Document-method: Modshogun::StreamingFileFromSparseUlongFeatures.new
call-seq:
StreamingFileFromSparseUlongFeatures.new
StreamingFileFromSparseUlongFeatures.new(feat)
StreamingFileFromSparseUlongFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseUlongFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint64_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< uint64_t > *)new shogun::CStreamingFileFromSparseFeatures< uint64_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseUlongFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< unsigned long > *arg1 = (CSparseFeatures< unsigned long > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromSparseFeatures< uint64_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_unsigned_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< unsigned long > *","CStreamingFileFromSparseFeatures<(uint64_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< unsigned long > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< uint64_t > *)new shogun::CStreamingFileFromSparseFeatures< uint64_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromSparseUlongFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromSparseUlongFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_long_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseUlongFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< unsigned long > *arg1 = (CSparseFeatures< unsigned long > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromSparseFeatures< uint64_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_unsigned_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< unsigned long > *","CStreamingFileFromSparseFeatures<(uint64_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< unsigned long > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromSparseFeatures<(uint64_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< uint64_t > *)new shogun::CStreamingFileFromSparseFeatures< uint64_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromSparseUlongFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromSparseUlongFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_unsigned_long_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseUlongFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_unsigned_long_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseUlongFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromSparseUlongFeatures.new",
" StreamingFileFromSparseUlongFeatures.new()\n"
" StreamingFileFromSparseUlongFeatures.new(CSparseFeatures< unsigned long > *feat)\n"
" StreamingFileFromSparseUlongFeatures.new(CSparseFeatures< unsigned long > *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromSparseFeatures_Sl_uint64_t_Sg_(void *self) {
shogun::CStreamingFileFromSparseFeatures< uint64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint64_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromSparseUlongFeatures.get_sparse_vector
call-seq:
get_sparse_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseUlongFeatures_get_sparse_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint64_t > *) 0 ;
shogun::SGSparseVectorEntry< unsigned long > **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< uint64_t > *","get_sparse_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< uint64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_unsigned_long_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< unsigned long > *&","get_sparse_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< unsigned long > *&","get_sparse_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< unsigned long > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_sparse_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseUlongFeatures.get_sparse_vector_and_label
call-seq:
get_sparse_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseUlongFeatures_get_sparse_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint64_t > *) 0 ;
shogun::SGSparseVectorEntry< unsigned long > **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< uint64_t > *","get_sparse_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< uint64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_unsigned_long_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< unsigned long > *&","get_sparse_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< unsigned long > *&","get_sparse_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< unsigned long > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_sparse_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_sparse_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_sparse_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseUlongFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseUlongFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< uint64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< uint64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_unsigned_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< uint64_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< uint64_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromSparseShortRealFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromSparseShortRealFeatures class
*/
static swig_class SwigClassStreamingFileFromSparseShortRealFeatures;
/*
Document-method: Modshogun::StreamingFileFromSparseShortRealFeatures.new
call-seq:
StreamingFileFromSparseShortRealFeatures.new
StreamingFileFromSparseShortRealFeatures.new(feat)
StreamingFileFromSparseShortRealFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseShortRealFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< float32_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< float32_t > *)new shogun::CStreamingFileFromSparseFeatures< float32_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseShortRealFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< float > *arg1 = (CSparseFeatures< float > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromSparseFeatures< float32_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_float_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< float > *","CStreamingFileFromSparseFeatures<(float32_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< float > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< float32_t > *)new shogun::CStreamingFileFromSparseFeatures< float32_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromSparseShortRealFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromSparseShortRealFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_float_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseShortRealFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< float > *arg1 = (CSparseFeatures< float > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromSparseFeatures< float32_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_float_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< float > *","CStreamingFileFromSparseFeatures<(float32_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< float > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromSparseFeatures<(float32_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< float32_t > *)new shogun::CStreamingFileFromSparseFeatures< float32_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromSparseShortRealFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromSparseShortRealFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_float_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseShortRealFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_float_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseShortRealFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromSparseShortRealFeatures.new",
" StreamingFileFromSparseShortRealFeatures.new()\n"
" StreamingFileFromSparseShortRealFeatures.new(CSparseFeatures< float > *feat)\n"
" StreamingFileFromSparseShortRealFeatures.new(CSparseFeatures< float > *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromSparseFeatures_Sl_float32_t_Sg_(void *self) {
shogun::CStreamingFileFromSparseFeatures< float32_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< float32_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromSparseShortRealFeatures.get_sparse_vector
call-seq:
get_sparse_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseShortRealFeatures_get_sparse_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< float32_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< float32_t > *) 0 ;
shogun::SGSparseVectorEntry< float > **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_float_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< float32_t > *","get_sparse_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< float32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_float_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< float > *&","get_sparse_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< float > *&","get_sparse_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< float > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_sparse_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseShortRealFeatures.get_sparse_vector_and_label
call-seq:
get_sparse_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseShortRealFeatures_get_sparse_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< float32_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< float32_t > *) 0 ;
shogun::SGSparseVectorEntry< float > **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_float_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< float32_t > *","get_sparse_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< float32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_float_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< float > *&","get_sparse_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< float > *&","get_sparse_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< float > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_sparse_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_sparse_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_sparse_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseShortRealFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseShortRealFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< float32_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< float32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_float_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< float32_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< float32_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromSparseRealFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromSparseRealFeatures class
*/
static swig_class SwigClassStreamingFileFromSparseRealFeatures;
/*
Document-method: Modshogun::StreamingFileFromSparseRealFeatures.new
call-seq:
StreamingFileFromSparseRealFeatures.new
StreamingFileFromSparseRealFeatures.new(feat)
StreamingFileFromSparseRealFeatures.new(feat, lab)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseRealFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< float64_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< float64_t > *)new shogun::CStreamingFileFromSparseFeatures< float64_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseRealFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< double > *arg1 = (CSparseFeatures< double > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromSparseFeatures< float64_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_double_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< double > *","CStreamingFileFromSparseFeatures<(float64_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< double > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< float64_t > *)new shogun::CStreamingFileFromSparseFeatures< float64_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromSparseRealFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromSparseRealFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_double_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromSparseRealFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CSparseFeatures< double > *arg1 = (CSparseFeatures< double > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromSparseFeatures< float64_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CSparseFeaturesT_double_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CSparseFeatures< double > *","CStreamingFileFromSparseFeatures<(float64_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CSparseFeatures< double > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromSparseFeatures<(float64_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromSparseFeatures< float64_t > *)new shogun::CStreamingFileFromSparseFeatures< float64_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromSparseRealFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromSparseRealFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_double_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseRealFeatures__SWIG_1(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CSparseFeaturesT_double_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromSparseRealFeatures__SWIG_2(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromSparseRealFeatures.new",
" StreamingFileFromSparseRealFeatures.new()\n"
" StreamingFileFromSparseRealFeatures.new(CSparseFeatures< double > *feat)\n"
" StreamingFileFromSparseRealFeatures.new(CSparseFeatures< double > *feat, float64_t *lab)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromSparseFeatures_Sl_float64_t_Sg_(void *self) {
shogun::CStreamingFileFromSparseFeatures< float64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< float64_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromSparseRealFeatures.get_sparse_vector
call-seq:
get_sparse_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseRealFeatures_get_sparse_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< float64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< float64_t > *) 0 ;
shogun::SGSparseVectorEntry< double > **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_double_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< float64_t > *","get_sparse_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< float64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_double_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< double > *&","get_sparse_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< double > *&","get_sparse_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< double > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_sparse_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseRealFeatures.get_sparse_vector_and_label
call-seq:
get_sparse_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseRealFeatures_get_sparse_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< float64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< float64_t > *) 0 ;
shogun::SGSparseVectorEntry< double > **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_double_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< float64_t > *","get_sparse_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< float64_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_shogun__SGSparseVectorEntryT_double_t, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "shogun::SGSparseVectorEntry< double > *&","get_sparse_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "shogun::SGSparseVectorEntry< double > *&","get_sparse_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< shogun::SGSparseVectorEntry< double > ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_sparse_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_sparse_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_sparse_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_sparse_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_sparse_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromSparseRealFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromSparseRealFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromSparseFeatures< float64_t > *arg1 = (shogun::CStreamingFileFromSparseFeatures< float64_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromSparseFeaturesT_double_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromSparseFeatures< float64_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromSparseFeatures< float64_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromBoolFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromBoolFeatures class
*/
static swig_class SwigClassStreamingFileFromBoolFeatures;
/*
Document-method: Modshogun::StreamingFileFromBoolFeatures.new
call-seq:
StreamingFileFromBoolFeatures.new
StreamingFileFromBoolFeatures.new(feat, lab=nil)
StreamingFileFromBoolFeatures.new(feat)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromBoolFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< bool > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< bool > *)new shogun::CStreamingFileFromDenseFeatures< bool >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromBoolFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< bool > *arg1 = (CDenseFeatures< bool > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromDenseFeatures< bool > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< bool > *","CStreamingFileFromDenseFeatures<(bool)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< bool > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromDenseFeatures<(bool)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< bool > *)new shogun::CStreamingFileFromDenseFeatures< bool >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromBoolFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromBoolFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_bool_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromBoolFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< bool > *arg1 = (CDenseFeatures< bool > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromDenseFeatures< bool > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< bool > *","CStreamingFileFromDenseFeatures<(bool)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< bool > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< bool > *)new shogun::CStreamingFileFromDenseFeatures< bool >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromBoolFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromBoolFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_bool_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromBoolFeatures__SWIG_2(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_bool_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromBoolFeatures__SWIG_1(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromBoolFeatures.new",
" StreamingFileFromBoolFeatures.new()\n"
" StreamingFileFromBoolFeatures.new(CDenseFeatures< bool > *feat, float64_t *lab)\n"
" StreamingFileFromBoolFeatures.new(CDenseFeatures< bool > *feat)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromDenseFeatures_Sl_bool_Sg_(void *self) {
shogun::CStreamingFileFromDenseFeatures< bool > *arg1 = (shogun::CStreamingFileFromDenseFeatures< bool > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromBoolFeatures.get_vector
call-seq:
get_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromBoolFeatures_get_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< bool > *arg1 = (shogun::CStreamingFileFromDenseFeatures< bool > *) 0 ;
bool **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< bool > *","get_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< bool > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_bool, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "bool *&","get_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "bool *&","get_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< bool ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromBoolFeatures.get_vector_and_label
call-seq:
get_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromBoolFeatures_get_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< bool > *arg1 = (shogun::CStreamingFileFromDenseFeatures< bool > *) 0 ;
bool **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< bool > *","get_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< bool > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_bool, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "bool *&","get_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "bool *&","get_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< bool ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromBoolFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromBoolFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< bool > *arg1 = (shogun::CStreamingFileFromDenseFeatures< bool > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_bool_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< bool > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< bool > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromCharFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromCharFeatures class
*/
static swig_class SwigClassStreamingFileFromCharFeatures;
/*
Document-method: Modshogun::StreamingFileFromCharFeatures.new
call-seq:
StreamingFileFromCharFeatures.new
StreamingFileFromCharFeatures.new(feat, lab=nil)
StreamingFileFromCharFeatures.new(feat)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromCharFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< char > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< char > *)new shogun::CStreamingFileFromDenseFeatures< char >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromCharFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< char > *arg1 = (CDenseFeatures< char > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromDenseFeatures< char > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< char > *","CStreamingFileFromDenseFeatures<(char)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< char > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromDenseFeatures<(char)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< char > *)new shogun::CStreamingFileFromDenseFeatures< char >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromCharFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromCharFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_char_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromCharFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< char > *arg1 = (CDenseFeatures< char > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromDenseFeatures< char > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< char > *","CStreamingFileFromDenseFeatures<(char)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< char > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< char > *)new shogun::CStreamingFileFromDenseFeatures< char >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromCharFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromCharFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_char_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromCharFeatures__SWIG_2(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_char_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromCharFeatures__SWIG_1(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromCharFeatures.new",
" StreamingFileFromCharFeatures.new()\n"
" StreamingFileFromCharFeatures.new(CDenseFeatures< char > *feat, float64_t *lab)\n"
" StreamingFileFromCharFeatures.new(CDenseFeatures< char > *feat)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromDenseFeatures_Sl_char_Sg_(void *self) {
shogun::CStreamingFileFromDenseFeatures< char > *arg1 = (shogun::CStreamingFileFromDenseFeatures< char > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromCharFeatures.get_vector
call-seq:
get_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromCharFeatures_get_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< char > *arg1 = (shogun::CStreamingFileFromDenseFeatures< char > *) 0 ;
char **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< char > *","get_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< char > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_char, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char *&","get_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "char *&","get_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< char ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromCharFeatures.get_vector_and_label
call-seq:
get_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromCharFeatures_get_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< char > *arg1 = (shogun::CStreamingFileFromDenseFeatures< char > *) 0 ;
char **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< char > *","get_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< char > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_char, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "char *&","get_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "char *&","get_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< char ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromCharFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromCharFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< char > *arg1 = (shogun::CStreamingFileFromDenseFeatures< char > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< char > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< char > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromByteFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromByteFeatures class
*/
static swig_class SwigClassStreamingFileFromByteFeatures;
/*
Document-method: Modshogun::StreamingFileFromByteFeatures.new
call-seq:
StreamingFileFromByteFeatures.new
StreamingFileFromByteFeatures.new(feat, lab=nil)
StreamingFileFromByteFeatures.new(feat)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromByteFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< uint8_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< uint8_t > *)new shogun::CStreamingFileFromDenseFeatures< uint8_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromByteFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< unsigned char > *arg1 = (CDenseFeatures< unsigned char > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromDenseFeatures< uint8_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< unsigned char > *","CStreamingFileFromDenseFeatures<(uint8_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< unsigned char > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromDenseFeatures<(uint8_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< uint8_t > *)new shogun::CStreamingFileFromDenseFeatures< uint8_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromByteFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromByteFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_char_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromByteFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< unsigned char > *arg1 = (CDenseFeatures< unsigned char > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromDenseFeatures< uint8_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< unsigned char > *","CStreamingFileFromDenseFeatures<(uint8_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< unsigned char > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< uint8_t > *)new shogun::CStreamingFileFromDenseFeatures< uint8_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromByteFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromByteFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_unsigned_char_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromByteFeatures__SWIG_2(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_unsigned_char_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromByteFeatures__SWIG_1(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromByteFeatures.new",
" StreamingFileFromByteFeatures.new()\n"
" StreamingFileFromByteFeatures.new(CDenseFeatures< unsigned char > *feat, float64_t *lab)\n"
" StreamingFileFromByteFeatures.new(CDenseFeatures< unsigned char > *feat)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromDenseFeatures_Sl_uint8_t_Sg_(void *self) {
shogun::CStreamingFileFromDenseFeatures< uint8_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< uint8_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromByteFeatures.get_vector
call-seq:
get_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromByteFeatures_get_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< uint8_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< uint8_t > *) 0 ;
unsigned char **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< uint8_t > *","get_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< uint8_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_unsigned_char, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "unsigned char *&","get_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "unsigned char *&","get_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< unsigned char ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromByteFeatures.get_vector_and_label
call-seq:
get_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromByteFeatures_get_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< uint8_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< uint8_t > *) 0 ;
unsigned char **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< uint8_t > *","get_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< uint8_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_unsigned_char, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "unsigned char *&","get_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "unsigned char *&","get_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< unsigned char ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromByteFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromByteFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< uint8_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< uint8_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_char_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< uint8_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< uint8_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromWordFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromWordFeatures class
*/
static swig_class SwigClassStreamingFileFromWordFeatures;
/*
Document-method: Modshogun::StreamingFileFromWordFeatures.new
call-seq:
StreamingFileFromWordFeatures.new
StreamingFileFromWordFeatures.new(feat, lab=nil)
StreamingFileFromWordFeatures.new(feat)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromWordFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< uint16_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< uint16_t > *)new shogun::CStreamingFileFromDenseFeatures< uint16_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromWordFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< unsigned short > *arg1 = (CDenseFeatures< unsigned short > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromDenseFeatures< uint16_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< unsigned short > *","CStreamingFileFromDenseFeatures<(uint16_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< unsigned short > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromDenseFeatures<(uint16_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< uint16_t > *)new shogun::CStreamingFileFromDenseFeatures< uint16_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromWordFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromWordFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_short_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromWordFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< unsigned short > *arg1 = (CDenseFeatures< unsigned short > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromDenseFeatures< uint16_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< unsigned short > *","CStreamingFileFromDenseFeatures<(uint16_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< unsigned short > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< uint16_t > *)new shogun::CStreamingFileFromDenseFeatures< uint16_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromWordFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromWordFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_unsigned_short_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromWordFeatures__SWIG_2(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_unsigned_short_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromWordFeatures__SWIG_1(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromWordFeatures.new",
" StreamingFileFromWordFeatures.new()\n"
" StreamingFileFromWordFeatures.new(CDenseFeatures< unsigned short > *feat, float64_t *lab)\n"
" StreamingFileFromWordFeatures.new(CDenseFeatures< unsigned short > *feat)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromDenseFeatures_Sl_uint16_t_Sg_(void *self) {
shogun::CStreamingFileFromDenseFeatures< uint16_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< uint16_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromWordFeatures.get_vector
call-seq:
get_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromWordFeatures_get_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< uint16_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< uint16_t > *) 0 ;
unsigned short **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< uint16_t > *","get_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< uint16_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_unsigned_short, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "unsigned short *&","get_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "unsigned short *&","get_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< unsigned short ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromWordFeatures.get_vector_and_label
call-seq:
get_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromWordFeatures_get_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< uint16_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< uint16_t > *) 0 ;
unsigned short **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< uint16_t > *","get_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< uint16_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_unsigned_short, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "unsigned short *&","get_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "unsigned short *&","get_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< unsigned short ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromWordFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromWordFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< uint16_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< uint16_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_unsigned_short_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< uint16_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< uint16_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromIntFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromIntFeatures class
*/
static swig_class SwigClassStreamingFileFromIntFeatures;
/*
Document-method: Modshogun::StreamingFileFromIntFeatures.new
call-seq:
StreamingFileFromIntFeatures.new
StreamingFileFromIntFeatures.new(feat, lab=nil)
StreamingFileFromIntFeatures.new(feat)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromIntFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< int32_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< int32_t > *)new shogun::CStreamingFileFromDenseFeatures< int32_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromIntFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< int > *arg1 = (CDenseFeatures< int > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromDenseFeatures< int32_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< int > *","CStreamingFileFromDenseFeatures<(int32_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< int > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromDenseFeatures<(int32_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< int32_t > *)new shogun::CStreamingFileFromDenseFeatures< int32_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromIntFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromIntFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_int_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromIntFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< int > *arg1 = (CDenseFeatures< int > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromDenseFeatures< int32_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< int > *","CStreamingFileFromDenseFeatures<(int32_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< int > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< int32_t > *)new shogun::CStreamingFileFromDenseFeatures< int32_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromIntFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromIntFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_int_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromIntFeatures__SWIG_2(nargs, args, self);
}
}
if (argc == 2) {
int _v;
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_CDenseFeaturesT_int_t, 0);
_v = SWIG_CheckState(res);
if (_v) {
void *vptr = 0;
int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_double, 0);
_v = SWIG_CheckState(res);
if (_v) {
return _wrap_new_StreamingFileFromIntFeatures__SWIG_1(nargs, args, self);
}
}
}
fail:
Ruby_Format_OverloadedError( argc, 2, "StreamingFileFromIntFeatures.new",
" StreamingFileFromIntFeatures.new()\n"
" StreamingFileFromIntFeatures.new(CDenseFeatures< int > *feat, float64_t *lab)\n"
" StreamingFileFromIntFeatures.new(CDenseFeatures< int > *feat)\n");
return Qnil;
}
SWIGINTERN void
free_shogun_CStreamingFileFromDenseFeatures_Sl_int32_t_Sg_(void *self) {
shogun::CStreamingFileFromDenseFeatures< int32_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< int32_t > *)self;
SG_UNREF(arg1);
}
/*
Document-method: Modshogun::StreamingFileFromIntFeatures.get_vector
call-seq:
get_vector(vec, len)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromIntFeatures_get_vector(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< int32_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< int32_t > *) 0 ;
int **arg2 = 0 ;
int32_t *arg3 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< int32_t > *","get_vector", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< int32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_int, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "int *&","get_vector", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int *&","get_vector", 2, argv[0]));
}
arg2 = reinterpret_cast< int ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
{
try
{
(arg1)->get_vector(*arg2,*arg3);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromIntFeatures.get_vector_and_label
call-seq:
get_vector_and_label(vec, len, label)
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromIntFeatures_get_vector_and_label(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< int32_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< int32_t > *) 0 ;
int **arg2 = 0 ;
int32_t *arg3 = 0 ;
float64_t *arg4 = 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
void *argp3 = 0 ;
int res3 = 0 ;
void *argp4 = 0 ;
int res4 = 0 ;
if ((argc < 3) || (argc > 3)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 3)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< int32_t > *","get_vector_and_label", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< int32_t > * >(argp1);
res2 = SWIG_ConvertPtr(argv[0], &argp2, SWIGTYPE_p_p_int, 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "int *&","get_vector_and_label", 2, argv[0] ));
}
if (!argp2) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int *&","get_vector_and_label", 2, argv[0]));
}
arg2 = reinterpret_cast< int ** >(argp2);
res3 = SWIG_ConvertPtr(argv[1], &argp3, SWIGTYPE_p_int, 0 );
if (!SWIG_IsOK(res3)) {
SWIG_exception_fail(SWIG_ArgError(res3), Ruby_Format_TypeError( "", "int32_t &","get_vector_and_label", 3, argv[1] ));
}
if (!argp3) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "int32_t &","get_vector_and_label", 3, argv[1]));
}
arg3 = reinterpret_cast< int32_t * >(argp3);
res4 = SWIG_ConvertPtr(argv[2], &argp4, SWIGTYPE_p_double, 0 );
if (!SWIG_IsOK(res4)) {
SWIG_exception_fail(SWIG_ArgError(res4), Ruby_Format_TypeError( "", "float64_t &","get_vector_and_label", 4, argv[2] ));
}
if (!argp4) {
SWIG_exception_fail(SWIG_ValueError, Ruby_Format_TypeError("invalid null reference ", "float64_t &","get_vector_and_label", 4, argv[2]));
}
arg4 = reinterpret_cast< float64_t * >(argp4);
{
try
{
(arg1)->get_vector_and_label(*arg2,*arg3,*arg4);
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-method: Modshogun::StreamingFileFromIntFeatures.reset_stream
call-seq:
reset_stream
An instance method.
*/
SWIGINTERN VALUE
_wrap_StreamingFileFromIntFeatures_reset_stream(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< int32_t > *arg1 = (shogun::CStreamingFileFromDenseFeatures< int32_t > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(self, &argp1,SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_int_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "shogun::CStreamingFileFromDenseFeatures< int32_t > *","reset_stream", 1, self ));
}
arg1 = reinterpret_cast< shogun::CStreamingFileFromDenseFeatures< int32_t > * >(argp1);
{
try
{
(arg1)->reset_stream();
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
return Qnil;
fail:
return Qnil;
}
/*
Document-class: Modshogun::StreamingFileFromLongFeatures < Modshogun::shogun::StreamingFileFromFeatures
Proxy of C++ Modshogun::StreamingFileFromLongFeatures class
*/
static swig_class SwigClassStreamingFileFromLongFeatures;
/*
Document-method: Modshogun::StreamingFileFromLongFeatures.new
call-seq:
StreamingFileFromLongFeatures.new
StreamingFileFromLongFeatures.new(feat, lab=nil)
StreamingFileFromLongFeatures.new(feat)
Class constructor.
*/
SWIGINTERN VALUE
_wrap_new_StreamingFileFromLongFeatures__SWIG_0(int argc, VALUE *argv, VALUE self) {
shogun::CStreamingFileFromDenseFeatures< int64_t > *result = 0 ;
if ((argc < 0) || (argc > 0)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 0)",argc); SWIG_fail;
}
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< int64_t > *)new shogun::CStreamingFileFromDenseFeatures< int64_t >();
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromLongFeatures__SWIG_1(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< long > *arg1 = (CDenseFeatures< long > *) 0 ;
float64_t *arg2 = (float64_t *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
void *argp2 = 0 ;
int res2 = 0 ;
shogun::CStreamingFileFromDenseFeatures< int64_t > *result = 0 ;
if ((argc < 2) || (argc > 2)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 2)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< long > *","CStreamingFileFromDenseFeatures<(int64_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< long > * >(argp1);
res2 = SWIG_ConvertPtr(argv[1], &argp2,SWIGTYPE_p_double, 0 | 0 );
if (!SWIG_IsOK(res2)) {
SWIG_exception_fail(SWIG_ArgError(res2), Ruby_Format_TypeError( "", "float64_t *","CStreamingFileFromDenseFeatures<(int64_t)>", 2, argv[1] ));
}
arg2 = reinterpret_cast< float64_t * >(argp2);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< int64_t > *)new shogun::CStreamingFileFromDenseFeatures< int64_t >(arg1,arg2);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE
#ifdef HAVE_RB_DEFINE_ALLOC_FUNC
_wrap_StreamingFileFromLongFeatures_allocate(VALUE self)
#else
_wrap_StreamingFileFromLongFeatures_allocate(int argc, VALUE *argv, VALUE self)
#endif
{
VALUE vresult = SWIG_NewClassInstance(self, SWIGTYPE_p_shogun__CStreamingFileFromDenseFeaturesT_long_t);
#ifndef HAVE_RB_DEFINE_ALLOC_FUNC
rb_obj_call_init(vresult, argc, argv);
#endif
return vresult;
}
SWIGINTERN VALUE
_wrap_new_StreamingFileFromLongFeatures__SWIG_2(int argc, VALUE *argv, VALUE self) {
CDenseFeatures< long > *arg1 = (CDenseFeatures< long > *) 0 ;
void *argp1 = 0 ;
int res1 = 0 ;
shogun::CStreamingFileFromDenseFeatures< int64_t > *result = 0 ;
if ((argc < 1) || (argc > 1)) {
rb_raise(rb_eArgError, "wrong # of arguments(%d for 1)",argc); SWIG_fail;
}
res1 = SWIG_ConvertPtr(argv[0], &argp1,SWIGTYPE_p_CDenseFeaturesT_long_t, 0 | 0 );
if (!SWIG_IsOK(res1)) {
SWIG_exception_fail(SWIG_ArgError(res1), Ruby_Format_TypeError( "", "CDenseFeatures< long > *","CStreamingFileFromDenseFeatures<(int64_t)>", 1, argv[0] ));
}
arg1 = reinterpret_cast< CDenseFeatures< long > * >(argp1);
{
try
{
result = (shogun::CStreamingFileFromDenseFeatures< int64_t > *)new shogun::CStreamingFileFromDenseFeatures< int64_t >(arg1);
DATA_PTR(self) = result;
}
catch (std::bad_alloc)
{
SWIG_exception(SWIG_MemoryError, const_cast<char*>("Out of memory error.\n"));
SWIG_fail;
}
catch (shogun::ShogunException e)
{
SWIG_exception(SWIG_SystemError, const_cast<char*>(e.get_exception_string()));
SWIG_fail;
}
}
SG_REF(result);
return self;
fail:
return Qnil;
}
SWIGINTERN VALUE _wrap_new_StreamingFileFromLongFeatures(int nargs, VALUE *args, VALUE self) {
int argc;
VALUE argv[2];
int ii;
argc = nargs;
if (argc > 2) SWIG_fail;
for (ii = 0; (ii < argc); ++ii) {
argv[ii] = args[ii];
}
if (argc == 0) {
return _wrap_new_StreamingFileFromLongFeatures__SWIG_0(nargs, args, self);
}
if (argc == 1) {
int _v;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment