/* ----------------------------------------------------------------------------
 * This file was automatically generated by SWIG (https://www.swig.org).
 * Version 4.1.1
 *
 * Do not make changes to this file unless you know what you are doing - modify
 * the SWIG interface file instead.
 * ----------------------------------------------------------------------------- */


#define SWIG_VERSION 0x040101
#define SWIGPYTHON
#define SWIG_PYTHON_DIRECTOR_NO_VTABLE

/* -----------------------------------------------------------------------------
 *  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


#if defined(__GNUC__) && defined(_WIN32) && !defined(SWIG_PYTHON_NO_HYPOT_WORKAROUND)
/* Workaround for '::hypot' has not been declared', see https://bugs.python.org/issue11566 */
# include <math.h>
#endif

#if !defined(PY_SSIZE_T_CLEAN) && !defined(SWIG_NO_PY_SSIZE_T_CLEAN)
#define PY_SSIZE_T_CLEAN
#endif

#if __GNUC__ >= 7
#pragma GCC diagnostic push
#if defined(__cplusplus) && __cplusplus >=201703L
#pragma GCC diagnostic ignored "-Wregister" /* For python-2.7 headers that use register */
#endif
#endif

#if defined(_DEBUG) && defined(SWIG_PYTHON_INTERPRETER_NO_DEBUG)
/* Use debug wrappers with the Python release dll */

#if defined(_MSC_VER) && _MSC_VER >= 1929
/* Workaround compilation errors when redefining _DEBUG in MSVC 2019 version 16.10 and later
 * See https://github.com/swig/swig/issues/2090 */
# include <corecrt.h>
#endif

# undef _DEBUG
# include <Python.h>
# define _DEBUG 1
#else
# include <Python.h>
#endif

#if __GNUC__ >= 7
#pragma GCC diagnostic pop
#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
#define SWIG_POINTER_NO_NULL       0x4
#define SWIG_POINTER_CLEAR         0x8
#define SWIG_POINTER_RELEASE       (SWIG_POINTER_CLEAR | SWIG_POINTER_DISOWN)

/* 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 returning 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)
/* Runtime errors are < 0 */
#define SWIG_ERROR                 (-1)
/* Errors in range -1 to -99 are in swigerrors.swg (errors for all languages including those not using the runtime) */
/* Errors in range -100 to -199 are language specific errors defined in *errors.swg */
/* Errors < -200 are generic runtime specific errors */
#define SWIG_ERROR_RELEASE_NOT_OWNED (-200)

#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 object 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(const 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.  Choose the last
     name. It should be the most specific; a fully resolved name
     but not necessarily with default template parameters expanded. */
  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

/* SWIG Errors applicable to all language modules, values are reserved from -1 to -99 */
#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


/* Compatibility macros for Python 3 */
#if PY_VERSION_HEX >= 0x03000000

#define PyClass_Check(obj) PyObject_IsInstance(obj, (PyObject *)&PyType_Type)
#define PyInt_Check(x) PyLong_Check(x)
#define PyInt_AsLong(x) PyLong_AsLong(x)
#define PyInt_FromLong(x) PyLong_FromLong(x)
#define PyInt_FromSize_t(x) PyLong_FromSize_t(x)
#define PyString_Check(name) PyBytes_Check(name)
#define PyString_FromString(x) PyUnicode_FromString(x)
#define PyString_Format(fmt, args)  PyUnicode_Format(fmt, args)
#define PyString_AsString(str) PyBytes_AsString(str)
#define PyString_Size(str) PyBytes_Size(str)	
#define PyString_InternFromString(key) PyUnicode_InternFromString(key)
#define Py_TPFLAGS_HAVE_CLASS Py_TPFLAGS_BASETYPE
#define _PyLong_FromSsize_t(x) PyLong_FromSsize_t(x)

#endif

#ifndef Py_TYPE
#  define Py_TYPE(op) ((op)->ob_type)
#endif

/* SWIG APIs for compatibility of both Python 2 & 3 */

#if PY_VERSION_HEX >= 0x03000000
#  define SWIG_Python_str_FromFormat PyUnicode_FromFormat
#else
#  define SWIG_Python_str_FromFormat PyString_FromFormat
#endif


SWIGINTERN char*
SWIG_Python_str_AsChar(PyObject *str)
{
#if PY_VERSION_HEX >= 0x03030000
  return (char *)PyUnicode_AsUTF8(str);
#else
  return PyString_AsString(str);
#endif
}

/* Was useful for Python 3.0.x-3.2.x - now provided only for compatibility
 * with any uses in user interface files. */
#define SWIG_Python_str_DelForPy3(x)


SWIGINTERN PyObject*
SWIG_Python_str_FromChar(const char *c)
{
#if PY_VERSION_HEX >= 0x03000000
  return PyUnicode_FromString(c); 
#else
  return PyString_FromString(c);
#endif
}

#ifndef PyObject_DEL
# define PyObject_DEL PyObject_Del
#endif

/* SWIGPY_USE_CAPSULE is no longer used within SWIG itself, but some user interface files check for it. */
# define SWIGPY_USE_CAPSULE
#ifdef SWIGPYTHON_BUILTIN
# define SWIGPY_CAPSULE_ATTR_NAME "type_pointer_capsule_builtin" SWIG_TYPE_TABLE_NAME
#else
# define SWIGPY_CAPSULE_ATTR_NAME "type_pointer_capsule" SWIG_TYPE_TABLE_NAME
#endif
# define SWIGPY_CAPSULE_NAME ("swig_runtime_data" SWIG_RUNTIME_VERSION "." SWIGPY_CAPSULE_ATTR_NAME)

#if PY_VERSION_HEX < 0x03020000
#define PyDescr_TYPE(x) (((PyDescrObject *)(x))->d_type)
#define PyDescr_NAME(x) (((PyDescrObject *)(x))->d_name)
#define Py_hash_t long
#endif

/* -----------------------------------------------------------------------------
 * error manipulation
 * ----------------------------------------------------------------------------- */

SWIGRUNTIME PyObject*
SWIG_Python_ErrorType(int code) {
  PyObject* type = 0;
  switch(code) {
  case SWIG_MemoryError:
    type = PyExc_MemoryError;
    break;
  case SWIG_IOError:
    type = PyExc_IOError;
    break;
  case SWIG_RuntimeError:
    type = PyExc_RuntimeError;
    break;
  case SWIG_IndexError:
    type = PyExc_IndexError;
    break;
  case SWIG_TypeError:
    type = PyExc_TypeError;
    break;
  case SWIG_DivisionByZero:
    type = PyExc_ZeroDivisionError;
    break;
  case SWIG_OverflowError:
    type = PyExc_OverflowError;
    break;
  case SWIG_SyntaxError:
    type = PyExc_SyntaxError;
    break;
  case SWIG_ValueError:
    type = PyExc_ValueError;
    break;
  case SWIG_SystemError:
    type = PyExc_SystemError;
    break;
  case SWIG_AttributeError:
    type = PyExc_AttributeError;
    break;
  default:
    type = PyExc_RuntimeError;
  }
  return type;
}


SWIGRUNTIME void
SWIG_Python_AddErrorMsg(const char* mesg)
{
  PyObject *type = 0;
  PyObject *value = 0;
  PyObject *traceback = 0;

  if (PyErr_Occurred())
    PyErr_Fetch(&type, &value, &traceback);
  if (value) {
    PyObject *old_str = PyObject_Str(value);
    const char *tmp = SWIG_Python_str_AsChar(old_str);
    PyErr_Clear();
    Py_XINCREF(type);
    if (tmp)
      PyErr_Format(type, "%s %s", tmp, mesg);
    else
      PyErr_Format(type, "%s", mesg);
    Py_DECREF(old_str);
    Py_DECREF(value);
  } else {
    PyErr_SetString(PyExc_RuntimeError, mesg);
  }
}

SWIGRUNTIME int
SWIG_Python_TypeErrorOccurred(PyObject *obj)
{
  PyObject *error;
  if (obj)
    return 0;
  error = PyErr_Occurred();
  return error && PyErr_GivenExceptionMatches(error, PyExc_TypeError);
}

SWIGRUNTIME void
SWIG_Python_RaiseOrModifyTypeError(const char *message)
{
  if (SWIG_Python_TypeErrorOccurred(NULL)) {
    /* Use existing TypeError to preserve stacktrace and enhance with given message */
    PyObject *newvalue;
    PyObject *type = NULL, *value = NULL, *traceback = NULL;
    PyErr_Fetch(&type, &value, &traceback);
#if PY_VERSION_HEX >= 0x03000000
    newvalue = PyUnicode_FromFormat("%S\nAdditional information:\n%s", value, message);
#else
    newvalue = PyString_FromFormat("%s\nAdditional information:\n%s", PyString_AsString(value), message);
#endif
    if (newvalue) {
      Py_XDECREF(value);
      PyErr_Restore(type, newvalue, traceback);
    } else {
      PyErr_Restore(type, value, traceback);
    }
  } else {
    /* Raise TypeError using given message */
    PyErr_SetString(PyExc_TypeError, message);
  }
}

#if defined(SWIG_PYTHON_NO_THREADS)
#  if defined(SWIG_PYTHON_THREADS)
#    undef SWIG_PYTHON_THREADS
#  endif
#endif
#if defined(SWIG_PYTHON_THREADS) /* Threading support is enabled */
#  if !defined(SWIG_PYTHON_USE_GIL) && !defined(SWIG_PYTHON_NO_USE_GIL)
#    define SWIG_PYTHON_USE_GIL
#  endif
#  if defined(SWIG_PYTHON_USE_GIL) /* Use PyGILState threads calls */
#    if !defined(SWIG_PYTHON_INITIALIZE_THREADS)
#      if PY_VERSION_HEX < 0x03070000
#        define SWIG_PYTHON_INITIALIZE_THREADS PyEval_InitThreads()
#      else
#        define SWIG_PYTHON_INITIALIZE_THREADS
#      endif
#    endif
#    ifdef __cplusplus /* C++ code */
       class SWIG_Python_Thread_Block {
         bool status;
         PyGILState_STATE state;
       public:
         void end() { if (status) { PyGILState_Release(state); status = false;} }
         SWIG_Python_Thread_Block() : status(true), state(PyGILState_Ensure()) {}
         ~SWIG_Python_Thread_Block() { end(); }
       };
       class SWIG_Python_Thread_Allow {
         bool status;
         PyThreadState *save;
       public:
         void end() { if (status) { PyEval_RestoreThread(save); status = false; }}
         SWIG_Python_Thread_Allow() : status(true), save(PyEval_SaveThread()) {}
         ~SWIG_Python_Thread_Allow() { end(); }
       };
#      define SWIG_PYTHON_THREAD_BEGIN_BLOCK   SWIG_Python_Thread_Block _swig_thread_block
#      define SWIG_PYTHON_THREAD_END_BLOCK     _swig_thread_block.end()
#      define SWIG_PYTHON_THREAD_BEGIN_ALLOW   SWIG_Python_Thread_Allow _swig_thread_allow
#      define SWIG_PYTHON_THREAD_END_ALLOW     _swig_thread_allow.end()
#    else /* C code */
#      define SWIG_PYTHON_THREAD_BEGIN_BLOCK   PyGILState_STATE _swig_thread_block = PyGILState_Ensure()
#      define SWIG_PYTHON_THREAD_END_BLOCK     PyGILState_Release(_swig_thread_block)
#      define SWIG_PYTHON_THREAD_BEGIN_ALLOW   PyThreadState *_swig_thread_allow = PyEval_SaveThread()
#      define SWIG_PYTHON_THREAD_END_ALLOW     PyEval_RestoreThread(_swig_thread_allow)
#    endif
#  else /* Old thread way, not implemented, user must provide it */
#    if !defined(SWIG_PYTHON_INITIALIZE_THREADS)
#      define SWIG_PYTHON_INITIALIZE_THREADS
#    endif
#    if !defined(SWIG_PYTHON_THREAD_BEGIN_BLOCK)
#      define SWIG_PYTHON_THREAD_BEGIN_BLOCK
#    endif
#    if !defined(SWIG_PYTHON_THREAD_END_BLOCK)
#      define SWIG_PYTHON_THREAD_END_BLOCK
#    endif
#    if !defined(SWIG_PYTHON_THREAD_BEGIN_ALLOW)
#      define SWIG_PYTHON_THREAD_BEGIN_ALLOW
#    endif
#    if !defined(SWIG_PYTHON_THREAD_END_ALLOW)
#      define SWIG_PYTHON_THREAD_END_ALLOW
#    endif
#  endif
#else /* No thread support */
#  define SWIG_PYTHON_INITIALIZE_THREADS
#  define SWIG_PYTHON_THREAD_BEGIN_BLOCK
#  define SWIG_PYTHON_THREAD_END_BLOCK
#  define SWIG_PYTHON_THREAD_BEGIN_ALLOW
#  define SWIG_PYTHON_THREAD_END_ALLOW
#endif

/* -----------------------------------------------------------------------------
 * Python API portion that goes into the runtime
 * ----------------------------------------------------------------------------- */

#ifdef __cplusplus
extern "C" {
#endif

/* -----------------------------------------------------------------------------
 * Constant declarations
 * ----------------------------------------------------------------------------- */

/* Constant Types */
#define SWIG_PY_POINTER 4
#define SWIG_PY_BINARY  5

/* Constant information structure */
typedef struct swig_const_info {
  int type;
  const char *name;
  long lvalue;
  double dvalue;
  void   *pvalue;
  swig_type_info **ptype;
} swig_const_info;

#ifdef __cplusplus
}
#endif


/* -----------------------------------------------------------------------------
 * pyrun.swg
 *
 * This file contains the runtime support for Python modules
 * and includes code for managing global variables and pointer
 * type checking.
 *
 * ----------------------------------------------------------------------------- */

#if PY_VERSION_HEX < 0x02070000 /* 2.7.0 */
# error "This version of SWIG only supports Python >= 2.7"
#endif

#if PY_VERSION_HEX >= 0x03000000 && PY_VERSION_HEX < 0x03030000
# error "This version of SWIG only supports Python 3 >= 3.3"
#endif

/* Common SWIG API */

/* for raw pointers */
#define SWIG_Python_ConvertPtr(obj, pptr, type, flags)  SWIG_Python_ConvertPtrAndOwn(obj, pptr, type, flags, 0)
#define SWIG_ConvertPtr(obj, pptr, type, flags)         SWIG_Python_ConvertPtr(obj, pptr, type, flags)
#define SWIG_ConvertPtrAndOwn(obj,pptr,type,flags,own)  SWIG_Python_ConvertPtrAndOwn(obj, pptr, type, flags, own)

#ifdef SWIGPYTHON_BUILTIN
#define SWIG_NewPointerObj(ptr, type, flags)            SWIG_Python_NewPointerObj(self, ptr, type, flags)
#else
#define SWIG_NewPointerObj(ptr, type, flags)            SWIG_Python_NewPointerObj(NULL, ptr, type, flags)
#endif

#define SWIG_InternalNewPointerObj(ptr, type, flags)	SWIG_Python_NewPointerObj(NULL, ptr, type, flags)

#define SWIG_CheckImplicit(ty)                          SWIG_Python_CheckImplicit(ty) 
#define SWIG_AcquirePtr(ptr, src)                       SWIG_Python_AcquirePtr(ptr, src)
#define swig_owntype                                    int

/* for raw packed data */
#define SWIG_ConvertPacked(obj, ptr, sz, ty)            SWIG_Python_ConvertPacked(obj, ptr, sz, ty)
#define SWIG_NewPackedObj(ptr, sz, type)                SWIG_Python_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_Python_ConvertFunctionPtr(obj, pptr, type)
#define SWIG_NewFunctionPtrObj(ptr, type)               SWIG_Python_NewPointerObj(NULL, ptr, type, 0)

/* for C++ member pointers, ie, member methods */
#define SWIG_ConvertMember(obj, ptr, sz, ty)            SWIG_Python_ConvertPacked(obj, ptr, sz, ty)
#define SWIG_NewMemberObj(ptr, sz, type)                SWIG_Python_NewPackedObj(ptr, sz, type)


/* Runtime API */

#define SWIG_GetModule(clientdata)                      SWIG_Python_GetModule(clientdata)
#define SWIG_SetModule(clientdata, pointer)             SWIG_Python_SetModule(pointer)
#define SWIG_NewClientData(obj)                         SwigPyClientData_New(obj)

#define SWIG_SetErrorObj                                SWIG_Python_SetErrorObj                            
#define SWIG_SetErrorMsg                        	SWIG_Python_SetErrorMsg				   
#define SWIG_ErrorType(code)                    	SWIG_Python_ErrorType(code)                        
#define SWIG_Error(code, msg)            		SWIG_Python_SetErrorMsg(SWIG_ErrorType(code), msg) 
#define SWIG_fail                        		goto fail					   


/* Runtime API implementation */

/* Error manipulation */

SWIGINTERN void 
SWIG_Python_SetErrorObj(PyObject *errtype, PyObject *obj) {
  SWIG_PYTHON_THREAD_BEGIN_BLOCK; 
  PyErr_SetObject(errtype, obj);
  Py_DECREF(obj);
  SWIG_PYTHON_THREAD_END_BLOCK;
}

SWIGINTERN void 
SWIG_Python_SetErrorMsg(PyObject *errtype, const char *msg) {
  SWIG_PYTHON_THREAD_BEGIN_BLOCK;
  PyErr_SetString(errtype, msg);
  SWIG_PYTHON_THREAD_END_BLOCK;
}

#define SWIG_Python_Raise(obj, type, desc)  SWIG_Python_SetErrorObj(SWIG_Python_ExceptionType(desc), obj)

/* Set a constant value */

#if defined(SWIGPYTHON_BUILTIN)

SWIGINTERN void
SwigPyBuiltin_AddPublicSymbol(PyObject *seq, const char *key) {
  PyObject *s = PyString_InternFromString(key);
  PyList_Append(seq, s);
  Py_DECREF(s);
}

SWIGINTERN void
SWIG_Python_SetConstant(PyObject *d, PyObject *public_interface, const char *name, PyObject *obj) {   
  PyDict_SetItemString(d, name, obj);
  Py_DECREF(obj);
  if (public_interface)
    SwigPyBuiltin_AddPublicSymbol(public_interface, name);
}

#else

SWIGINTERN void
SWIG_Python_SetConstant(PyObject *d, const char *name, PyObject *obj) {   
  PyDict_SetItemString(d, name, obj);
  Py_DECREF(obj);                            
}

#endif

/* Append a value to the result obj */

SWIGINTERN PyObject*
SWIG_Python_AppendOutput(PyObject* result, PyObject* obj) {
  if (!result) {
    result = obj;
  } else if (result == Py_None) {
    Py_DECREF(result);
    result = obj;
  } else {
    if (!PyList_Check(result)) {
      PyObject *o2 = result;
      result = PyList_New(1);
      if (result) {
        PyList_SET_ITEM(result, 0, o2);
      } else {
        Py_DECREF(obj);
        return o2;
      }
    }
    PyList_Append(result,obj);
    Py_DECREF(obj);
  }
  return result;
}

/* Unpack the argument tuple */

SWIGINTERN Py_ssize_t
SWIG_Python_UnpackTuple(PyObject *args, const char *name, Py_ssize_t min, Py_ssize_t max, PyObject **objs)
{
  if (!args) {
    if (!min && !max) {
      return 1;
    } else {
      PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got none", 
		   name, (min == max ? "" : "at least "), (int)min);
      return 0;
    }
  }  
  if (!PyTuple_Check(args)) {
    if (min <= 1 && max >= 1) {
      Py_ssize_t i;
      objs[0] = args;
      for (i = 1; i < max; ++i) {
	objs[i] = 0;
      }
      return 2;
    }
    PyErr_SetString(PyExc_SystemError, "UnpackTuple() argument list is not a tuple");
    return 0;
  } else {
    Py_ssize_t l = PyTuple_GET_SIZE(args);
    if (l < min) {
      PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d", 
		   name, (min == max ? "" : "at least "), (int)min, (int)l);
      return 0;
    } else if (l > max) {
      PyErr_Format(PyExc_TypeError, "%s expected %s%d arguments, got %d", 
		   name, (min == max ? "" : "at most "), (int)max, (int)l);
      return 0;
    } else {
      Py_ssize_t i;
      for (i = 0; i < l; ++i) {
	objs[i] = PyTuple_GET_ITEM(args, i);
      }
      for (; l < max; ++l) {
	objs[l] = 0;
      }
      return i + 1;
    }    
  }
}

SWIGINTERN int
SWIG_Python_CheckNoKeywords(PyObject *kwargs, const char *name) {
  int no_kwargs = 1;
  if (kwargs) {
    assert(PyDict_Check(kwargs));
    if (PyDict_Size(kwargs) > 0) {
      PyErr_Format(PyExc_TypeError, "%s() does not take keyword arguments", name);
      no_kwargs = 0;
    }
  }
  return no_kwargs;
}

/* A functor is a function object with one single object argument */
#define SWIG_Python_CallFunctor(functor, obj)	        PyObject_CallFunctionObjArgs(functor, obj, NULL);

/*
  Helper for static pointer initialization for both C and C++ code, for example
  static PyObject *SWIG_STATIC_POINTER(MyVar) = NewSomething(...);
*/
#ifdef __cplusplus
#define SWIG_STATIC_POINTER(var)  var
#else
#define SWIG_STATIC_POINTER(var)  var = 0; if (!var) var
#endif

#ifdef __cplusplus
extern "C" {
#endif

/* Python-specific SWIG API */
#define SWIG_newvarlink()                             SWIG_Python_newvarlink()
#define SWIG_addvarlink(p, name, get_attr, set_attr)  SWIG_Python_addvarlink(p, name, get_attr, set_attr)
#define SWIG_InstallConstants(d, constants)           SWIG_Python_InstallConstants(d, constants)
 
/* -----------------------------------------------------------------------------
 * global variable support code.
 * ----------------------------------------------------------------------------- */
 
typedef struct swig_globalvar {   
  char       *name;                  /* Name of global variable */
  PyObject *(*get_attr)(void);       /* Return the current value */
  int       (*set_attr)(PyObject *); /* Set the value */
  struct swig_globalvar *next;
} swig_globalvar;

typedef struct swig_varlinkobject {
  PyObject_HEAD
  swig_globalvar *vars;
} swig_varlinkobject;

SWIGINTERN PyObject *
swig_varlink_repr(PyObject *SWIGUNUSEDPARM(v)) {
#if PY_VERSION_HEX >= 0x03000000
  return PyUnicode_InternFromString("<Swig global variables>");
#else
  return PyString_FromString("<Swig global variables>");
#endif
}

SWIGINTERN PyObject *
swig_varlink_str(PyObject *o) {
  swig_varlinkobject *v = (swig_varlinkobject *) o;
#if PY_VERSION_HEX >= 0x03000000
  PyObject *str = PyUnicode_InternFromString("(");
  PyObject *tail;
  PyObject *joined;
  swig_globalvar *var;
  for (var = v->vars; var; var=var->next) {
    tail = PyUnicode_FromString(var->name);
    joined = PyUnicode_Concat(str, tail);
    Py_DecRef(str);
    Py_DecRef(tail);
    str = joined;
    if (var->next) {
        tail = PyUnicode_InternFromString(", ");
        joined = PyUnicode_Concat(str, tail);
        Py_DecRef(str);
        Py_DecRef(tail);
        str = joined;
    }
  }
  tail = PyUnicode_InternFromString(")");
  joined = PyUnicode_Concat(str, tail);
  Py_DecRef(str);
  Py_DecRef(tail);
  str = joined;
#else
  PyObject *str = PyString_FromString("(");
  swig_globalvar *var;
  for (var = v->vars; var; var=var->next) {
    PyString_ConcatAndDel(&str,PyString_FromString(var->name));
    if (var->next) PyString_ConcatAndDel(&str,PyString_FromString(", "));
  }
  PyString_ConcatAndDel(&str,PyString_FromString(")"));
#endif
  return str;
}

SWIGINTERN void
swig_varlink_dealloc(PyObject *o) {
  swig_varlinkobject *v = (swig_varlinkobject *) o;
  swig_globalvar *var = v->vars;
  while (var) {
    swig_globalvar *n = var->next;
    free(var->name);
    free(var);
    var = n;
  }
}

SWIGINTERN PyObject *
swig_varlink_getattr(PyObject *o, char *n) {
  swig_varlinkobject *v = (swig_varlinkobject *) o;
  PyObject *res = NULL;
  swig_globalvar *var = v->vars;
  while (var) {
    if (strcmp(var->name,n) == 0) {
      res = (*var->get_attr)();
      break;
    }
    var = var->next;
  }
  if (res == NULL && !PyErr_Occurred()) {
    PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
  }
  return res;
}

SWIGINTERN int
swig_varlink_setattr(PyObject *o, char *n, PyObject *p) {
  swig_varlinkobject *v = (swig_varlinkobject *) o;
  int res = 1;
  swig_globalvar *var = v->vars;
  while (var) {
    if (strcmp(var->name,n) == 0) {
      res = (*var->set_attr)(p);
      break;
    }
    var = var->next;
  }
  if (res == 1 && !PyErr_Occurred()) {
    PyErr_Format(PyExc_AttributeError, "Unknown C global variable '%s'", n);
  }
  return res;
}

SWIGINTERN PyTypeObject*
swig_varlink_type(void) {
  static char varlink__doc__[] = "Swig var link object";
  static PyTypeObject varlink_type;
  static int type_init = 0;
  if (!type_init) {
    const PyTypeObject tmp = {
#if PY_VERSION_HEX >= 0x03000000
      PyVarObject_HEAD_INIT(NULL, 0)
#else
      PyObject_HEAD_INIT(NULL)
      0,                                  /* ob_size */
#endif
      "swigvarlink",                      /* tp_name */
      sizeof(swig_varlinkobject),         /* tp_basicsize */
      0,                                  /* tp_itemsize */
      (destructor) swig_varlink_dealloc,  /* tp_dealloc */
#if PY_VERSION_HEX < 0x030800b4
      (printfunc)0,                       /*tp_print*/
#else
      (Py_ssize_t)0,                      /*tp_vectorcall_offset*/
#endif
      (getattrfunc) swig_varlink_getattr, /* tp_getattr */
      (setattrfunc) swig_varlink_setattr, /* tp_setattr */
      0,                                  /* tp_compare */
      (reprfunc) swig_varlink_repr,       /* tp_repr */
      0,                                  /* tp_as_number */
      0,                                  /* tp_as_sequence */
      0,                                  /* tp_as_mapping */
      0,                                  /* tp_hash */
      0,                                  /* tp_call */
      (reprfunc) swig_varlink_str,        /* tp_str */
      0,                                  /* tp_getattro */
      0,                                  /* tp_setattro */
      0,                                  /* tp_as_buffer */
      0,                                  /* tp_flags */
      varlink__doc__,                     /* tp_doc */
      0,                                  /* tp_traverse */
      0,                                  /* tp_clear */
      0,                                  /* tp_richcompare */
      0,                                  /* tp_weaklistoffset */
      0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* tp_iter -> tp_weaklist */
      0,                                  /* tp_del */
      0,                                  /* tp_version_tag */
#if PY_VERSION_HEX >= 0x03040000
      0,                                  /* tp_finalize */
#endif
#if PY_VERSION_HEX >= 0x03080000
      0,                                  /* tp_vectorcall */
#endif
#if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000)
      0,                                  /* tp_print */
#endif
#ifdef COUNT_ALLOCS
      0,                                  /* tp_allocs */
      0,                                  /* tp_frees */
      0,                                  /* tp_maxalloc */
      0,                                  /* tp_prev */
      0                                   /* tp_next */
#endif
    };
    varlink_type = tmp;
    type_init = 1;
    if (PyType_Ready(&varlink_type) < 0)
      return NULL;
  }
  return &varlink_type;
}

/* Create a variable linking object for use later */
SWIGINTERN PyObject *
SWIG_Python_newvarlink(void) {
  swig_varlinkobject *result = PyObject_NEW(swig_varlinkobject, swig_varlink_type());
  if (result) {
    result->vars = 0;
  }
  return ((PyObject*) result);
}

SWIGINTERN void 
SWIG_Python_addvarlink(PyObject *p, const char *name, PyObject *(*get_attr)(void), int (*set_attr)(PyObject *p)) {
  swig_varlinkobject *v = (swig_varlinkobject *) p;
  swig_globalvar *gv = (swig_globalvar *) malloc(sizeof(swig_globalvar));
  if (gv) {
    size_t size = strlen(name)+1;
    gv->name = (char *)malloc(size);
    if (gv->name) {
      memcpy(gv->name, name, size);
      gv->get_attr = get_attr;
      gv->set_attr = set_attr;
      gv->next = v->vars;
    }
  }
  v->vars = gv;
}


static PyObject *Swig_Globals_global = NULL;
  
SWIGINTERN PyObject *
SWIG_globals(void) {
  if (Swig_Globals_global == NULL) {
    Swig_Globals_global = SWIG_newvarlink();
  }
  return Swig_Globals_global;
}

#ifdef __cplusplus
}
#endif

/* -----------------------------------------------------------------------------
 * Pointer declarations
 * ----------------------------------------------------------------------------- */

/* Flags for new pointer objects */
#define SWIG_POINTER_NOSHADOW       (SWIG_POINTER_OWN      << 1)
#define SWIG_POINTER_NEW            (SWIG_POINTER_NOSHADOW | SWIG_POINTER_OWN)

#define SWIG_POINTER_IMPLICIT_CONV  (SWIG_POINTER_DISOWN   << 1)

#define SWIG_BUILTIN_TP_INIT	    (SWIG_POINTER_OWN << 2)
#define SWIG_BUILTIN_INIT	    (SWIG_BUILTIN_TP_INIT | SWIG_POINTER_OWN)

#ifdef __cplusplus
extern "C" {
#endif

/* The python void return value */

SWIGRUNTIMEINLINE PyObject * 
SWIG_Py_Void(void)
{
  PyObject *none = Py_None;
  Py_INCREF(none);
  return none;
}

/* SwigPyClientData */

typedef struct {
  PyObject *klass;
  PyObject *newraw;
  PyObject *newargs;
  PyObject *destroy;
  int delargs;
  int implicitconv;
  PyTypeObject *pytype;
} SwigPyClientData;

SWIGRUNTIMEINLINE int 
SWIG_Python_CheckImplicit(swig_type_info *ty)
{
  SwigPyClientData *data = (SwigPyClientData *)ty->clientdata;
  int fail = data ? data->implicitconv : 0;
  if (fail)
    PyErr_SetString(PyExc_TypeError, "Implicit conversion is prohibited for explicit constructors.");
  return fail;
}

SWIGRUNTIMEINLINE PyObject *
SWIG_Python_ExceptionType(swig_type_info *desc) {
  SwigPyClientData *data = desc ? (SwigPyClientData *) desc->clientdata : 0;
  PyObject *klass = data ? data->klass : 0;
  return (klass ? klass : PyExc_RuntimeError);
}


SWIGRUNTIME SwigPyClientData * 
SwigPyClientData_New(PyObject* obj)
{
  if (!obj) {
    return 0;
  } else {
    SwigPyClientData *data = (SwigPyClientData *)malloc(sizeof(SwigPyClientData));
    /* the klass element */
    data->klass = obj;
    Py_INCREF(data->klass);
    /* the newraw method and newargs arguments used to create a new raw instance */
    if (PyClass_Check(obj)) {
      data->newraw = 0;
      Py_INCREF(obj);
      data->newargs = obj;
    } else {
      data->newraw = PyObject_GetAttrString(data->klass, "__new__");
      if (data->newraw) {
        data->newargs = PyTuple_New(1);
        if (data->newargs) {
          Py_INCREF(obj);
          PyTuple_SET_ITEM(data->newargs, 0, obj);
        } else {
          Py_DECREF(data->newraw);
          Py_DECREF(data->klass);
          free(data);
          return 0;
        }
      } else {
        Py_INCREF(obj);
        data->newargs = obj;
      }
    }
    /* the destroy method, aka as the C++ delete method */
    data->destroy = PyObject_GetAttrString(data->klass, "__swig_destroy__");
    if (PyErr_Occurred()) {
      PyErr_Clear();
      data->destroy = 0;
    }
    if (data->destroy) {
      data->delargs = !(PyCFunction_GET_FLAGS(data->destroy) & METH_O);
    } else {
      data->delargs = 0;
    }
    data->implicitconv = 0;
    data->pytype = 0;
    return data;
  }
}

SWIGRUNTIME void 
SwigPyClientData_Del(SwigPyClientData *data)
{
  Py_XDECREF(data->klass);
  Py_XDECREF(data->newraw);
  Py_XDECREF(data->newargs);
  Py_XDECREF(data->destroy);
  free(data);
}

/* =============== SwigPyObject =====================*/

typedef struct {
  PyObject_HEAD
  void *ptr;
  swig_type_info *ty;
  int own;
  PyObject *next;
#ifdef SWIGPYTHON_BUILTIN
  PyObject *dict;
#endif
} SwigPyObject;


#ifdef SWIGPYTHON_BUILTIN

SWIGRUNTIME PyObject *
SwigPyObject_get___dict__(PyObject *v, PyObject *SWIGUNUSEDPARM(args))
{
  SwigPyObject *sobj = (SwigPyObject *)v;

  if (!sobj->dict)
    sobj->dict = PyDict_New();

  Py_XINCREF(sobj->dict);
  return sobj->dict;
}

#endif

SWIGRUNTIME PyObject *
SwigPyObject_long(SwigPyObject *v)
{
  return PyLong_FromVoidPtr(v->ptr);
}

SWIGRUNTIME PyObject *
SwigPyObject_format(const char* fmt, SwigPyObject *v)
{
  PyObject *res = NULL;
  PyObject *args = PyTuple_New(1);
  if (args) {
    PyObject *val = SwigPyObject_long(v);
    if (val) {
      PyObject *ofmt;
      PyTuple_SET_ITEM(args, 0, val);
      ofmt = SWIG_Python_str_FromChar(fmt);
      if (ofmt) {
#if PY_VERSION_HEX >= 0x03000000
        res = PyUnicode_Format(ofmt,args);
#else
        res = PyString_Format(ofmt,args);
#endif
        Py_DECREF(ofmt);
      }
    }
    Py_DECREF(args);
  }
  return res;
}

SWIGRUNTIME PyObject *
SwigPyObject_oct(SwigPyObject *v)
{
  return SwigPyObject_format("%o",v);
}

SWIGRUNTIME PyObject *
SwigPyObject_hex(SwigPyObject *v)
{
  return SwigPyObject_format("%x",v);
}

SWIGRUNTIME PyObject *
SwigPyObject_repr(SwigPyObject *v)
{
  const char *name = SWIG_TypePrettyName(v->ty);
  PyObject *repr = SWIG_Python_str_FromFormat("<Swig Object of type '%s' at %p>", (name ? name : "unknown"), (void *)v);
  if (repr && v->next) {
    PyObject *nrep = SwigPyObject_repr((SwigPyObject *)v->next);
    if (nrep) {
# if PY_VERSION_HEX >= 0x03000000
      PyObject *joined = PyUnicode_Concat(repr, nrep);
      Py_DecRef(repr);
      Py_DecRef(nrep);
      repr = joined;
# else
      PyString_ConcatAndDel(&repr,nrep);
# endif
    } else {
      Py_DecRef(repr);
      repr = NULL;
    }
  }
  return repr;
}

/* We need a version taking two PyObject* parameters so it's a valid
 * PyCFunction to use in swigobject_methods[]. */
SWIGRUNTIME PyObject *
SwigPyObject_repr2(PyObject *v, PyObject *SWIGUNUSEDPARM(args))
{
  return SwigPyObject_repr((SwigPyObject*)v);
}

SWIGRUNTIME int
SwigPyObject_compare(SwigPyObject *v, SwigPyObject *w)
{
  void *i = v->ptr;
  void *j = w->ptr;
  return (i < j) ? -1 : ((i > j) ? 1 : 0);
}

/* Added for Python 3.x, would it also be useful for Python 2.x? */
SWIGRUNTIME PyObject*
SwigPyObject_richcompare(SwigPyObject *v, SwigPyObject *w, int op)
{
  PyObject* res;
  if( op != Py_EQ && op != Py_NE ) {
    Py_INCREF(Py_NotImplemented);
    return Py_NotImplemented;
  }
  res = PyBool_FromLong( (SwigPyObject_compare(v, w)==0) == (op == Py_EQ) ? 1 : 0);
  return res;  
}


SWIGRUNTIME PyTypeObject* SwigPyObject_TypeOnce(void);

#ifdef SWIGPYTHON_BUILTIN
static swig_type_info *SwigPyObject_stype = 0;
SWIGRUNTIME PyTypeObject*
SwigPyObject_type(void) {
    SwigPyClientData *cd;
    assert(SwigPyObject_stype);
    cd = (SwigPyClientData*) SwigPyObject_stype->clientdata;
    assert(cd);
    assert(cd->pytype);
    return cd->pytype;
}
#else
SWIGRUNTIME PyTypeObject*
SwigPyObject_type(void) {
  static PyTypeObject *SWIG_STATIC_POINTER(type) = SwigPyObject_TypeOnce();
  return type;
}
#endif

SWIGRUNTIMEINLINE int
SwigPyObject_Check(PyObject *op) {
#ifdef SWIGPYTHON_BUILTIN
  PyTypeObject *target_tp = SwigPyObject_type();
  if (PyType_IsSubtype(op->ob_type, target_tp))
    return 1;
  return (strcmp(op->ob_type->tp_name, "SwigPyObject") == 0);
#else
  return (Py_TYPE(op) == SwigPyObject_type())
    || (strcmp(Py_TYPE(op)->tp_name,"SwigPyObject") == 0);
#endif
}

SWIGRUNTIME PyObject *
SwigPyObject_New(void *ptr, swig_type_info *ty, int own);

static PyObject* Swig_Capsule_global = NULL;

SWIGRUNTIME void
SwigPyObject_dealloc(PyObject *v)
{
  SwigPyObject *sobj = (SwigPyObject *) v;
  PyObject *next = sobj->next;
  if (sobj->own == SWIG_POINTER_OWN) {
    swig_type_info *ty = sobj->ty;
    SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0;
    PyObject *destroy = data ? data->destroy : 0;
    if (destroy) {
      /* destroy is always a VARARGS method */
      PyObject *res;

      /* PyObject_CallFunction() has the potential to silently drop
         the active exception.  In cases of unnamed temporary
         variable or where we just finished iterating over a generator
         StopIteration will be active right now, and this needs to
         remain true upon return from SwigPyObject_dealloc.  So save
         and restore. */
      
      PyObject *type = NULL, *value = NULL, *traceback = NULL;
      PyErr_Fetch(&type, &value, &traceback);

      if (data->delargs) {
        /* we need to create a temporary object to carry the destroy operation */
        PyObject *tmp = SwigPyObject_New(sobj->ptr, ty, 0);
        if (tmp) {
          res = SWIG_Python_CallFunctor(destroy, tmp);
        } else {
          res = 0;
        }
        Py_XDECREF(tmp);
      } else {
        PyCFunction meth = PyCFunction_GET_FUNCTION(destroy);
        PyObject *mself = PyCFunction_GET_SELF(destroy);
        res = ((*meth)(mself, v));
      }
      if (!res)
        PyErr_WriteUnraisable(destroy);

      PyErr_Restore(type, value, traceback);

      Py_XDECREF(res);
    } 
#if !defined(SWIG_PYTHON_SILENT_MEMLEAK)
    else {
      const char *name = SWIG_TypePrettyName(ty);
      printf("swig/python detected a memory leak of type '%s', no destructor found.\n", (name ? name : "unknown"));
    }
#endif
    Py_XDECREF(Swig_Capsule_global);
  }
  Py_XDECREF(next);
#ifdef SWIGPYTHON_BUILTIN
  Py_XDECREF(sobj->dict);
#endif
  PyObject_DEL(v);
}

SWIGRUNTIME PyObject* 
SwigPyObject_append(PyObject* v, PyObject* next)
{
  SwigPyObject *sobj = (SwigPyObject *) v;
  if (!SwigPyObject_Check(next)) {
    PyErr_SetString(PyExc_TypeError, "Attempt to append a non SwigPyObject");
    return NULL;
  }
  ((SwigPyObject *)next)->next = sobj->next;
  sobj->next = next;
  Py_INCREF(next);
  return SWIG_Py_Void();
}

SWIGRUNTIME PyObject* 
SwigPyObject_next(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
{
  SwigPyObject *sobj = (SwigPyObject *) v;
  if (sobj->next) {    
    Py_INCREF(sobj->next);
    return sobj->next;
  } else {
    return SWIG_Py_Void();
  }
}

SWIGINTERN PyObject*
SwigPyObject_disown(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
{
  SwigPyObject *sobj = (SwigPyObject *)v;
  sobj->own = 0;
  return SWIG_Py_Void();
}

SWIGINTERN PyObject*
SwigPyObject_acquire(PyObject* v, PyObject *SWIGUNUSEDPARM(args))
{
  SwigPyObject *sobj = (SwigPyObject *)v;
  sobj->own = SWIG_POINTER_OWN;
  return SWIG_Py_Void();
}

SWIGINTERN PyObject*
SwigPyObject_own(PyObject *v, PyObject *args)
{
  PyObject *val = 0;
  if (!PyArg_UnpackTuple(args, "own", 0, 1, &val)) {
    return NULL;
  } else {
    SwigPyObject *sobj = (SwigPyObject *)v;
    PyObject *obj = PyBool_FromLong(sobj->own);
    if (val) {
      if (PyObject_IsTrue(val)) {
        Py_DECREF(SwigPyObject_acquire(v,args));
      } else {
        Py_DECREF(SwigPyObject_disown(v,args));
      }
    } 
    return obj;
  }
}

static PyMethodDef
swigobject_methods[] = {
  {"disown",  SwigPyObject_disown,  METH_NOARGS,  "releases ownership of the pointer"},
  {"acquire", SwigPyObject_acquire, METH_NOARGS,  "acquires ownership of the pointer"},
  {"own",     SwigPyObject_own,     METH_VARARGS, "returns/sets ownership of the pointer"},
  {"append",  SwigPyObject_append,  METH_O,       "appends another 'this' object"},
  {"next",    SwigPyObject_next,    METH_NOARGS,  "returns the next 'this' object"},
  {"__repr__",SwigPyObject_repr2,   METH_NOARGS,  "returns object representation"},
  {0, 0, 0, 0}  
};

SWIGRUNTIME PyTypeObject*
SwigPyObject_TypeOnce(void) {
  static char swigobject_doc[] = "Swig object carries a C/C++ instance pointer";

  static PyNumberMethods SwigPyObject_as_number = {
    (binaryfunc)0, /*nb_add*/
    (binaryfunc)0, /*nb_subtract*/
    (binaryfunc)0, /*nb_multiply*/
    /* nb_divide removed in Python 3 */
#if PY_VERSION_HEX < 0x03000000
    (binaryfunc)0, /*nb_divide*/
#endif
    (binaryfunc)0, /*nb_remainder*/
    (binaryfunc)0, /*nb_divmod*/
    (ternaryfunc)0,/*nb_power*/
    (unaryfunc)0,  /*nb_negative*/
    (unaryfunc)0,  /*nb_positive*/
    (unaryfunc)0,  /*nb_absolute*/
    (inquiry)0,    /*nb_nonzero*/
    0,		   /*nb_invert*/
    0,		   /*nb_lshift*/
    0,		   /*nb_rshift*/
    0,		   /*nb_and*/
    0,		   /*nb_xor*/
    0,		   /*nb_or*/
#if PY_VERSION_HEX < 0x03000000
    0,   /*nb_coerce*/
#endif
    (unaryfunc)SwigPyObject_long, /*nb_int*/
#if PY_VERSION_HEX < 0x03000000
    (unaryfunc)SwigPyObject_long, /*nb_long*/
#else
    0, /*nb_reserved*/
#endif
    (unaryfunc)0,                 /*nb_float*/
#if PY_VERSION_HEX < 0x03000000
    (unaryfunc)SwigPyObject_oct,  /*nb_oct*/
    (unaryfunc)SwigPyObject_hex,  /*nb_hex*/
#endif
#if PY_VERSION_HEX >= 0x03050000 /* 3.5 */
    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_inplace_matrix_multiply */
#elif PY_VERSION_HEX >= 0x03000000 /* 3.0 */
    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index, nb_inplace_divide removed */
#else
    0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 /* nb_inplace_add -> nb_index */
#endif
  };

  static PyTypeObject swigpyobject_type;
  static int type_init = 0;
  if (!type_init) {
    const PyTypeObject tmp = {
#if PY_VERSION_HEX >= 0x03000000
      PyVarObject_HEAD_INIT(NULL, 0)
#else
      PyObject_HEAD_INIT(NULL)
      0,                                    /* ob_size */
#endif
      "SwigPyObject",                       /* tp_name */
      sizeof(SwigPyObject),                 /* tp_basicsize */
      0,                                    /* tp_itemsize */
      (destructor)SwigPyObject_dealloc,     /* tp_dealloc */
#if PY_VERSION_HEX < 0x030800b4
      (printfunc)0,                         /*tp_print*/
#else
      (Py_ssize_t)0,                        /*tp_vectorcall_offset*/
#endif
      (getattrfunc)0,                       /* tp_getattr */
      (setattrfunc)0,                       /* tp_setattr */
#if PY_VERSION_HEX >= 0x03000000
      0, /* tp_reserved in 3.0.1, tp_compare in 3.0.0 but not used */
#else
      (cmpfunc)SwigPyObject_compare,        /* tp_compare */
#endif
      (reprfunc)SwigPyObject_repr,          /* tp_repr */
      &SwigPyObject_as_number,              /* tp_as_number */
      0,                                    /* tp_as_sequence */
      0,                                    /* tp_as_mapping */
      (hashfunc)0,                          /* tp_hash */
      (ternaryfunc)0,                       /* tp_call */
      0,                                    /* tp_str */
      PyObject_GenericGetAttr,              /* tp_getattro */
      0,                                    /* tp_setattro */
      0,                                    /* tp_as_buffer */
      Py_TPFLAGS_DEFAULT,                   /* tp_flags */
      swigobject_doc,                       /* tp_doc */
      0,                                    /* tp_traverse */
      0,                                    /* tp_clear */
      (richcmpfunc)SwigPyObject_richcompare,/* tp_richcompare */
      0,                                    /* tp_weaklistoffset */
      0,                                    /* tp_iter */
      0,                                    /* tp_iternext */
      swigobject_methods,                   /* tp_methods */
      0,                                    /* tp_members */
      0,                                    /* tp_getset */
      0,                                    /* tp_base */
      0,                                    /* tp_dict */
      0,                                    /* tp_descr_get */
      0,                                    /* tp_descr_set */
      0,                                    /* tp_dictoffset */
      0,                                    /* tp_init */
      0,                                    /* tp_alloc */
      0,                                    /* tp_new */
      0,                                    /* tp_free */
      0,                                    /* tp_is_gc */
      0,                                    /* tp_bases */
      0,                                    /* tp_mro */
      0,                                    /* tp_cache */
      0,                                    /* tp_subclasses */
      0,                                    /* tp_weaklist */
      0,                                    /* tp_del */
      0,                                    /* tp_version_tag */
#if PY_VERSION_HEX >= 0x03040000
      0,                                    /* tp_finalize */
#endif
#if PY_VERSION_HEX >= 0x03080000
      0,                                    /* tp_vectorcall */
#endif
#if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000)
      0,                                    /* tp_print */
#endif
#ifdef COUNT_ALLOCS
      0,                                    /* tp_allocs */
      0,                                    /* tp_frees */
      0,                                    /* tp_maxalloc */
      0,                                    /* tp_prev */
      0                                     /* tp_next */
#endif
    };
    swigpyobject_type = tmp;
    type_init = 1;
    if (PyType_Ready(&swigpyobject_type) != 0)
      return NULL;
  }
  return &swigpyobject_type;
}

SWIGRUNTIME PyObject *
SwigPyObject_New(void *ptr, swig_type_info *ty, int own)
{
  SwigPyObject *sobj = PyObject_NEW(SwigPyObject, SwigPyObject_type());
  if (sobj) {
    sobj->ptr  = ptr;
    sobj->ty   = ty;
    sobj->own  = own;
    sobj->next = 0;
#ifdef SWIGPYTHON_BUILTIN
    sobj->dict = 0;
#endif
    if (own == SWIG_POINTER_OWN) {
      /* Obtain a reference to the Python capsule wrapping the module information, so that the
       * module information is correctly destroyed after all SWIG python objects have been freed
       * by the GC (and corresponding destructors invoked) */
      Py_XINCREF(Swig_Capsule_global);
    }
  }
  return (PyObject *)sobj;
}

/* -----------------------------------------------------------------------------
 * Implements a simple Swig Packed type, and use it instead of string
 * ----------------------------------------------------------------------------- */

typedef struct {
  PyObject_HEAD
  void *pack;
  swig_type_info *ty;
  size_t size;
} SwigPyPacked;

SWIGRUNTIME PyObject *
SwigPyPacked_repr(SwigPyPacked *v)
{
  char result[SWIG_BUFFER_SIZE];
  if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))) {
    return SWIG_Python_str_FromFormat("<Swig Packed at %s%s>", result, v->ty->name);
  } else {
    return SWIG_Python_str_FromFormat("<Swig Packed %s>", v->ty->name);
  }  
}

SWIGRUNTIME PyObject *
SwigPyPacked_str(SwigPyPacked *v)
{
  char result[SWIG_BUFFER_SIZE];
  if (SWIG_PackDataName(result, v->pack, v->size, 0, sizeof(result))){
    return SWIG_Python_str_FromFormat("%s%s", result, v->ty->name);
  } else {
    return SWIG_Python_str_FromChar(v->ty->name);
  }  
}

SWIGRUNTIME int
SwigPyPacked_compare(SwigPyPacked *v, SwigPyPacked *w)
{
  size_t i = v->size;
  size_t j = w->size;
  int s = (i < j) ? -1 : ((i > j) ? 1 : 0);
  return s ? s : strncmp((const char *)v->pack, (const char *)w->pack, 2*v->size);
}

SWIGRUNTIME PyTypeObject* SwigPyPacked_TypeOnce(void);

SWIGRUNTIME PyTypeObject*
SwigPyPacked_type(void) {
  static PyTypeObject *SWIG_STATIC_POINTER(type) = SwigPyPacked_TypeOnce();
  return type;
}

SWIGRUNTIMEINLINE int
SwigPyPacked_Check(PyObject *op) {
  return ((op)->ob_type == SwigPyPacked_TypeOnce()) 
    || (strcmp((op)->ob_type->tp_name,"SwigPyPacked") == 0);
}

SWIGRUNTIME void
SwigPyPacked_dealloc(PyObject *v)
{
  if (SwigPyPacked_Check(v)) {
    SwigPyPacked *sobj = (SwigPyPacked *) v;
    free(sobj->pack);
  }
  PyObject_DEL(v);
}

SWIGRUNTIME PyTypeObject*
SwigPyPacked_TypeOnce(void) {
  static char swigpacked_doc[] = "Swig object carries a C/C++ instance pointer";
  static PyTypeObject swigpypacked_type;
  static int type_init = 0;
  if (!type_init) {
    const PyTypeObject tmp = {
#if PY_VERSION_HEX>=0x03000000
      PyVarObject_HEAD_INIT(NULL, 0)
#else
      PyObject_HEAD_INIT(NULL)
      0,                                    /* ob_size */
#endif
      "SwigPyPacked",                       /* tp_name */
      sizeof(SwigPyPacked),                 /* tp_basicsize */
      0,                                    /* tp_itemsize */
      (destructor)SwigPyPacked_dealloc,     /* tp_dealloc */
#if PY_VERSION_HEX < 0x030800b4
      (printfunc)0,                         /*tp_print*/
#else
      (Py_ssize_t)0,                        /*tp_vectorcall_offset*/
#endif
      (getattrfunc)0,                       /* tp_getattr */
      (setattrfunc)0,                       /* tp_setattr */
#if PY_VERSION_HEX>=0x03000000
      0, /* tp_reserved in 3.0.1 */
#else
      (cmpfunc)SwigPyPacked_compare,        /* tp_compare */
#endif
      (reprfunc)SwigPyPacked_repr,          /* tp_repr */
      0,                                    /* tp_as_number */
      0,                                    /* tp_as_sequence */
      0,                                    /* tp_as_mapping */
      (hashfunc)0,                          /* tp_hash */
      (ternaryfunc)0,                       /* tp_call */
      (reprfunc)SwigPyPacked_str,           /* tp_str */
      PyObject_GenericGetAttr,              /* tp_getattro */
      0,                                    /* tp_setattro */
      0,                                    /* tp_as_buffer */
      Py_TPFLAGS_DEFAULT,                   /* tp_flags */
      swigpacked_doc,                       /* tp_doc */
      0,                                    /* tp_traverse */
      0,                                    /* tp_clear */
      0,                                    /* tp_richcompare */
      0,                                    /* tp_weaklistoffset */
      0,                                    /* tp_iter */
      0,                                    /* tp_iternext */
      0,                                    /* tp_methods */
      0,                                    /* tp_members */
      0,                                    /* tp_getset */
      0,                                    /* tp_base */
      0,                                    /* tp_dict */
      0,                                    /* tp_descr_get */
      0,                                    /* tp_descr_set */
      0,                                    /* tp_dictoffset */
      0,                                    /* tp_init */
      0,                                    /* tp_alloc */
      0,                                    /* tp_new */
      0,                                    /* tp_free */
      0,                                    /* tp_is_gc */
      0,                                    /* tp_bases */
      0,                                    /* tp_mro */
      0,                                    /* tp_cache */
      0,                                    /* tp_subclasses */
      0,                                    /* tp_weaklist */
      0,                                    /* tp_del */
      0,                                    /* tp_version_tag */
#if PY_VERSION_HEX >= 0x03040000
      0,                                    /* tp_finalize */
#endif
#if PY_VERSION_HEX >= 0x03080000
      0,                                    /* tp_vectorcall */
#endif
#if (PY_VERSION_HEX >= 0x03080000) && (PY_VERSION_HEX < 0x03090000)
      0,                                    /* tp_print */
#endif
#ifdef COUNT_ALLOCS
      0,                                    /* tp_allocs */
      0,                                    /* tp_frees */
      0,                                    /* tp_maxalloc */
      0,                                    /* tp_prev */
      0                                     /* tp_next */
#endif
    };
    swigpypacked_type = tmp;
    type_init = 1;
    if (PyType_Ready(&swigpypacked_type) != 0)
      return NULL;
  }
  return &swigpypacked_type;
}

SWIGRUNTIME PyObject *
SwigPyPacked_New(void *ptr, size_t size, swig_type_info *ty)
{
  SwigPyPacked *sobj = PyObject_NEW(SwigPyPacked, SwigPyPacked_type());
  if (sobj) {
    void *pack = malloc(size);
    if (pack) {
      memcpy(pack, ptr, size);
      sobj->pack = pack;
      sobj->ty   = ty;
      sobj->size = size;
    } else {
      PyObject_DEL((PyObject *) sobj);
      sobj = 0;
    }
  }
  return (PyObject *) sobj;
}

SWIGRUNTIME swig_type_info *
SwigPyPacked_UnpackData(PyObject *obj, void *ptr, size_t size)
{
  if (SwigPyPacked_Check(obj)) {
    SwigPyPacked *sobj = (SwigPyPacked *)obj;
    if (sobj->size != size) return 0;
    memcpy(ptr, sobj->pack, size);
    return sobj->ty;
  } else {
    return 0;
  }
}

/* -----------------------------------------------------------------------------
 * pointers/data manipulation
 * ----------------------------------------------------------------------------- */

static PyObject *Swig_This_global = NULL;

SWIGRUNTIME PyObject *
SWIG_This(void)
{
  if (Swig_This_global == NULL)
    Swig_This_global = SWIG_Python_str_FromChar("this");
  return Swig_This_global;
}

/* #define SWIG_PYTHON_SLOW_GETSET_THIS */

/* TODO: I don't know how to implement the fast getset in Python 3 right now */
#if PY_VERSION_HEX>=0x03000000
#define SWIG_PYTHON_SLOW_GETSET_THIS 
#endif

SWIGRUNTIME SwigPyObject *
SWIG_Python_GetSwigThis(PyObject *pyobj) 
{
  PyObject *obj;

  if (SwigPyObject_Check(pyobj))
    return (SwigPyObject *) pyobj;

#ifdef SWIGPYTHON_BUILTIN
  (void)obj;
# ifdef PyWeakref_CheckProxy
  if (PyWeakref_CheckProxy(pyobj)) {
    pyobj = PyWeakref_GET_OBJECT(pyobj);
    if (pyobj && SwigPyObject_Check(pyobj))
      return (SwigPyObject*) pyobj;
  }
# endif
  return NULL;
#else

  obj = 0;

#if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
  if (PyInstance_Check(pyobj)) {
    obj = _PyInstance_Lookup(pyobj, SWIG_This());      
  } else {
    PyObject **dictptr = _PyObject_GetDictPtr(pyobj);
    if (dictptr != NULL) {
      PyObject *dict = *dictptr;
      obj = dict ? PyDict_GetItem(dict, SWIG_This()) : 0;
    } else {
#ifdef PyWeakref_CheckProxy
      if (PyWeakref_CheckProxy(pyobj)) {
	PyObject *wobj = PyWeakref_GET_OBJECT(pyobj);
	return wobj ? SWIG_Python_GetSwigThis(wobj) : 0;
      }
#endif
      obj = PyObject_GetAttr(pyobj,SWIG_This());
      if (obj) {
	Py_DECREF(obj);
      } else {
	if (PyErr_Occurred()) PyErr_Clear();
	return 0;
      }
    }
  }
#else
  obj = PyObject_GetAttr(pyobj,SWIG_This());
  if (obj) {
    Py_DECREF(obj);
  } else {
    if (PyErr_Occurred()) PyErr_Clear();
    return 0;
  }
#endif
  if (obj && !SwigPyObject_Check(obj)) {
    /* a PyObject is called 'this', try to get the 'real this'
       SwigPyObject from it */ 
    return SWIG_Python_GetSwigThis(obj);
  }
  return (SwigPyObject *)obj;
#endif
}

/* Acquire a pointer value */

SWIGRUNTIME int
SWIG_Python_AcquirePtr(PyObject *obj, int own) {
  if (own == SWIG_POINTER_OWN) {
    SwigPyObject *sobj = SWIG_Python_GetSwigThis(obj);
    if (sobj) {
      int oldown = sobj->own;
      sobj->own = own;
      return oldown;
    }
  }
  return 0;
}

/* Convert a pointer value */

SWIGRUNTIME int
SWIG_Python_ConvertPtrAndOwn(PyObject *obj, void **ptr, swig_type_info *ty, int flags, int *own) {
  int res;
  SwigPyObject *sobj;
  int implicit_conv = (flags & SWIG_POINTER_IMPLICIT_CONV) != 0;

  if (!obj)
    return SWIG_ERROR;
  if (obj == Py_None && !implicit_conv) {
    if (ptr)
      *ptr = 0;
    return (flags & SWIG_POINTER_NO_NULL) ? SWIG_NullReferenceError : SWIG_OK;
  }

  res = SWIG_ERROR;

  sobj = SWIG_Python_GetSwigThis(obj);
  if (own)
    *own = 0;
  while (sobj) {
    void *vptr = sobj->ptr;
    if (ty) {
      swig_type_info *to = sobj->ty;
      if (to == ty) {
        /* no type cast needed */
        if (ptr) *ptr = vptr;
        break;
      } else {
        swig_cast_info *tc = SWIG_TypeCheck(to->name,ty);
        if (!tc) {
          sobj = (SwigPyObject *)sobj->next;
        } else {
          if (ptr) {
            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 | SWIG_CAST_NEW_MEMORY;
            }
          }
          break;
        }
      }
    } else {
      if (ptr) *ptr = vptr;
      break;
    }
  }
  if (sobj) {
    if (((flags & SWIG_POINTER_RELEASE) == SWIG_POINTER_RELEASE) && !sobj->own) {
      res = SWIG_ERROR_RELEASE_NOT_OWNED;
    } else {
      if (own)
        *own = *own | sobj->own;
      if (flags & SWIG_POINTER_DISOWN) {
        sobj->own = 0;
      }
      if (flags & SWIG_POINTER_CLEAR) {
        sobj->ptr = 0;
      }
      res = SWIG_OK;
    }
  } else {
    if (implicit_conv) {
      SwigPyClientData *data = ty ? (SwigPyClientData *) ty->clientdata : 0;
      if (data && !data->implicitconv) {
        PyObject *klass = data->klass;
        if (klass) {
          PyObject *impconv;
          data->implicitconv = 1; /* avoid recursion and call 'explicit' constructors*/
          impconv = SWIG_Python_CallFunctor(klass, obj);
          data->implicitconv = 0;
          if (PyErr_Occurred()) {
            PyErr_Clear();
            impconv = 0;
          }
          if (impconv) {
            SwigPyObject *iobj = SWIG_Python_GetSwigThis(impconv);
            if (iobj) {
              void *vptr;
              res = SWIG_Python_ConvertPtrAndOwn((PyObject*)iobj, &vptr, ty, 0, 0);
              if (SWIG_IsOK(res)) {
                if (ptr) {
                  *ptr = vptr;
                  /* transfer the ownership to 'ptr' */
                  iobj->own = 0;
                  res = SWIG_AddCast(res);
                  res = SWIG_AddNewMask(res);
                } else {
                  res = SWIG_AddCast(res);		    
                }
              }
            }
            Py_DECREF(impconv);
          }
        }
      }
      if (!SWIG_IsOK(res) && obj == Py_None) {
        if (ptr)
          *ptr = 0;
        if (PyErr_Occurred())
          PyErr_Clear();
        res = SWIG_OK;
      }
    }
  }
  return res;
}

/* Convert a function ptr value */

SWIGRUNTIME int
SWIG_Python_ConvertFunctionPtr(PyObject *obj, void **ptr, swig_type_info *ty) {
  if (!PyCFunction_Check(obj)) {
    return SWIG_ConvertPtr(obj, ptr, ty, 0);
  } else {
    void *vptr = 0;
    swig_cast_info *tc;

    /* here we get the method pointer for callbacks */
    const char *doc = (((PyCFunctionObject *)obj) -> m_ml -> ml_doc);
    const char *desc = doc ? strstr(doc, "swig_ptr: ") : 0;
    if (desc)
      desc = ty ? SWIG_UnpackVoidPtr(desc + 10, &vptr, ty->name) : 0;
    if (!desc)
      return SWIG_ERROR;
    tc = SWIG_TypeCheck(desc,ty);
    if (tc) {
      int newmemory = 0;
      *ptr = SWIG_TypeCast(tc,vptr,&newmemory);
      assert(!newmemory); /* newmemory handling not yet implemented */
    } else {
      return SWIG_ERROR;
    }
    return SWIG_OK;
  }
}

/* Convert a packed pointer value */

SWIGRUNTIME int
SWIG_Python_ConvertPacked(PyObject *obj, void *ptr, size_t sz, swig_type_info *ty) {
  swig_type_info *to = SwigPyPacked_UnpackData(obj, ptr, sz);
  if (!to) return SWIG_ERROR;
  if (ty) {
    if (to != ty) {
      /* check type cast? */
      swig_cast_info *tc = SWIG_TypeCheck(to->name,ty);
      if (!tc) return SWIG_ERROR;
    }
  }
  return SWIG_OK;
}  

/* -----------------------------------------------------------------------------
 * Create a new pointer object
 * ----------------------------------------------------------------------------- */

/*
  Create a new instance object, without calling __init__, and set the
  'this' attribute.
*/

SWIGRUNTIME PyObject* 
SWIG_Python_NewShadowInstance(SwigPyClientData *data, PyObject *swig_this)
{
  PyObject *inst = 0;
  PyObject *newraw = data->newraw;
  if (newraw) {
    inst = PyObject_Call(newraw, data->newargs, NULL);
    if (inst) {
#if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
      PyObject **dictptr = _PyObject_GetDictPtr(inst);
      if (dictptr != NULL) {
        PyObject *dict = *dictptr;
        if (dict == NULL) {
          dict = PyDict_New();
          *dictptr = dict;
        }
        if (dict) {
          PyDict_SetItem(dict, SWIG_This(), swig_this);
        } else{
          Py_DECREF(inst);
          inst = 0;
        }
      }
#else
      if (PyObject_SetAttr(inst, SWIG_This(), swig_this) == -1) {
        Py_DECREF(inst);
        inst = 0;
      }
#endif
    }
  } else {
#if PY_VERSION_HEX >= 0x03000000
    PyObject *empty_args = PyTuple_New(0);
    if (empty_args) {
      PyObject *empty_kwargs = PyDict_New();
      if (empty_kwargs) {
        inst = ((PyTypeObject *)data->newargs)->tp_new((PyTypeObject *)data->newargs, empty_args, empty_kwargs);
        Py_DECREF(empty_kwargs);
        if (inst) {
          if (PyObject_SetAttr(inst, SWIG_This(), swig_this) == -1) {
            Py_DECREF(inst);
            inst = 0;
          } else {
            PyType_Modified(Py_TYPE(inst));
          }
        }
      }
      Py_DECREF(empty_args);
    }
#else
    PyObject *dict = PyDict_New();
    if (dict) {
      PyDict_SetItem(dict, SWIG_This(), swig_this);
      inst = PyInstance_NewRaw(data->newargs, dict);
      Py_DECREF(dict);
    }
#endif
  }
  return inst;
}

SWIGRUNTIME int
SWIG_Python_SetSwigThis(PyObject *inst, PyObject *swig_this)
{
#if !defined(SWIG_PYTHON_SLOW_GETSET_THIS)
  PyObject **dictptr = _PyObject_GetDictPtr(inst);
  if (dictptr != NULL) {
    PyObject *dict = *dictptr;
    if (dict == NULL) {
      dict = PyDict_New();
      *dictptr = dict;
    }
    if (dict) {
      return PyDict_SetItem(dict, SWIG_This(), swig_this);
    } else{
      return -1;
    }
  }
#endif
  return PyObject_SetAttr(inst, SWIG_This(), swig_this);
} 


SWIGINTERN PyObject *
SWIG_Python_InitShadowInstance(PyObject *args) {
  PyObject *obj[2];
  if (!SWIG_Python_UnpackTuple(args, "swiginit", 2, 2, obj)) {
    return NULL;
  } else {
    SwigPyObject *sthis = SWIG_Python_GetSwigThis(obj[0]);
    if (sthis) {
      Py_DECREF(SwigPyObject_append((PyObject*) sthis, obj[1]));
    } else {
      if (SWIG_Python_SetSwigThis(obj[0], obj[1]) != 0)
        return NULL;
    }
    return SWIG_Py_Void();
  }
}

/* Create a new pointer object */

SWIGRUNTIME PyObject *
SWIG_Python_NewPointerObj(PyObject *self, void *ptr, swig_type_info *type, int flags) {
  SwigPyClientData *clientdata;
  PyObject * robj;
  int own;

  if (!ptr)
    return SWIG_Py_Void();

  clientdata = type ? (SwigPyClientData *)(type->clientdata) : 0;
  own = (flags & SWIG_POINTER_OWN) ? SWIG_POINTER_OWN : 0;
  if (clientdata && clientdata->pytype) {
    SwigPyObject *newobj;
    if (flags & SWIG_BUILTIN_TP_INIT) {
      newobj = (SwigPyObject*) self;
      if (newobj->ptr) {
        PyObject *next_self = clientdata->pytype->tp_alloc(clientdata->pytype, 0);
        while (newobj->next)
	  newobj = (SwigPyObject *) newobj->next;
        newobj->next = next_self;
        newobj = (SwigPyObject *)next_self;
#ifdef SWIGPYTHON_BUILTIN
        newobj->dict = 0;
#endif
      }
    } else {
      newobj = PyObject_New(SwigPyObject, clientdata->pytype);
#ifdef SWIGPYTHON_BUILTIN
      if (newobj) {
        newobj->dict = 0;
      }
#endif
    }
    if (newobj) {
      newobj->ptr = ptr;
      newobj->ty = type;
      newobj->own = own;
      newobj->next = 0;
      return (PyObject*) newobj;
    }
    return SWIG_Py_Void();
  }

  assert(!(flags & SWIG_BUILTIN_TP_INIT));

  robj = SwigPyObject_New(ptr, type, own);
  if (robj && clientdata && !(flags & SWIG_POINTER_NOSHADOW)) {
    PyObject *inst = SWIG_Python_NewShadowInstance(clientdata, robj);
    Py_DECREF(robj);
    robj = inst;
  }
  return robj;
}

/* Create a new packed object */

SWIGRUNTIMEINLINE PyObject *
SWIG_Python_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) {
  return ptr ? SwigPyPacked_New((void *) ptr, sz, type) : SWIG_Py_Void();
}

/* -----------------------------------------------------------------------------*
 *  Get type list 
 * -----------------------------------------------------------------------------*/

#ifdef SWIG_LINK_RUNTIME
void *SWIG_ReturnGlobalTypeList(void *);
#endif

static PyObject *Swig_TypeCache_global = NULL;

/* The python cached type query */
SWIGRUNTIME PyObject *
SWIG_Python_TypeCache(void) {
  if (Swig_TypeCache_global == NULL) {
    Swig_TypeCache_global = PyDict_New();
  }
  return Swig_TypeCache_global;
}

SWIGRUNTIME swig_module_info *
SWIG_Python_GetModule(void *SWIGUNUSEDPARM(clientdata)) {
#ifdef SWIG_LINK_RUNTIME
  static void *type_pointer = (void *)0;
  /* first check if module already created */
  if (!type_pointer) {
    type_pointer = SWIG_ReturnGlobalTypeList((void *)0);
  }
#else
  void *type_pointer = PyCapsule_Import(SWIGPY_CAPSULE_NAME, 0);
  if (PyErr_Occurred()) {
    PyErr_Clear();
    type_pointer = (void *)0;
  }
#endif
  return (swig_module_info *) type_pointer;
}


static int interpreter_counter = 0; // how many (sub-)interpreters are using swig_module's types

SWIGRUNTIME void
SWIG_Python_DestroyModule(PyObject *obj)
{
  swig_module_info *swig_module = (swig_module_info *) PyCapsule_GetPointer(obj, SWIGPY_CAPSULE_NAME);
  swig_type_info **types = swig_module->types;
  size_t i;
  if (--interpreter_counter != 0) // another sub-interpreter may still be using the swig_module's types
    return;
  for (i =0; i < swig_module->size; ++i) {
    swig_type_info *ty = types[i];
    if (ty->owndata) {
      SwigPyClientData *data = (SwigPyClientData *) ty->clientdata;
      ty->clientdata = 0;
      if (data) SwigPyClientData_Del(data);
    }
  }
  Py_DECREF(SWIG_This());
  Swig_This_global = NULL;
  Py_DECREF(SWIG_globals());
  Swig_Globals_global = NULL;
  Py_DECREF(SWIG_Python_TypeCache());
  Swig_TypeCache_global = NULL;
  Swig_Capsule_global = NULL;
}

SWIGRUNTIME void
SWIG_Python_SetModule(swig_module_info *swig_module) {
#if PY_VERSION_HEX >= 0x03000000
 /* Add a dummy module object into sys.modules */
  PyObject *module = PyImport_AddModule("swig_runtime_data" SWIG_RUNTIME_VERSION);
#else
  static PyMethodDef swig_empty_runtime_method_table[] = { {NULL, NULL, 0, NULL} }; /* Sentinel */
  PyObject *module = Py_InitModule("swig_runtime_data" SWIG_RUNTIME_VERSION, swig_empty_runtime_method_table);
#endif
  PyObject *pointer = PyCapsule_New((void *) swig_module, SWIGPY_CAPSULE_NAME, SWIG_Python_DestroyModule);
  if (pointer && module) {
    if (PyModule_AddObject(module, SWIGPY_CAPSULE_ATTR_NAME, pointer) == 0) {
      ++interpreter_counter;
      Swig_Capsule_global = pointer;
    } else {
      Py_DECREF(pointer);
    }
  } else {
    Py_XDECREF(pointer);
  }
}

SWIGRUNTIME swig_type_info *
SWIG_Python_TypeQuery(const char *type)
{
  PyObject *cache = SWIG_Python_TypeCache();
  PyObject *key = SWIG_Python_str_FromChar(type); 
  PyObject *obj = PyDict_GetItem(cache, key);
  swig_type_info *descriptor;
  if (obj) {
    descriptor = (swig_type_info *) PyCapsule_GetPointer(obj, NULL);
  } else {
    swig_module_info *swig_module = SWIG_GetModule(0);
    descriptor = SWIG_TypeQueryModule(swig_module, swig_module, type);
    if (descriptor) {
      obj = PyCapsule_New((void*) descriptor, NULL, NULL);
      if (obj) {
        PyDict_SetItem(cache, key, obj);
        Py_DECREF(obj);
      }
    }
  }
  Py_DECREF(key);
  return descriptor;
}

/* 
   For backward compatibility only
*/
#define SWIG_POINTER_EXCEPTION  0
#define SWIG_arg_fail(arg)      SWIG_Python_ArgFail(arg)
#define SWIG_MustGetPtr(p, type, argnum, flags)  SWIG_Python_MustGetPtr(p, type, argnum, flags)

SWIGRUNTIME int
SWIG_Python_AddErrMesg(const char* mesg, int infront)
{  
  if (PyErr_Occurred()) {
    PyObject *type = 0;
    PyObject *value = 0;
    PyObject *traceback = 0;
    PyErr_Fetch(&type, &value, &traceback);
    if (value) {
      PyObject *old_str = PyObject_Str(value);
      const char *tmp = SWIG_Python_str_AsChar(old_str);
      const char *errmesg = tmp ? tmp : "Invalid error message";
      Py_XINCREF(type);
      PyErr_Clear();
      if (infront) {
	PyErr_Format(type, "%s %s", mesg, errmesg);
      } else {
	PyErr_Format(type, "%s %s", errmesg, mesg);
      }
      Py_DECREF(old_str);
    }
    return 1;
  } else {
    return 0;
  }
}
  
SWIGRUNTIME int
SWIG_Python_ArgFail(int argnum)
{
  if (PyErr_Occurred()) {
    /* add information about failing argument */
    char mesg[256];
    PyOS_snprintf(mesg, sizeof(mesg), "argument number %d:", argnum);
    return SWIG_Python_AddErrMesg(mesg, 1);
  } else {
    return 0;
  }
}

SWIGRUNTIMEINLINE const char *
SwigPyObject_GetDesc(PyObject *self)
{
  SwigPyObject *v = (SwigPyObject *)self;
  swig_type_info *ty = v ? v->ty : 0;
  return ty ? ty->str : "";
}

SWIGRUNTIME void
SWIG_Python_TypeError(const char *type, PyObject *obj)
{
  if (type) {
#if defined(SWIG_COBJECT_TYPES)
    if (obj && SwigPyObject_Check(obj)) {
      const char *otype = (const char *) SwigPyObject_GetDesc(obj);
      if (otype) {
	PyErr_Format(PyExc_TypeError, "a '%s' is expected, 'SwigPyObject(%s)' is received",
		     type, otype);
	return;
      }
    } else 
#endif      
    {
      const char *otype = (obj ? obj->ob_type->tp_name : 0); 
      if (otype) {
	PyObject *str = PyObject_Str(obj);
	const char *cstr = str ? SWIG_Python_str_AsChar(str) : 0;
	if (cstr) {
	  PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s(%s)' is received",
		       type, otype, cstr);
	} else {
	  PyErr_Format(PyExc_TypeError, "a '%s' is expected, '%s' is received",
		       type, otype);
	}
	Py_XDECREF(str);
	return;
      }
    }   
    PyErr_Format(PyExc_TypeError, "a '%s' is expected", type);
  } else {
    PyErr_Format(PyExc_TypeError, "unexpected type is received");
  }
}


/* Convert a pointer value, signal an exception on a type mismatch */
SWIGRUNTIME void *
SWIG_Python_MustGetPtr(PyObject *obj, swig_type_info *ty, int SWIGUNUSEDPARM(argnum), int flags) {
  void *result;
  if (SWIG_Python_ConvertPtr(obj, &result, ty, flags) == -1) {
    PyErr_Clear();
  }
  return result;
}

#ifdef SWIGPYTHON_BUILTIN
SWIGRUNTIME int
SWIG_Python_NonDynamicSetAttr(PyObject *obj, PyObject *name, PyObject *value) {
  PyTypeObject *tp = obj->ob_type;
  PyObject *descr;
  PyObject *encoded_name;
  descrsetfunc f;
  int res = -1;

# ifdef Py_USING_UNICODE
  if (PyString_Check(name)) {
    name = PyUnicode_Decode(PyString_AsString(name), PyString_Size(name), NULL, NULL);
    if (!name)
      return -1;
  } else if (!PyUnicode_Check(name))
# else
  if (!PyString_Check(name))
# endif
  {
    PyErr_Format(PyExc_TypeError, "attribute name must be string, not '%.200s'", name->ob_type->tp_name);
    return -1;
  } else {
    Py_INCREF(name);
  }

  if (!tp->tp_dict) {
    if (PyType_Ready(tp) != 0)
      goto done;
  }

  descr = _PyType_Lookup(tp, name);
  f = NULL;
  if (descr != NULL)
    f = descr->ob_type->tp_descr_set;
  if (!f) {
    if (PyString_Check(name)) {
      encoded_name = name;
      Py_INCREF(name);
    } else {
      encoded_name = PyUnicode_AsUTF8String(name);
      if (!encoded_name)
        goto done;
    }
    PyErr_Format(PyExc_AttributeError, "'%.100s' object has no attribute '%.200s'", tp->tp_name, PyString_AsString(encoded_name));
    Py_DECREF(encoded_name);
  } else {
    res = f(descr, obj, value);
  }
  
  done:
  Py_DECREF(name);
  return res;
}
#endif


#ifdef __cplusplus
}
#endif



#define SWIG_exception_fail(code, msg) do { SWIG_Error(code, msg); SWIG_fail; } while(0) 

#define SWIG_contract_assert(expr, msg) do { if (!(expr)) { SWIG_Error(SWIG_RuntimeError, msg); SWIG_fail; } } while (0) 



  #define SWIG_exception(code, msg) do { SWIG_Error(code, msg); SWIG_fail;; } while(0) 


/* -------- TYPES TABLE (BEGIN) -------- */

#define SWIGTYPE_p_allocator_type swig_types[0]
#define SWIGTYPE_p_char swig_types[1]
#define SWIGTYPE_p_difference_type swig_types[2]
#define SWIGTYPE_p_double swig_types[3]
#define SWIGTYPE_p_heasp__arf swig_types[4]
#define SWIGTYPE_p_heasp__arfII swig_types[5]
#define SWIGTYPE_p_heasp__grouping swig_types[6]
#define SWIGTYPE_p_heasp__pha swig_types[7]
#define SWIGTYPE_p_heasp__phaII swig_types[8]
#define SWIGTYPE_p_heasp__rmf swig_types[9]
#define SWIGTYPE_p_heasp__rmft swig_types[10]
#define SWIGTYPE_p_heasp__table swig_types[11]
#define SWIGTYPE_p_heasp__tableParameter swig_types[12]
#define SWIGTYPE_p_heasp__tableSpectrum swig_types[13]
#define SWIGTYPE_p_int swig_types[14]
#define SWIGTYPE_p_p_PyObject swig_types[15]
#define SWIGTYPE_p_size_type swig_types[16]
#define SWIGTYPE_p_std__allocatorT_std__string_t swig_types[17]
#define SWIGTYPE_p_std__invalid_argument swig_types[18]
#define SWIGTYPE_p_std__mapT_std__string_std__string_t swig_types[19]
#define SWIGTYPE_p_std__string swig_types[20]
#define SWIGTYPE_p_std__valarrayT_double_t swig_types[21]
#define SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t swig_types[22]
#define SWIGTYPE_p_std__vectorT_heasp__arf_std__allocatorT_heasp__arf_t_t swig_types[23]
#define SWIGTYPE_p_std__vectorT_heasp__pha_std__allocatorT_heasp__pha_t_t swig_types[24]
#define SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t swig_types[25]
#define SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t swig_types[26]
#define SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t swig_types[27]
#define SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t swig_types[28]
#define SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t swig_types[29]
#define SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t swig_types[30]
#define SWIGTYPE_p_swig__SwigPyIterator swig_types[31]
#define SWIGTYPE_p_value_type swig_types[32]
static swig_type_info *swig_types[34];
static swig_module_info swig_module = {swig_types, 33, 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) -------- */

#ifdef SWIG_TypeQuery
# undef SWIG_TypeQuery
#endif
#define SWIG_TypeQuery SWIG_Python_TypeQuery

/*-----------------------------------------------
              @(target):= _heasp.so
  ------------------------------------------------*/
#if PY_VERSION_HEX >= 0x03000000
#  define SWIG_init    PyInit__heasp

#else
#  define SWIG_init    init_heasp

#endif
#define SWIG_name    "_heasp"

#ifdef __cplusplus
#include <utility>
/* SwigValueWrapper is described in swig.swg */
template<typename T> class SwigValueWrapper {
  struct SwigSmartPointer {
    T *ptr;
    SwigSmartPointer(T *p) : ptr(p) { }
    ~SwigSmartPointer() { delete ptr; }
    SwigSmartPointer& operator=(SwigSmartPointer& rhs) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = rhs.ptr; rhs.ptr = 0; return *this; }
    void reset(T *p) { T* oldptr = ptr; ptr = 0; delete oldptr; ptr = p; }
  } pointer;
  SwigValueWrapper& operator=(const SwigValueWrapper<T>& rhs);
  SwigValueWrapper(const SwigValueWrapper<T>& rhs);
public:
  SwigValueWrapper() : pointer(0) { }
  SwigValueWrapper& operator=(const T& t) { SwigSmartPointer tmp(new T(t)); pointer = tmp; return *this; }
#if __cplusplus >=201103L
  SwigValueWrapper& operator=(T&& t) { SwigSmartPointer tmp(new T(std::move(t))); pointer = tmp; return *this; }
  operator T&&() const { return std::move(*pointer.ptr); }
#else
  operator T&() const { return *pointer.ptr; }
#endif
  T *operator&() const { return pointer.ptr; }
  static void reset(SwigValueWrapper& t, T *p) { t.pointer.reset(p); }
};

/*
 * SwigValueInit() is a generic initialisation solution as the following approach:
 * 
 *       T c_result = T();
 * 
 * doesn't compile for all types for example:
 * 
 *       unsigned int c_result = unsigned int();
 */
template <typename T> T SwigValueInit() {
  return T();
}

#if __cplusplus >=201103L
# define SWIG_STD_MOVE(OBJ) std::move(OBJ)
#else
# define SWIG_STD_MOVE(OBJ) OBJ
#endif

#endif


#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>


namespace swig {
  class SwigPtr_PyObject {
  protected:
    PyObject *_obj;

  public:
    SwigPtr_PyObject() :_obj(0)
    {
    }

    SwigPtr_PyObject(const SwigPtr_PyObject& item) : _obj(item._obj)
    {
      SWIG_PYTHON_THREAD_BEGIN_BLOCK;
      Py_XINCREF(_obj);      
      SWIG_PYTHON_THREAD_END_BLOCK;
    }
    
    SwigPtr_PyObject(PyObject *obj, bool initial_ref = true) :_obj(obj)
    {
      if (initial_ref) {
        SWIG_PYTHON_THREAD_BEGIN_BLOCK;
        Py_XINCREF(_obj);
        SWIG_PYTHON_THREAD_END_BLOCK;
      }
    }
    
    SwigPtr_PyObject & operator=(const SwigPtr_PyObject& item) 
    {
      SWIG_PYTHON_THREAD_BEGIN_BLOCK;
      Py_XINCREF(item._obj);
      Py_XDECREF(_obj);
      _obj = item._obj;
      SWIG_PYTHON_THREAD_END_BLOCK;
      return *this;      
    }
    
    ~SwigPtr_PyObject() 
    {
      SWIG_PYTHON_THREAD_BEGIN_BLOCK;
      Py_XDECREF(_obj);
      SWIG_PYTHON_THREAD_END_BLOCK;
    }
    
    operator PyObject *() const
    {
      return _obj;
    }

    PyObject *operator->() const
    {
      return _obj;
    }
  };
}


namespace swig {
  struct SwigVar_PyObject : SwigPtr_PyObject {
    SwigVar_PyObject(PyObject* obj = 0) : SwigPtr_PyObject(obj, false) { }
    
    SwigVar_PyObject & operator = (PyObject* obj)
    {
      Py_XDECREF(_obj);
      _obj = obj;
      return *this;      
    }
  };
}


#include <fstream>
#include <iostream>
#include <iomanip>
#include <cstdlib>
#include <cmath>
#include <cstdio>
#include <sstream>
#include <string>
#include <stdexcept>
#include <ctime>
#include <valarray>
#include <vector>

#include <CCfits/CCfits>

#include "../heasp.h"
#include "../pha.h"
#include "../phaII.h"
#include "../rmf.h"
#include "../rmft.h"
#include "../arf.h"
#include "../arfII.h"
#include "../grouping.h"
#include "../table.h"

// using heasp namespace
using namespace heasp;


SWIGINTERNINLINE PyObject*
  SWIG_From_int  (int value)
{
  return PyInt_FromLong((long) value);
}


  #define SWIG_From_double   PyFloat_FromDouble 


#include <string>


#include <iostream>

#if PY_VERSION_HEX >= 0x03020000
# define SWIGPY_SLICEOBJECT PyObject
#else
# define SWIGPY_SLICEOBJECT PySliceObject
#endif


#include <typeinfo>
#include <stdexcept>


#if defined(__GNUC__)
#  if __GNUC__ == 2 && __GNUC_MINOR <= 96
#     define SWIG_STD_NOMODERN_STL
#  endif
#endif


#include <stddef.h>


namespace swig {
  struct stop_iteration {
  };

  struct SwigPyIterator {
  private:
    SwigPtr_PyObject _seq;

  protected:
    SwigPyIterator(PyObject *seq) : _seq(seq)
    {
    }
      
  public:
    virtual ~SwigPyIterator() {}

    // Access iterator method, required by Python
    virtual PyObject *value() const = 0;

    // Forward iterator method, required by Python
    virtual SwigPyIterator *incr(size_t n = 1) = 0;
    
    // Backward iterator method, very common in C++, but not required in Python
    virtual SwigPyIterator *decr(size_t /*n*/ = 1)
    {
      throw stop_iteration();
    }

    // Random access iterator methods, but not required in Python
    virtual ptrdiff_t distance(const SwigPyIterator &/*x*/) const
    {
      throw std::invalid_argument("operation not supported");
    }

    virtual bool equal (const SwigPyIterator &/*x*/) const
    {
      throw std::invalid_argument("operation not supported");
    }
    
    // C++ common/needed methods
    virtual SwigPyIterator *copy() const = 0;

    PyObject *next()     
    {
      SWIG_PYTHON_THREAD_BEGIN_BLOCK; // disable threads       
      PyObject *obj = value();
      incr();       
      SWIG_PYTHON_THREAD_END_BLOCK; // re-enable threads
      return obj;     
    }

    /* Make an alias for Python 3.x */
    PyObject *__next__()
    {
      return next();
    }

    PyObject *previous()
    {
      SWIG_PYTHON_THREAD_BEGIN_BLOCK; // disable threads       
      decr();
      PyObject *obj = value();
      SWIG_PYTHON_THREAD_END_BLOCK; // re-enable threads       
      return obj;
    }

    SwigPyIterator *advance(ptrdiff_t n)
    {
      return  (n > 0) ?  incr(n) : decr(-n);
    }
      
    bool operator == (const SwigPyIterator& x)  const
    {
      return equal(x);
    }
      
    bool operator != (const SwigPyIterator& x) const
    {
      return ! operator==(x);
    }
      
    SwigPyIterator& operator += (ptrdiff_t n)
    {
      return *advance(n);
    }

    SwigPyIterator& operator -= (ptrdiff_t n)
    {
      return *advance(-n);
    }
      
    SwigPyIterator* operator + (ptrdiff_t n) const
    {
      return copy()->advance(n);
    }

    SwigPyIterator* operator - (ptrdiff_t n) const
    {
      return copy()->advance(-n);
    }
      
    ptrdiff_t operator - (const SwigPyIterator& 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::SwigPyIterator *");
	init = 1;
      }	
      return desc;
    }    
  };

#if defined(SWIGPYTHON_BUILTIN)
  inline PyObject* make_output_iterator_builtin (PyObject *pyself)
  {
    Py_INCREF(pyself);
    return pyself;
  }
#endif
}


SWIGINTERN int
SWIG_AsVal_double (PyObject *obj, double *val)
{
  int res = SWIG_TypeError;
  if (PyFloat_Check(obj)) {
    if (val) *val = PyFloat_AsDouble(obj);
    return SWIG_OK;
#if PY_VERSION_HEX < 0x03000000
  } else if (PyInt_Check(obj)) {
    if (val) *val = (double) PyInt_AsLong(obj);
    return SWIG_OK;
#endif
  } else if (PyLong_Check(obj)) {
    double v = PyLong_AsDouble(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      PyErr_Clear();
    }
  }
#ifdef SWIG_PYTHON_CAST_MODE
  {
    int dispatch = 0;
    double d = PyFloat_AsDouble(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = d;
      return SWIG_AddCast(SWIG_OK);
    } else {
      PyErr_Clear();
    }
    if (!dispatch) {
      long v = PyLong_AsLong(obj);
      if (!PyErr_Occurred()) {
	if (val) *val = v;
	return SWIG_AddCast(SWIG_AddCast(SWIG_OK));
      } else {
	PyErr_Clear();
      }
    }
  }
#endif
  return res;
}


#include <float.h>


#include <math.h>


SWIGINTERNINLINE int
SWIG_CanCastAsInteger(double *d, double min, double max) {
  double x = *d;
  if ((min <= x && x <= max)) {
   double fx = floor(x);
   double cx = ceil(x);
   double rd =  ((x - fx) < 0.5) ? fx : cx; /* simple rint */
   if ((errno == EDOM) || (errno == ERANGE)) {
     errno = 0;
   } else {
     double summ, reps, diff;
     if (rd < x) {
       diff = x - rd;
     } else if (rd > x) {
       diff = rd - x;
     } else {
       return 1;
     }
     summ = rd + x;
     reps = diff/summ;
     if (reps < 8*DBL_EPSILON) {
       *d = rd;
       return 1;
     }
   }
  }
  return 0;
}


SWIGINTERN int
SWIG_AsVal_unsigned_SS_long (PyObject *obj, unsigned long *val) 
{
#if PY_VERSION_HEX < 0x03000000
  if (PyInt_Check(obj)) {
    long v = PyInt_AsLong(obj);
    if (v >= 0) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      return SWIG_OverflowError;
    }
  } else
#endif
  if (PyLong_Check(obj)) {
    unsigned long v = PyLong_AsUnsignedLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      PyErr_Clear();
      return SWIG_OverflowError;
    }
  }
#ifdef SWIG_PYTHON_CAST_MODE
  {
    int dispatch = 0;
    unsigned long v = PyLong_AsUnsignedLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_AddCast(SWIG_OK);
    } else {
      PyErr_Clear();
    }
    if (!dispatch) {
      double d;
      int res = SWIG_AddCast(SWIG_AsVal_double (obj,&d));
      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, 0, ULONG_MAX)) {
	if (val) *val = (unsigned long)(d);
	return res;
      }
    }
  }
#endif
  return SWIG_TypeError;
}


#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


#if defined(LLONG_MAX) && !defined(SWIG_LONG_LONG_AVAILABLE)
#  define SWIG_LONG_LONG_AVAILABLE
#endif


#ifdef SWIG_LONG_LONG_AVAILABLE
SWIGINTERN int
SWIG_AsVal_unsigned_SS_long_SS_long (PyObject *obj, unsigned long long *val)
{
  int res = SWIG_TypeError;
  if (PyLong_Check(obj)) {
    unsigned long long v = PyLong_AsUnsignedLongLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      PyErr_Clear();
      res = SWIG_OverflowError;
    }
  } else {
    unsigned long v;
    res = SWIG_AsVal_unsigned_SS_long (obj,&v);
    if (SWIG_IsOK(res)) {
      if (val) *val = v;
      return res;
    }
  }
#ifdef SWIG_PYTHON_CAST_MODE
  {
    const double mant_max = 1LL << DBL_MANT_DIG;
    double d;
    res = SWIG_AsVal_double (obj,&d);
    if (SWIG_IsOK(res) && !SWIG_CanCastAsInteger(&d, 0, mant_max))
      return SWIG_OverflowError;
    if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, 0, mant_max)) {
      if (val) *val = (unsigned long long)(d);
      return SWIG_AddCast(res);
    }
    res = SWIG_TypeError;
  }
#endif
  return res;
}
#endif


SWIGINTERNINLINE int
SWIG_AsVal_size_t (PyObject * 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;
}


  #define SWIG_From_long   PyInt_FromLong 


#ifdef SWIG_LONG_LONG_AVAILABLE
SWIGINTERNINLINE PyObject* 
SWIG_From_long_SS_long  (long long value)
{
  return ((value < LONG_MIN) || (value > LONG_MAX)) ?
    PyLong_FromLongLong(value) : PyInt_FromLong(static_cast< long >(value));
}
#endif


SWIGINTERNINLINE PyObject *
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
}


SWIGINTERNINLINE PyObject*
  SWIG_From_bool  (bool value)
{
  return PyBool_FromLong(value ? 1 : 0);
}


SWIGINTERN int
SWIG_AsVal_long (PyObject *obj, long* val)
{
#if PY_VERSION_HEX < 0x03000000
  if (PyInt_Check(obj)) {
    if (val) *val = PyInt_AsLong(obj);
    return SWIG_OK;
  } else
#endif
  if (PyLong_Check(obj)) {
    long v = PyLong_AsLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      PyErr_Clear();
      return SWIG_OverflowError;
    }
  }
#ifdef SWIG_PYTHON_CAST_MODE
  {
    int dispatch = 0;
    long v = PyInt_AsLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_AddCast(SWIG_OK);
    } else {
      PyErr_Clear();
    }
    if (!dispatch) {
      double d;
      int res = SWIG_AddCast(SWIG_AsVal_double (obj,&d));
      if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, LONG_MIN, LONG_MAX)) {
	if (val) *val = (long)(d);
	return res;
      }
    }
  }
#endif
  return SWIG_TypeError;
}


#ifdef SWIG_LONG_LONG_AVAILABLE
SWIGINTERN int
SWIG_AsVal_long_SS_long (PyObject *obj, long long *val)
{
  int res = SWIG_TypeError;
  if (PyLong_Check(obj)) {
    long long v = PyLong_AsLongLong(obj);
    if (!PyErr_Occurred()) {
      if (val) *val = v;
      return SWIG_OK;
    } else {
      PyErr_Clear();
      res = SWIG_OverflowError;
    }
  } else {
    long v;
    res = SWIG_AsVal_long (obj,&v);
    if (SWIG_IsOK(res)) {
      if (val) *val = v;
      return res;
    }
  }
#ifdef SWIG_PYTHON_CAST_MODE
  {
    const double mant_max = 1LL << DBL_MANT_DIG;
    const double mant_min = -mant_max;
    double d;
    res = SWIG_AsVal_double (obj,&d);
    if (SWIG_IsOK(res) && !SWIG_CanCastAsInteger(&d, mant_min, mant_max))
      return SWIG_OverflowError;
    if (SWIG_IsOK(res) && SWIG_CanCastAsInteger(&d, mant_min, mant_max)) {
      if (val) *val = (long long)(d);
      return SWIG_AddCast(res);
    }
    res = SWIG_TypeError;
  }
#endif
  return res;
}
#endif


SWIGINTERNINLINE int
SWIG_AsVal_ptrdiff_t (PyObject * 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;
}


#include <algorithm>


#include <vector>


#define SWIG_FILE_WITH_INIT


#ifndef SWIG_FILE_WITH_INIT
#define NO_IMPORT_ARRAY
#endif
#include "stdio.h"
#define NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION
#include <numpy/arrayobject.h>


#include <complex> 


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;
    }
  };

  /*
    Partial specialization for pointers (traits_info)
  */
  template <class Type> struct traits_info<Type *> {
    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 (traits)
  */
  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 PyObject *from(Type *val, int owner = 0) {
      return SWIG_InternalNewPointerObj(val, type_info<Type>(), owner);
    }
  };

  template <class Type> struct traits_from {
    static PyObject *from(const Type& val) {
      return traits_from_ptr<Type>::from(new Type(val), 1);
    }
  };

  template <class Type> struct traits_from<Type *> {
    static PyObject *from(Type* val) {
      return traits_from_ptr<Type>::from(val, 0);
    }
  };

  template <class Type> struct traits_from<const Type *> {
    static PyObject *from(const Type* val) {
      return traits_from_ptr<Type>::from(const_cast<Type*>(val), 0);
    }
  };


  template <class Type>
  inline PyObject *from(const Type& val) {
    return traits_from<Type>::from(val);
  }

  template <class Type>
  inline PyObject *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(PyObject *obj, Type **val) {
      int res = SWIG_ERROR;
      swig_type_info *descriptor = type_info<Type>();
      if (val) {
        Type *p = 0;
        int newmem = 0;
        res = descriptor ? SWIG_ConvertPtrAndOwn(obj, (void **)&p, descriptor, 0, &newmem) : SWIG_ERROR;
        if (SWIG_IsOK(res)) {
          if (newmem & SWIG_CAST_NEW_MEMORY) {
            res |= SWIG_NEWOBJMASK;
          }
          *val = p;
        }
      } else {
        res = descriptor ? SWIG_ConvertPtr(obj, 0, descriptor, 0) : SWIG_ERROR;
      }
      return res;
    }
  }; 

  template <class Type>
  inline int asptr(PyObject *obj, Type **vptr) {
    return traits_asptr<Type>::asptr(obj, vptr);
  }

  template <class Type> 
  struct traits_asval {
    static int asval(PyObject *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(PyObject *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(PyObject *obj, Type *val) {
    return traits_asval<Type>::asval(obj, val);
  }

  template <class Type> 
  struct traits_as<Type, value_category> {
    static Type as(PyObject *obj) {
      Type v;
      int res = asval(obj, &v);
      if (!obj || !SWIG_IsOK(res)) {
	if (!PyErr_Occurred()) {
	  ::SWIG_Error(SWIG_TypeError,  swig::type_name<Type>());
	}
	throw std::invalid_argument("bad type");
      }
      return v;
    }
  };

  template <class Type> 
  struct traits_as<Type, pointer_category> {
    static Type as(PyObject *obj) {
      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 {
	if (!PyErr_Occurred()) {
	  SWIG_Error(SWIG_TypeError,  swig::type_name<Type>());
	}
	throw std::invalid_argument("bad type");
      }
    }
  };

  template <class Type> 
  struct traits_as<Type*, pointer_category> {
    static Type* as(PyObject *obj) {
      Type *v = 0;      
      int res = (obj ? traits_asptr<Type>::asptr(obj, &v) : SWIG_ERROR);
      if (SWIG_IsOK(res)) {
	return v;
      } else {
	if (!PyErr_Occurred()) {
	  SWIG_Error(SWIG_TypeError,  swig::type_name<Type>());
	}
	throw std::invalid_argument("bad type");
      }
    }
  };
    
  template <class Type>
  inline Type as(PyObject *obj) {
    return traits_as<Type, typename traits<Type>::category>::as(obj);
  }

  template <class Type> 
  struct traits_check<Type, value_category> {
    static bool check(PyObject *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(PyObject *obj) {
      int res = obj ? asptr(obj, (Type **)(0)) : SWIG_ERROR;
      return SWIG_IsOK(res) ? true : false;
    }
  };

  template <class Type>
  inline bool check(PyObject *obj) {
    return traits_check<Type, typename traits<Type>::category>::check(obj);
  }
}


#include <functional>

namespace std {
  template <>
  struct less <PyObject *>
  {
    bool
    operator()(PyObject * v, PyObject *w) const
    { 
      bool res;
      SWIG_PYTHON_THREAD_BEGIN_BLOCK;
      res = PyObject_RichCompareBool(v, w, Py_LT) ? true : false;
      /* This may fall into a case of inconsistent
               eg. ObjA > ObjX > ObjB
               but ObjA < ObjB
      */
      if( PyErr_Occurred() && PyErr_ExceptionMatches(PyExc_TypeError) )
      {
        /* Objects can't be compared, this mostly occurred in Python 3.0 */
        /* Compare their ptr directly for a workaround */
        res = (v < w);
        PyErr_Clear();
      }
      SWIG_PYTHON_THREAD_END_BLOCK;
      return res;
    }
  };

  template <>
  struct less <swig::SwigPtr_PyObject>
  {
    bool
    operator()(const swig::SwigPtr_PyObject& v, const swig::SwigPtr_PyObject& w) const
    {
      return std::less<PyObject *>()(v, w);
    }
  };

  template <>
  struct less <swig::SwigVar_PyObject>
  {
    bool
    operator()(const swig::SwigVar_PyObject& v, const swig::SwigVar_PyObject& w) const
    {
      return std::less<PyObject *>()(v, w);
    }
  };

}

namespace swig {
  template <> struct traits<PyObject *> {
    typedef value_category category;
    static const char* type_name() { return "PyObject *"; }
  };  

  template <>  struct traits_asval<PyObject * > {   
    typedef PyObject * value_type;
    static int asval(PyObject *obj, value_type *val) {
      if (val) *val = obj;
      return SWIG_OK;
    }
  };

  template <> 
  struct traits_check<PyObject *, value_category> {
    static bool check(PyObject *) {
      return true;
    }
  };

  template <>  struct traits_from<PyObject *> {
    typedef PyObject * value_type;
    static PyObject *from(const value_type& val) {
      Py_XINCREF(val);
      return val;
    }
  };
  
}

namespace swig {
  template <class Difference>
  inline size_t
  check_index(Difference 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");
  }

  template <class Difference>
  void
  slice_adjust(Difference i, Difference j, Py_ssize_t step, size_t size, Difference &ii, Difference &jj, bool insert = false) {
    if (step == 0) {
      throw std::invalid_argument("slice step cannot be zero");
    } else if (step > 0) {
      // Required range: 0 <= i < size, 0 <= j < size, i <= j
      if (i < 0) {
        ii = 0;
      } else if (i < (Difference)size) {
        ii = i;
      } else if (insert && (i >= (Difference)size)) {
        ii = (Difference)size;
      }
      if (j < 0) {
        jj = 0;
      } else {
        jj = (j < (Difference)size) ? j : (Difference)size;
      }
      if (jj < ii)
        jj = ii;
    } else {
      // Required range: -1 <= i < size-1, -1 <= j < size-1, i >= j
      if (i < -1) {
        ii = -1;
      } else if (i < (Difference) size) {
        ii = i;
      } else if (i >= (Difference)(size-1)) {
        ii = (Difference)(size-1);
      }
      if (j < -1) {
        jj = -1;
      } else {
        jj = (j < (Difference)size ) ? j : (Difference)(size-1);
      }
      if (ii < jj)
        ii = jj;
    }
  }

  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
  erase(Sequence* seq, const typename Sequence::iterator& position) {
    seq->erase(position);
  }

  template <class Sequence>
  struct traits_reserve {
    static void reserve(Sequence & /*seq*/, typename Sequence::size_type /*n*/) {
      // This should be specialized for types that support reserve
    }
  };

  template <class Sequence, class Difference>
  inline Sequence*
  getslice(const Sequence* self, Difference i, Difference j, Py_ssize_t step) {
    typename Sequence::size_type size = self->size();
    Difference ii = 0;
    Difference jj = 0;
    swig::slice_adjust(i, j, step, size, ii, jj);

    if (step > 0) {
      typename Sequence::const_iterator sb = self->begin();
      typename Sequence::const_iterator se = self->begin();
      std::advance(sb,ii);
      std::advance(se,jj);
      if (step == 1) {
        return new Sequence(sb, se);
      } else {
        Sequence *sequence = new Sequence();
        swig::traits_reserve<Sequence>::reserve(*sequence, (jj - ii + step - 1) / step);
        typename Sequence::const_iterator it = sb;
        while (it!=se) {
          sequence->push_back(*it);
          for (Py_ssize_t c=0; c<step && it!=se; ++c)
            it++;
        }
        return sequence;
      } 
    } else {
      Sequence *sequence = new Sequence();
      swig::traits_reserve<Sequence>::reserve(*sequence, (ii - jj - step - 1) / -step);
      typename Sequence::const_reverse_iterator sb = self->rbegin();
      typename Sequence::const_reverse_iterator se = self->rbegin();
      std::advance(sb,size-ii-1);
      std::advance(se,size-jj-1);
      typename Sequence::const_reverse_iterator it = sb;
      while (it!=se) {
        sequence->push_back(*it);
        for (Py_ssize_t c=0; c<-step && it!=se; ++c)
          it++;
      }
      return sequence;
    }
  }

  template <class Sequence, class Difference, class InputSeq>
  inline void
  setslice(Sequence* self, Difference i, Difference j, Py_ssize_t step, const InputSeq& is = InputSeq()) {
    typename Sequence::size_type size = self->size();
    Difference ii = 0;
    Difference jj = 0;
    swig::slice_adjust(i, j, step, size, ii, jj, true);
    if (step > 0) {
      if (step == 1) {
        size_t ssize = jj - ii;
        if (ssize <= is.size()) {
          // expanding/staying the same size
          swig::traits_reserve<Sequence>::reserve(*self, self->size() - ssize + is.size());
          typename Sequence::iterator sb = self->begin();
          typename InputSeq::const_iterator isit = is.begin();
          std::advance(sb,ii);
          std::advance(isit, jj - ii);
          self->insert(std::copy(is.begin(), isit, sb), isit, is.end());
        } else {
          // shrinking
          typename Sequence::iterator sb = self->begin();
          typename Sequence::iterator se = self->begin();
          std::advance(sb,ii);
          std::advance(se,jj);
          self->erase(sb,se);
          sb = self->begin();
          std::advance(sb,ii);
          self->insert(sb, is.begin(), is.end());
        }
      } else {
        size_t replacecount = (jj - ii + step - 1) / step;
        if (is.size() != replacecount) {
          char msg[1024];
          sprintf(msg, "attempt to assign sequence of size %lu to extended slice of size %lu", (unsigned long)is.size(), (unsigned long)replacecount);
          throw std::invalid_argument(msg);
        }
        typename Sequence::const_iterator isit = is.begin();
        typename Sequence::iterator it = self->begin();
        std::advance(it,ii);
        for (size_t rc=0; rc<replacecount && it != self->end(); ++rc) {
          *it++ = *isit++;
          for (Py_ssize_t c=0; c<(step-1) && it != self->end(); ++c)
            it++;
        }
      }
    } else {
      size_t replacecount = (ii - jj - step - 1) / -step;
      if (is.size() != replacecount) {
        char msg[1024];
        sprintf(msg, "attempt to assign sequence of size %lu to extended slice of size %lu", (unsigned long)is.size(), (unsigned long)replacecount);
        throw std::invalid_argument(msg);
      }
      typename Sequence::const_iterator isit = is.begin();
      typename Sequence::reverse_iterator it = self->rbegin();
      std::advance(it,size-ii-1);
      for (size_t rc=0; rc<replacecount && it != self->rend(); ++rc) {
        *it++ = *isit++;
        for (Py_ssize_t c=0; c<(-step-1) && it != self->rend(); ++c)
          it++;
      }
    }
  }

  template <class Sequence, class Difference>
  inline void
  delslice(Sequence* self, Difference i, Difference j, Py_ssize_t step) {
    typename Sequence::size_type size = self->size();
    Difference ii = 0;
    Difference jj = 0;
    swig::slice_adjust(i, j, step, size, ii, jj, true);
    if (step > 0) {
      typename Sequence::iterator sb = self->begin();
      std::advance(sb,ii);
      if (step == 1) {
        typename Sequence::iterator se = self->begin();
        std::advance(se,jj);
        self->erase(sb,se);
      } else {
        typename Sequence::iterator it = sb;
        size_t delcount = (jj - ii + step - 1) / step;
        while (delcount) {
          it = self->erase(it);
          for (Py_ssize_t c=0; c<(step-1) && it != self->end(); ++c)
            it++;
          delcount--;
        }
      }
    } else {
      typename Sequence::reverse_iterator sb = self->rbegin();
      std::advance(sb,size-ii-1);
      typename Sequence::reverse_iterator it = sb;
      size_t delcount = (ii - jj - step - 1) / -step;
      while (delcount) {
        it = typename Sequence::reverse_iterator(self->erase((++it).base()));
        for (Py_ssize_t c=0; c<(-step-1) && it != self->rend(); ++c)
          it++;
        delcount--;
      }
    }
  }
}


#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 {
  template<typename OutIterator>
  class SwigPyIterator_T :  public SwigPyIterator
  {
  public:
    typedef OutIterator out_iterator;
    typedef typename std::iterator_traits<out_iterator>::value_type value_type;    
    typedef SwigPyIterator_T<out_iterator> self_type;

    SwigPyIterator_T(out_iterator curr, PyObject *seq)
      : SwigPyIterator(seq), current(curr)
    {
    }

    const out_iterator& get_current() const
    {
      return current;
    }

    
    bool equal (const SwigPyIterator &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");
      }
    }
    
    ptrdiff_t distance(const SwigPyIterator &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");
      }
    }    
    
  protected:
    out_iterator current;
  };
  
  template <class ValueType>
  struct from_oper 
  {
    typedef const ValueType& argument_type;
    typedef PyObject *result_type;
    result_type operator()(argument_type v) const
    {
      return swig::from(v);
    }
  };

  template<typename OutIterator, 
	   typename ValueType = typename std::iterator_traits<OutIterator>::value_type,
	   typename FromOper = from_oper<ValueType> >
  class SwigPyForwardIteratorOpen_T :  public SwigPyIterator_T<OutIterator>
  {
  public:
    FromOper from;
    typedef OutIterator out_iterator;
    typedef ValueType value_type;
    typedef SwigPyIterator_T<out_iterator>  base;
    typedef SwigPyForwardIteratorOpen_T<OutIterator, ValueType, FromOper> self_type;
    
    SwigPyForwardIteratorOpen_T(out_iterator curr, PyObject *seq)
      : SwigPyIterator_T<OutIterator>(curr, seq)
    {
    }
    
    PyObject *value() const {
      return from(static_cast<const value_type&>(*(base::current)));
    }
    
    SwigPyIterator *copy() const
    {
      return new self_type(*this);
    }

    SwigPyIterator *incr(size_t n = 1)
    {
      while (n--) {
	++base::current;
      }
      return this;
    }

  };

  template<typename OutIterator, 
	   typename ValueType = typename std::iterator_traits<OutIterator>::value_type,
	   typename FromOper = from_oper<ValueType> >
  class SwigPyIteratorOpen_T :  public SwigPyForwardIteratorOpen_T<OutIterator, ValueType, FromOper>
  {
  public:
    FromOper from;
    typedef OutIterator out_iterator;
    typedef ValueType value_type;
    typedef SwigPyIterator_T<out_iterator>  base;
    typedef SwigPyIteratorOpen_T<OutIterator, ValueType, FromOper> self_type;
    
    SwigPyIteratorOpen_T(out_iterator curr, PyObject *seq)
      : SwigPyForwardIteratorOpen_T<OutIterator>(curr, seq)
    {
    }

    SwigPyIterator *decr(size_t n = 1)
    {
      while (n--) {
	--base::current;
      }
      return this;
    }
  };

  template<typename OutIterator, 
	   typename ValueType = typename std::iterator_traits<OutIterator>::value_type,
	   typename FromOper = from_oper<ValueType> >
  class SwigPyForwardIteratorClosed_T :  public SwigPyIterator_T<OutIterator>
  {
  public:
    FromOper from;
    typedef OutIterator out_iterator;
    typedef ValueType value_type;
    typedef SwigPyIterator_T<out_iterator>  base;    
    typedef SwigPyForwardIteratorClosed_T<OutIterator, ValueType, FromOper> self_type;
    
    SwigPyForwardIteratorClosed_T(out_iterator curr, out_iterator first, out_iterator last, PyObject *seq)
      : SwigPyIterator_T<OutIterator>(curr, seq), begin(first), end(last)
    {
    }
    
    PyObject *value() const {
      if (base::current == end) {
	throw stop_iteration();
      } else {
	return from(static_cast<const value_type&>(*(base::current)));
      }
    }
    
    SwigPyIterator *copy() const
    {
      return new self_type(*this);
    }

    SwigPyIterator *incr(size_t n = 1)
    {
      while (n--) {
	if (base::current == end) {
	  throw stop_iteration();
	} else {
	  ++base::current;
	}
      }
      return this;
    }

  protected:
    out_iterator begin;
    out_iterator end;
  };

  template<typename OutIterator, 
	   typename ValueType = typename std::iterator_traits<OutIterator>::value_type,
	   typename FromOper = from_oper<ValueType> >
  class SwigPyIteratorClosed_T :  public SwigPyForwardIteratorClosed_T<OutIterator,ValueType,FromOper>
  {
  public:
    FromOper from;
    typedef OutIterator out_iterator;
    typedef ValueType value_type;
    typedef SwigPyIterator_T<out_iterator>  base;
    typedef SwigPyForwardIteratorClosed_T<OutIterator, ValueType, FromOper> base0;
    typedef SwigPyIteratorClosed_T<OutIterator, ValueType, FromOper> self_type;
    
    SwigPyIteratorClosed_T(out_iterator curr, out_iterator first, out_iterator last, PyObject *seq)
      : SwigPyForwardIteratorClosed_T<OutIterator,ValueType,FromOper>(curr, first, last, seq)
    {
    }

    SwigPyIterator *decr(size_t n = 1)
    {
      while (n--) {
	if (base::current == base0::begin) {
	  throw stop_iteration();
	} else {
	  --base::current;
	}
      }
      return this;
    }
  };


  template<typename OutIter>
  inline SwigPyIterator*
  make_output_forward_iterator(const OutIter& current, const OutIter& begin,const OutIter& end, PyObject *seq = 0)
  {
    return new SwigPyForwardIteratorClosed_T<OutIter>(current, begin, end, seq);
  }

  template<typename OutIter>
  inline SwigPyIterator*
  make_output_iterator(const OutIter& current, const OutIter& begin,const OutIter& end, PyObject *seq = 0)
  {
    return new SwigPyIteratorClosed_T<OutIter>(current, begin, end, seq);
  }

  template<typename OutIter>
  inline SwigPyIterator*
  make_output_forward_iterator(const OutIter& current, PyObject *seq = 0)
  {
    return new SwigPyForwardIteratorOpen_T<OutIter>(current, seq);
  }

  template<typename OutIter>
  inline SwigPyIterator*
  make_output_iterator(const OutIter& current, PyObject *seq = 0)
  {
    return new SwigPyIteratorOpen_T<OutIter>(current, seq);
  }

}


namespace swig
{
  template <class T>
  struct SwigPySequence_Ref
  {
    SwigPySequence_Ref(PyObject* seq, Py_ssize_t index)
      : _seq(seq), _index(index)
    {
    }
    
    operator T () const
    {
      swig::SwigVar_PyObject item = PySequence_GetItem(_seq, _index);
      try {
	return swig::as<T>(item);
      } catch (const std::invalid_argument& e) {
	char msg[1024];
	sprintf(msg, "in sequence element %d ", (int)_index);
	if (!PyErr_Occurred()) {
	  ::SWIG_Error(SWIG_TypeError,  swig::type_name<T>());
	}
	SWIG_Python_AddErrorMsg(msg);
	SWIG_Python_AddErrorMsg(e.what());
	throw;
      }
    }

    SwigPySequence_Ref& operator=(const T& v)
    {
      PySequence_SetItem(_seq, _index, swig::from<T>(v));
      return *this;
    }

  private:
    PyObject* _seq;
    Py_ssize_t _index;
  };

  template <class T>
  struct SwigPySequence_ArrowProxy
  {
    SwigPySequence_ArrowProxy(const T& x): m_value(x) {}
    const T* operator->() const { return &m_value; }
    operator const T*() const { return &m_value; }
    T m_value;
  };

  template <class T, class Reference >
  struct SwigPySequence_InputIterator
  {
    typedef SwigPySequence_InputIterator<T, Reference > self;

    typedef std::random_access_iterator_tag iterator_category;
    typedef Reference reference;
    typedef T value_type;
    typedef T* pointer;
    typedef Py_ssize_t difference_type;

    SwigPySequence_InputIterator()
    {
    }

    SwigPySequence_InputIterator(PyObject* seq, Py_ssize_t index)
      : _seq(seq), _index(index)
    {
    }

    reference operator*() const
    {
      return reference(_seq, _index);
    }

    SwigPySequence_ArrowProxy<T>
    operator->() const {
      return SwigPySequence_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:
    PyObject* _seq;
    difference_type _index;
  };

  // STL container wrapper around a Python sequence
  template <class T>
  struct SwigPySequence_Cont
  {
    typedef SwigPySequence_Ref<T> reference;
    typedef const SwigPySequence_Ref<T> const_reference;
    typedef T value_type;
    typedef T* pointer;
    typedef Py_ssize_t difference_type;
    typedef size_t size_type;
    typedef const pointer const_pointer;
    typedef SwigPySequence_InputIterator<T, reference> iterator;
    typedef SwigPySequence_InputIterator<T, const_reference> const_iterator;

    SwigPySequence_Cont(PyObject* seq) : _seq(0)
    {
      if (!PySequence_Check(seq)) {
	throw std::invalid_argument("a sequence is expected");
      }
      _seq = seq;
      Py_INCREF(_seq);
    }

    ~SwigPySequence_Cont()
    {
      Py_XDECREF(_seq);
    }

    size_type size() const
    {
      return static_cast<size_type>(PySequence_Size(_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() const
    {
      Py_ssize_t s = size();
      for (Py_ssize_t i = 0; i < s; ++i) {
	swig::SwigVar_PyObject item = PySequence_GetItem(_seq, i);
	if (!swig::check<value_type>(item))
	  return false;
      }
      return true;
    }

  private:
    PyObject* _seq;
  };

}


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;
}


SWIGINTERN int
SWIG_AsCharPtrAndSize(PyObject *obj, char** cptr, size_t* psize, int *alloc)
{
#if PY_VERSION_HEX>=0x03000000
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
  if (PyBytes_Check(obj))
#else
  if (PyUnicode_Check(obj))
#endif
#else  
  if (PyString_Check(obj))
#endif
  {
    char *cstr; Py_ssize_t len;
    int ret = SWIG_OK;
#if PY_VERSION_HEX>=0x03000000
#if !defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
    if (!alloc && cptr) {
        /* We can't allow converting without allocation, since the internal
           representation of string in Python 3 is UCS-2/UCS-4 but we require
           a UTF-8 representation.
           TODO(bhy) More detailed explanation */
        return SWIG_RuntimeError;
    }
    obj = PyUnicode_AsUTF8String(obj);
    if (!obj)
      return SWIG_TypeError;
    if (alloc)
      *alloc = SWIG_NEWOBJ;
#endif
    if (PyBytes_AsStringAndSize(obj, &cstr, &len) == -1)
      return SWIG_TypeError;
#else
    if (PyString_AsStringAndSize(obj, &cstr, &len) == -1)
      return SWIG_TypeError;
#endif
    if (cptr) {
      if (alloc) {
	if (*alloc == SWIG_NEWOBJ) {
	  *cptr = reinterpret_cast< char* >(memcpy(new char[len + 1], cstr, sizeof(char)*(len + 1)));
	  *alloc = SWIG_NEWOBJ;
	} else {
	  *cptr = cstr;
	  *alloc = SWIG_OLDOBJ;
	}
      } else {
#if PY_VERSION_HEX>=0x03000000
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
	*cptr = PyBytes_AsString(obj);
#else
	assert(0); /* Should never reach here with Unicode strings in Python 3 */
#endif
#else
	*cptr = SWIG_Python_str_AsChar(obj);
        if (!*cptr)
          ret = SWIG_TypeError;
#endif
      }
    }
    if (psize) *psize = len + 1;
#if PY_VERSION_HEX>=0x03000000 && !defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
    Py_XDECREF(obj);
#endif
    return ret;
  } else {
#if defined(SWIG_PYTHON_2_UNICODE)
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
#error "Cannot use both SWIG_PYTHON_2_UNICODE and SWIG_PYTHON_STRICT_BYTE_CHAR at once"
#endif
#if PY_VERSION_HEX<0x03000000
    if (PyUnicode_Check(obj)) {
      char *cstr; Py_ssize_t len;
      if (!alloc && cptr) {
        return SWIG_RuntimeError;
      }
      obj = PyUnicode_AsUTF8String(obj);
      if (!obj)
        return SWIG_TypeError;
      if (PyString_AsStringAndSize(obj, &cstr, &len) != -1) {
        if (cptr) {
          if (alloc) *alloc = SWIG_NEWOBJ;
          *cptr = reinterpret_cast< char* >(memcpy(new char[len + 1], cstr, sizeof(char)*(len + 1)));
        }
        if (psize) *psize = len + 1;

        Py_XDECREF(obj);
        return SWIG_OK;
      } else {
        Py_XDECREF(obj);
      }
    }
#endif
#endif

    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_AsPtr_std_string (PyObject * obj, std::string **val) 
{
  char* buf = 0 ; size_t size = 0; int alloc = SWIG_OLDOBJ;
  if (SWIG_IsOK((SWIG_AsCharPtrAndSize(obj, &buf, &size, &alloc)))) {
    if (buf) {
      if (val) *val = new std::string(buf, size - 1);
      if (alloc == SWIG_NEWOBJ) delete[] buf;
      return SWIG_NEWOBJ;
    } else {
      if (val) *val = 0;
      return SWIG_OLDOBJ;
    }
  } else {
    static int init = 0;
    static swig_type_info* descriptor = 0;
    if (!init) {
      descriptor = SWIG_TypeQuery("std::string" " *");
      init = 1;
    }
    if (descriptor) {
      std::string *vptr;
      int res = SWIG_ConvertPtr(obj, (void**)&vptr, descriptor, 0);
      if (SWIG_IsOK(res) && val) *val = vptr;
      return res;
    }
  }
  return SWIG_ERROR;
}


SWIGINTERN int
SWIG_AsVal_std_string (PyObject * obj, std::string *val)
{
  std::string* v = (std::string *) 0;
  int res = SWIG_AsPtr_std_string (obj, &v);
  if (!SWIG_IsOK(res)) return res;
  if (v) {
    if (val) *val = *v;
    if (SWIG_IsNewObj(res)) {
      delete v;
      res = SWIG_DelNewMask(res);
    }
    return res;
  }
  return SWIG_ERROR;
}


SWIGINTERNINLINE PyObject *
SWIG_FromCharPtrAndSize(const char* carray, size_t size)
{
  if (carray) {
    if (size > INT_MAX) {
      swig_type_info* pchar_descriptor = SWIG_pchar_descriptor();
      return pchar_descriptor ? 
	SWIG_InternalNewPointerObj(const_cast< char * >(carray), pchar_descriptor, 0) : SWIG_Py_Void();
    } else {
#if PY_VERSION_HEX >= 0x03000000
#if defined(SWIG_PYTHON_STRICT_BYTE_CHAR)
      return PyBytes_FromStringAndSize(carray, static_cast< Py_ssize_t >(size));
#else
      return PyUnicode_DecodeUTF8(carray, static_cast< Py_ssize_t >(size), "surrogateescape");
#endif
#else
      return PyString_FromStringAndSize(carray, static_cast< Py_ssize_t >(size));
#endif
    }
  } else {
    return SWIG_Py_Void();
  }
}


SWIGINTERNINLINE PyObject *
SWIG_From_std_string  (const std::string& s)
{
  return SWIG_FromCharPtrAndSize(s.data(), s.size());
}


namespace swig {
  template <> struct traits< std::string > {
    typedef value_category category;
    static const char* type_name() { return"std::string"; }
  };
  template <>  struct traits_asval< std::string > {
    typedef std::string value_type;
    static int asval(PyObject *obj, value_type *val) {
      return SWIG_AsVal_std_string (obj, val);
    }
  };
  template <>  struct traits_from< std::string > {
    typedef std::string value_type;
    static PyObject *from(const value_type& val) {
      return SWIG_From_std_string  (val);
    }
  };
}


namespace swig {
  template <class SwigPySeq, class Seq>
  inline void
  assign(const SwigPySeq& swigpyseq, Seq* seq) {
    // seq->assign(swigpyseq.begin(), swigpyseq.end()); // not used as not always implemented
    typedef typename SwigPySeq::value_type value_type;
    typename SwigPySeq::const_iterator it = swigpyseq.begin();
    for (;it != swigpyseq.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(PyObject *obj, sequence **seq) {
      if (obj == Py_None || SWIG_Python_GetSwigThis(obj)) {
	sequence *p;
	swig_type_info *descriptor = swig::type_info<sequence>();
	if (descriptor && SWIG_IsOK(::SWIG_ConvertPtr(obj, (void **)&p, descriptor, 0))) {
	  if (seq) *seq = p;
	  return SWIG_OLDOBJ;
	}
      } else if (PySequence_Check(obj)) {
	try {
	  SwigPySequence_Cont<value_type> swigpyseq(obj);
	  if (seq) {
	    sequence *pseq = new sequence();
	    assign(swigpyseq, pseq);
	    *seq = pseq;
	    return SWIG_NEWOBJ;
	  } else {
	    return swigpyseq.check() ? SWIG_OK : SWIG_ERROR;
	  }
	} catch (std::exception& e) {
	  if (seq) {
	    if (!PyErr_Occurred()) {
	      PyErr_SetString(PyExc_TypeError, e.what());
	    }
	  }
	  return SWIG_ERROR;
	}
      }
      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 PyObject *from(const sequence& seq) {
#ifdef SWIG_PYTHON_EXTRA_NATIVE_CONTAINERS
      swig_type_info *desc = swig::type_info<sequence>();
      if (desc && desc->clientdata) {
	return SWIG_InternalNewPointerObj(new sequence(seq), desc, SWIG_POINTER_OWN);
      }
#endif
      size_type size = seq.size();
      if (size <= (size_type)INT_MAX) {
	PyObject *obj = PyTuple_New((Py_ssize_t)size);
	Py_ssize_t i = 0;
	for (const_iterator it = seq.begin(); it != seq.end(); ++it, ++i) {
	  PyTuple_SetItem(obj,i,swig::from<value_type>(*it));
	}
	return obj;
      } else {
	PyErr_SetString(PyExc_OverflowError,"sequence size not valid in python");
	return NULL;
      }
    }
  };
}


  namespace swig {
    template <class T>
    struct traits_reserve<std::vector<T> > {
      static void reserve(std::vector<T> &seq, typename std::vector<T>::size_type n) {
        seq.reserve(n);
      }
    };

    template <class T>
    struct traits_asptr<std::vector<T> >  {
      static int asptr(PyObject *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 PyObject *from(const std::vector<T>& vec) {
	return traits_from_stdseq<std::vector<T> >::from(vec);
      }
    };
  }


      namespace swig {
	template <>  struct traits<std::vector< std::string, std::allocator< std::string > > > {
	  typedef pointer_category category;
	  static const char* type_name() {
	    return "std::vector<" "std::string" "," "std::allocator< std::string >" " >";
	  }
	};
      }
    
SWIGINTERN swig::SwigPyIterator *std_vector_Sl_std_string_Sg__iterator(std::vector< std::string > *self,PyObject **PYTHON_SELF){
      return swig::make_output_iterator(self->begin(), self->begin(), self->end(), *PYTHON_SELF);
    }
SWIGINTERN bool std_vector_Sl_std_string_Sg____nonzero__(std::vector< std::string > const *self){
      return !(self->empty());
    }
SWIGINTERN bool std_vector_Sl_std_string_Sg____bool__(std::vector< std::string > const *self){
      return !(self->empty());
    }
SWIGINTERN std::vector< std::string >::size_type std_vector_Sl_std_string_Sg____len__(std::vector< std::string > const *self){
      return self->size();
    }

SWIGINTERNINLINE PyObject* 
SWIG_From_unsigned_SS_long  (unsigned long value)
{
  return (value > LONG_MAX) ?
    PyLong_FromUnsignedLong(value) : PyInt_FromLong(static_cast< long >(value));
}


#ifdef SWIG_LONG_LONG_AVAILABLE
SWIGINTERNINLINE PyObject* 
SWIG_From_unsigned_SS_long_SS_long  (unsigned long long value)
{
  return (value > LONG_MAX) ?
    PyLong_FromUnsignedLongLong(value) : PyInt_FromLong(static_cast< long >(value));
}
#endif


SWIGINTERNINLINE PyObject *
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< std::string,std::allocator< std::string > > *std_vector_Sl_std_string_Sg____getslice__(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::difference_type j){
      return swig::getslice(self, i, j, 1);
    }
SWIGINTERN void std_vector_Sl_std_string_Sg____setslice____SWIG_0(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::difference_type j){
      swig::setslice(self, i, j, 1, std::vector< std::string,std::allocator< std::string > >());
    }
SWIGINTERN void std_vector_Sl_std_string_Sg____setslice____SWIG_1(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::difference_type j,std::vector< std::string,std::allocator< std::string > > const &v){
      swig::setslice(self, i, j, 1, v);
    }
SWIGINTERN void std_vector_Sl_std_string_Sg____delslice__(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::difference_type j){
      swig::delslice(self, i, j, 1);
    }
SWIGINTERN void std_vector_Sl_std_string_Sg____delitem____SWIG_0(std::vector< std::string > *self,std::vector< std::string >::difference_type i){
      swig::erase(self, swig::getpos(self, i));
    }
SWIGINTERN std::vector< std::string,std::allocator< std::string > > *std_vector_Sl_std_string_Sg____getitem____SWIG_0(std::vector< std::string > *self,SWIGPY_SLICEOBJECT *slice){
      Py_ssize_t i, j, step;
      if( !PySlice_Check(slice) ) {
        SWIG_Error(SWIG_TypeError, "Slice object expected.");
        return NULL;
      }
      PySlice_GetIndices(slice, (Py_ssize_t)self->size(), &i, &j, &step);
      std::vector< std::string,std::allocator< std::string > >::difference_type id = i;
      std::vector< std::string,std::allocator< std::string > >::difference_type jd = j;
      return swig::getslice(self, id, jd, step);
    }
SWIGINTERN void std_vector_Sl_std_string_Sg____setitem____SWIG_0(std::vector< std::string > *self,SWIGPY_SLICEOBJECT *slice,std::vector< std::string,std::allocator< std::string > > const &v){
      Py_ssize_t i, j, step;
      if( !PySlice_Check(slice) ) {
        SWIG_Error(SWIG_TypeError, "Slice object expected.");
        return;
      }
      PySlice_GetIndices(slice, (Py_ssize_t)self->size(), &i, &j, &step);
      std::vector< std::string,std::allocator< std::string > >::difference_type id = i;
      std::vector< std::string,std::allocator< std::string > >::difference_type jd = j;
      swig::setslice(self, id, jd, step, v);
    }
SWIGINTERN void std_vector_Sl_std_string_Sg____setitem____SWIG_1(std::vector< std::string > *self,SWIGPY_SLICEOBJECT *slice){
      Py_ssize_t i, j, step;
      if( !PySlice_Check(slice) ) {
        SWIG_Error(SWIG_TypeError, "Slice object expected.");
        return;
      }
      PySlice_GetIndices(slice, (Py_ssize_t)self->size(), &i, &j, &step);
      std::vector< std::string,std::allocator< std::string > >::difference_type id = i;
      std::vector< std::string,std::allocator< std::string > >::difference_type jd = j;
      swig::delslice(self, id, jd, step);
    }
SWIGINTERN void std_vector_Sl_std_string_Sg____delitem____SWIG_1(std::vector< std::string > *self,SWIGPY_SLICEOBJECT *slice){
      Py_ssize_t i, j, step;
      if( !PySlice_Check(slice) ) {
        SWIG_Error(SWIG_TypeError, "Slice object expected.");
        return;
      }
      PySlice_GetIndices(slice, (Py_ssize_t)self->size(), &i, &j, &step);
      std::vector< std::string,std::allocator< std::string > >::difference_type id = i;
      std::vector< std::string,std::allocator< std::string > >::difference_type jd = j;
      swig::delslice(self, id, jd, step);
    }
SWIGINTERN std::vector< std::string >::value_type const &std_vector_Sl_std_string_Sg____getitem____SWIG_1(std::vector< std::string > const *self,std::vector< std::string >::difference_type i){
      return *(swig::cgetpos(self, i));
    }

namespace swig {
  static PyObject* container_owner_attribute() {
    static PyObject* attr = SWIG_Python_str_FromChar("__swig_container");
    return attr;
  }

  template <typename T>
  struct container_owner {
    // By default, do not add the back-reference (for value types)
    // Specialization below will check the reference for pointer types.
    static bool back_reference(PyObject* /*child*/, PyObject* /*owner*/) {
      return false;
    }
  };

  template <>
  struct container_owner<swig::pointer_category> {  
    /*
     * Call to add a back-reference to the owning object when returning a 
     * reference from a container.  Will only set the reference if child
     * is a SWIG wrapper object that does not own the pointer.
     *
     * returns whether the reference was set or not
     */
    static bool back_reference(PyObject* child, PyObject* owner) {
      SwigPyObject* swigThis = SWIG_Python_GetSwigThis(child);
      if (swigThis && (swigThis->own & SWIG_POINTER_OWN) != SWIG_POINTER_OWN) {
        return PyObject_SetAttr(child, container_owner_attribute(), owner) != -1;
      }
      return false;
    }
  };
}

SWIGINTERN void std_vector_Sl_std_string_Sg____setitem____SWIG_2(std::vector< std::string > *self,std::vector< std::string >::difference_type i,std::vector< std::string >::value_type const &x){
      *(swig::getpos(self,i)) = x;
    }
SWIGINTERN std::vector< std::string >::value_type std_vector_Sl_std_string_Sg__pop(std::vector< std::string > *self){
      if (self->size() == 0)
	throw std::out_of_range("pop from empty container");
      std::vector< std::string,std::allocator< std::string > >::value_type x = self->back();
      self->pop_back();
      return x;
    }
SWIGINTERN void std_vector_Sl_std_string_Sg__append(std::vector< std::string > *self,std::vector< std::string >::value_type const &x){
      self->push_back(x);
    }
SWIGINTERN std::vector< std::string >::iterator std_vector_Sl_std_string_Sg__erase__SWIG_0(std::vector< std::string > *self,std::vector< std::string >::iterator pos){ return self->erase(pos); }
SWIGINTERN std::vector< std::string >::iterator std_vector_Sl_std_string_Sg__erase__SWIG_1(std::vector< std::string > *self,std::vector< std::string >::iterator first,std::vector< std::string >::iterator last){ return self->erase(first, last); }
SWIGINTERN std::vector< std::string >::iterator std_vector_Sl_std_string_Sg__insert__SWIG_0(std::vector< std::string > *self,std::vector< std::string >::iterator pos,std::vector< std::string >::value_type const &x){ return self->insert(pos, x); }
SWIGINTERN void std_vector_Sl_std_string_Sg__insert__SWIG_1(std::vector< std::string > *self,std::vector< std::string >::iterator pos,std::vector< std::string >::size_type n,std::vector< std::string >::value_type const &x){ self->insert(pos, n, x); }

SWIGINTERN int
SWIG_AsVal_int (PyObject * 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;
}


#if NPY_API_VERSION < 0x00000007
#define NPY_ARRAY_DEFAULT NPY_DEFAULT
#define NPY_ARRAY_FARRAY  NPY_FARRAY
#define NPY_FORTRANORDER  NPY_FORTRAN
#endif


/* Macros to extract array attributes.
 */
#if NPY_API_VERSION < 0x00000007
#define is_array(a)            ((a) && PyArray_Check((PyArrayObject*)a))
#define array_type(a)          (int)(PyArray_TYPE((PyArrayObject*)a))
#define array_numdims(a)       (((PyArrayObject*)a)->nd)
#define array_dimensions(a)    (((PyArrayObject*)a)->dimensions)
#define array_size(a,i)        (((PyArrayObject*)a)->dimensions[i])
#define array_strides(a)       (((PyArrayObject*)a)->strides)
#define array_stride(a,i)      (((PyArrayObject*)a)->strides[i])
#define array_data(a)          (((PyArrayObject*)a)->data)
#define array_descr(a)         (((PyArrayObject*)a)->descr)
#define array_flags(a)         (((PyArrayObject*)a)->flags)
#define array_clearflags(a,f)  (((PyArrayObject*)a)->flags) &= ~f
#define array_enableflags(a,f) (((PyArrayObject*)a)->flags) = f
#define array_is_fortran(a)    (PyArray_ISFORTRAN((PyArrayObject*)a))
#else
#define is_array(a)            ((a) && PyArray_Check(a))
#define array_type(a)          PyArray_TYPE((PyArrayObject*)a)
#define array_numdims(a)       PyArray_NDIM((PyArrayObject*)a)
#define array_dimensions(a)    PyArray_DIMS((PyArrayObject*)a)
#define array_strides(a)       PyArray_STRIDES((PyArrayObject*)a)
#define array_stride(a,i)      PyArray_STRIDE((PyArrayObject*)a,i)
#define array_size(a,i)        PyArray_DIM((PyArrayObject*)a,i)
#define array_data(a)          PyArray_DATA((PyArrayObject*)a)
#define array_descr(a)         PyArray_DESCR((PyArrayObject*)a)
#define array_flags(a)         PyArray_FLAGS((PyArrayObject*)a)
#define array_enableflags(a,f) PyArray_ENABLEFLAGS((PyArrayObject*)a,f)
#define array_clearflags(a,f)  PyArray_CLEARFLAGS((PyArrayObject*)a,f)
#define array_is_fortran(a)    (PyArray_IS_F_CONTIGUOUS((PyArrayObject*)a))
#endif
#define array_is_contiguous(a) (PyArray_ISCONTIGUOUS((PyArrayObject*)a))
#define array_is_native(a)     (PyArray_ISNOTSWAPPED((PyArrayObject*)a))


  /* Given a PyObject, return a string describing its type.
   */
  const char* pytype_string(PyObject* py_obj)
  {
    if (py_obj == NULL          ) return "C NULL value";
    if (py_obj == Py_None       ) return "Python None" ;
    if (PyCallable_Check(py_obj)) return "callable"    ;
    if (PyString_Check(  py_obj)) return "string"      ;
    if (PyInt_Check(     py_obj)) return "int"         ;
    if (PyFloat_Check(   py_obj)) return "float"       ;
    if (PyDict_Check(    py_obj)) return "dict"        ;
    if (PyList_Check(    py_obj)) return "list"        ;
    if (PyTuple_Check(   py_obj)) return "tuple"       ;
#if PY_MAJOR_VERSION < 3
    if (PyFile_Check(    py_obj)) return "file"        ;
    if (PyModule_Check(  py_obj)) return "module"      ;
    if (PyInstance_Check(py_obj)) return "instance"    ;
#endif

    return "unknown type";
  }

  /* Given a NumPy typecode, return a string describing the type.
   */
  const char* typecode_string(int typecode)
  {
    static const char* type_names[25] = {"bool",
                                         "byte",
                                         "unsigned byte",
                                         "short",
                                         "unsigned short",
                                         "int",
                                         "unsigned int",
                                         "long",
                                         "unsigned long",
                                         "long long",
                                         "unsigned long long",
                                         "float",
                                         "double",
                                         "long double",
                                         "complex float",
                                         "complex double",
                                         "complex long double",
                                         "object",
                                         "string",
                                         "unicode",
                                         "void",
                                         "ntypes",
                                         "notype",
                                         "char",
                                         "unknown"};
    return typecode < 24 ? type_names[typecode] : type_names[24];
  }

  /* Make sure input has correct numpy type.  This now just calls
     PyArray_EquivTypenums().
   */
  int type_match(int actual_type,
                 int desired_type)
  {
    return PyArray_EquivTypenums(actual_type, desired_type);
  }

#ifdef SWIGPY_USE_CAPSULE
  void free_cap(PyObject * cap)
  {
    void* array = (void*) PyCapsule_GetPointer(cap,SWIGPY_CAPSULE_NAME);
    if (array != NULL) free(array);
  }
#endif




  /* Given a PyObject pointer, cast it to a PyArrayObject pointer if
   * legal.  If not, set the python error string appropriately and
   * return NULL.
   */
  PyArrayObject* obj_to_array_no_conversion(PyObject* input,
                                            int        typecode)
  {
    PyArrayObject* ary = NULL;
    if (is_array(input) && (typecode == NPY_NOTYPE ||
                            PyArray_EquivTypenums(array_type(input), typecode)))
    {
      ary = (PyArrayObject*) input;
    }
    else if is_array(input)
    {
      const char* desired_type = typecode_string(typecode);
      const char* actual_type  = typecode_string(array_type(input));
      PyErr_Format(PyExc_TypeError,
                   "Array of type '%s' required.  Array of type '%s' given",
                   desired_type, actual_type);
      ary = NULL;
    }
    else
    {
      const char* desired_type = typecode_string(typecode);
      const char* actual_type  = pytype_string(input);
      PyErr_Format(PyExc_TypeError,
                   "Array of type '%s' required.  A '%s' was given",
                   desired_type,
                   actual_type);
      ary = NULL;
    }
    return ary;
  }

  /* Convert the given PyObject to a NumPy array with the given
   * typecode.  On success, return a valid PyArrayObject* with the
   * correct type.  On failure, the python error string will be set and
   * the routine returns NULL.
   */
  PyArrayObject* obj_to_array_allow_conversion(PyObject* input,
                                               int       typecode,
                                               int*      is_new_object)
  {
    PyArrayObject* ary = NULL;
    PyObject*      py_obj;
    if (is_array(input) && (typecode == NPY_NOTYPE ||
                            PyArray_EquivTypenums(array_type(input),typecode)))
    {
      ary = (PyArrayObject*) input;
      *is_new_object = 0;
    }
    else
    {
      py_obj = PyArray_FROMANY(input, typecode, 0, 0, NPY_ARRAY_DEFAULT);
      /* If NULL, PyArray_FromObject will have set python error value.*/
      ary = (PyArrayObject*) py_obj;
      *is_new_object = 1;
    }
    return ary;
  }

  /* Given a PyArrayObject, check to see if it is contiguous.  If so,
   * return the input pointer and flag it as not a new object.  If it is
   * not contiguous, create a new PyArrayObject using the original data,
   * flag it as a new object and return the pointer.
   */
  PyArrayObject* make_contiguous(PyArrayObject* ary,
                                 int*           is_new_object,
                                 int            min_dims,
                                 int            max_dims)
  {
    PyArrayObject* result;
    if (array_is_contiguous(ary))
    {
      result = ary;
      *is_new_object = 0;
    }
    else
    {
      result = (PyArrayObject*) PyArray_ContiguousFromObject((PyObject*)ary,
                                                              array_type(ary),
                                                              min_dims,
                                                              max_dims);
      *is_new_object = 1;
    }
    return result;
  }

  /* Given a PyArrayObject, check to see if it is Fortran-contiguous.
   * If so, return the input pointer, but do not flag it as not a new
   * object.  If it is not Fortran-contiguous, create a new
   * PyArrayObject using the original data, flag it as a new object
   * and return the pointer.
   */
  PyArrayObject* make_fortran(PyArrayObject* ary,
                              int*           is_new_object)
  {
    PyArrayObject* result;
    if (array_is_fortran(ary))
    {
      result = ary;
      *is_new_object = 0;
    }
    else
    {
      Py_INCREF(array_descr(ary));
      result = (PyArrayObject*) PyArray_FromArray(ary,
                                                  array_descr(ary),
#if NPY_API_VERSION < 0x00000007
                                                  NPY_FORTRANORDER);
#else
                                                  NPY_ARRAY_F_CONTIGUOUS);
#endif
      *is_new_object = 1;
    }
    return result;
  }

  /* Convert a given PyObject to a contiguous PyArrayObject of the
   * specified type.  If the input object is not a contiguous
   * PyArrayObject, a new one will be created and the new object flag
   * will be set.
   */
  PyArrayObject* obj_to_array_contiguous_allow_conversion(PyObject* input,
                                                          int       typecode,
                                                          int*      is_new_object)
  {
    int is_new1 = 0;
    int is_new2 = 0;
    PyArrayObject* ary2;
    PyArrayObject* ary1 = obj_to_array_allow_conversion(input,
                                                        typecode,
                                                        &is_new1);
    if (ary1)
    {
      ary2 = make_contiguous(ary1, &is_new2, 0, 0);
      if ( is_new1 && is_new2)
      {
        Py_DECREF(ary1);
      }
      ary1 = ary2;
    }
    *is_new_object = is_new1 || is_new2;
    return ary1;
  }

  /* Convert a given PyObject to a Fortran-ordered PyArrayObject of the
   * specified type.  If the input object is not a Fortran-ordered
   * PyArrayObject, a new one will be created and the new object flag
   * will be set.
   */
  PyArrayObject* obj_to_array_fortran_allow_conversion(PyObject* input,
                                                       int       typecode,
                                                       int*      is_new_object)
  {
    int is_new1 = 0;
    int is_new2 = 0;
    PyArrayObject* ary2;
    PyArrayObject* ary1 = obj_to_array_allow_conversion(input,
                                                        typecode,
                                                        &is_new1);
    if (ary1)
    {
      ary2 = make_fortran(ary1, &is_new2);
      if (is_new1 && is_new2)
      {
        Py_DECREF(ary1);
      }
      ary1 = ary2;
    }
    *is_new_object = is_new1 || is_new2;
    return ary1;
  }


  /* Test whether a python object is contiguous.  If array is
   * contiguous, return 1.  Otherwise, set the python error string and
   * return 0.
   */
  int require_contiguous(PyArrayObject* ary)
  {
    int contiguous = 1;
    if (!array_is_contiguous(ary))
    {
      PyErr_SetString(PyExc_TypeError,
                      "Array must be contiguous.  A non-contiguous array was given");
      contiguous = 0;
    }
    return contiguous;
  }

  /* Test whether a python object is (C_ or F_) contiguous.  If array is
   * contiguous, return 1.  Otherwise, set the python error string and
   * return 0.
   */
  int require_c_or_f_contiguous(PyArrayObject* ary)
  {
    int contiguous = 1;
    if (!(array_is_contiguous(ary) || array_is_fortran(ary)))
    {
      PyErr_SetString(PyExc_TypeError,
                      "Array must be contiguous (C_ or F_).  A non-contiguous array was given");
      contiguous = 0;
    }
    return contiguous;
  }

  /* Require that a numpy array is not byte-swapped.  If the array is
   * not byte-swapped, return 1.  Otherwise, set the python error string
   * and return 0.
   */
  int require_native(PyArrayObject* ary)
  {
    int native = 1;
    if (!array_is_native(ary))
    {
      PyErr_SetString(PyExc_TypeError,
                      "Array must have native byteorder.  "
                      "A byte-swapped array was given");
      native = 0;
    }
    return native;
  }

  /* Require the given PyArrayObject to have a specified number of
   * dimensions.  If the array has the specified number of dimensions,
   * return 1.  Otherwise, set the python error string and return 0.
   */
  int require_dimensions(PyArrayObject* ary,
                         int            exact_dimensions)
  {
    int success = 1;
    if (array_numdims(ary) != exact_dimensions)
    {
      PyErr_Format(PyExc_TypeError,
                   "Array must have %d dimensions.  Given array has %d dimensions",
                   exact_dimensions,
                   array_numdims(ary));
      success = 0;
    }
    return success;
  }

  /* Require the given PyArrayObject to have one of a list of specified
   * number of dimensions.  If the array has one of the specified number
   * of dimensions, return 1.  Otherwise, set the python error string
   * and return 0.
   */
  int require_dimensions_n(PyArrayObject* ary,
                           int*           exact_dimensions,
                           int            n)
  {
    int success = 0;
    int i;
    char dims_str[255] = "";
    char s[255];
    for (i = 0; i < n && !success; i++)
    {
      if (array_numdims(ary) == exact_dimensions[i])
      {
        success = 1;
      }
    }
    if (!success)
    {
      for (i = 0; i < n-1; i++)
      {
        sprintf(s, "%d, ", exact_dimensions[i]);
        strcat(dims_str,s);
      }
      sprintf(s, " or %d", exact_dimensions[n-1]);
      strcat(dims_str,s);
      PyErr_Format(PyExc_TypeError,
                   "Array must have %s dimensions.  Given array has %d dimensions",
                   dims_str,
                   array_numdims(ary));
    }
    return success;
  }

  /* Require the given PyArrayObject to have a specified shape.  If the
   * array has the specified shape, return 1.  Otherwise, set the python
   * error string and return 0.
   */
  int require_size(PyArrayObject* ary,
                   npy_intp*      size,
                   int            n)
  {
    int i;
    int success = 1;
    size_t len;
    char desired_dims[255] = "[";
    char s[255];
    char actual_dims[255] = "[";
    for(i=0; i < n;i++)
    {
      if (size[i] != -1 &&  size[i] != array_size(ary,i))
      {
        success = 0;
      }
    }
    if (!success)
    {
      for (i = 0; i < n; i++)
      {
        if (size[i] == -1)
        {
          sprintf(s, "*,");
        }
        else
        {
          sprintf(s, "%ld,", (long int)size[i]);
        }
        strcat(desired_dims,s);
      }
      len = strlen(desired_dims);
      desired_dims[len-1] = ']';
      for (i = 0; i < n; i++)
      {
        sprintf(s, "%ld,", (long int)array_size(ary,i));
        strcat(actual_dims,s);
      }
      len = strlen(actual_dims);
      actual_dims[len-1] = ']';
      PyErr_Format(PyExc_TypeError,
                   "Array must have shape of %s.  Given array has shape of %s",
                   desired_dims,
                   actual_dims);
    }
    return success;
  }

  /* Require the given PyArrayObject to to be Fortran ordered.  If the
   * the PyArrayObject is already Fortran ordered, do nothing.  Else,
   * set the Fortran ordering flag and recompute the strides.
   */
  int require_fortran(PyArrayObject* ary)
  {
    int success = 1;
    int nd = array_numdims(ary);
    int i;
    npy_intp * strides = array_strides(ary);
    if (array_is_fortran(ary)) return success;
    int n_non_one = 0;
    /* Set the Fortran ordered flag */
    const npy_intp *dims = array_dimensions(ary);
    for (i=0; i < nd; ++i)
      n_non_one += (dims[i] != 1) ? 1 : 0;
    if (n_non_one > 1)    
      array_clearflags(ary,NPY_ARRAY_CARRAY);
    array_enableflags(ary,NPY_ARRAY_FARRAY);
    /* Recompute the strides */
    strides[0] = strides[nd-1];
    for (i=1; i < nd; ++i)
      strides[i] = strides[i-1] * array_size(ary,i-1);
    return success;
  }




SWIGINTERN int
SWIG_AsVal_bool (PyObject *obj, bool *val)
{
  int r;
  if (!PyBool_Check(obj))
    return SWIG_ERROR;
  r = PyObject_IsTrue(obj);
  if (r == -1)
    return SWIG_ERROR;
  if (val) *val = r ? true : false;
  return SWIG_OK;
}


#include <memory>

#ifdef __cplusplus
extern "C" {
#endif
SWIGINTERN int Swig_var_SPerrorNames_set(PyObject *) {
  SWIG_Error(SWIG_AttributeError,"Variable SPerrorNames is read-only.");
  return 1;
}


SWIGINTERN PyObject *Swig_var_SPerrorNames_get(void) {
  PyObject *pyobj = 0;
  
  pyobj = SWIG_NewPointerObj(SWIG_as_voidptr(SPerrorNames), SWIGTYPE_p_std__string,  0 );
  return pyobj;
}


SWIGINTERN int Swig_var_SPerrorStack_set(PyObject *_val) {
  {
    void *argp = 0;
    int res = SWIG_ConvertPtr(_val, &argp, SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t,  0  | 0);
    if (!SWIG_IsOK(res)) {
      SWIG_exception_fail(SWIG_ArgError(res), "in variable '""SPerrorStack""' of type '""StringVector""'");
    }
    if (!argp) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in variable '""SPerrorStack""' of type '""StringVector""'");
    } else {
      StringVector * temp;
      temp  = reinterpret_cast< StringVector * >(argp);
      SPerrorStack = *temp;
      if (SWIG_IsNewObj(res)) delete temp;
    }
  }
  return 0;
fail:
  return 1;
}


SWIGINTERN PyObject *Swig_var_SPerrorStack_get(void) {
  PyObject *pyobj = 0;
  
  pyobj = SWIG_NewPointerObj(SWIG_as_voidptr(&SPerrorStack), SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t,  0 );
  return pyobj;
}


SWIGINTERN int Swig_var_FUZZY_set(PyObject *) {
  SWIG_Error(SWIG_AttributeError,"Variable FUZZY is read-only.");
  return 1;
}


SWIGINTERN PyObject *Swig_var_FUZZY_get(void) {
  PyObject *pyobj = 0;
  
  pyobj = SWIG_From_double(static_cast< double >(FUZZY));
  return pyobj;
}


SWIGINTERN int Swig_var_BlankStr_set(PyObject *) {
  SWIG_Error(SWIG_AttributeError,"Variable BlankStr is read-only.");
  return 1;
}


SWIGINTERN PyObject *Swig_var_BlankStr_get(void) {
  PyObject *pyobj = 0;
  
  pyobj = SWIG_NewPointerObj(SWIG_as_voidptr(&BlankStr), SWIGTYPE_p_std__string,  0 );
  return pyobj;
}


SWIGINTERN PyObject *_wrap_delete_SwigPyIterator(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SwigPyIterator" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_value(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  PyObject *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_value" "', argument " "1"" of type '" "swig::SwigPyIterator const *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  try {
    result = (PyObject *)((swig::SwigPyIterator const *)arg1)->value();
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = result;
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_incr__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  size_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  size_t val2 ;
  int ecode2 = 0 ;
  swig::SwigPyIterator *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_incr" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  ecode2 = SWIG_AsVal_size_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SwigPyIterator_incr" "', argument " "2"" of type '" "size_t""'");
  } 
  arg2 = static_cast< size_t >(val2);
  try {
    result = (swig::SwigPyIterator *)(arg1)->incr(arg2);
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_incr__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  swig::SwigPyIterator *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_incr" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  try {
    result = (swig::SwigPyIterator *)(arg1)->incr();
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_incr(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "SwigPyIterator_incr", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 1) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__SwigPyIterator, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_SwigPyIterator_incr__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__SwigPyIterator, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_size_t(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_SwigPyIterator_incr__SWIG_0(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'SwigPyIterator_incr'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    swig::SwigPyIterator::incr(size_t)\n"
    "    swig::SwigPyIterator::incr()\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_decr__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  size_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  size_t val2 ;
  int ecode2 = 0 ;
  swig::SwigPyIterator *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_decr" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  ecode2 = SWIG_AsVal_size_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SwigPyIterator_decr" "', argument " "2"" of type '" "size_t""'");
  } 
  arg2 = static_cast< size_t >(val2);
  try {
    result = (swig::SwigPyIterator *)(arg1)->decr(arg2);
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_decr__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  swig::SwigPyIterator *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_decr" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  try {
    result = (swig::SwigPyIterator *)(arg1)->decr();
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_decr(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "SwigPyIterator_decr", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 1) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__SwigPyIterator, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_SwigPyIterator_decr__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__SwigPyIterator, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_size_t(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_SwigPyIterator_decr__SWIG_0(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'SwigPyIterator_decr'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    swig::SwigPyIterator::decr(size_t)\n"
    "    swig::SwigPyIterator::decr()\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_distance(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  swig::SwigPyIterator *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  ptrdiff_t result;
  
  if (!SWIG_Python_UnpackTuple(args, "SwigPyIterator_distance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_distance" "', argument " "1"" of type '" "swig::SwigPyIterator const *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_swig__SwigPyIterator,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SwigPyIterator_distance" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SwigPyIterator_distance" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  arg2 = reinterpret_cast< swig::SwigPyIterator * >(argp2);
  try {
    result = ((swig::SwigPyIterator const *)arg1)->distance((swig::SwigPyIterator const &)*arg2);
  } catch(std::invalid_argument &_e) {
    SWIG_Python_Raise(SWIG_NewPointerObj((new std::invalid_argument(static_cast< const std::invalid_argument& >(_e))),SWIGTYPE_p_std__invalid_argument,SWIG_POINTER_OWN), "std::invalid_argument", SWIGTYPE_p_std__invalid_argument); SWIG_fail;
  }
  resultobj = SWIG_From_ptrdiff_t(static_cast< ptrdiff_t >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_equal(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  swig::SwigPyIterator *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  bool result;
  
  if (!SWIG_Python_UnpackTuple(args, "SwigPyIterator_equal", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_equal" "', argument " "1"" of type '" "swig::SwigPyIterator const *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_swig__SwigPyIterator,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SwigPyIterator_equal" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SwigPyIterator_equal" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  arg2 = reinterpret_cast< swig::SwigPyIterator * >(argp2);
  try {
    result = (bool)((swig::SwigPyIterator const *)arg1)->equal((swig::SwigPyIterator const &)*arg2);
  } catch(std::invalid_argument &_e) {
    SWIG_Python_Raise(SWIG_NewPointerObj((new std::invalid_argument(static_cast< const std::invalid_argument& >(_e))),SWIGTYPE_p_std__invalid_argument,SWIG_POINTER_OWN), "std::invalid_argument", SWIGTYPE_p_std__invalid_argument); SWIG_fail;
  }
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_copy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  swig::SwigPyIterator *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_copy" "', argument " "1"" of type '" "swig::SwigPyIterator const *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  result = (swig::SwigPyIterator *)((swig::SwigPyIterator const *)arg1)->copy();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_next(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  PyObject *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_next" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  try {
    result = (PyObject *)(arg1)->next();
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = result;
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator___next__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  PyObject *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator___next__" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  try {
    result = (PyObject *)(arg1)->__next__();
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = result;
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_previous(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  PyObject *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_previous" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  try {
    result = (PyObject *)(arg1)->previous();
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = result;
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator_advance(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  ptrdiff_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  swig::SwigPyIterator *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "SwigPyIterator_advance", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator_advance" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SwigPyIterator_advance" "', argument " "2"" of type '" "ptrdiff_t""'");
  } 
  arg2 = static_cast< ptrdiff_t >(val2);
  try {
    result = (swig::SwigPyIterator *)(arg1)->advance(arg2);
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator___eq__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  swig::SwigPyIterator *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  bool result;
  
  if (!SWIG_Python_UnpackTuple(args, "SwigPyIterator___eq__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator___eq__" "', argument " "1"" of type '" "swig::SwigPyIterator const *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_swig__SwigPyIterator,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SwigPyIterator___eq__" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SwigPyIterator___eq__" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  arg2 = reinterpret_cast< swig::SwigPyIterator * >(argp2);
  result = (bool)((swig::SwigPyIterator const *)arg1)->operator ==((swig::SwigPyIterator const &)*arg2);
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator___ne__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  swig::SwigPyIterator *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  bool result;
  
  if (!SWIG_Python_UnpackTuple(args, "SwigPyIterator___ne__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator___ne__" "', argument " "1"" of type '" "swig::SwigPyIterator const *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_swig__SwigPyIterator,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SwigPyIterator___ne__" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SwigPyIterator___ne__" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  arg2 = reinterpret_cast< swig::SwigPyIterator * >(argp2);
  result = (bool)((swig::SwigPyIterator const *)arg1)->operator !=((swig::SwigPyIterator const &)*arg2);
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator___iadd__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  ptrdiff_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  swig::SwigPyIterator *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "SwigPyIterator___iadd__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator___iadd__" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SwigPyIterator___iadd__" "', argument " "2"" of type '" "ptrdiff_t""'");
  } 
  arg2 = static_cast< ptrdiff_t >(val2);
  try {
    result = (swig::SwigPyIterator *) &(arg1)->operator +=(arg2);
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator___isub__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  ptrdiff_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  swig::SwigPyIterator *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "SwigPyIterator___isub__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator___isub__" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SwigPyIterator___isub__" "', argument " "2"" of type '" "ptrdiff_t""'");
  } 
  arg2 = static_cast< ptrdiff_t >(val2);
  try {
    result = (swig::SwigPyIterator *) &(arg1)->operator -=(arg2);
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator___add__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  ptrdiff_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  swig::SwigPyIterator *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "SwigPyIterator___add__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator___add__" "', argument " "1"" of type '" "swig::SwigPyIterator const *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SwigPyIterator___add__" "', argument " "2"" of type '" "ptrdiff_t""'");
  } 
  arg2 = static_cast< ptrdiff_t >(val2);
  try {
    result = (swig::SwigPyIterator *)((swig::SwigPyIterator const *)arg1)->operator +(arg2);
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator___sub____SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  ptrdiff_t arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  swig::SwigPyIterator *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator___sub__" "', argument " "1"" of type '" "swig::SwigPyIterator const *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SwigPyIterator___sub__" "', argument " "2"" of type '" "ptrdiff_t""'");
  } 
  arg2 = static_cast< ptrdiff_t >(val2);
  try {
    result = (swig::SwigPyIterator *)((swig::SwigPyIterator const *)arg1)->operator -(arg2);
  } catch(swig::stop_iteration &_e) {
    {
      (void)_e;
      SWIG_SetErrorObj(PyExc_StopIteration, SWIG_Py_Void());
      SWIG_fail;
    }
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator___sub____SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ;
  swig::SwigPyIterator *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  ptrdiff_t result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_swig__SwigPyIterator, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SwigPyIterator___sub__" "', argument " "1"" of type '" "swig::SwigPyIterator const *""'"); 
  }
  arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_swig__SwigPyIterator,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SwigPyIterator___sub__" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SwigPyIterator___sub__" "', argument " "2"" of type '" "swig::SwigPyIterator const &""'"); 
  }
  arg2 = reinterpret_cast< swig::SwigPyIterator * >(argp2);
  result = ((swig::SwigPyIterator const *)arg1)->operator -((swig::SwigPyIterator const &)*arg2);
  resultobj = SWIG_From_ptrdiff_t(static_cast< ptrdiff_t >(result));
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap_SwigPyIterator___sub__(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "SwigPyIterator___sub__", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__SwigPyIterator, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_SwigPyIterator___sub____SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_swig__SwigPyIterator, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_SwigPyIterator___sub____SWIG_0(self, argc, argv);
      }
    }
  }
  
fail:
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *SwigPyIterator_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_swig__SwigPyIterator, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *_wrap_StringVector_iterator(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  PyObject **arg2 = (PyObject **) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  swig::SwigPyIterator *result = 0 ;
  
  arg2 = &swig_obj[0];
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_iterator" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (swig::SwigPyIterator *)std_vector_Sl_std_string_Sg__iterator(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___nonzero__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  bool result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___nonzero__" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (bool)std_vector_Sl_std_string_Sg____nonzero__((std::vector< std::string > const *)arg1);
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___bool__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  bool result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___bool__" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (bool)std_vector_Sl_std_string_Sg____bool__((std::vector< std::string > const *)arg1);
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___len__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::size_type result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___len__" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = std_vector_Sl_std_string_Sg____len__((std::vector< std::string > const *)arg1);
  resultobj = SWIG_From_size_t(static_cast< size_t >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___getslice__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::difference_type arg2 ;
  std::vector< std::string >::difference_type arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  ptrdiff_t val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  std::vector< std::string,std::allocator< std::string > > *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "StringVector___getslice__", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___getslice__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector___getslice__" "', argument " "2"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::difference_type >(val2);
  ecode3 = SWIG_AsVal_ptrdiff_t(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "StringVector___getslice__" "', argument " "3"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg3 = static_cast< std::vector< std::string >::difference_type >(val3);
  try {
    result = (std::vector< std::string,std::allocator< std::string > > *)std_vector_Sl_std_string_Sg____getslice__(arg1,SWIG_STD_MOVE(arg2),SWIG_STD_MOVE(arg3));
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  } catch(std::invalid_argument &_e) {
    SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___setslice____SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::difference_type arg2 ;
  std::vector< std::string >::difference_type arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  ptrdiff_t val3 ;
  int ecode3 = 0 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___setslice__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector___setslice__" "', argument " "2"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::difference_type >(val2);
  ecode3 = SWIG_AsVal_ptrdiff_t(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "StringVector___setslice__" "', argument " "3"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg3 = static_cast< std::vector< std::string >::difference_type >(val3);
  try {
    std_vector_Sl_std_string_Sg____setslice____SWIG_0(arg1,SWIG_STD_MOVE(arg2),SWIG_STD_MOVE(arg3));
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  } catch(std::invalid_argument &_e) {
    SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___setslice____SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::difference_type arg2 ;
  std::vector< std::string >::difference_type arg3 ;
  std::vector< std::string,std::allocator< std::string > > *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  ptrdiff_t val3 ;
  int ecode3 = 0 ;
  int res4 = SWIG_OLDOBJ ;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___setslice__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector___setslice__" "', argument " "2"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::difference_type >(val2);
  ecode3 = SWIG_AsVal_ptrdiff_t(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "StringVector___setslice__" "', argument " "3"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg3 = static_cast< std::vector< std::string >::difference_type >(val3);
  {
    std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0;
    res4 = swig::asptr(swig_obj[3], &ptr);
    if (!SWIG_IsOK(res4)) {
      SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "StringVector___setslice__" "', argument " "4"" of type '" "std::vector< std::string,std::allocator< std::string > > const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector___setslice__" "', argument " "4"" of type '" "std::vector< std::string,std::allocator< std::string > > const &""'"); 
    }
    arg4 = ptr;
  }
  try {
    std_vector_Sl_std_string_Sg____setslice____SWIG_1(arg1,SWIG_STD_MOVE(arg2),SWIG_STD_MOVE(arg3),(std::vector< std::string,std::allocator< std::string > > const &)*arg4);
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  } catch(std::invalid_argument &_e) {
    SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
  }
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res4)) delete arg4;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res4)) delete arg4;
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___setslice__(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "StringVector___setslice__", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(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_StringVector___setslice____SWIG_0(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(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< std::string,std::allocator< std::string > >**)(0));
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_StringVector___setslice____SWIG_1(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'StringVector___setslice__'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    std::vector< std::string >::__setslice__(std::vector< std::string >::difference_type,std::vector< std::string >::difference_type)\n"
    "    std::vector< std::string >::__setslice__(std::vector< std::string >::difference_type,std::vector< std::string >::difference_type,std::vector< std::string,std::allocator< std::string > > const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_StringVector___delslice__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::difference_type arg2 ;
  std::vector< std::string >::difference_type arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  ptrdiff_t val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "StringVector___delslice__", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___delslice__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector___delslice__" "', argument " "2"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::difference_type >(val2);
  ecode3 = SWIG_AsVal_ptrdiff_t(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "StringVector___delslice__" "', argument " "3"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg3 = static_cast< std::vector< std::string >::difference_type >(val3);
  try {
    std_vector_Sl_std_string_Sg____delslice__(arg1,SWIG_STD_MOVE(arg2),SWIG_STD_MOVE(arg3));
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  } catch(std::invalid_argument &_e) {
    SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___delitem____SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::difference_type arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___delitem__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector___delitem__" "', argument " "2"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::difference_type >(val2);
  try {
    std_vector_Sl_std_string_Sg____delitem____SWIG_0(arg1,SWIG_STD_MOVE(arg2));
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  } catch(std::invalid_argument &_e) {
    SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___getitem____SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  SWIGPY_SLICEOBJECT *arg2 = (SWIGPY_SLICEOBJECT *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< std::string,std::allocator< std::string > > *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___getitem__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  {
    if (!PySlice_Check(swig_obj[1])) {
      SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector___getitem__" "', argument " "2"" of type '" "SWIGPY_SLICEOBJECT *""'");
    }
    arg2 = (SWIGPY_SLICEOBJECT *) swig_obj[1];
  }
  try {
    result = (std::vector< std::string,std::allocator< std::string > > *)std_vector_Sl_std_string_Sg____getitem____SWIG_0(arg1,arg2);
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  } catch(std::invalid_argument &_e) {
    SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
  }
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___setitem____SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  SWIGPY_SLICEOBJECT *arg2 = (SWIGPY_SLICEOBJECT *) 0 ;
  std::vector< std::string,std::allocator< std::string > > *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res3 = SWIG_OLDOBJ ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___setitem__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  {
    if (!PySlice_Check(swig_obj[1])) {
      SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector___setitem__" "', argument " "2"" of type '" "SWIGPY_SLICEOBJECT *""'");
    }
    arg2 = (SWIGPY_SLICEOBJECT *) swig_obj[1];
  }
  {
    std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0;
    res3 = swig::asptr(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "StringVector___setitem__" "', argument " "3"" of type '" "std::vector< std::string,std::allocator< std::string > > const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector___setitem__" "', argument " "3"" of type '" "std::vector< std::string,std::allocator< std::string > > const &""'"); 
    }
    arg3 = ptr;
  }
  try {
    std_vector_Sl_std_string_Sg____setitem____SWIG_0(arg1,arg2,(std::vector< std::string,std::allocator< std::string > > const &)*arg3);
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  } catch(std::invalid_argument &_e) {
    SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
  }
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res3)) delete arg3;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res3)) delete arg3;
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___setitem____SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  SWIGPY_SLICEOBJECT *arg2 = (SWIGPY_SLICEOBJECT *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___setitem__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  {
    if (!PySlice_Check(swig_obj[1])) {
      SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector___setitem__" "', argument " "2"" of type '" "SWIGPY_SLICEOBJECT *""'");
    }
    arg2 = (SWIGPY_SLICEOBJECT *) swig_obj[1];
  }
  try {
    std_vector_Sl_std_string_Sg____setitem____SWIG_1(arg1,arg2);
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  } catch(std::invalid_argument &_e) {
    SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___delitem____SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  SWIGPY_SLICEOBJECT *arg2 = (SWIGPY_SLICEOBJECT *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___delitem__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  {
    if (!PySlice_Check(swig_obj[1])) {
      SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector___delitem__" "', argument " "2"" of type '" "SWIGPY_SLICEOBJECT *""'");
    }
    arg2 = (SWIGPY_SLICEOBJECT *) swig_obj[1];
  }
  try {
    std_vector_Sl_std_string_Sg____delitem____SWIG_1(arg1,arg2);
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  } catch(std::invalid_argument &_e) {
    SWIG_exception_fail(SWIG_ValueError, (&_e)->what());
  }
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___delitem__(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "StringVector___delitem__", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        _v = PySlice_Check(argv[1]);
      }
      if (_v) {
        return _wrap_StringVector___delitem____SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_StringVector___delitem____SWIG_0(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'StringVector___delitem__'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    std::vector< std::string >::__delitem__(std::vector< std::string >::difference_type)\n"
    "    std::vector< std::string >::__delitem__(SWIGPY_SLICEOBJECT *)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_StringVector___getitem____SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::difference_type arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  std::vector< std::string >::value_type *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___getitem__" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector___getitem__" "', argument " "2"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::difference_type >(val2);
  try {
    result = (std::vector< std::string >::value_type *) &std_vector_Sl_std_string_Sg____getitem____SWIG_1((std::vector< std::string > const *)arg1,SWIG_STD_MOVE(arg2));
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  }
  resultobj = SWIG_From_std_string(static_cast< std::string >(*result));
  (void)swig::container_owner<swig::traits<std::vector< std::string >::value_type>::category>::back_reference(resultobj, swig_obj[0]);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___getitem__(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "StringVector___getitem__", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        _v = PySlice_Check(argv[1]);
      }
      if (_v) {
        return _wrap_StringVector___getitem____SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_ptrdiff_t(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_StringVector___getitem____SWIG_1(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'StringVector___getitem__'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    std::vector< std::string >::__getitem__(SWIGPY_SLICEOBJECT *)\n"
    "    std::vector< std::string >::__getitem__(std::vector< std::string >::difference_type) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_StringVector___setitem____SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::difference_type arg2 ;
  std::vector< std::string >::value_type *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  ptrdiff_t val2 ;
  int ecode2 = 0 ;
  int res3 = SWIG_OLDOBJ ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector___setitem__" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_ptrdiff_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector___setitem__" "', argument " "2"" of type '" "std::vector< std::string >::difference_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::difference_type >(val2);
  {
    std::string *ptr = (std::string *)0;
    res3 = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "StringVector___setitem__" "', argument " "3"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector___setitem__" "', argument " "3"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    arg3 = ptr;
  }
  try {
    std_vector_Sl_std_string_Sg____setitem____SWIG_2(arg1,SWIG_STD_MOVE(arg2),(std::string const &)*arg3);
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  }
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res3)) delete arg3;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res3)) delete arg3;
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector___setitem__(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "StringVector___setitem__", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        _v = PySlice_Check(argv[1]);
      }
      if (_v) {
        return _wrap_StringVector___setitem____SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        _v = PySlice_Check(argv[1]);
      }
      if (_v) {
        int res = swig::asptr(argv[2], (std::vector< std::string,std::allocator< std::string > >**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_StringVector___setitem____SWIG_0(self, argc, argv);
        }
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(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_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_StringVector___setitem____SWIG_2(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'StringVector___setitem__'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    std::vector< std::string >::__setitem__(SWIGPY_SLICEOBJECT *,std::vector< std::string,std::allocator< std::string > > const &)\n"
    "    std::vector< std::string >::__setitem__(SWIGPY_SLICEOBJECT *)\n"
    "    std::vector< std::string >::__setitem__(std::vector< std::string >::difference_type,std::vector< std::string >::value_type const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_StringVector_pop(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::value_type result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_pop" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  try {
    result = std_vector_Sl_std_string_Sg__pop(arg1);
  } catch(std::out_of_range &_e) {
    SWIG_exception_fail(SWIG_IndexError, (&_e)->what());
  }
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_append(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::value_type *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "StringVector_append", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_append" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "StringVector_append" "', argument " "2"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector_append" "', argument " "2"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    arg2 = ptr;
  }
  std_vector_Sl_std_string_Sg__append(arg1,(std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_StringVector__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  std::vector< std::string > *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (std::vector< std::string > *)new std::vector< std::string >();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_StringVector__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = 0 ;
  int res1 = SWIG_OLDOBJ ;
  std::vector< std::string > *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0;
    res1 = swig::asptr(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_StringVector" "', argument " "1"" of type '" "std::vector< std::string > const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_StringVector" "', argument " "1"" of type '" "std::vector< std::string > const &""'"); 
    }
    arg1 = ptr;
  }
  result = (std::vector< std::string > *)new std::vector< std::string >((std::vector< std::string > const &)*arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, SWIG_POINTER_NEW |  0 );
  if (SWIG_IsNewObj(res1)) delete arg1;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res1)) delete arg1;
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_empty(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  bool result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_empty" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (bool)((std::vector< std::string > const *)arg1)->empty();
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_size(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::size_type result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_size" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = ((std::vector< std::string > const *)arg1)->size();
  resultobj = SWIG_From_size_t(static_cast< size_t >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_swap(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "StringVector_swap", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_swap" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "StringVector_swap" "', argument " "2"" of type '" "std::vector< std::string > &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector_swap" "', argument " "2"" of type '" "std::vector< std::string > &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< std::string > * >(argp2);
  (arg1)->swap(*arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_begin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::iterator result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_begin" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (arg1)->begin();
  resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::iterator & >(result)),
    swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_end(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::iterator result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_end" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (arg1)->end();
  resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::iterator & >(result)),
    swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_rbegin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::reverse_iterator result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_rbegin" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (arg1)->rbegin();
  resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::reverse_iterator & >(result)),
    swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_rend(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::reverse_iterator result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_rend" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (arg1)->rend();
  resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::reverse_iterator & >(result)),
    swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_clear" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_get_allocator(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  SwigValueWrapper< std::allocator< std::string > > result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_get_allocator" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = ((std::vector< std::string > const *)arg1)->get_allocator();
  resultobj = SWIG_NewPointerObj((new std::vector< std::string >::allocator_type(result)), SWIGTYPE_p_std__allocatorT_std__string_t, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_StringVector__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string >::size_type arg1 ;
  size_t val1 ;
  int ecode1 = 0 ;
  std::vector< std::string > *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  ecode1 = SWIG_AsVal_size_t(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_StringVector" "', argument " "1"" of type '" "std::vector< std::string >::size_type""'");
  } 
  arg1 = static_cast< std::vector< std::string >::size_type >(val1);
  result = (std::vector< std::string > *)new std::vector< std::string >(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_pop_back(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_pop_back" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  (arg1)->pop_back();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_resize__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::size_type arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  size_t val2 ;
  int ecode2 = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_resize" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_size_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector_resize" "', argument " "2"" of type '" "std::vector< std::string >::size_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::size_type >(val2);
  (arg1)->resize(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_erase__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::iterator arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  swig::SwigPyIterator *iter2 = 0 ;
  int res2 ;
  std::vector< std::string >::iterator result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_erase" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], SWIG_as_voidptrptr(&iter2), swig::SwigPyIterator::descriptor(), 0);
  if (!SWIG_IsOK(res2) || !iter2) {
    SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_erase" "', argument " "2"" of type '" "std::vector< std::string >::iterator""'");
  } else {
    swig::SwigPyIterator_T<std::vector< std::string >::iterator > *iter_t = dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter2);
    if (iter_t) {
      arg2 = iter_t->get_current();
    } else {
      SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_erase" "', argument " "2"" of type '" "std::vector< std::string >::iterator""'");
    }
  }
  result = std_vector_Sl_std_string_Sg__erase__SWIG_0(arg1,SWIG_STD_MOVE(arg2));
  resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::iterator & >(result)),
    swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_erase__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::iterator arg2 ;
  std::vector< std::string >::iterator arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  swig::SwigPyIterator *iter2 = 0 ;
  int res2 ;
  swig::SwigPyIterator *iter3 = 0 ;
  int res3 ;
  std::vector< std::string >::iterator result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_erase" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], SWIG_as_voidptrptr(&iter2), swig::SwigPyIterator::descriptor(), 0);
  if (!SWIG_IsOK(res2) || !iter2) {
    SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_erase" "', argument " "2"" of type '" "std::vector< std::string >::iterator""'");
  } else {
    swig::SwigPyIterator_T<std::vector< std::string >::iterator > *iter_t = dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter2);
    if (iter_t) {
      arg2 = iter_t->get_current();
    } else {
      SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_erase" "', argument " "2"" of type '" "std::vector< std::string >::iterator""'");
    }
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], SWIG_as_voidptrptr(&iter3), swig::SwigPyIterator::descriptor(), 0);
  if (!SWIG_IsOK(res3) || !iter3) {
    SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_erase" "', argument " "3"" of type '" "std::vector< std::string >::iterator""'");
  } else {
    swig::SwigPyIterator_T<std::vector< std::string >::iterator > *iter_t = dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter3);
    if (iter_t) {
      arg3 = iter_t->get_current();
    } else {
      SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_erase" "', argument " "3"" of type '" "std::vector< std::string >::iterator""'");
    }
  }
  result = std_vector_Sl_std_string_Sg__erase__SWIG_1(arg1,SWIG_STD_MOVE(arg2),SWIG_STD_MOVE(arg3));
  resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::iterator & >(result)),
    swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_erase(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "StringVector_erase", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      swig::SwigPyIterator *iter = 0;
      int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter), swig::SwigPyIterator::descriptor(), 0);
      _v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter) != 0));
      if (_v) {
        return _wrap_StringVector_erase__SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      swig::SwigPyIterator *iter = 0;
      int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter), swig::SwigPyIterator::descriptor(), 0);
      _v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter) != 0));
      if (_v) {
        swig::SwigPyIterator *iter = 0;
        int res = SWIG_ConvertPtr(argv[2], SWIG_as_voidptrptr(&iter), swig::SwigPyIterator::descriptor(), 0);
        _v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter) != 0));
        if (_v) {
          return _wrap_StringVector_erase__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'StringVector_erase'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    std::vector< std::string >::erase(std::vector< std::string >::iterator)\n"
    "    std::vector< std::string >::erase(std::vector< std::string >::iterator,std::vector< std::string >::iterator)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_new_StringVector__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string >::size_type arg1 ;
  std::vector< std::string >::value_type *arg2 = 0 ;
  size_t val1 ;
  int ecode1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  std::vector< std::string > *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  ecode1 = SWIG_AsVal_size_t(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "new_StringVector" "', argument " "1"" of type '" "std::vector< std::string >::size_type""'");
  } 
  arg1 = static_cast< std::vector< std::string >::size_type >(val1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_StringVector" "', argument " "2"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_StringVector" "', argument " "2"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    arg2 = ptr;
  }
  result = (std::vector< std::string > *)new std::vector< std::string >(arg1,(std::vector< std::string >::value_type const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, SWIG_POINTER_NEW |  0 );
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_StringVector(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_StringVector", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_StringVector__SWIG_0(self, argc, argv);
  }
  if (argc == 1) {
    int _v = 0;
    {
      int res = SWIG_AsVal_size_t(argv[0], NULL);
      _v = SWIG_CheckState(res);
    }
    if (_v) {
      return _wrap_new_StringVector__SWIG_2(self, argc, argv);
    }
  }
  if (argc == 1) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_StringVector__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    {
      int res = SWIG_AsVal_size_t(argv[0], NULL);
      _v = SWIG_CheckState(res);
    }
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_new_StringVector__SWIG_3(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_StringVector'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    std::vector< std::string >::vector()\n"
    "    std::vector< std::string >::vector(std::vector< std::string > const &)\n"
    "    std::vector< std::string >::vector(std::vector< std::string >::size_type)\n"
    "    std::vector< std::string >::vector(std::vector< std::string >::size_type,std::vector< std::string >::value_type const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_StringVector_push_back(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::value_type *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "StringVector_push_back", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_push_back" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "StringVector_push_back" "', argument " "2"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector_push_back" "', argument " "2"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->push_back((std::vector< std::string >::value_type const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_front(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::value_type *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_front" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (std::vector< std::string >::value_type *) &((std::vector< std::string > const *)arg1)->front();
  resultobj = SWIG_From_std_string(static_cast< std::string >(*result));
  (void)swig::container_owner<swig::traits<std::vector< std::string >::value_type>::category>::back_reference(resultobj, swig_obj[0]);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_back(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::value_type *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_back" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = (std::vector< std::string >::value_type *) &((std::vector< std::string > const *)arg1)->back();
  resultobj = SWIG_From_std_string(static_cast< std::string >(*result));
  (void)swig::container_owner<swig::traits<std::vector< std::string >::value_type>::category>::back_reference(resultobj, swig_obj[0]);
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_assign(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::size_type arg2 ;
  std::vector< std::string >::value_type *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  size_t val2 ;
  int ecode2 = 0 ;
  int res3 = SWIG_OLDOBJ ;
  PyObject *swig_obj[3] ;
  
  if (!SWIG_Python_UnpackTuple(args, "StringVector_assign", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_assign" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_size_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector_assign" "', argument " "2"" of type '" "std::vector< std::string >::size_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::size_type >(val2);
  {
    std::string *ptr = (std::string *)0;
    res3 = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "StringVector_assign" "', argument " "3"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector_assign" "', argument " "3"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    arg3 = ptr;
  }
  (arg1)->assign(arg2,(std::vector< std::string >::value_type const &)*arg3);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res3)) delete arg3;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res3)) delete arg3;
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_resize__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::size_type arg2 ;
  std::vector< std::string >::value_type *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  size_t val2 ;
  int ecode2 = 0 ;
  int res3 = SWIG_OLDOBJ ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_resize" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_size_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector_resize" "', argument " "2"" of type '" "std::vector< std::string >::size_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::size_type >(val2);
  {
    std::string *ptr = (std::string *)0;
    res3 = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "StringVector_resize" "', argument " "3"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector_resize" "', argument " "3"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    arg3 = ptr;
  }
  (arg1)->resize(arg2,(std::vector< std::string >::value_type const &)*arg3);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res3)) delete arg3;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res3)) delete arg3;
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_resize(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "StringVector_resize", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_size_t(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_StringVector_resize__SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(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_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_StringVector_resize__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'StringVector_resize'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    std::vector< std::string >::resize(std::vector< std::string >::size_type)\n"
    "    std::vector< std::string >::resize(std::vector< std::string >::size_type,std::vector< std::string >::value_type const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_StringVector_insert__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::iterator arg2 ;
  std::vector< std::string >::value_type *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  swig::SwigPyIterator *iter2 = 0 ;
  int res2 ;
  int res3 = SWIG_OLDOBJ ;
  std::vector< std::string >::iterator result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_insert" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], SWIG_as_voidptrptr(&iter2), swig::SwigPyIterator::descriptor(), 0);
  if (!SWIG_IsOK(res2) || !iter2) {
    SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_insert" "', argument " "2"" of type '" "std::vector< std::string >::iterator""'");
  } else {
    swig::SwigPyIterator_T<std::vector< std::string >::iterator > *iter_t = dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter2);
    if (iter_t) {
      arg2 = iter_t->get_current();
    } else {
      SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_insert" "', argument " "2"" of type '" "std::vector< std::string >::iterator""'");
    }
  }
  {
    std::string *ptr = (std::string *)0;
    res3 = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "StringVector_insert" "', argument " "3"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector_insert" "', argument " "3"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    arg3 = ptr;
  }
  result = std_vector_Sl_std_string_Sg__insert__SWIG_0(arg1,SWIG_STD_MOVE(arg2),(std::string const &)*arg3);
  resultobj = SWIG_NewPointerObj(swig::make_output_iterator(static_cast< const std::vector< std::string >::iterator & >(result)),
    swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN);
  if (SWIG_IsNewObj(res3)) delete arg3;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res3)) delete arg3;
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_insert__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::iterator arg2 ;
  std::vector< std::string >::size_type arg3 ;
  std::vector< std::string >::value_type *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  swig::SwigPyIterator *iter2 = 0 ;
  int res2 ;
  size_t val3 ;
  int ecode3 = 0 ;
  int res4 = SWIG_OLDOBJ ;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_insert" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], SWIG_as_voidptrptr(&iter2), swig::SwigPyIterator::descriptor(), 0);
  if (!SWIG_IsOK(res2) || !iter2) {
    SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_insert" "', argument " "2"" of type '" "std::vector< std::string >::iterator""'");
  } else {
    swig::SwigPyIterator_T<std::vector< std::string >::iterator > *iter_t = dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter2);
    if (iter_t) {
      arg2 = iter_t->get_current();
    } else {
      SWIG_exception_fail(SWIG_ArgError(SWIG_TypeError), "in method '" "StringVector_insert" "', argument " "2"" of type '" "std::vector< std::string >::iterator""'");
    }
  }
  ecode3 = SWIG_AsVal_size_t(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "StringVector_insert" "', argument " "3"" of type '" "std::vector< std::string >::size_type""'");
  } 
  arg3 = static_cast< std::vector< std::string >::size_type >(val3);
  {
    std::string *ptr = (std::string *)0;
    res4 = SWIG_AsPtr_std_string(swig_obj[3], &ptr);
    if (!SWIG_IsOK(res4)) {
      SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "StringVector_insert" "', argument " "4"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "StringVector_insert" "', argument " "4"" of type '" "std::vector< std::string >::value_type const &""'"); 
    }
    arg4 = ptr;
  }
  std_vector_Sl_std_string_Sg__insert__SWIG_1(arg1,SWIG_STD_MOVE(arg2),SWIG_STD_MOVE(arg3),(std::string const &)*arg4);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res4)) delete arg4;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res4)) delete arg4;
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_insert(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "StringVector_insert", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      swig::SwigPyIterator *iter = 0;
      int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter), swig::SwigPyIterator::descriptor(), 0);
      _v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter) != 0));
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_StringVector_insert__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    int res = swig::asptr(argv[0], (std::vector< std::string,std::allocator< std::string > >**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      swig::SwigPyIterator *iter = 0;
      int res = SWIG_ConvertPtr(argv[1], SWIG_as_voidptrptr(&iter), swig::SwigPyIterator::descriptor(), 0);
      _v = (SWIG_IsOK(res) && iter && (dynamic_cast<swig::SwigPyIterator_T<std::vector< std::string >::iterator > *>(iter) != 0));
      if (_v) {
        {
          int res = SWIG_AsVal_size_t(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          int res = SWIG_AsPtr_std_string(argv[3], (std::string**)(0));
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_StringVector_insert__SWIG_1(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'StringVector_insert'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    std::vector< std::string >::insert(std::vector< std::string >::iterator,std::vector< std::string >::value_type const &)\n"
    "    std::vector< std::string >::insert(std::vector< std::string >::iterator,std::vector< std::string >::size_type,std::vector< std::string >::value_type const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_StringVector_reserve(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  std::vector< std::string >::size_type arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  size_t val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "StringVector_reserve", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_reserve" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  ecode2 = SWIG_AsVal_size_t(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "StringVector_reserve" "', argument " "2"" of type '" "std::vector< std::string >::size_type""'");
  } 
  arg2 = static_cast< std::vector< std::string >::size_type >(val2);
  (arg1)->reserve(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_StringVector_capacity(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< std::string >::size_type result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "StringVector_capacity" "', argument " "1"" of type '" "std::vector< std::string > const *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  result = ((std::vector< std::string > const *)arg1)->capacity();
  resultobj = SWIG_From_size_t(static_cast< size_t >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_StringVector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::vector< std::string > *arg1 = (std::vector< std::string > *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_StringVector" "', argument " "1"" of type '" "std::vector< std::string > *""'"); 
  }
  arg1 = reinterpret_cast< std::vector< std::string > * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *StringVector_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_std__vectorT_std__string_std__allocatorT_std__string_t_t, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *StringVector_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_new_pha__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  heasp::pha *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (heasp::pha *)new heasp::pha();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_pha__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  heasp::pha *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_pha" "', argument " "1"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_pha" "', argument " "1"" of type '" "heasp::pha const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (heasp::pha *)new heasp::pha((heasp::pha const &)*arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_pha__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  Integer arg3 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  heasp::pha *result = 0 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_pha" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_pha" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_pha" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (heasp::pha *)new heasp::pha(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_pha__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  heasp::pha *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_pha" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_pha" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (heasp::pha *)new heasp::pha(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_pha__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  heasp::pha *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_pha" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (heasp::pha *)new heasp::pha(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_pha__SWIG_5(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  RealVector *arg1 = 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  IntegerVector *arg4 = 0 ;
  IntegerVector *arg5 = 0 ;
  IntegerVector *arg6 = 0 ;
  RealVector *arg7 = 0 ;
  RealVector *arg8 = 0 ;
  Integer arg9 ;
  Real arg10 ;
  Real arg11 ;
  Integer arg12 ;
  bool arg13 ;
  std::map< std::string,std::string > *arg14 = 0 ;
  StringVector *arg15 = 0 ;
  std::vector< double,std::allocator< double > > tvec1 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  std::vector< int,std::allocator< int > > tvec5 ;
  std::vector< int,std::allocator< int > > tvec6 ;
  std::vector< double,std::allocator< double > > tvec7 ;
  std::vector< double,std::allocator< double > > tvec8 ;
  int val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  double val11 ;
  int ecode11 = 0 ;
  int val12 ;
  int ecode12 = 0 ;
  bool val13 ;
  int ecode13 = 0 ;
  void *argp14 = 0 ;
  int res14 = 0 ;
  int res15 = SWIG_OLDOBJ ;
  heasp::pha *result = 0 ;
  
  if ((nobjs < 15) || (nobjs > 15)) SWIG_fail;
  {
    // a Python array is in swig_obj[0]. We need to get its size then resize
    // arg1 and copy the contents from swig_obj[0] into (&arg1)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[0], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec1.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec1[i] = static_cast<double>(in_data[i]);
    }
    arg1 = &tvec1;
    
    
  }
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<int>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  {
    // a Python array is in swig_obj[5]. We need to get its size then resize
    // arg6 and copy the contents from swig_obj[5] into (&arg6)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[5], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec6.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec6[i] = static_cast<int>(in_data[i]);
    }
    arg6 = &tvec6;
    
    
  }
  {
    // a Python array is in swig_obj[6]. We need to get its size then resize
    // arg7 and copy the contents from swig_obj[6] into (&arg7)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[6], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec7.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec7[i] = static_cast<double>(in_data[i]);
    }
    arg7 = &tvec7;
    
    
  }
  {
    // a Python array is in swig_obj[7]. We need to get its size then resize
    // arg8 and copy the contents from swig_obj[7] into (&arg8)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[7], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec8.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec8[i] = static_cast<double>(in_data[i]);
    }
    arg8 = &tvec8;
    
    
  }
  ecode9 = SWIG_AsVal_int(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_pha" "', argument " "9"" of type '" "Integer""'");
  } 
  arg9 = static_cast< Integer >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "new_pha" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  ecode11 = SWIG_AsVal_double(swig_obj[10], &val11);
  if (!SWIG_IsOK(ecode11)) {
    SWIG_exception_fail(SWIG_ArgError(ecode11), "in method '" "new_pha" "', argument " "11"" of type '" "Real""'");
  } 
  arg11 = static_cast< Real >(val11);
  ecode12 = SWIG_AsVal_int(swig_obj[11], &val12);
  if (!SWIG_IsOK(ecode12)) {
    SWIG_exception_fail(SWIG_ArgError(ecode12), "in method '" "new_pha" "', argument " "12"" of type '" "Integer""'");
  } 
  arg12 = static_cast< Integer >(val12);
  ecode13 = SWIG_AsVal_bool(swig_obj[12], &val13);
  if (!SWIG_IsOK(ecode13)) {
    SWIG_exception_fail(SWIG_ArgError(ecode13), "in method '" "new_pha" "', argument " "13"" of type '" "bool""'");
  } 
  arg13 = static_cast< bool >(val13);
  res14 = SWIG_ConvertPtr(swig_obj[13], &argp14, SWIGTYPE_p_std__mapT_std__string_std__string_t,  0  | 0);
  if (!SWIG_IsOK(res14)) {
    SWIG_exception_fail(SWIG_ArgError(res14), "in method '" "new_pha" "', argument " "14"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  if (!argp14) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_pha" "', argument " "14"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  arg14 = reinterpret_cast< std::map< std::string,std::string > * >(argp14);
  {
    std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0;
    res15 = swig::asptr(swig_obj[14], &ptr);
    if (!SWIG_IsOK(res15)) {
      SWIG_exception_fail(SWIG_ArgError(res15), "in method '" "new_pha" "', argument " "15"" of type '" "StringVector const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_pha" "', argument " "15"" of type '" "StringVector const &""'"); 
    }
    arg15 = ptr;
  }
  result = (heasp::pha *)new heasp::pha((RealVector const &)*arg1,(RealVector const &)*arg2,(RealVector const &)*arg3,(IntegerVector const &)*arg4,(IntegerVector const &)*arg5,(IntegerVector const &)*arg6,(RealVector const &)*arg7,(RealVector const &)*arg8,arg9,arg10,arg11,arg12,arg13,(std::map< std::string,std::string > const &)*arg14,(StringVector const &)*arg15);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, SWIG_POINTER_NEW |  0 );
  if (SWIG_IsNewObj(res15)) delete arg15;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res15)) delete arg15;
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_pha__SWIG_6(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  RealVector *arg1 = 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  IntegerVector *arg4 = 0 ;
  IntegerVector *arg5 = 0 ;
  IntegerVector *arg6 = 0 ;
  RealVector *arg7 = 0 ;
  RealVector *arg8 = 0 ;
  Integer arg9 ;
  Real arg10 ;
  Real arg11 ;
  Integer arg12 ;
  bool arg13 ;
  std::map< std::string,std::string > *arg14 = 0 ;
  std::vector< double,std::allocator< double > > tvec1 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  std::vector< int,std::allocator< int > > tvec5 ;
  std::vector< int,std::allocator< int > > tvec6 ;
  std::vector< double,std::allocator< double > > tvec7 ;
  std::vector< double,std::allocator< double > > tvec8 ;
  int val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  double val11 ;
  int ecode11 = 0 ;
  int val12 ;
  int ecode12 = 0 ;
  bool val13 ;
  int ecode13 = 0 ;
  void *argp14 = 0 ;
  int res14 = 0 ;
  heasp::pha *result = 0 ;
  
  if ((nobjs < 14) || (nobjs > 14)) SWIG_fail;
  {
    // a Python array is in swig_obj[0]. We need to get its size then resize
    // arg1 and copy the contents from swig_obj[0] into (&arg1)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[0], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec1.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec1[i] = static_cast<double>(in_data[i]);
    }
    arg1 = &tvec1;
    
    
  }
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<int>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  {
    // a Python array is in swig_obj[5]. We need to get its size then resize
    // arg6 and copy the contents from swig_obj[5] into (&arg6)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[5], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec6.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec6[i] = static_cast<int>(in_data[i]);
    }
    arg6 = &tvec6;
    
    
  }
  {
    // a Python array is in swig_obj[6]. We need to get its size then resize
    // arg7 and copy the contents from swig_obj[6] into (&arg7)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[6], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec7.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec7[i] = static_cast<double>(in_data[i]);
    }
    arg7 = &tvec7;
    
    
  }
  {
    // a Python array is in swig_obj[7]. We need to get its size then resize
    // arg8 and copy the contents from swig_obj[7] into (&arg8)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[7], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec8.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec8[i] = static_cast<double>(in_data[i]);
    }
    arg8 = &tvec8;
    
    
  }
  ecode9 = SWIG_AsVal_int(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_pha" "', argument " "9"" of type '" "Integer""'");
  } 
  arg9 = static_cast< Integer >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "new_pha" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  ecode11 = SWIG_AsVal_double(swig_obj[10], &val11);
  if (!SWIG_IsOK(ecode11)) {
    SWIG_exception_fail(SWIG_ArgError(ecode11), "in method '" "new_pha" "', argument " "11"" of type '" "Real""'");
  } 
  arg11 = static_cast< Real >(val11);
  ecode12 = SWIG_AsVal_int(swig_obj[11], &val12);
  if (!SWIG_IsOK(ecode12)) {
    SWIG_exception_fail(SWIG_ArgError(ecode12), "in method '" "new_pha" "', argument " "12"" of type '" "Integer""'");
  } 
  arg12 = static_cast< Integer >(val12);
  ecode13 = SWIG_AsVal_bool(swig_obj[12], &val13);
  if (!SWIG_IsOK(ecode13)) {
    SWIG_exception_fail(SWIG_ArgError(ecode13), "in method '" "new_pha" "', argument " "13"" of type '" "bool""'");
  } 
  arg13 = static_cast< bool >(val13);
  res14 = SWIG_ConvertPtr(swig_obj[13], &argp14, SWIGTYPE_p_std__mapT_std__string_std__string_t,  0  | 0);
  if (!SWIG_IsOK(res14)) {
    SWIG_exception_fail(SWIG_ArgError(res14), "in method '" "new_pha" "', argument " "14"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  if (!argp14) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_pha" "', argument " "14"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  arg14 = reinterpret_cast< std::map< std::string,std::string > * >(argp14);
  result = (heasp::pha *)new heasp::pha((RealVector const &)*arg1,(RealVector const &)*arg2,(RealVector const &)*arg3,(IntegerVector const &)*arg4,(IntegerVector const &)*arg5,(IntegerVector const &)*arg6,(RealVector const &)*arg7,(RealVector const &)*arg8,arg9,arg10,arg11,arg12,arg13,(std::map< std::string,std::string > const &)*arg14);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_pha(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[16] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_pha", 0, 15, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_pha__SWIG_0(self, argc, argv);
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_pha__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_pha__SWIG_4(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_new_pha__SWIG_3(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(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_new_pha__SWIG_2(self, argc, argv);
        }
      }
    }
  }
  if (argc == 14) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              int res = SWIG_ConvertPtr(argv[5], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
              _v = SWIG_CheckState(res);
              if (_v) {
                int res = SWIG_ConvertPtr(argv[6], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                _v = SWIG_CheckState(res);
                if (_v) {
                  int res = SWIG_ConvertPtr(argv[7], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    {
                      int res = SWIG_AsVal_int(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        {
                          int res = SWIG_AsVal_double(argv[10], NULL);
                          _v = SWIG_CheckState(res);
                        }
                        if (_v) {
                          {
                            int res = SWIG_AsVal_int(argv[11], NULL);
                            _v = SWIG_CheckState(res);
                          }
                          if (_v) {
                            {
                              int res = SWIG_AsVal_bool(argv[12], NULL);
                              _v = SWIG_CheckState(res);
                            }
                            if (_v) {
                              int res = SWIG_ConvertPtr(argv[13], 0, SWIGTYPE_p_std__mapT_std__string_std__string_t, SWIG_POINTER_NO_NULL | 0);
                              _v = SWIG_CheckState(res);
                              if (_v) {
                                return _wrap_new_pha__SWIG_6(self, argc, argv);
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 15) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              int res = SWIG_ConvertPtr(argv[5], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
              _v = SWIG_CheckState(res);
              if (_v) {
                int res = SWIG_ConvertPtr(argv[6], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                _v = SWIG_CheckState(res);
                if (_v) {
                  int res = SWIG_ConvertPtr(argv[7], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    {
                      int res = SWIG_AsVal_int(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        {
                          int res = SWIG_AsVal_double(argv[10], NULL);
                          _v = SWIG_CheckState(res);
                        }
                        if (_v) {
                          {
                            int res = SWIG_AsVal_int(argv[11], NULL);
                            _v = SWIG_CheckState(res);
                          }
                          if (_v) {
                            {
                              int res = SWIG_AsVal_bool(argv[12], NULL);
                              _v = SWIG_CheckState(res);
                            }
                            if (_v) {
                              int res = SWIG_ConvertPtr(argv[13], 0, SWIGTYPE_p_std__mapT_std__string_std__string_t, SWIG_POINTER_NO_NULL | 0);
                              _v = SWIG_CheckState(res);
                              if (_v) {
                                int res = swig::asptr(argv[14], (std::vector< std::string,std::allocator< std::string > >**)(0));
                                _v = SWIG_CheckState(res);
                                if (_v) {
                                  return _wrap_new_pha__SWIG_5(self, argc, argv);
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_pha'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::pha()\n"
    "    heasp::pha::pha(heasp::pha const &)\n"
    "    heasp::pha::pha(std::string const,Integer const,Integer const)\n"
    "    heasp::pha::pha(std::string const,Integer const)\n"
    "    heasp::pha::pha(std::string const)\n"
    "    heasp::pha::pha(RealVector const &,RealVector const &,RealVector const &,IntegerVector const &,IntegerVector const &,IntegerVector const &,RealVector const &,RealVector const &,Integer const,Real const,Real const,Integer const,bool const,std::map< std::string,std::string > const &,StringVector const &)\n"
    "    heasp::pha::pha(RealVector const &,RealVector const &,RealVector const &,IntegerVector const &,IntegerVector const &,IntegerVector const &,RealVector const &,RealVector const &,Integer const,Real const,Real const,Integer const,bool const,std::map< std::string,std::string > const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_delete_pha(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_pha" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_read__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  Integer result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_read" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "pha_read" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  result = (Integer)(arg1)->read(arg2,arg3,arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_read__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_read" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->read(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_read__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_read" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->read(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_read(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "pha_read", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_pha_read__SWIG_2(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_pha_read__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_pha_read__SWIG_0(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'pha_read'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::read(std::string const,Integer const,Integer const)\n"
    "    heasp::pha::read(std::string const,Integer const)\n"
    "    heasp::pha::read(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_pha_load__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  IntegerVector *arg5 = 0 ;
  IntegerVector *arg6 = 0 ;
  IntegerVector *arg7 = 0 ;
  RealVector *arg8 = 0 ;
  RealVector *arg9 = 0 ;
  Integer arg10 ;
  Real arg11 ;
  Real arg12 ;
  Integer arg13 ;
  bool arg14 ;
  std::map< std::string,std::string > *arg15 = 0 ;
  StringVector *arg16 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  std::vector< int,std::allocator< int > > tvec5 ;
  std::vector< int,std::allocator< int > > tvec6 ;
  std::vector< int,std::allocator< int > > tvec7 ;
  std::vector< double,std::allocator< double > > tvec8 ;
  std::vector< double,std::allocator< double > > tvec9 ;
  int val10 ;
  int ecode10 = 0 ;
  double val11 ;
  int ecode11 = 0 ;
  double val12 ;
  int ecode12 = 0 ;
  int val13 ;
  int ecode13 = 0 ;
  bool val14 ;
  int ecode14 = 0 ;
  void *argp15 = 0 ;
  int res15 = 0 ;
  int res16 = SWIG_OLDOBJ ;
  Integer result;
  
  if ((nobjs < 16) || (nobjs > 16)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_load" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<int>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  {
    // a Python array is in swig_obj[5]. We need to get its size then resize
    // arg6 and copy the contents from swig_obj[5] into (&arg6)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[5], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec6.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec6[i] = static_cast<int>(in_data[i]);
    }
    arg6 = &tvec6;
    
    
  }
  {
    // a Python array is in swig_obj[6]. We need to get its size then resize
    // arg7 and copy the contents from swig_obj[6] into (&arg7)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[6], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec7.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec7[i] = static_cast<int>(in_data[i]);
    }
    arg7 = &tvec7;
    
    
  }
  {
    // a Python array is in swig_obj[7]. We need to get its size then resize
    // arg8 and copy the contents from swig_obj[7] into (&arg8)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[7], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec8.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec8[i] = static_cast<double>(in_data[i]);
    }
    arg8 = &tvec8;
    
    
  }
  {
    // a Python array is in swig_obj[8]. We need to get its size then resize
    // arg9 and copy the contents from swig_obj[8] into (&arg9)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[8], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec9.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec9[i] = static_cast<double>(in_data[i]);
    }
    arg9 = &tvec9;
    
    
  }
  ecode10 = SWIG_AsVal_int(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "pha_load" "', argument " "10"" of type '" "Integer""'");
  } 
  arg10 = static_cast< Integer >(val10);
  ecode11 = SWIG_AsVal_double(swig_obj[10], &val11);
  if (!SWIG_IsOK(ecode11)) {
    SWIG_exception_fail(SWIG_ArgError(ecode11), "in method '" "pha_load" "', argument " "11"" of type '" "Real""'");
  } 
  arg11 = static_cast< Real >(val11);
  ecode12 = SWIG_AsVal_double(swig_obj[11], &val12);
  if (!SWIG_IsOK(ecode12)) {
    SWIG_exception_fail(SWIG_ArgError(ecode12), "in method '" "pha_load" "', argument " "12"" of type '" "Real""'");
  } 
  arg12 = static_cast< Real >(val12);
  ecode13 = SWIG_AsVal_int(swig_obj[12], &val13);
  if (!SWIG_IsOK(ecode13)) {
    SWIG_exception_fail(SWIG_ArgError(ecode13), "in method '" "pha_load" "', argument " "13"" of type '" "Integer""'");
  } 
  arg13 = static_cast< Integer >(val13);
  ecode14 = SWIG_AsVal_bool(swig_obj[13], &val14);
  if (!SWIG_IsOK(ecode14)) {
    SWIG_exception_fail(SWIG_ArgError(ecode14), "in method '" "pha_load" "', argument " "14"" of type '" "bool""'");
  } 
  arg14 = static_cast< bool >(val14);
  res15 = SWIG_ConvertPtr(swig_obj[14], &argp15, SWIGTYPE_p_std__mapT_std__string_std__string_t,  0  | 0);
  if (!SWIG_IsOK(res15)) {
    SWIG_exception_fail(SWIG_ArgError(res15), "in method '" "pha_load" "', argument " "15"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  if (!argp15) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_load" "', argument " "15"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  arg15 = reinterpret_cast< std::map< std::string,std::string > * >(argp15);
  {
    std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0;
    res16 = swig::asptr(swig_obj[15], &ptr);
    if (!SWIG_IsOK(res16)) {
      SWIG_exception_fail(SWIG_ArgError(res16), "in method '" "pha_load" "', argument " "16"" of type '" "StringVector const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_load" "', argument " "16"" of type '" "StringVector const &""'"); 
    }
    arg16 = ptr;
  }
  result = (Integer)(arg1)->load((RealVector const &)*arg2,(RealVector const &)*arg3,(RealVector const &)*arg4,(IntegerVector const &)*arg5,(IntegerVector const &)*arg6,(IntegerVector const &)*arg7,(RealVector const &)*arg8,(RealVector const &)*arg9,arg10,arg11,arg12,arg13,arg14,(std::map< std::string,std::string > const &)*arg15,(StringVector const &)*arg16);
  resultobj = SWIG_From_int(static_cast< int >(result));
  if (SWIG_IsNewObj(res16)) delete arg16;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res16)) delete arg16;
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_load__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  IntegerVector *arg5 = 0 ;
  IntegerVector *arg6 = 0 ;
  IntegerVector *arg7 = 0 ;
  RealVector *arg8 = 0 ;
  RealVector *arg9 = 0 ;
  Integer arg10 ;
  Real arg11 ;
  Real arg12 ;
  Integer arg13 ;
  bool arg14 ;
  std::map< std::string,std::string > *arg15 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  std::vector< int,std::allocator< int > > tvec5 ;
  std::vector< int,std::allocator< int > > tvec6 ;
  std::vector< int,std::allocator< int > > tvec7 ;
  std::vector< double,std::allocator< double > > tvec8 ;
  std::vector< double,std::allocator< double > > tvec9 ;
  int val10 ;
  int ecode10 = 0 ;
  double val11 ;
  int ecode11 = 0 ;
  double val12 ;
  int ecode12 = 0 ;
  int val13 ;
  int ecode13 = 0 ;
  bool val14 ;
  int ecode14 = 0 ;
  void *argp15 = 0 ;
  int res15 = 0 ;
  Integer result;
  
  if ((nobjs < 15) || (nobjs > 15)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_load" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<int>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  {
    // a Python array is in swig_obj[5]. We need to get its size then resize
    // arg6 and copy the contents from swig_obj[5] into (&arg6)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[5], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec6.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec6[i] = static_cast<int>(in_data[i]);
    }
    arg6 = &tvec6;
    
    
  }
  {
    // a Python array is in swig_obj[6]. We need to get its size then resize
    // arg7 and copy the contents from swig_obj[6] into (&arg7)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[6], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec7.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec7[i] = static_cast<int>(in_data[i]);
    }
    arg7 = &tvec7;
    
    
  }
  {
    // a Python array is in swig_obj[7]. We need to get its size then resize
    // arg8 and copy the contents from swig_obj[7] into (&arg8)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[7], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec8.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec8[i] = static_cast<double>(in_data[i]);
    }
    arg8 = &tvec8;
    
    
  }
  {
    // a Python array is in swig_obj[8]. We need to get its size then resize
    // arg9 and copy the contents from swig_obj[8] into (&arg9)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[8], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec9.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec9[i] = static_cast<double>(in_data[i]);
    }
    arg9 = &tvec9;
    
    
  }
  ecode10 = SWIG_AsVal_int(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "pha_load" "', argument " "10"" of type '" "Integer""'");
  } 
  arg10 = static_cast< Integer >(val10);
  ecode11 = SWIG_AsVal_double(swig_obj[10], &val11);
  if (!SWIG_IsOK(ecode11)) {
    SWIG_exception_fail(SWIG_ArgError(ecode11), "in method '" "pha_load" "', argument " "11"" of type '" "Real""'");
  } 
  arg11 = static_cast< Real >(val11);
  ecode12 = SWIG_AsVal_double(swig_obj[11], &val12);
  if (!SWIG_IsOK(ecode12)) {
    SWIG_exception_fail(SWIG_ArgError(ecode12), "in method '" "pha_load" "', argument " "12"" of type '" "Real""'");
  } 
  arg12 = static_cast< Real >(val12);
  ecode13 = SWIG_AsVal_int(swig_obj[12], &val13);
  if (!SWIG_IsOK(ecode13)) {
    SWIG_exception_fail(SWIG_ArgError(ecode13), "in method '" "pha_load" "', argument " "13"" of type '" "Integer""'");
  } 
  arg13 = static_cast< Integer >(val13);
  ecode14 = SWIG_AsVal_bool(swig_obj[13], &val14);
  if (!SWIG_IsOK(ecode14)) {
    SWIG_exception_fail(SWIG_ArgError(ecode14), "in method '" "pha_load" "', argument " "14"" of type '" "bool""'");
  } 
  arg14 = static_cast< bool >(val14);
  res15 = SWIG_ConvertPtr(swig_obj[14], &argp15, SWIGTYPE_p_std__mapT_std__string_std__string_t,  0  | 0);
  if (!SWIG_IsOK(res15)) {
    SWIG_exception_fail(SWIG_ArgError(res15), "in method '" "pha_load" "', argument " "15"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  if (!argp15) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_load" "', argument " "15"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  arg15 = reinterpret_cast< std::map< std::string,std::string > * >(argp15);
  result = (Integer)(arg1)->load((RealVector const &)*arg2,(RealVector const &)*arg3,(RealVector const &)*arg4,(IntegerVector const &)*arg5,(IntegerVector const &)*arg6,(IntegerVector const &)*arg7,(RealVector const &)*arg8,(RealVector const &)*arg9,arg10,arg11,arg12,arg13,arg14,(std::map< std::string,std::string > const &)*arg15);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_load(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[17] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "pha_load", 0, 16, argv))) SWIG_fail;
  --argc;
  if (argc == 15) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              int res = SWIG_ConvertPtr(argv[5], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
              _v = SWIG_CheckState(res);
              if (_v) {
                int res = SWIG_ConvertPtr(argv[6], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
                _v = SWIG_CheckState(res);
                if (_v) {
                  int res = SWIG_ConvertPtr(argv[7], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    int res = SWIG_ConvertPtr(argv[8], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                    _v = SWIG_CheckState(res);
                    if (_v) {
                      {
                        int res = SWIG_AsVal_int(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        {
                          int res = SWIG_AsVal_double(argv[10], NULL);
                          _v = SWIG_CheckState(res);
                        }
                        if (_v) {
                          {
                            int res = SWIG_AsVal_double(argv[11], NULL);
                            _v = SWIG_CheckState(res);
                          }
                          if (_v) {
                            {
                              int res = SWIG_AsVal_int(argv[12], NULL);
                              _v = SWIG_CheckState(res);
                            }
                            if (_v) {
                              {
                                int res = SWIG_AsVal_bool(argv[13], NULL);
                                _v = SWIG_CheckState(res);
                              }
                              if (_v) {
                                int res = SWIG_ConvertPtr(argv[14], 0, SWIGTYPE_p_std__mapT_std__string_std__string_t, SWIG_POINTER_NO_NULL | 0);
                                _v = SWIG_CheckState(res);
                                if (_v) {
                                  return _wrap_pha_load__SWIG_1(self, argc, argv);
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 16) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              int res = SWIG_ConvertPtr(argv[5], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
              _v = SWIG_CheckState(res);
              if (_v) {
                int res = SWIG_ConvertPtr(argv[6], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
                _v = SWIG_CheckState(res);
                if (_v) {
                  int res = SWIG_ConvertPtr(argv[7], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    int res = SWIG_ConvertPtr(argv[8], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                    _v = SWIG_CheckState(res);
                    if (_v) {
                      {
                        int res = SWIG_AsVal_int(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        {
                          int res = SWIG_AsVal_double(argv[10], NULL);
                          _v = SWIG_CheckState(res);
                        }
                        if (_v) {
                          {
                            int res = SWIG_AsVal_double(argv[11], NULL);
                            _v = SWIG_CheckState(res);
                          }
                          if (_v) {
                            {
                              int res = SWIG_AsVal_int(argv[12], NULL);
                              _v = SWIG_CheckState(res);
                            }
                            if (_v) {
                              {
                                int res = SWIG_AsVal_bool(argv[13], NULL);
                                _v = SWIG_CheckState(res);
                              }
                              if (_v) {
                                int res = SWIG_ConvertPtr(argv[14], 0, SWIGTYPE_p_std__mapT_std__string_std__string_t, SWIG_POINTER_NO_NULL | 0);
                                _v = SWIG_CheckState(res);
                                if (_v) {
                                  int res = swig::asptr(argv[15], (std::vector< std::string,std::allocator< std::string > >**)(0));
                                  _v = SWIG_CheckState(res);
                                  if (_v) {
                                    return _wrap_pha_load__SWIG_0(self, argc, argv);
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'pha_load'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::load(RealVector const &,RealVector const &,RealVector const &,IntegerVector const &,IntegerVector const &,IntegerVector const &,RealVector const &,RealVector const &,Integer const,Real const,Real const,Integer const,bool const,std::map< std::string,std::string > const &,StringVector const &)\n"
    "    heasp::pha::load(RealVector const &,RealVector const &,RealVector const &,IntegerVector const &,IntegerVector const &,IntegerVector const &,RealVector const &,RealVector const &,Integer const,Real const,Real const,Integer const,bool const,std::map< std::string,std::string > const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_pha_copy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  heasp::pha *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::pha *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_copy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_copy" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_copy" "', argument " "2"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_copy" "', argument " "2"" of type '" "heasp::pha const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::pha * >(argp2);
  result = (heasp::pha *) &(arg1)->copy((heasp::pha const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_disp" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->disp();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_clear" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_check(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_check" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->check();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_write__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  std::string arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_write" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_write" "', argument " "3"" of type '" "std::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::pha const *)arg1)->write(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_write__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_write" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::pha const *)arg1)->write(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_write(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "pha_write", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_pha_write__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_pha_write__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'pha_write'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::write(std::string const,std::string const) const\n"
    "    heasp::pha::write(std::string const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_pha___imul__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::pha *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha___imul__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha___imul__" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha___imul__" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  result = (heasp::pha *) &(arg1)->operator *=(arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha___iadd__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  heasp::pha *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::pha *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha___iadd__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha___iadd__" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha___iadd__" "', argument " "2"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha___iadd__" "', argument " "2"" of type '" "heasp::pha const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::pha * >(argp2);
  result = (heasp::pha *) &(arg1)->operator +=((heasp::pha const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__pha, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_checkCompatibility(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  heasp::pha *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_checkCompatibility", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_checkCompatibility" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_checkCompatibility" "', argument " "2"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_checkCompatibility" "', argument " "2"" of type '" "heasp::pha const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::pha * >(argp2);
  result = (Integer)((heasp::pha const *)arg1)->checkCompatibility((heasp::pha const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_selectChannels(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_selectChannels", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_selectChannels" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = (Integer)(arg1)->selectChannels((IntegerVector const &)*arg2,(IntegerVector const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setGrouping(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  heasp::grouping *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setGrouping", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setGrouping" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__grouping,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_setGrouping" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_setGrouping" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  arg2 = reinterpret_cast< heasp::grouping * >(argp2);
  result = (Integer)(arg1)->setGrouping(*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getGrouping(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::grouping result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getGrouping();
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinCountsGrouping__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinCountsGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getMinCountsGrouping" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_getMinCountsGrouping" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "pha_getMinCountsGrouping" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  result = ((heasp::pha const *)arg1)->getMinCountsGrouping(arg2,arg3,arg4);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinCountsGrouping__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinCountsGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getMinCountsGrouping" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_getMinCountsGrouping" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = ((heasp::pha const *)arg1)->getMinCountsGrouping(arg2,arg3);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinCountsGrouping__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinCountsGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getMinCountsGrouping" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::pha const *)arg1)->getMinCountsGrouping(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinCountsGrouping(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "pha_getMinCountsGrouping", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_pha_getMinCountsGrouping__SWIG_2(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(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_pha_getMinCountsGrouping__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_pha_getMinCountsGrouping__SWIG_0(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'pha_getMinCountsGrouping'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::getMinCountsGrouping(Integer const,Integer const,Integer const) const\n"
    "    heasp::pha::getMinCountsGrouping(Integer const,Integer const) const\n"
    "    heasp::pha::getMinCountsGrouping(Integer const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNGrouping__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Real arg2 ;
  heasp::pha *arg3 = 0 ;
  Integer arg4 ;
  Integer arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinSNGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getMinSNGrouping" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "pha_getMinSNGrouping" "', argument " "3"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNGrouping" "', argument " "3"" of type '" "heasp::pha const &""'"); 
  }
  arg3 = reinterpret_cast< heasp::pha * >(argp3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "pha_getMinSNGrouping" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "pha_getMinSNGrouping" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  result = ((heasp::pha const *)arg1)->getMinSNGrouping(arg2,(heasp::pha const &)*arg3,arg4,arg5);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNGrouping__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Real arg2 ;
  heasp::pha *arg3 = 0 ;
  Integer arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinSNGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getMinSNGrouping" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "pha_getMinSNGrouping" "', argument " "3"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNGrouping" "', argument " "3"" of type '" "heasp::pha const &""'"); 
  }
  arg3 = reinterpret_cast< heasp::pha * >(argp3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "pha_getMinSNGrouping" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  result = ((heasp::pha const *)arg1)->getMinSNGrouping(arg2,(heasp::pha const &)*arg3,arg4);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNGrouping__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Real arg2 ;
  heasp::pha *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinSNGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getMinSNGrouping" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "pha_getMinSNGrouping" "', argument " "3"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNGrouping" "', argument " "3"" of type '" "heasp::pha const &""'"); 
  }
  arg3 = reinterpret_cast< heasp::pha * >(argp3);
  result = ((heasp::pha const *)arg1)->getMinSNGrouping(arg2,(heasp::pha const &)*arg3);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNGrouping__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinSNGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getMinSNGrouping" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  result = ((heasp::pha const *)arg1)->getMinSNGrouping(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNGrouping(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[6] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "pha_getMinSNGrouping", 0, 5, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_double(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_pha_getMinSNGrouping__SWIG_3(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_double(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_pha_getMinSNGrouping__SWIG_2(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_double(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            return _wrap_pha_getMinSNGrouping__SWIG_1(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_double(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_pha_getMinSNGrouping__SWIG_0(self, argc, argv);
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'pha_getMinSNGrouping'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::getMinSNGrouping(Real const,heasp::pha const &,Integer const,Integer const) const\n"
    "    heasp::pha::getMinSNGrouping(Real const,heasp::pha const &,Integer const) const\n"
    "    heasp::pha::getMinSNGrouping(Real const,heasp::pha const &) const\n"
    "    heasp::pha::getMinSNGrouping(Real const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNOptimalGrouping__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > arg2 ;
  Real arg3 ;
  heasp::pha *arg4 = 0 ;
  Integer arg5 ;
  Integer arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  int val6 ;
  int ecode6 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 6) || (nobjs > 6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t,  0  | 0);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "2"" of type '" "RealVector const""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNOptimalGrouping" "', argument " "2"" of type '" "RealVector const""'");
    } else {
      RealVector * temp = reinterpret_cast< RealVector * >(argp2);
      arg2 = *temp;
      if (SWIG_IsNewObj(res2)) delete temp;
    }
  }
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "4"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNOptimalGrouping" "', argument " "4"" of type '" "heasp::pha const &""'"); 
  }
  arg4 = reinterpret_cast< heasp::pha * >(argp4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_int(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "6"" of type '" "Integer""'");
  } 
  arg6 = static_cast< Integer >(val6);
  result = ((heasp::pha const *)arg1)->getMinSNOptimalGrouping(arg2,arg3,(heasp::pha const &)*arg4,arg5,arg6);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNOptimalGrouping__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > arg2 ;
  Real arg3 ;
  heasp::pha *arg4 = 0 ;
  Integer arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t,  0  | 0);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "2"" of type '" "RealVector const""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNOptimalGrouping" "', argument " "2"" of type '" "RealVector const""'");
    } else {
      RealVector * temp = reinterpret_cast< RealVector * >(argp2);
      arg2 = *temp;
      if (SWIG_IsNewObj(res2)) delete temp;
    }
  }
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "4"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNOptimalGrouping" "', argument " "4"" of type '" "heasp::pha const &""'"); 
  }
  arg4 = reinterpret_cast< heasp::pha * >(argp4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  result = ((heasp::pha const *)arg1)->getMinSNOptimalGrouping(arg2,arg3,(heasp::pha const &)*arg4,arg5);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNOptimalGrouping__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > arg2 ;
  Real arg3 ;
  heasp::pha *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t,  0  | 0);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "2"" of type '" "RealVector const""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNOptimalGrouping" "', argument " "2"" of type '" "RealVector const""'");
    } else {
      RealVector * temp = reinterpret_cast< RealVector * >(argp2);
      arg2 = *temp;
      if (SWIG_IsNewObj(res2)) delete temp;
    }
  }
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "4"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNOptimalGrouping" "', argument " "4"" of type '" "heasp::pha const &""'"); 
  }
  arg4 = reinterpret_cast< heasp::pha * >(argp4);
  result = ((heasp::pha const *)arg1)->getMinSNOptimalGrouping(arg2,arg3,(heasp::pha const &)*arg4);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNOptimalGrouping__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  heasp::grouping result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t,  0  | 0);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "2"" of type '" "RealVector const""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_getMinSNOptimalGrouping" "', argument " "2"" of type '" "RealVector const""'");
    } else {
      RealVector * temp = reinterpret_cast< RealVector * >(argp2);
      arg2 = *temp;
      if (SWIG_IsNewObj(res2)) delete temp;
    }
  }
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_getMinSNOptimalGrouping" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = ((heasp::pha const *)arg1)->getMinSNOptimalGrouping(arg2,arg3);
  resultobj = SWIG_NewPointerObj((new heasp::grouping(result)), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getMinSNOptimalGrouping(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[7] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "pha_getMinSNOptimalGrouping", 0, 6, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_double(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_pha_getMinSNOptimalGrouping__SWIG_3(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_double(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_pha_getMinSNOptimalGrouping__SWIG_2(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_double(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            {
              int res = SWIG_AsVal_int(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              return _wrap_pha_getMinSNOptimalGrouping__SWIG_1(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 6) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_double(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            {
              int res = SWIG_AsVal_int(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_pha_getMinSNOptimalGrouping__SWIG_0(self, argc, argv);
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'pha_getMinSNOptimalGrouping'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::getMinSNOptimalGrouping(RealVector const,Real const,heasp::pha const &,Integer const,Integer const) const\n"
    "    heasp::pha::getMinSNOptimalGrouping(RealVector const,Real const,heasp::pha const &,Integer const) const\n"
    "    heasp::pha::getMinSNOptimalGrouping(RealVector const,Real const,heasp::pha const &) const\n"
    "    heasp::pha::getMinSNOptimalGrouping(RealVector const,Real const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_pha_calcSignalAndNoise__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  heasp::pha *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_calcSignalAndNoise" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "pha_calcSignalAndNoise" "', argument " "4"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_calcSignalAndNoise" "', argument " "4"" of type '" "heasp::pha const &""'"); 
  }
  arg4 = reinterpret_cast< heasp::pha * >(argp4);
  ((heasp::pha const *)arg1)->calcSignalAndNoise(*arg2,*arg3,(heasp::pha const &)*arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_calcSignalAndNoise__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_calcSignalAndNoise" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  ((heasp::pha const *)arg1)->calcSignalAndNoise(*arg2,*arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_calcSignalAndNoise(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "pha_calcSignalAndNoise", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      void *vptr = 0;
      int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL);
      _v = SWIG_CheckState(res);
      if (_v) {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_pha_calcSignalAndNoise__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      void *vptr = 0;
      int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL);
      _v = SWIG_CheckState(res);
      if (_v) {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_pha_calcSignalAndNoise__SWIG_0(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'pha_calcSignalAndNoise'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::calcSignalAndNoise(RealVector &,RealVector &,heasp::pha const &) const\n"
    "    heasp::pha::calcSignalAndNoise(RealVector &,RealVector &) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_pha_rebinChannels__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  heasp::grouping *arg2 = 0 ;
  std::string arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_rebinChannels" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__grouping,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_rebinChannels" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_rebinChannels" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  arg2 = reinterpret_cast< heasp::grouping * >(argp2);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_rebinChannels" "', argument " "3"" of type '" "std::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->rebinChannels(*arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_rebinChannels__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  heasp::grouping *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_rebinChannels" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__grouping,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_rebinChannels" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_rebinChannels" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  arg2 = reinterpret_cast< heasp::grouping * >(argp2);
  result = (Integer)(arg1)->rebinChannels(*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_rebinChannels(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "pha_rebinChannels", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      void *vptr = 0;
      int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_heasp__grouping, SWIG_POINTER_NO_NULL);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_pha_rebinChannels__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      void *vptr = 0;
      int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_heasp__grouping, SWIG_POINTER_NO_NULL);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_pha_rebinChannels__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'pha_rebinChannels'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::rebinChannels(heasp::grouping &,std::string const)\n"
    "    heasp::pha::rebinChannels(heasp::grouping &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_pha_shiftChannels__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Real arg4 ;
  Real arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  Integer result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_shiftChannels" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_shiftChannels" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_shiftChannels" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "pha_shiftChannels" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "pha_shiftChannels" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  result = (Integer)(arg1)->shiftChannels(arg2,arg3,arg4,arg5);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_shiftChannels__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Real arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  Integer result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_shiftChannels" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_shiftChannels" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_shiftChannels" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "pha_shiftChannels" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  result = (Integer)(arg1)->shiftChannels(arg2,arg3,arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_shiftChannels__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  RealVector *arg5 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  std::vector< double,std::allocator< double > > tvec5 ;
  Integer result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_shiftChannels" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<double>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  result = (Integer)(arg1)->shiftChannels((IntegerVector const &)*arg2,(IntegerVector const &)*arg3,(RealVector const &)*arg4,(RealVector const &)*arg5);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_shiftChannels__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  Integer arg4 ;
  Integer arg5 ;
  Real arg6 ;
  Real arg7 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  double val7 ;
  int ecode7 = 0 ;
  Integer result;
  
  if ((nobjs < 7) || (nobjs > 7)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_shiftChannels" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "pha_shiftChannels" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "pha_shiftChannels" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "pha_shiftChannels" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  ecode7 = SWIG_AsVal_double(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "pha_shiftChannels" "', argument " "7"" of type '" "Real""'");
  } 
  arg7 = static_cast< Real >(val7);
  result = (Integer)(arg1)->shiftChannels((RealVector const &)*arg2,(RealVector const &)*arg3,arg4,arg5,arg6,arg7);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_shiftChannels__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  Integer arg4 ;
  Integer arg5 ;
  Real arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  Integer result;
  
  if ((nobjs < 6) || (nobjs > 6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_shiftChannels" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "pha_shiftChannels" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "pha_shiftChannels" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "pha_shiftChannels" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  result = (Integer)(arg1)->shiftChannels((RealVector const &)*arg2,(RealVector const &)*arg3,arg4,arg5,arg6);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_shiftChannels__SWIG_5(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  IntegerVector *arg4 = 0 ;
  IntegerVector *arg5 = 0 ;
  RealVector *arg6 = 0 ;
  RealVector *arg7 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  std::vector< int,std::allocator< int > > tvec5 ;
  std::vector< double,std::allocator< double > > tvec6 ;
  std::vector< double,std::allocator< double > > tvec7 ;
  Integer result;
  
  if ((nobjs < 7) || (nobjs > 7)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_shiftChannels" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<int>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  {
    // a Python array is in swig_obj[5]. We need to get its size then resize
    // arg6 and copy the contents from swig_obj[5] into (&arg6)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[5], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec6.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec6[i] = static_cast<double>(in_data[i]);
    }
    arg6 = &tvec6;
    
    
  }
  {
    // a Python array is in swig_obj[6]. We need to get its size then resize
    // arg7 and copy the contents from swig_obj[6] into (&arg7)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[6], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec7.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec7[i] = static_cast<double>(in_data[i]);
    }
    arg7 = &tvec7;
    
    
  }
  result = (Integer)(arg1)->shiftChannels((RealVector const &)*arg2,(RealVector const &)*arg3,(IntegerVector const &)*arg4,(IntegerVector const &)*arg5,(RealVector const &)*arg6,(RealVector const &)*arg7);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_shiftChannels(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[8] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "pha_shiftChannels", 0, 7, argv))) SWIG_fail;
  --argc;
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_pha_shiftChannels__SWIG_1(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              return _wrap_pha_shiftChannels__SWIG_2(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_pha_shiftChannels__SWIG_0(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 6) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_AsVal_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                return _wrap_pha_shiftChannels__SWIG_4(self, argc, argv);
              }
            }
          }
        }
      }
    }
  }
  if (argc == 7) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              int res = SWIG_ConvertPtr(argv[5], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
              _v = SWIG_CheckState(res);
              if (_v) {
                int res = SWIG_ConvertPtr(argv[6], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                _v = SWIG_CheckState(res);
                if (_v) {
                  return _wrap_pha_shiftChannels__SWIG_5(self, argc, argv);
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 7) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__pha, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_AsVal_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_double(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  return _wrap_pha_shiftChannels__SWIG_3(self, argc, argv);
                }
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'pha_shiftChannels'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::pha::shiftChannels(Integer const,Integer const,Real const,Real const)\n"
    "    heasp::pha::shiftChannels(Integer const,Integer const,Real const)\n"
    "    heasp::pha::shiftChannels(IntegerVector const &,IntegerVector const &,RealVector const &,RealVector const &)\n"
    "    heasp::pha::shiftChannels(RealVector const &,RealVector const &,Integer const,Integer const,Real const,Real const)\n"
    "    heasp::pha::shiftChannels(RealVector const &,RealVector const &,Integer const,Integer const,Real const)\n"
    "    heasp::pha::shiftChannels(RealVector const &,RealVector const &,IntegerVector const &,IntegerVector const &,RealVector const &,RealVector const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_pha_convertUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  std::string arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  PyObject *swig_obj[4] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_convertUnits", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_convertUnits" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[3], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_convertUnits" "', argument " "4"" of type '" "std::string const""'"); 
    }
    arg4 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->convertUnits((RealVector const &)*arg2,(RealVector const &)*arg3,arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_NumberChannels(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_NumberChannels" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (Integer)((heasp::pha const *)arg1)->NumberChannels();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getNumberChannels(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getNumberChannels" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (Integer)((heasp::pha const *)arg1)->getNumberChannels();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getFirstChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getFirstChannel" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (Integer)((heasp::pha const *)arg1)->getFirstChannel();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setFirstChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setFirstChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setFirstChannel" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setFirstChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  (arg1)->setFirstChannel(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getPha(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getPha" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (RealVector *) &((heasp::pha const *)arg1)->getPha();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setPha(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setPha", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setPha" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setPha((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getPhaElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_getPhaElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getPhaElement" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getPhaElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::pha const *)arg1)->getPhaElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setPhaElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setPhaElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setPhaElement" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setPhaElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_setPhaElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setPhaElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getStatError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getStatError" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (RealVector *) &((heasp::pha const *)arg1)->getStatError();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setStatError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setStatError", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setStatError" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setStatError((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getStatErrorElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_getStatErrorElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getStatErrorElement" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getStatErrorElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::pha const *)arg1)->getStatErrorElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setStatErrorElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setStatErrorElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setStatErrorElement" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setStatErrorElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_setStatErrorElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setStatErrorElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getSysError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getSysError" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (RealVector *) &((heasp::pha const *)arg1)->getSysError();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setSysError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setSysError", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setSysError" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setSysError((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getSysErrorElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_getSysErrorElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getSysErrorElement" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getSysErrorElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::pha const *)arg1)->getSysErrorElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setSysErrorElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setSysErrorElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setSysErrorElement" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setSysErrorElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_setSysErrorElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setSysErrorElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  IntegerVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getChannel" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (IntegerVector *) &((heasp::pha const *)arg1)->getChannel();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  IntegerVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setChannel" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setChannel((IntegerVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getChannelElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_getChannelElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getChannelElement" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getChannelElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::pha const *)arg1)->getChannelElement(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setChannelElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setChannelElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setChannelElement" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setChannelElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_setChannelElement" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->setChannelElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getQuality(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  IntegerVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getQuality" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (IntegerVector *) &((heasp::pha const *)arg1)->getQuality();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setQuality(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  IntegerVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setQuality", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setQuality" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setQuality((IntegerVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getQualityElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_getQualityElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getQualityElement" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getQualityElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::pha const *)arg1)->getQualityElement(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setQualityElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setQualityElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setQualityElement" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setQualityElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_setQualityElement" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->setQualityElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  IntegerVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getGroup" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (IntegerVector *) &((heasp::pha const *)arg1)->getGroup();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  IntegerVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setGroup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setGroup" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setGroup((IntegerVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getGroupElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_getGroupElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getGroupElement" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getGroupElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::pha const *)arg1)->getGroupElement(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setGroupElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setGroupElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setGroupElement" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setGroupElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_setGroupElement" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->setGroupElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getAreaScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getAreaScaling" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (RealVector *) &((heasp::pha const *)arg1)->getAreaScaling();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setAreaScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setAreaScaling", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setAreaScaling" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setAreaScaling((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getAreaScalingElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_getAreaScalingElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getAreaScalingElement" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getAreaScalingElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::pha const *)arg1)->getAreaScalingElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setAreaScalingElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setAreaScalingElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setAreaScalingElement" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setAreaScalingElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_setAreaScalingElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setAreaScalingElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getBackScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getBackScaling" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (RealVector *) &((heasp::pha const *)arg1)->getBackScaling();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setBackScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setBackScaling", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setBackScaling" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setBackScaling((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getBackScalingElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_getBackScalingElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getBackScalingElement" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getBackScalingElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::pha const *)arg1)->getBackScalingElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setBackScalingElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setBackScalingElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setBackScalingElement" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setBackScalingElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "pha_setBackScalingElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setBackScalingElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getExposure(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getExposure" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (Real)((heasp::pha const *)arg1)->getExposure();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setExposure(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setExposure", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setExposure" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setExposure" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setExposure(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getCorrectionScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getCorrectionScaling" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (Real)((heasp::pha const *)arg1)->getCorrectionScaling();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setCorrectionScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setCorrectionScaling", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setCorrectionScaling" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setCorrectionScaling" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setCorrectionScaling(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getDetChans(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getDetChans" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (Integer)((heasp::pha const *)arg1)->getDetChans();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setDetChans(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setDetChans", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setDetChans" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setDetChans" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  (arg1)->setDetChans(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getPoisserr(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  bool result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getPoisserr" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (bool)((heasp::pha const *)arg1)->getPoisserr();
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setPoisserr(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  bool arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  bool val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setPoisserr", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setPoisserr" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_bool(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setPoisserr" "', argument " "2"" of type '" "bool""'");
  } 
  arg2 = static_cast< bool >(val2);
  (arg1)->setPoisserr(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getDatatype(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getDatatype" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getDatatype();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setDatatype(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setDatatype", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setDatatype" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setDatatype" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setDatatype(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getSpectrumtype(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getSpectrumtype" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getSpectrumtype();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setSpectrumtype(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setSpectrumtype", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setSpectrumtype" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setSpectrumtype" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setSpectrumtype(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getResponseFile(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getResponseFile" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getResponseFile();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setResponseFile(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setResponseFile", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setResponseFile" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setResponseFile" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setResponseFile(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getAncillaryFile(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getAncillaryFile" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getAncillaryFile();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setAncillaryFile(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setAncillaryFile", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setAncillaryFile" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setAncillaryFile" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setAncillaryFile(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getBackgroundFile(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getBackgroundFile" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getBackgroundFile();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setBackgroundFile(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setBackgroundFile", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setBackgroundFile" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setBackgroundFile" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setBackgroundFile(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getCorrectionFile(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getCorrectionFile" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getCorrectionFile();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setCorrectionFile(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setCorrectionFile", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setCorrectionFile" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setCorrectionFile" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setCorrectionFile(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getFluxUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getFluxUnits" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getFluxUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setFluxUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setFluxUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setFluxUnits" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setFluxUnits" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setFluxUnits(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getChannelType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getChannelType" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getChannelType();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setChannelType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setChannelType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setChannelType" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setChannelType" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setChannelType(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getTelescope(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getTelescope" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getTelescope();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setTelescope(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setTelescope", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setTelescope" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setTelescope" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setTelescope(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getInstrument(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getInstrument" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getInstrument();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setInstrument(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setInstrument", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setInstrument" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setInstrument" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setInstrument(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getDetector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getDetector" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getDetector();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setDetector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setDetector", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setDetector" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setDetector" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setDetector(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getFilter" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getFilter();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setFilter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setFilter" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setFilter" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setFilter(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getDatamode(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getDatamode" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getDatamode();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setDatamode(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setDatamode", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setDatamode" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setDatamode" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setDatamode(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getStokesParameter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getStokesParameter" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getStokesParameter();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setStokesParameter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setStokesParameter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setStokesParameter" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setStokesParameter" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setStokesParameter(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getStokesWeighting(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getStokesWeighting" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = ((heasp::pha const *)arg1)->getStokesWeighting();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setStokesWeighting(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setStokesWeighting", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setStokesWeighting" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setStokesWeighting" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setStokesWeighting(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getXSPECFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  StringVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getXSPECFilter" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  result = (StringVector *) &((heasp::pha const *)arg1)->getXSPECFilter();
  resultobj = swig::from(static_cast< std::vector< std::string,std::allocator< std::string > > >(*result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setXSPECFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  StringVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setXSPECFilter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setXSPECFilter" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  {
    std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0;
    res2 = swig::asptr(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "pha_setXSPECFilter" "', argument " "2"" of type '" "StringVector const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "pha_setXSPECFilter" "', argument " "2"" of type '" "StringVector const &""'"); 
    }
    arg2 = ptr;
  }
  result = (Integer)(arg1)->setXSPECFilter((StringVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_getXSPECFilterElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  std::string result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_getXSPECFilterElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_getXSPECFilterElement" "', argument " "1"" of type '" "heasp::pha const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_getXSPECFilterElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::pha const *)arg1)->getXSPECFilterElement(arg2);
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_pha_setXSPECFilterElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = (heasp::pha *) 0 ;
  Integer arg2 ;
  std::string arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "pha_setXSPECFilterElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__pha, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "pha_setXSPECFilterElement" "', argument " "1"" of type '" "heasp::pha *""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "pha_setXSPECFilterElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "pha_setXSPECFilterElement" "', argument " "3"" of type '" "std::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->setXSPECFilterElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *pha_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__pha, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *pha_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap___add____SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::pha *arg1 = 0 ;
  heasp::pha *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  heasp::pha result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "__add__" "', argument " "1"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__add__" "', argument " "1"" of type '" "heasp::pha const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::pha * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "__add__" "', argument " "2"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__add__" "', argument " "2"" of type '" "heasp::pha const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::pha * >(argp2);
  result = heasp::operator +((heasp::pha const &)*arg1,(heasp::pha const &)*arg2);
  resultobj = SWIG_NewPointerObj((new heasp::pha(result)), SWIGTYPE_p_heasp__pha, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap_PHAtype__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "PHAtype" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "PHAtype" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)heasp::PHAtype(SWIG_STD_MOVE(arg1),arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_PHAtype__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  Integer *arg3 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "PHAtype" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "PHAtype" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_int,  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "PHAtype" "', argument " "3"" of type '" "Integer &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "PHAtype" "', argument " "3"" of type '" "Integer &""'"); 
  }
  arg3 = reinterpret_cast< Integer * >(argp3);
  result = (Integer)heasp::PHAtype(SWIG_STD_MOVE(arg1),arg2,*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_PHAtype(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "PHAtype", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_PHAtype__SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_int, SWIG_POINTER_NO_NULL);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_PHAtype__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'PHAtype'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::PHAtype(std::string const,Integer const)\n"
    "    heasp::PHAtype(std::string const,Integer const,Integer &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_IsPHAcounts__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  bool result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "IsPHAcounts" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "IsPHAcounts" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (bool)heasp::IsPHAcounts(SWIG_STD_MOVE(arg1),arg2);
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_IsPHAcounts__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  Integer *arg3 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  bool result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "IsPHAcounts" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "IsPHAcounts" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_int,  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "IsPHAcounts" "', argument " "3"" of type '" "Integer &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "IsPHAcounts" "', argument " "3"" of type '" "Integer &""'"); 
  }
  arg3 = reinterpret_cast< Integer * >(argp3);
  result = (bool)heasp::IsPHAcounts(SWIG_STD_MOVE(arg1),arg2,*arg3);
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_IsPHAcounts(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "IsPHAcounts", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_IsPHAcounts__SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_int, SWIG_POINTER_NO_NULL);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_IsPHAcounts__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'IsPHAcounts'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::IsPHAcounts(std::string const,Integer const)\n"
    "    heasp::IsPHAcounts(std::string const,Integer const,Integer &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_NumberofSpectra__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "NumberofSpectra" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "NumberofSpectra" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)heasp::NumberofSpectra(SWIG_STD_MOVE(arg1),arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_NumberofSpectra__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  Integer *arg3 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "NumberofSpectra" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "NumberofSpectra" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_int,  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "NumberofSpectra" "', argument " "3"" of type '" "Integer &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "NumberofSpectra" "', argument " "3"" of type '" "Integer &""'"); 
  }
  arg3 = reinterpret_cast< Integer * >(argp3);
  result = (Integer)heasp::NumberofSpectra(SWIG_STD_MOVE(arg1),arg2,*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_NumberofSpectra(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "NumberofSpectra", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_NumberofSpectra__SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_int, SWIG_POINTER_NO_NULL);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_NumberofSpectra__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'NumberofSpectra'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::NumberofSpectra(std::string const,Integer const)\n"
    "    heasp::NumberofSpectra(std::string const,Integer const,Integer &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_SpectrumExtensions__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "SpectrumExtensions" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = heasp::SpectrumExtensions(SWIG_STD_MOVE(arg1));
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SpectrumExtensions__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer *arg2 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "SpectrumExtensions" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_int,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "SpectrumExtensions" "', argument " "2"" of type '" "Integer &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "SpectrumExtensions" "', argument " "2"" of type '" "Integer &""'"); 
  }
  arg2 = reinterpret_cast< Integer * >(argp2);
  result = heasp::SpectrumExtensions(SWIG_STD_MOVE(arg1),*arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_SpectrumExtensions(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "SpectrumExtensions", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_SpectrumExtensions__SWIG_0(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      void *vptr = 0;
      int res = SWIG_ConvertPtr(argv[1], &vptr, SWIGTYPE_p_int, SWIG_POINTER_NO_NULL);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_SpectrumExtensions__SWIG_1(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'SpectrumExtensions'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::SpectrumExtensions(std::string const)\n"
    "    heasp::SpectrumExtensions(std::string const,Integer &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_new_phaII__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  heasp::phaII *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (heasp::phaII *)new heasp::phaII();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__phaII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_phaII__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  heasp::phaII *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__phaII,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_phaII" "', argument " "1"" of type '" "heasp::phaII const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_phaII" "', argument " "1"" of type '" "heasp::phaII const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  result = (heasp::phaII *)new heasp::phaII((heasp::phaII const &)*arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__phaII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_phaII__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  IntegerVector *arg3 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  heasp::phaII *result = 0 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_phaII" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_phaII" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = (heasp::phaII *)new heasp::phaII(arg1,arg2,(IntegerVector const &)*arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__phaII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_phaII__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  heasp::phaII *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_phaII" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_phaII" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (heasp::phaII *)new heasp::phaII(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__phaII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_phaII__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  heasp::phaII *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_phaII" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (heasp::phaII *)new heasp::phaII(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__phaII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_phaII(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_phaII", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_phaII__SWIG_0(self, argc, argv);
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__phaII, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_phaII__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_phaII__SWIG_4(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_new_phaII__SWIG_3(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_new_phaII__SWIG_2(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_phaII'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::phaII::phaII()\n"
    "    heasp::phaII::phaII(heasp::phaII const &)\n"
    "    heasp::phaII::phaII(std::string const,Integer const,IntegerVector const &)\n"
    "    heasp::phaII::phaII(std::string const,Integer const)\n"
    "    heasp::phaII::phaII(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_delete_phaII(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_phaII" "', argument " "1"" of type '" "heasp::phaII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_read__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  IntegerVector *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  Integer result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_read" "', argument " "1"" of type '" "heasp::phaII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "phaII_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "phaII_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  result = (Integer)(arg1)->read(arg2,arg3,(IntegerVector const &)*arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_read__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_read" "', argument " "1"" of type '" "heasp::phaII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "phaII_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "phaII_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->read(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_read__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_read" "', argument " "1"" of type '" "heasp::phaII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "phaII_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->read(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_read(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "phaII_read", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__phaII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_phaII_read__SWIG_2(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__phaII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_phaII_read__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__phaII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_phaII_read__SWIG_0(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'phaII_read'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::phaII::read(std::string const,Integer const,IntegerVector const &)\n"
    "    heasp::phaII::read(std::string const,Integer const)\n"
    "    heasp::phaII::read(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_phaII_copy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  heasp::phaII *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::phaII *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "phaII_copy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_copy" "', argument " "1"" of type '" "heasp::phaII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__phaII,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "phaII_copy" "', argument " "2"" of type '" "heasp::phaII const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "phaII_copy" "', argument " "2"" of type '" "heasp::phaII const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::phaII * >(argp2);
  result = (heasp::phaII *) &(arg1)->copy((heasp::phaII const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__phaII, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_get(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::pha result;
  
  if (!SWIG_Python_UnpackTuple(args, "phaII_get", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_get" "', argument " "1"" of type '" "heasp::phaII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "phaII_get" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::phaII const *)arg1)->get(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::pha(result)), SWIGTYPE_p_heasp__pha, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_push(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  heasp::pha arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "phaII_push", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_push" "', argument " "1"" of type '" "heasp::phaII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__pha,  0  | 0);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "phaII_push" "', argument " "2"" of type '" "heasp::pha""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "phaII_push" "', argument " "2"" of type '" "heasp::pha""'");
    } else {
      heasp::pha * temp = reinterpret_cast< heasp::pha * >(argp2);
      arg2 = *temp;
      if (SWIG_IsNewObj(res2)) delete temp;
    }
  }
  (arg1)->push(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_disp" "', argument " "1"" of type '" "heasp::phaII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  result = ((heasp::phaII const *)arg1)->disp();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_clear" "', argument " "1"" of type '" "heasp::phaII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_check(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_check" "', argument " "1"" of type '" "heasp::phaII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  result = ((heasp::phaII const *)arg1)->check();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_write__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  std::string arg2 ;
  std::string arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_write" "', argument " "1"" of type '" "heasp::phaII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "phaII_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "phaII_write" "', argument " "3"" of type '" "std::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::phaII const *)arg1)->write(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_write__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_write" "', argument " "1"" of type '" "heasp::phaII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "phaII_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::phaII const *)arg1)->write(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_write(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "phaII_write", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__phaII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_phaII_write__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__phaII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_phaII_write__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'phaII_write'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::phaII::write(std::string const,std::string const) const\n"
    "    heasp::phaII::write(std::string const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_phaII_NumberSpectra(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_NumberSpectra" "', argument " "1"" of type '" "heasp::phaII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  result = (Integer)((heasp::phaII const *)arg1)->NumberSpectra();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_getNumberSpectra(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_getNumberSpectra" "', argument " "1"" of type '" "heasp::phaII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  result = (Integer)((heasp::phaII const *)arg1)->getNumberSpectra();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_getphas(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< heasp::pha,std::allocator< heasp::pha > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_getphas" "', argument " "1"" of type '" "heasp::phaII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  result = (std::vector< heasp::pha,std::allocator< heasp::pha > > *) &((heasp::phaII const *)arg1)->getphas();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_heasp__pha_std__allocatorT_heasp__pha_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_setphas(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  std::vector< heasp::pha,std::allocator< heasp::pha > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "phaII_setphas", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_setphas" "', argument " "1"" of type '" "heasp::phaII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_heasp__pha_std__allocatorT_heasp__pha_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "phaII_setphas" "', argument " "2"" of type '" "std::vector< heasp::pha,std::allocator< heasp::pha > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "phaII_setphas" "', argument " "2"" of type '" "std::vector< heasp::pha,std::allocator< heasp::pha > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< heasp::pha,std::allocator< heasp::pha > > * >(argp2);
  result = (Integer)(arg1)->setphas((std::vector< heasp::pha,std::allocator< heasp::pha > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_getphasElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::pha result;
  
  if (!SWIG_Python_UnpackTuple(args, "phaII_getphasElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_getphasElement" "', argument " "1"" of type '" "heasp::phaII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "phaII_getphasElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::phaII const *)arg1)->getphasElement(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::pha(result)), SWIGTYPE_p_heasp__pha, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_phaII_setphasElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::phaII *arg1 = (heasp::phaII *) 0 ;
  Integer arg2 ;
  heasp::pha *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "phaII_setphasElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__phaII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "phaII_setphasElement" "', argument " "1"" of type '" "heasp::phaII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::phaII * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "phaII_setphasElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_heasp__pha,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "phaII_setphasElement" "', argument " "3"" of type '" "heasp::pha const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "phaII_setphasElement" "', argument " "3"" of type '" "heasp::pha const &""'"); 
  }
  arg3 = reinterpret_cast< heasp::pha * >(argp3);
  result = (Integer)(arg1)->setphasElement(arg2,(heasp::pha const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *phaII_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__phaII, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *phaII_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_new_rmf__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  heasp::rmf *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (heasp::rmf *)new heasp::rmf();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_rmf__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  heasp::rmf *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_rmf" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_rmf" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (heasp::rmf *)new heasp::rmf(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_rmf__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  heasp::rmf *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_rmf" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (heasp::rmf *)new heasp::rmf(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_rmf__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  IntegerVector *arg1 = 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg2 = 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg3 = 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg4 = 0 ;
  RealVector *arg5 = 0 ;
  RealVector *arg6 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg7 = 0 ;
  RealVector *arg8 = 0 ;
  RealVector *arg9 = 0 ;
  Integer arg10 ;
  Real arg11 ;
  Real arg12 ;
  std::map< std::string,std::string > *arg13 = 0 ;
  std::vector< int,std::allocator< int > > tvec1 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  std::vector< double,std::allocator< double > > tvec5 ;
  std::vector< double,std::allocator< double > > tvec6 ;
  void *argp7 = 0 ;
  int res7 = 0 ;
  std::vector< double,std::allocator< double > > tvec8 ;
  std::vector< double,std::allocator< double > > tvec9 ;
  int val10 ;
  int ecode10 = 0 ;
  double val11 ;
  int ecode11 = 0 ;
  double val12 ;
  int ecode12 = 0 ;
  void *argp13 = 0 ;
  int res13 = 0 ;
  heasp::rmf *result = 0 ;
  
  if ((nobjs < 13) || (nobjs > 13)) SWIG_fail;
  {
    // a Python array is in swig_obj[0]. We need to get its size then resize
    // arg1 and copy the contents from swig_obj[0] into (&arg1)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[0], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec1.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec1[i] = static_cast<int>(in_data[i]);
    }
    arg1 = &tvec1;
    
    
  }
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_rmf" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_rmf" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_rmf" "', argument " "3"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_rmf" "', argument " "3"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg3 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "new_rmf" "', argument " "4"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_rmf" "', argument " "4"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg4 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp4);
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<double>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  {
    // a Python array is in swig_obj[5]. We need to get its size then resize
    // arg6 and copy the contents from swig_obj[5] into (&arg6)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[5], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec6.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec6[i] = static_cast<double>(in_data[i]);
    }
    arg6 = &tvec6;
    
    
  }
  res7 = SWIG_ConvertPtr(swig_obj[6], &argp7, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res7)) {
    SWIG_exception_fail(SWIG_ArgError(res7), "in method '" "new_rmf" "', argument " "7"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp7) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_rmf" "', argument " "7"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg7 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp7);
  {
    // a Python array is in swig_obj[7]. We need to get its size then resize
    // arg8 and copy the contents from swig_obj[7] into (&arg8)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[7], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec8.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec8[i] = static_cast<double>(in_data[i]);
    }
    arg8 = &tvec8;
    
    
  }
  {
    // a Python array is in swig_obj[8]. We need to get its size then resize
    // arg9 and copy the contents from swig_obj[8] into (&arg9)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[8], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec9.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec9[i] = static_cast<double>(in_data[i]);
    }
    arg9 = &tvec9;
    
    
  }
  ecode10 = SWIG_AsVal_int(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "new_rmf" "', argument " "10"" of type '" "Integer""'");
  } 
  arg10 = static_cast< Integer >(val10);
  ecode11 = SWIG_AsVal_double(swig_obj[10], &val11);
  if (!SWIG_IsOK(ecode11)) {
    SWIG_exception_fail(SWIG_ArgError(ecode11), "in method '" "new_rmf" "', argument " "11"" of type '" "Real""'");
  } 
  arg11 = static_cast< Real >(val11);
  ecode12 = SWIG_AsVal_double(swig_obj[11], &val12);
  if (!SWIG_IsOK(ecode12)) {
    SWIG_exception_fail(SWIG_ArgError(ecode12), "in method '" "new_rmf" "', argument " "12"" of type '" "Real""'");
  } 
  arg12 = static_cast< Real >(val12);
  res13 = SWIG_ConvertPtr(swig_obj[12], &argp13, SWIGTYPE_p_std__mapT_std__string_std__string_t,  0  | 0);
  if (!SWIG_IsOK(res13)) {
    SWIG_exception_fail(SWIG_ArgError(res13), "in method '" "new_rmf" "', argument " "13"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  if (!argp13) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_rmf" "', argument " "13"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  arg13 = reinterpret_cast< std::map< std::string,std::string > * >(argp13);
  result = (heasp::rmf *)new heasp::rmf((IntegerVector const &)*arg1,(std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg2,(std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg3,(std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg4,(RealVector const &)*arg5,(RealVector const &)*arg6,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg7,(RealVector const &)*arg8,(RealVector const &)*arg9,arg10,arg11,arg12,(std::map< std::string,std::string > const &)*arg13);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_rmf__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  heasp::rmf *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__rmf,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_rmf" "', argument " "1"" of type '" "heasp::rmf const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_rmf" "', argument " "1"" of type '" "heasp::rmf const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (heasp::rmf *)new heasp::rmf((heasp::rmf const &)*arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_rmf__SWIG_5(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::unique_ptr< heasp::rmf > rvrdeleter1 ;
  heasp::rmf *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_RELEASE |  0 );
  if (!SWIG_IsOK(res1)) {
    if (res1 == SWIG_ERROR_RELEASE_NOT_OWNED) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_rmf" "', cannot release ownership as memory is not owned for argument " "1"" of type '" "heasp::rmf &&""'");
    } else {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_rmf" "', argument " "1"" of type '" "heasp::rmf &&""'"); 
    }
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_rmf" "', argument " "1"" of type '" "heasp::rmf &&""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  rvrdeleter1.reset(arg1);
  result = (heasp::rmf *)new heasp::rmf((heasp::rmf &&)*arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_rmf(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[14] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_rmf", 0, 13, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_rmf__SWIG_0(self, argc, argv);
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_rmf__SWIG_4(self, argc, argv);
    }
  }
  if (argc == 1) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NO_NULL);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_rmf__SWIG_5(self, argc, argv);
    }
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_rmf__SWIG_2(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_new_rmf__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 13) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              int res = SWIG_ConvertPtr(argv[5], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
              _v = SWIG_CheckState(res);
              if (_v) {
                int res = SWIG_ConvertPtr(argv[6], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
                _v = SWIG_CheckState(res);
                if (_v) {
                  int res = SWIG_ConvertPtr(argv[7], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    int res = SWIG_ConvertPtr(argv[8], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                    _v = SWIG_CheckState(res);
                    if (_v) {
                      {
                        int res = SWIG_AsVal_int(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        {
                          int res = SWIG_AsVal_double(argv[10], NULL);
                          _v = SWIG_CheckState(res);
                        }
                        if (_v) {
                          {
                            int res = SWIG_AsVal_double(argv[11], NULL);
                            _v = SWIG_CheckState(res);
                          }
                          if (_v) {
                            int res = SWIG_ConvertPtr(argv[12], 0, SWIGTYPE_p_std__mapT_std__string_std__string_t, SWIG_POINTER_NO_NULL | 0);
                            _v = SWIG_CheckState(res);
                            if (_v) {
                              return _wrap_new_rmf__SWIG_3(self, argc, argv);
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_rmf'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::rmf()\n"
    "    heasp::rmf::rmf(std::string const,Integer const)\n"
    "    heasp::rmf::rmf(std::string const)\n"
    "    heasp::rmf::rmf(IntegerVector const &,std::vector< IntegerVector,std::allocator< IntegerVector > > const &,std::vector< IntegerVector,std::allocator< IntegerVector > > const &,std::vector< IntegerVector,std::allocator< IntegerVector > > const &,RealVector const &,RealVector const &,std::vector< RealVector,std::allocator< RealVector > > const &,RealVector const &,RealVector const &,Integer const,Real const,Real const,std::map< std::string,std::string > const &)\n"
    "    heasp::rmf::rmf(heasp::rmf const &)\n"
    "    heasp::rmf::rmf(heasp::rmf &&)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_delete_rmf(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_rmf" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_read__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_read" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->read(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_read__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_read" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->read(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_read(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_read", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_rmf_read__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_rmf_read__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_read'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::read(std::string const,Integer const)\n"
    "    heasp::rmf::read(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_readMatrix__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_readMatrix" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_readMatrix" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_readMatrix" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->readMatrix(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_readMatrix__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_readMatrix" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_readMatrix" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->readMatrix(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_readMatrix(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_readMatrix", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_rmf_readMatrix__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_rmf_readMatrix__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_readMatrix'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::readMatrix(std::string const,Integer const)\n"
    "    heasp::rmf::readMatrix(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_readChannelBounds__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_readChannelBounds" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_readChannelBounds" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_readChannelBounds" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->readChannelBounds(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_readChannelBounds__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_readChannelBounds" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_readChannelBounds" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->readChannelBounds(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_readChannelBounds(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_readChannelBounds", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_rmf_readChannelBounds__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_rmf_readChannelBounds__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_readChannelBounds'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::readChannelBounds(std::string const,Integer const)\n"
    "    heasp::rmf::readChannelBounds(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_load(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  IntegerVector *arg2 = 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg3 = 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg4 = 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg5 = 0 ;
  RealVector *arg6 = 0 ;
  RealVector *arg7 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg8 = 0 ;
  RealVector *arg9 = 0 ;
  RealVector *arg10 = 0 ;
  Integer arg11 ;
  Real arg12 ;
  Real arg13 ;
  std::map< std::string,std::string > *arg14 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  void *argp5 = 0 ;
  int res5 = 0 ;
  std::vector< double,std::allocator< double > > tvec6 ;
  std::vector< double,std::allocator< double > > tvec7 ;
  void *argp8 = 0 ;
  int res8 = 0 ;
  std::vector< double,std::allocator< double > > tvec9 ;
  std::vector< double,std::allocator< double > > tvec10 ;
  int val11 ;
  int ecode11 = 0 ;
  double val12 ;
  int ecode12 = 0 ;
  double val13 ;
  int ecode13 = 0 ;
  void *argp14 = 0 ;
  int res14 = 0 ;
  PyObject *swig_obj[14] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_load", 14, 14, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_load" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmf_load" "', argument " "3"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_load" "', argument " "3"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg3 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp3);
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "rmf_load" "', argument " "4"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_load" "', argument " "4"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg4 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp4);
  res5 = SWIG_ConvertPtr(swig_obj[4], &argp5, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res5)) {
    SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "rmf_load" "', argument " "5"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp5) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_load" "', argument " "5"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg5 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp5);
  {
    // a Python array is in swig_obj[5]. We need to get its size then resize
    // arg6 and copy the contents from swig_obj[5] into (&arg6)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[5], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec6.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec6[i] = static_cast<double>(in_data[i]);
    }
    arg6 = &tvec6;
    
    
  }
  {
    // a Python array is in swig_obj[6]. We need to get its size then resize
    // arg7 and copy the contents from swig_obj[6] into (&arg7)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[6], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec7.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec7[i] = static_cast<double>(in_data[i]);
    }
    arg7 = &tvec7;
    
    
  }
  res8 = SWIG_ConvertPtr(swig_obj[7], &argp8, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res8)) {
    SWIG_exception_fail(SWIG_ArgError(res8), "in method '" "rmf_load" "', argument " "8"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp8) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_load" "', argument " "8"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg8 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp8);
  {
    // a Python array is in swig_obj[8]. We need to get its size then resize
    // arg9 and copy the contents from swig_obj[8] into (&arg9)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[8], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec9.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec9[i] = static_cast<double>(in_data[i]);
    }
    arg9 = &tvec9;
    
    
  }
  {
    // a Python array is in swig_obj[9]. We need to get its size then resize
    // arg10 and copy the contents from swig_obj[9] into (&arg10)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[9], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec10.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec10[i] = static_cast<double>(in_data[i]);
    }
    arg10 = &tvec10;
    
    
  }
  ecode11 = SWIG_AsVal_int(swig_obj[10], &val11);
  if (!SWIG_IsOK(ecode11)) {
    SWIG_exception_fail(SWIG_ArgError(ecode11), "in method '" "rmf_load" "', argument " "11"" of type '" "Integer""'");
  } 
  arg11 = static_cast< Integer >(val11);
  ecode12 = SWIG_AsVal_double(swig_obj[11], &val12);
  if (!SWIG_IsOK(ecode12)) {
    SWIG_exception_fail(SWIG_ArgError(ecode12), "in method '" "rmf_load" "', argument " "12"" of type '" "Real""'");
  } 
  arg12 = static_cast< Real >(val12);
  ecode13 = SWIG_AsVal_double(swig_obj[12], &val13);
  if (!SWIG_IsOK(ecode13)) {
    SWIG_exception_fail(SWIG_ArgError(ecode13), "in method '" "rmf_load" "', argument " "13"" of type '" "Real""'");
  } 
  arg13 = static_cast< Real >(val13);
  res14 = SWIG_ConvertPtr(swig_obj[13], &argp14, SWIGTYPE_p_std__mapT_std__string_std__string_t,  0  | 0);
  if (!SWIG_IsOK(res14)) {
    SWIG_exception_fail(SWIG_ArgError(res14), "in method '" "rmf_load" "', argument " "14"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  if (!argp14) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_load" "', argument " "14"" of type '" "std::map< std::string,std::string > const &""'"); 
  }
  arg14 = reinterpret_cast< std::map< std::string,std::string > * >(argp14);
  result = (Integer)(arg1)->load((IntegerVector const &)*arg2,(std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg3,(std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg4,(std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg5,(RealVector const &)*arg6,(RealVector const &)*arg7,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg8,(RealVector const &)*arg9,(RealVector const &)*arg10,arg11,arg12,arg13,(std::map< std::string,std::string > const &)*arg14);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_initialize(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  heasp::arf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_initialize", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_initialize" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_initialize" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_initialize" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arf * >(argp2);
  (arg1)->initialize((heasp::arf const &)*arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_loadDiagonalResponse(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  Integer arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  int val5 ;
  int ecode5 = 0 ;
  PyObject *swig_obj[5] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_loadDiagonalResponse", 5, 5, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_loadDiagonalResponse" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "rmf_loadDiagonalResponse" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  (arg1)->loadDiagonalResponse((RealVector const &)*arg2,(RealVector const &)*arg3,(RealVector const &)*arg4,arg5);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_ElementValue__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  Real result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_ElementValue" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_ElementValue" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_ElementValue" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "rmf_ElementValue" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  result = (Real)((heasp::rmf const *)arg1)->ElementValue(arg2,arg3,arg4);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_ElementValue__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  Real result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_ElementValue" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_ElementValue" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_ElementValue" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Real)((heasp::rmf const *)arg1)->ElementValue(arg2,arg3);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_ElementValue(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_ElementValue", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(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_rmf_ElementValue__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_rmf_ElementValue__SWIG_0(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_ElementValue'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::ElementValue(Integer const,Integer const,Integer const) const\n"
    "    heasp::rmf::ElementValue(Integer const,Integer const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_RowValues__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_RowValues" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_RowValues" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_RowValues" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = ((heasp::rmf const *)arg1)->RowValues(arg2,arg3);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_RowValues__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_RowValues" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_RowValues" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmf const *)arg1)->RowValues(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_RowValues(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_RowValues", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_rmf_RowValues__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(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_rmf_RowValues__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_RowValues'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::RowValues(Integer const,Integer const) const\n"
    "    heasp::rmf::RowValues(Integer const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_RandomChannels__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Real arg2 ;
  Integer arg3 ;
  RealVector *arg4 = 0 ;
  Integer arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  int val5 ;
  int ecode5 = 0 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_RandomChannels" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_RandomChannels" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_RandomChannels" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "rmf_RandomChannels" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  result = ((heasp::rmf const *)arg1)->RandomChannels(arg2,arg3,(RealVector const &)*arg4,arg5);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_RandomChannels__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Real arg2 ;
  Integer arg3 ;
  RealVector *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_RandomChannels" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_RandomChannels" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_RandomChannels" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  result = ((heasp::rmf const *)arg1)->RandomChannels(arg2,arg3,(RealVector const &)*arg4);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_RandomChannels__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg4 = 0 ;
  Integer arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_RandomChannels" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "rmf_RandomChannels" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_RandomChannels" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg4 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "rmf_RandomChannels" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  result = ((heasp::rmf const *)arg1)->RandomChannels((RealVector const &)*arg2,(IntegerVector const &)*arg3,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg4,arg5);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_RandomChannels__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_RandomChannels" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "rmf_RandomChannels" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_RandomChannels" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg4 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp4);
  result = ((heasp::rmf const *)arg1)->RandomChannels((RealVector const &)*arg2,(IntegerVector const &)*arg3,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg4);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_RandomChannels(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[6] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_RandomChannels", 0, 5, argv))) SWIG_fail;
  --argc;
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_rmf_RandomChannels__SWIG_3(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 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_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_rmf_RandomChannels__SWIG_1(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            {
              int res = SWIG_AsVal_int(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              return _wrap_rmf_RandomChannels__SWIG_2(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 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_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            {
              int res = SWIG_AsVal_int(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              return _wrap_rmf_RandomChannels__SWIG_0(self, argc, argv);
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_RandomChannels'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::RandomChannels(Real const,Integer const,RealVector const &,Integer const) const\n"
    "    heasp::rmf::RandomChannels(Real const,Integer const,RealVector const &) const\n"
    "    heasp::rmf::RandomChannels(RealVector const &,IntegerVector const &,std::vector< RealVector,std::allocator< RealVector > > const &,Integer const) const\n"
    "    heasp::rmf::RandomChannels(RealVector const &,IntegerVector const &,std::vector< RealVector,std::allocator< RealVector > > const &) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_disp" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->disp();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_clear" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_clearMatrix(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_clearMatrix" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  (arg1)->clearMatrix();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_check(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_check" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->check();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_normalize(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_normalize" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (arg1)->normalize();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_changeFirstChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_changeFirstChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_changeFirstChannel" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_changeFirstChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  (arg1)->changeFirstChannel(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_compress(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_compress", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_compress" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_compress" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->compress(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_uncompress(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_uncompress" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  (arg1)->uncompress();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_rebinChannels(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  heasp::grouping *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_rebinChannels", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_rebinChannels" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__grouping,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_rebinChannels" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_rebinChannels" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  arg2 = reinterpret_cast< heasp::grouping * >(argp2);
  result = (Integer)(arg1)->rebinChannels(*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_rebinEnergies(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  heasp::grouping *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_rebinEnergies", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_rebinEnergies" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__grouping,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_rebinEnergies" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_rebinEnergies" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  arg2 = reinterpret_cast< heasp::grouping * >(argp2);
  result = (Integer)(arg1)->rebinEnergies(*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_shiftChannels__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Real arg4 ;
  Real arg5 ;
  bool arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  Integer result;
  
  if ((nobjs < 6) || (nobjs > 6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_shiftChannels" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_shiftChannels" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_shiftChannels" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "rmf_shiftChannels" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "rmf_shiftChannels" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "rmf_shiftChannels" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  result = (Integer)(arg1)->shiftChannels(arg2,arg3,arg4,arg5,arg6);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_shiftChannels__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Real arg4 ;
  Real arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  Integer result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_shiftChannels" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_shiftChannels" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_shiftChannels" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "rmf_shiftChannels" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "rmf_shiftChannels" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  result = (Integer)(arg1)->shiftChannels(arg2,arg3,arg4,arg5);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_shiftChannels__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Real arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  Integer result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_shiftChannels" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_shiftChannels" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_shiftChannels" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "rmf_shiftChannels" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  result = (Integer)(arg1)->shiftChannels(arg2,arg3,arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_shiftChannels__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  RealVector *arg5 = 0 ;
  bool arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  std::vector< double,std::allocator< double > > tvec5 ;
  bool val6 ;
  int ecode6 = 0 ;
  Integer result;
  
  if ((nobjs < 6) || (nobjs > 6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_shiftChannels" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<double>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "rmf_shiftChannels" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  result = (Integer)(arg1)->shiftChannels((IntegerVector const &)*arg2,(IntegerVector const &)*arg3,(RealVector const &)*arg4,(RealVector const &)*arg5,arg6);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_shiftChannels__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  RealVector *arg5 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  std::vector< double,std::allocator< double > > tvec5 ;
  Integer result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_shiftChannels" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<double>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  result = (Integer)(arg1)->shiftChannels((IntegerVector const &)*arg2,(IntegerVector const &)*arg3,(RealVector const &)*arg4,(RealVector const &)*arg5);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_shiftChannels(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[7] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_shiftChannels", 0, 6, argv))) SWIG_fail;
  --argc;
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_rmf_shiftChannels__SWIG_2(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              return _wrap_rmf_shiftChannels__SWIG_4(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_rmf_shiftChannels__SWIG_1(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 6) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              {
                int res = SWIG_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                return _wrap_rmf_shiftChannels__SWIG_3(self, argc, argv);
              }
            }
          }
        }
      }
    }
  }
  if (argc == 6) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                return _wrap_rmf_shiftChannels__SWIG_0(self, argc, argv);
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_shiftChannels'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::shiftChannels(Integer const,Integer const,Real const,Real const,bool)\n"
    "    heasp::rmf::shiftChannels(Integer const,Integer const,Real const,Real const)\n"
    "    heasp::rmf::shiftChannels(Integer const,Integer const,Real const)\n"
    "    heasp::rmf::shiftChannels(IntegerVector const &,IntegerVector const &,RealVector const &,RealVector const &,bool)\n"
    "    heasp::rmf::shiftChannels(IntegerVector const &,IntegerVector const &,RealVector const &,RealVector const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_shiftEnergies__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Real arg4 ;
  Real arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  Integer result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_shiftEnergies" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_shiftEnergies" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_shiftEnergies" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "rmf_shiftEnergies" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "rmf_shiftEnergies" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  result = (Integer)(arg1)->shiftEnergies(arg2,arg3,arg4,arg5);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_shiftEnergies__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  RealVector *arg5 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  std::vector< double,std::allocator< double > > tvec5 ;
  Integer result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_shiftEnergies" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<double>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  result = (Integer)(arg1)->shiftEnergies((IntegerVector const &)*arg2,(IntegerVector const &)*arg3,(RealVector const &)*arg4,(RealVector const &)*arg5);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_shiftEnergies(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[6] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_shiftEnergies", 0, 5, argv))) SWIG_fail;
  --argc;
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              return _wrap_rmf_shiftEnergies__SWIG_1(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_rmf_shiftEnergies__SWIG_0(self, argc, argv);
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_shiftEnergies'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::shiftEnergies(Integer const,Integer const,Real const,Real const)\n"
    "    heasp::rmf::shiftEnergies(IntegerVector const &,IntegerVector const &,RealVector const &,RealVector const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_remapEnergies(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_remapEnergies", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_remapEnergies" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->remapEnergies((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_interpolateAndMultiply(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_interpolateAndMultiply", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_interpolateAndMultiply" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = (Integer)(arg1)->interpolateAndMultiply((RealVector const &)*arg2,(RealVector const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_write__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  std::string arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_write" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_write" "', argument " "3"" of type '" "std::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::rmf const *)arg1)->write(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_write__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_write" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::rmf const *)arg1)->write(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_write(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_write", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_rmf_write__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_rmf_write__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_write'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::write(std::string const,std::string const) const\n"
    "    heasp::rmf::write(std::string const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_writeMatrix(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_writeMatrix", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_writeMatrix" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_writeMatrix" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::rmf const *)arg1)->writeMatrix(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_writeChannelBounds(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_writeChannelBounds", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_writeChannelBounds" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_writeChannelBounds" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::rmf const *)arg1)->writeChannelBounds(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf___imul____SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  heasp::arf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  heasp::rmf *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf___imul__" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf___imul__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf___imul__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arf * >(argp2);
  result = (heasp::rmf *) &(arg1)->operator *=((heasp::arf const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf___imul____SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Real *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Real temp2 ;
  double val2 ;
  int ecode2 = 0 ;
  heasp::rmf *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf___imul__" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf___imul__" "', argument " "2"" of type '" "Real""'");
  } 
  temp2 = static_cast< Real >(val2);
  arg2 = &temp2;
  result = (heasp::rmf *) &(arg1)->operator *=((Real const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf___imul__(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf___imul__", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__arf, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_rmf___imul____SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_double(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_rmf___imul____SWIG_1(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf___imul__'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::operator *=(heasp::arf const &)\n"
    "    heasp::rmf::operator *=(Real const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf___iadd__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  heasp::rmf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::rmf *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf___iadd__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf___iadd__" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__rmf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf___iadd__" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf___iadd__" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::rmf * >(argp2);
  result = (heasp::rmf *) &(arg1)->operator +=((heasp::rmf const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_checkCompatibility__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  heasp::rmf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_checkCompatibility" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__rmf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_checkCompatibility" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_checkCompatibility" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::rmf * >(argp2);
  result = (Integer)((heasp::rmf const *)arg1)->checkCompatibility((heasp::rmf const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_checkCompatibility__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  heasp::arf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_checkCompatibility" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_checkCompatibility" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_checkCompatibility" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arf * >(argp2);
  result = (Integer)((heasp::rmf const *)arg1)->checkCompatibility((heasp::arf const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_checkCompatibility(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_checkCompatibility", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_rmf_checkCompatibility__SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__arf, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_rmf_checkCompatibility__SWIG_1(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_checkCompatibility'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::checkCompatibility(heasp::rmf const &) const\n"
    "    heasp::rmf::checkCompatibility(heasp::arf const &) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_convertUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_convertUnits" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)(arg1)->convertUnits();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_reverseRows(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_reverseRows" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  (arg1)->reverseRows();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_addRow__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  Real arg3 ;
  Real arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  double val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_addRow" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_addRow" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "rmf_addRow" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  (arg1)->addRow((RealVector const &)*arg2,arg3,arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_addRow__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg2 = 0 ;
  Real arg3 ;
  Real arg4 ;
  IntegerVector *arg5 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  std::vector< int,std::allocator< int > > tvec5 ;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_addRow" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_addRow" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_addRow" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_addRow" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "rmf_addRow" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<int>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  (arg1)->addRow((std::vector< RealVector,std::allocator< RealVector > > const &)*arg2,arg3,arg4,(IntegerVector const &)*arg5);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_addRow__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  Real arg5 ;
  Real arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  double val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  
  if ((nobjs < 6) || (nobjs > 6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_addRow" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "rmf_addRow" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "rmf_addRow" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  (arg1)->addRow((IntegerVector const &)*arg2,(IntegerVector const &)*arg3,(RealVector const &)*arg4,arg5,arg6);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_addRow(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[7] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_addRow", 0, 6, argv))) SWIG_fail;
  --argc;
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 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_double(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            return _wrap_rmf_addRow__SWIG_0(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 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_double(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              return _wrap_rmf_addRow__SWIG_1(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 6) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            {
              int res = SWIG_AsVal_double(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              {
                int res = SWIG_AsVal_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                return _wrap_rmf_addRow__SWIG_2(self, argc, argv);
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_addRow'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::addRow(RealVector const &,Real const,Real const)\n"
    "    heasp::rmf::addRow(std::vector< RealVector,std::allocator< RealVector > > const &,Real const,Real const,IntegerVector const &)\n"
    "    heasp::rmf::addRow(IntegerVector const &,IntegerVector const &,RealVector const &,Real const,Real const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_substituteRow__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  RealVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_substituteRow" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_substituteRow" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  (arg1)->substituteRow(arg2,(RealVector const &)*arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_substituteRow__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg3 = 0 ;
  IntegerVector *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_substituteRow" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_substituteRow" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmf_substituteRow" "', argument " "3"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_substituteRow" "', argument " "3"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg3 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp3);
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  (arg1)->substituteRow(arg2,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg3,(IntegerVector const &)*arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_substituteRow__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  IntegerVector *arg3 = 0 ;
  IntegerVector *arg4 = 0 ;
  RealVector *arg5 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  std::vector< double,std::allocator< double > > tvec5 ;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_substituteRow" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_substituteRow" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<double>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  (arg1)->substituteRow(arg2,(IntegerVector const &)*arg3,(IntegerVector const &)*arg4,(RealVector const &)*arg5);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_substituteRow(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[6] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "rmf_substituteRow", 0, 5, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_rmf_substituteRow__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_rmf_substituteRow__SWIG_1(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__rmf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              return _wrap_rmf_substituteRow__SWIG_2(self, argc, argv);
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'rmf_substituteRow'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::rmf::substituteRow(Integer const,RealVector const &)\n"
    "    heasp::rmf::substituteRow(Integer const,std::vector< RealVector,std::allocator< RealVector > > const &,IntegerVector const &)\n"
    "    heasp::rmf::substituteRow(Integer const,IntegerVector const &,IntegerVector const &,RealVector const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_rmf_multiplyByModel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_multiplyByModel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_multiplyByModel" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (arg1)->multiplyByModel((RealVector const &)*arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_estimatedFWHM(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_estimatedFWHM" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->estimatedFWHM();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_estimatedFWHMperChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_estimatedFWHMperChannel" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->estimatedFWHMperChannel();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_NumberChannels(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_NumberChannels" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)((heasp::rmf const *)arg1)->NumberChannels();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getNumberChannels(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getNumberChannels" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)((heasp::rmf const *)arg1)->getNumberChannels();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_NumberEnergyBins(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_NumberEnergyBins" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)((heasp::rmf const *)arg1)->NumberEnergyBins();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getNumberEnergyBins(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getNumberEnergyBins" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)((heasp::rmf const *)arg1)->getNumberEnergyBins();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_NumberTotalGroups(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_NumberTotalGroups" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)((heasp::rmf const *)arg1)->NumberTotalGroups();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getNumberTotalGroups(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getNumberTotalGroups" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)((heasp::rmf const *)arg1)->getNumberTotalGroups();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_NumberTotalElements(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_NumberTotalElements" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)((heasp::rmf const *)arg1)->NumberTotalElements();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getNumberTotalElements(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getNumberTotalElements" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)((heasp::rmf const *)arg1)->getNumberTotalElements();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getFirstChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getFirstChannel" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Integer)((heasp::rmf const *)arg1)->getFirstChannel();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setFirstChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setFirstChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setFirstChannel" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setFirstChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  (arg1)->setFirstChannel(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getNumberGroups(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  IntegerVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getNumberGroups" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (IntegerVector *) &((heasp::rmf const *)arg1)->getNumberGroups();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setNumberGroups(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  IntegerVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setNumberGroups", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setNumberGroups" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setNumberGroups((IntegerVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getNumberGroupsForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_getNumberGroupsForEnergyBin", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getNumberGroupsForEnergyBin" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_getNumberGroupsForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::rmf const *)arg1)->getNumberGroupsForEnergyBin(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setNumberGroupsForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setNumberGroupsForEnergyBin", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setNumberGroupsForEnergyBin" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setNumberGroupsForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_setNumberGroupsForEnergyBin" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->setNumberGroupsForEnergyBin(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getFirstChannelGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getFirstChannelGroup" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (std::vector< IntegerVector,std::allocator< IntegerVector > > *) &((heasp::rmf const *)arg1)->getFirstChannelGroup();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setFirstChannelGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setFirstChannelGroup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setFirstChannelGroup" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_setFirstChannelGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setFirstChannelGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp2);
  result = (Integer)(arg1)->setFirstChannelGroup((std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getFirstChannelGroupForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_getFirstChannelGroupForEnergyBin", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getFirstChannelGroupForEnergyBin" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_getFirstChannelGroupForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmf const *)arg1)->getFirstChannelGroupForEnergyBin(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setFirstChannelGroupForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setFirstChannelGroupForEnergyBin", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setFirstChannelGroupForEnergyBin" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setFirstChannelGroupForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t,  0  | 0);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmf_setFirstChannelGroupForEnergyBin" "', argument " "3"" of type '" "IntegerVector const""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setFirstChannelGroupForEnergyBin" "', argument " "3"" of type '" "IntegerVector const""'");
    } else {
      IntegerVector * temp = reinterpret_cast< IntegerVector * >(argp3);
      arg3 = *temp;
      if (SWIG_IsNewObj(res3)) delete temp;
    }
  }
  result = (Integer)(arg1)->setFirstChannelGroupForEnergyBin(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getNumberChannelsGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getNumberChannelsGroup" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (std::vector< IntegerVector,std::allocator< IntegerVector > > *) &((heasp::rmf const *)arg1)->getNumberChannelsGroup();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setNumberChannelsGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setNumberChannelsGroup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setNumberChannelsGroup" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_setNumberChannelsGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setNumberChannelsGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp2);
  result = (Integer)(arg1)->setNumberChannelsGroup((std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getNumberChannelsGroupForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_getNumberChannelsGroupForEnergyBin", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getNumberChannelsGroupForEnergyBin" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_getNumberChannelsGroupForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmf const *)arg1)->getNumberChannelsGroupForEnergyBin(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setNumberChannelsGroupForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setNumberChannelsGroupForEnergyBin", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setNumberChannelsGroupForEnergyBin" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setNumberChannelsGroupForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t,  0  | 0);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmf_setNumberChannelsGroupForEnergyBin" "', argument " "3"" of type '" "IntegerVector const""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setNumberChannelsGroupForEnergyBin" "', argument " "3"" of type '" "IntegerVector const""'");
    } else {
      IntegerVector * temp = reinterpret_cast< IntegerVector * >(argp3);
      arg3 = *temp;
      if (SWIG_IsNewObj(res3)) delete temp;
    }
  }
  result = (Integer)(arg1)->setNumberChannelsGroupForEnergyBin(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getOrderGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getOrderGroup" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (std::vector< IntegerVector,std::allocator< IntegerVector > > *) &((heasp::rmf const *)arg1)->getOrderGroup();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setOrderGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setOrderGroup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setOrderGroup" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_setOrderGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setOrderGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp2);
  result = (Integer)(arg1)->setOrderGroup((std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getOrderGroupForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_getOrderGroupForEnergyBin", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getOrderGroupForEnergyBin" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_getOrderGroupForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmf const *)arg1)->getOrderGroupForEnergyBin(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setOrderGroupForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setOrderGroupForEnergyBin", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setOrderGroupForEnergyBin" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setOrderGroupForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t,  0  | 0);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmf_setOrderGroupForEnergyBin" "', argument " "3"" of type '" "IntegerVector const""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setOrderGroupForEnergyBin" "', argument " "3"" of type '" "IntegerVector const""'");
    } else {
      IntegerVector * temp = reinterpret_cast< IntegerVector * >(argp3);
      arg3 = *temp;
      if (SWIG_IsNewObj(res3)) delete temp;
    }
  }
  result = (Integer)(arg1)->setOrderGroupForEnergyBin(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getLowEnergy" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (RealVector *) &((heasp::rmf const *)arg1)->getLowEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setLowEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setLowEnergy" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setLowEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_getLowEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getLowEnergyElement" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_getLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::rmf const *)arg1)->getLowEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setLowEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setLowEnergyElement" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_setLowEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setLowEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getHighEnergy" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (RealVector *) &((heasp::rmf const *)arg1)->getHighEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setHighEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setHighEnergy" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setHighEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_getHighEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getHighEnergyElement" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_getHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::rmf const *)arg1)->getHighEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setHighEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setHighEnergyElement" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_setHighEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setHighEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getMatrix(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< RealVector,std::allocator< RealVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getMatrix" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (std::vector< RealVector,std::allocator< RealVector > > *) &((heasp::rmf const *)arg1)->getMatrix();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setMatrix(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setMatrix", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setMatrix" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_setMatrix" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setMatrix" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp2);
  result = (Integer)(arg1)->setMatrix((std::vector< RealVector,std::allocator< RealVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getMatrixForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_getMatrixForEnergyBin", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getMatrixForEnergyBin" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_getMatrixForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmf const *)arg1)->getMatrixForEnergyBin(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setMatrixForEnergyBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setMatrixForEnergyBin", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setMatrixForEnergyBin" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setMatrixForEnergyBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t,  0  | 0);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmf_setMatrixForEnergyBin" "', argument " "3"" of type '" "RealVector const""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setMatrixForEnergyBin" "', argument " "3"" of type '" "RealVector const""'");
    } else {
      RealVector * temp = reinterpret_cast< RealVector * >(argp3);
      arg3 = *temp;
      if (SWIG_IsNewObj(res3)) delete temp;
    }
  }
  result = (Integer)(arg1)->setMatrixForEnergyBin(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getChannelLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getChannelLowEnergy" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (RealVector *) &((heasp::rmf const *)arg1)->getChannelLowEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setChannelLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setChannelLowEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setChannelLowEnergy" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setChannelLowEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getChannelLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_getChannelLowEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getChannelLowEnergyElement" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_getChannelLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::rmf const *)arg1)->getChannelLowEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setChannelLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setChannelLowEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setChannelLowEnergyElement" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setChannelLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_setChannelLowEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setChannelLowEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getChannelHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getChannelHighEnergy" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (RealVector *) &((heasp::rmf const *)arg1)->getChannelHighEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setChannelHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setChannelHighEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setChannelHighEnergy" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setChannelHighEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getChannelHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_getChannelHighEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getChannelHighEnergyElement" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_getChannelHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::rmf const *)arg1)->getChannelHighEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setChannelHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setChannelHighEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setChannelHighEnergyElement" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setChannelHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmf_setChannelHighEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setChannelHighEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getAreaScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getAreaScaling" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Real)((heasp::rmf const *)arg1)->getAreaScaling();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setAreaScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setAreaScaling", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setAreaScaling" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setAreaScaling" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setAreaScaling(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getResponseThreshold(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getResponseThreshold" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = (Real)((heasp::rmf const *)arg1)->getResponseThreshold();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setResponseThreshold(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setResponseThreshold", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setResponseThreshold" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmf_setResponseThreshold" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setResponseThreshold(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getEnergyUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getEnergyUnits" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getEnergyUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setEnergyUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setEnergyUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setEnergyUnits" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setEnergyUnits" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setEnergyUnits(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getRMFUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getRMFUnits" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getRMFUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setRMFUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setRMFUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setRMFUnits" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setRMFUnits" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setRMFUnits(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getChannelType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getChannelType" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getChannelType();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setChannelType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setChannelType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setChannelType" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setChannelType" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setChannelType(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getTelescope(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getTelescope" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getTelescope();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setTelescope(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setTelescope", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setTelescope" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setTelescope" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setTelescope(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getInstrument(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getInstrument" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getInstrument();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setInstrument(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setInstrument", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setInstrument" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setInstrument" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setInstrument(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getDetector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getDetector" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getDetector();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setDetector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setDetector", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setDetector" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setDetector" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setDetector(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getFilter" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getFilter();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setFilter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setFilter" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setFilter" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setFilter(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getRMFType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getRMFType" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getRMFType();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setRMFType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setRMFType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setRMFType" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setRMFType" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setRMFType(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getRMFExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getRMFExtensionName" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getRMFExtensionName();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setRMFExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setRMFExtensionName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setRMFExtensionName" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setRMFExtensionName" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setRMFExtensionName(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getEBDExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getEBDExtensionName" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getEBDExtensionName();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setEBDExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setEBDExtensionName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setEBDExtensionName" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmf_setEBDExtensionName" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setEBDExtensionName(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getStokesParameter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getStokesParameter" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getStokesParameter();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setStokesParameter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setStokesParameter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setStokesParameter" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_setStokesParameter" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setStokesParameter" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setStokesParameter((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_getStokesWeighting(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_getStokesWeighting" "', argument " "1"" of type '" "heasp::rmf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  result = ((heasp::rmf const *)arg1)->getStokesWeighting();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmf_setStokesWeighting(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = (heasp::rmf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmf_setStokesWeighting", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmf_setStokesWeighting" "', argument " "1"" of type '" "heasp::rmf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmf_setStokesWeighting" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmf_setStokesWeighting" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setStokesWeighting((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *rmf_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__rmf, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *rmf_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap___mul____SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = 0 ;
  heasp::arf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  heasp::rmf result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__rmf,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "__mul__" "', argument " "1"" of type '" "heasp::rmf const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__mul__" "', argument " "1"" of type '" "heasp::rmf const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "__mul__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__mul__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arf * >(argp2);
  result = heasp::operator *((heasp::rmf const &)*arg1,(heasp::arf const &)*arg2);
  resultobj = SWIG_NewPointerObj((new heasp::rmf(result)), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap___mul____SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = 0 ;
  heasp::rmf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  heasp::rmf result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "__mul__" "', argument " "1"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__mul__" "', argument " "1"" of type '" "heasp::arf const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__rmf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "__mul__" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__mul__" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::rmf * >(argp2);
  result = heasp::operator *((heasp::arf const &)*arg1,(heasp::rmf const &)*arg2);
  resultobj = SWIG_NewPointerObj((new heasp::rmf(result)), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap___mul____SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = 0 ;
  Real *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Real temp2 ;
  double val2 ;
  int ecode2 = 0 ;
  heasp::rmf result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__rmf,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "__mul__" "', argument " "1"" of type '" "heasp::rmf const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__mul__" "', argument " "1"" of type '" "heasp::rmf const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "__mul__" "', argument " "2"" of type '" "Real""'");
  } 
  temp2 = static_cast< Real >(val2);
  arg2 = &temp2;
  result = heasp::operator *((heasp::rmf const &)*arg1,(double const &)*arg2);
  resultobj = SWIG_NewPointerObj((new heasp::rmf(result)), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap___mul____SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  Real *arg1 = 0 ;
  heasp::rmf *arg2 = 0 ;
  Real temp1 ;
  double val1 ;
  int ecode1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  heasp::rmf result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  ecode1 = SWIG_AsVal_double(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "__mul__" "', argument " "1"" of type '" "Real""'");
  } 
  temp1 = static_cast< Real >(val1);
  arg1 = &temp1;
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__rmf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "__mul__" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__mul__" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::rmf * >(argp2);
  result = heasp::operator *((double const &)*arg1,(heasp::rmf const &)*arg2);
  resultobj = SWIG_NewPointerObj((new heasp::rmf(result)), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap___add____SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::rmf *arg1 = 0 ;
  heasp::rmf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  heasp::rmf result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__rmf,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "__add__" "', argument " "1"" of type '" "heasp::rmf const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__add__" "', argument " "1"" of type '" "heasp::rmf const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__rmf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "__add__" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__add__" "', argument " "2"" of type '" "heasp::rmf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::rmf * >(argp2);
  result = heasp::operator +((heasp::rmf const &)*arg1,(heasp::rmf const &)*arg2);
  resultobj = SWIG_NewPointerObj((new heasp::rmf(result)), SWIGTYPE_p_heasp__rmf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap_RMFeboundsExtensions__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  std::string arg2 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "RMFeboundsExtensions" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "RMFeboundsExtensions" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = heasp::RMFeboundsExtensions(SWIG_STD_MOVE(arg1),SWIG_STD_MOVE(arg2));
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_RMFeboundsExtensions__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "RMFeboundsExtensions" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = heasp::RMFeboundsExtensions(SWIG_STD_MOVE(arg1));
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_RMFeboundsExtensions(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "RMFeboundsExtensions", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_RMFeboundsExtensions__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_RMFeboundsExtensions__SWIG_0(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'RMFeboundsExtensions'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::RMFeboundsExtensions(std::string const,std::string const)\n"
    "    heasp::RMFeboundsExtensions(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_RMFmatrixExtensions__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  std::string arg2 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "RMFmatrixExtensions" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "RMFmatrixExtensions" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = heasp::RMFmatrixExtensions(SWIG_STD_MOVE(arg1),SWIG_STD_MOVE(arg2));
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_RMFmatrixExtensions__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "RMFmatrixExtensions" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = heasp::RMFmatrixExtensions(SWIG_STD_MOVE(arg1));
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_RMFmatrixExtensions(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "RMFmatrixExtensions", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_RMFmatrixExtensions__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_RMFmatrixExtensions__SWIG_0(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'RMFmatrixExtensions'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::RMFmatrixExtensions(std::string const,std::string const)\n"
    "    heasp::RMFmatrixExtensions(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_calcGaussResp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  Real arg1 ;
  Real arg2 ;
  Real arg3 ;
  RealVector *arg4 = 0 ;
  RealVector *arg5 = 0 ;
  RealVector *arg6 = 0 ;
  double val1 ;
  int ecode1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  std::vector< double,std::allocator< double > > tvec5 ;
  std::vector< double,std::allocator< double > > tvec6 ;
  PyObject *swig_obj[6] ;
  
  if (!SWIG_Python_UnpackTuple(args, "calcGaussResp", 6, 6, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_double(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "calcGaussResp" "', argument " "1"" of type '" "Real""'");
  } 
  arg1 = static_cast< Real >(val1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "calcGaussResp" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "calcGaussResp" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<double>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  {
    // a Python array is in swig_obj[5]. We need to get its size then resize
    // arg6 and copy the contents from swig_obj[5] into (&arg6)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[5], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec6.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec6[i] = static_cast<double>(in_data[i]);
    }
    arg6 = &tvec6;
    
    
  }
  heasp::calcGaussResp(arg1,arg2,arg3,(std::vector< double,std::allocator< double > > const &)*arg4,(std::vector< double,std::allocator< double > > const &)*arg5,*arg6);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_binarySearch(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  Real arg1 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  double val1 ;
  int ecode1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  PyObject *swig_obj[3] ;
  size_t result;
  
  if (!SWIG_Python_UnpackTuple(args, "binarySearch", 3, 3, swig_obj)) SWIG_fail;
  ecode1 = SWIG_AsVal_double(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "binarySearch" "', argument " "1"" of type '" "Real""'");
  } 
  arg1 = static_cast< Real >(val1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = heasp::binarySearch(arg1,(std::vector< double,std::allocator< double > > const &)*arg2,(std::vector< double,std::allocator< double > > const &)*arg3);
  resultobj = SWIG_From_size_t(static_cast< size_t >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_rmft(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "new_rmft", 0, 0, 0)) SWIG_fail;
  result = (heasp::rmft *)new heasp::rmft();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__rmft, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_rmft(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_rmft" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_load(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  heasp::rmf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_load", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_load" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__rmf,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmft_load" "', argument " "2"" of type '" "heasp::rmf &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmft_load" "', argument " "2"" of type '" "heasp::rmf &""'"); 
  }
  arg2 = reinterpret_cast< heasp::rmf * >(argp2);
  (arg1)->load(*arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_ElementValue(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_ElementValue", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_ElementValue" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_ElementValue" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmft_ElementValue" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Real)((heasp::rmft const *)arg1)->ElementValue(arg2,arg3);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_RowValues(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_RowValues", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_RowValues" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_RowValues" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmft const *)arg1)->RowValues(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_disp" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->disp();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_clear" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_NumberChannels(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_NumberChannels" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Integer)((heasp::rmft const *)arg1)->NumberChannels();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getNumberChannels(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getNumberChannels" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Integer)((heasp::rmft const *)arg1)->getNumberChannels();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_NumberEnergyBins(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_NumberEnergyBins" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Integer)((heasp::rmft const *)arg1)->NumberEnergyBins();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getNumberEnergyBins(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getNumberEnergyBins" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Integer)((heasp::rmft const *)arg1)->getNumberEnergyBins();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_NumberTotalGroups(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_NumberTotalGroups" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Integer)((heasp::rmft const *)arg1)->NumberTotalGroups();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getNumberTotalGroups(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getNumberTotalGroups" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Integer)((heasp::rmft const *)arg1)->getNumberTotalGroups();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_NumberTotalElements(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_NumberTotalElements" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Integer)((heasp::rmft const *)arg1)->NumberTotalElements();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getNumberTotalElements(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getNumberTotalElements" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Integer)((heasp::rmft const *)arg1)->getNumberTotalElements();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getFirstChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getFirstChannel" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Integer)((heasp::rmft const *)arg1)->getFirstChannel();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setFirstChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setFirstChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setFirstChannel" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setFirstChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  (arg1)->setFirstChannel(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getNumberGroups(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  IntegerVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getNumberGroups" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (IntegerVector *) &((heasp::rmft const *)arg1)->getNumberGroups();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setNumberGroups(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  IntegerVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setNumberGroups", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setNumberGroups" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setNumberGroups((IntegerVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getNumberGroupsForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_getNumberGroupsForChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getNumberGroupsForChannel" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_getNumberGroupsForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::rmft const *)arg1)->getNumberGroupsForChannel(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setNumberGroupsForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setNumberGroupsForChannel", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setNumberGroupsForChannel" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setNumberGroupsForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmft_setNumberGroupsForChannel" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->setNumberGroupsForChannel(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getFirstEnergyGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getFirstEnergyGroup" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (std::vector< IntegerVector,std::allocator< IntegerVector > > *) &((heasp::rmft const *)arg1)->getFirstEnergyGroup();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setFirstEnergyGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setFirstEnergyGroup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setFirstEnergyGroup" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmft_setFirstEnergyGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmft_setFirstEnergyGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp2);
  result = (Integer)(arg1)->setFirstEnergyGroup((std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getFirstEnergyGroupForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_getFirstEnergyGroupForChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getFirstEnergyGroupForChannel" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_getFirstEnergyGroupForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmft const *)arg1)->getFirstEnergyGroupForChannel(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setFirstEnergyGroupForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setFirstEnergyGroupForChannel", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setFirstEnergyGroupForChannel" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setFirstEnergyGroupForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t,  0  | 0);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmft_setFirstEnergyGroupForChannel" "', argument " "3"" of type '" "IntegerVector const""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmft_setFirstEnergyGroupForChannel" "', argument " "3"" of type '" "IntegerVector const""'");
    } else {
      IntegerVector * temp = reinterpret_cast< IntegerVector * >(argp3);
      arg3 = *temp;
      if (SWIG_IsNewObj(res3)) delete temp;
    }
  }
  result = (Integer)(arg1)->setFirstEnergyGroupForChannel(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getNumberEnergiesGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getNumberEnergiesGroup" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (std::vector< IntegerVector,std::allocator< IntegerVector > > *) &((heasp::rmft const *)arg1)->getNumberEnergiesGroup();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setNumberEnergiesGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setNumberEnergiesGroup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setNumberEnergiesGroup" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmft_setNumberEnergiesGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmft_setNumberEnergiesGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp2);
  result = (Integer)(arg1)->setNumberEnergiesGroup((std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getNumberEnergiesGroupForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_getNumberEnergiesGroupForChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getNumberEnergiesGroupForChannel" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_getNumberEnergiesGroupForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmft const *)arg1)->getNumberEnergiesGroupForChannel(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setNumberEnergiesGroupForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setNumberEnergiesGroupForChannel", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setNumberEnergiesGroupForChannel" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setNumberEnergiesGroupForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t,  0  | 0);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmft_setNumberEnergiesGroupForChannel" "', argument " "3"" of type '" "IntegerVector const""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmft_setNumberEnergiesGroupForChannel" "', argument " "3"" of type '" "IntegerVector const""'");
    } else {
      IntegerVector * temp = reinterpret_cast< IntegerVector * >(argp3);
      arg3 = *temp;
      if (SWIG_IsNewObj(res3)) delete temp;
    }
  }
  result = (Integer)(arg1)->setNumberEnergiesGroupForChannel(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getOrderGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getOrderGroup" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (std::vector< IntegerVector,std::allocator< IntegerVector > > *) &((heasp::rmft const *)arg1)->getOrderGroup();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setOrderGroup(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::vector< IntegerVector,std::allocator< IntegerVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setOrderGroup", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setOrderGroup" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmft_setOrderGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmft_setOrderGroup" "', argument " "2"" of type '" "std::vector< IntegerVector,std::allocator< IntegerVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< IntegerVector,std::allocator< IntegerVector > > * >(argp2);
  result = (Integer)(arg1)->setOrderGroup((std::vector< IntegerVector,std::allocator< IntegerVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getOrderGroupForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_getOrderGroupForChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getOrderGroupForChannel" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_getOrderGroupForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmft const *)arg1)->getOrderGroupForChannel(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setOrderGroupForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setOrderGroupForChannel", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setOrderGroupForChannel" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setOrderGroupForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t,  0  | 0);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmft_setOrderGroupForChannel" "', argument " "3"" of type '" "IntegerVector const""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmft_setOrderGroupForChannel" "', argument " "3"" of type '" "IntegerVector const""'");
    } else {
      IntegerVector * temp = reinterpret_cast< IntegerVector * >(argp3);
      arg3 = *temp;
      if (SWIG_IsNewObj(res3)) delete temp;
    }
  }
  result = (Integer)(arg1)->setOrderGroupForChannel(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getLowEnergy" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (RealVector *) &((heasp::rmft const *)arg1)->getLowEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setLowEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setLowEnergy" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setLowEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_getLowEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getLowEnergyElement" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_getLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::rmft const *)arg1)->getLowEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setLowEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setLowEnergyElement" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmft_setLowEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setLowEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getHighEnergy" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (RealVector *) &((heasp::rmft const *)arg1)->getHighEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setHighEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setHighEnergy" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setHighEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_getHighEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getHighEnergyElement" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_getHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::rmft const *)arg1)->getHighEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setHighEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setHighEnergyElement" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmft_setHighEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setHighEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getMatrix(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< RealVector,std::allocator< RealVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getMatrix" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (std::vector< RealVector,std::allocator< RealVector > > *) &((heasp::rmft const *)arg1)->getMatrix();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setMatrix(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setMatrix", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setMatrix" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "rmft_setMatrix" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmft_setMatrix" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp2);
  result = (Integer)(arg1)->setMatrix((std::vector< RealVector,std::allocator< RealVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getMatrixForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_getMatrixForChannel", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getMatrixForChannel" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_getMatrixForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::rmft const *)arg1)->getMatrixForChannel(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setMatrixForChannel(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setMatrixForChannel", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setMatrixForChannel" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setMatrixForChannel" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t,  0  | 0);
    if (!SWIG_IsOK(res3)) {
      SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "rmft_setMatrixForChannel" "', argument " "3"" of type '" "RealVector const""'"); 
    }  
    if (!argp3) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "rmft_setMatrixForChannel" "', argument " "3"" of type '" "RealVector const""'");
    } else {
      RealVector * temp = reinterpret_cast< RealVector * >(argp3);
      arg3 = *temp;
      if (SWIG_IsNewObj(res3)) delete temp;
    }
  }
  result = (Integer)(arg1)->setMatrixForChannel(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getChannelLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getChannelLowEnergy" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (RealVector *) &((heasp::rmft const *)arg1)->getChannelLowEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setChannelLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setChannelLowEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setChannelLowEnergy" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setChannelLowEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getChannelLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_getChannelLowEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getChannelLowEnergyElement" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_getChannelLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::rmft const *)arg1)->getChannelLowEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setChannelLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setChannelLowEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setChannelLowEnergyElement" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setChannelLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmft_setChannelLowEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setChannelLowEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getChannelHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getChannelHighEnergy" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (RealVector *) &((heasp::rmft const *)arg1)->getChannelHighEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setChannelHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setChannelHighEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setChannelHighEnergy" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setChannelHighEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getChannelHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_getChannelHighEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getChannelHighEnergyElement" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_getChannelHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::rmft const *)arg1)->getChannelHighEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setChannelHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setChannelHighEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setChannelHighEnergyElement" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setChannelHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "rmft_setChannelHighEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setChannelHighEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getAreaScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getAreaScaling" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Real)((heasp::rmft const *)arg1)->getAreaScaling();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setAreaScaling(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setAreaScaling", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setAreaScaling" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setAreaScaling" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setAreaScaling(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getResponseThreshold(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getResponseThreshold" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = (Real)((heasp::rmft const *)arg1)->getResponseThreshold();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setResponseThreshold(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setResponseThreshold", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setResponseThreshold" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "rmft_setResponseThreshold" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setResponseThreshold(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getEnergyUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getEnergyUnits" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getEnergyUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setEnergyUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setEnergyUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setEnergyUnits" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setEnergyUnits" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setEnergyUnits(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getRMFUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getRMFUnits" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getRMFUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setRMFUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setRMFUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setRMFUnits" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setRMFUnits" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setRMFUnits(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getChannelType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getChannelType" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getChannelType();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setChannelType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setChannelType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setChannelType" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setChannelType" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setChannelType(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getTelescope(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getTelescope" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getTelescope();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setTelescope(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setTelescope", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setTelescope" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setTelescope" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setTelescope(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getInstrument(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getInstrument" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getInstrument();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setInstrument(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setInstrument", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setInstrument" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setInstrument" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setInstrument(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getDetector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getDetector" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getDetector();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setDetector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setDetector", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setDetector" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setDetector" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setDetector(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getFilter" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getFilter();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setFilter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setFilter" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setFilter" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setFilter(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getRMFType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getRMFType" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getRMFType();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setRMFType(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setRMFType", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setRMFType" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setRMFType" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setRMFType(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getRMFExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getRMFExtensionName" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getRMFExtensionName();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setRMFExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setRMFExtensionName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setRMFExtensionName" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setRMFExtensionName" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setRMFExtensionName(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_getEBDExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_getEBDExtensionName" "', argument " "1"" of type '" "heasp::rmft const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  result = ((heasp::rmft const *)arg1)->getEBDExtensionName();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_rmft_setEBDExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::rmft *arg1 = (heasp::rmft *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "rmft_setEBDExtensionName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__rmft, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "rmft_setEBDExtensionName" "', argument " "1"" of type '" "heasp::rmft *""'"); 
  }
  arg1 = reinterpret_cast< heasp::rmft * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "rmft_setEBDExtensionName" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setEBDExtensionName(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *rmft_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__rmft, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *rmft_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_new_arf__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  heasp::arf *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (heasp::arf *)new heasp::arf();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arf__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  heasp::arf *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_arf" "', argument " "1"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_arf" "', argument " "1"" of type '" "heasp::arf const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = (heasp::arf *)new heasp::arf((heasp::arf const &)*arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arf__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  Integer arg3 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  heasp::arf *result = 0 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_arf" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_arf" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_arf" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (heasp::arf *)new heasp::arf(arg1,arg2,arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arf__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  heasp::arf *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_arf" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_arf" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (heasp::arf *)new heasp::arf(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arf__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  heasp::arf *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_arf" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (heasp::arf *)new heasp::arf(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arf, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arf(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_arf", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_arf__SWIG_0(self, argc, argv);
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__arf, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_arf__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_arf__SWIG_4(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_new_arf__SWIG_3(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(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_new_arf__SWIG_2(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_arf'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::arf::arf()\n"
    "    heasp::arf::arf(heasp::arf const &)\n"
    "    heasp::arf::arf(std::string const,Integer const,Integer const)\n"
    "    heasp::arf::arf(std::string const,Integer const)\n"
    "    heasp::arf::arf(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_delete_arf(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_arf" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_read__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  Integer result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_read" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arf_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "arf_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "arf_read" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  result = (Integer)(arg1)->read(arg2,arg3,arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_read__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_read" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arf_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "arf_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->read(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_read__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_read" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arf_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->read(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_read(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "arf_read", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_arf_read__SWIG_2(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_arf_read__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_arf_read__SWIG_0(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'arf_read'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::arf::read(std::string const,Integer const,Integer const)\n"
    "    heasp::arf::read(std::string const,Integer const)\n"
    "    heasp::arf::read(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_arf_copy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  heasp::arf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::arf *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_copy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_copy" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_copy" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_copy" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arf * >(argp2);
  result = (heasp::arf *) &(arg1)->copy((heasp::arf const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arf, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_disp" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->disp();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_clear" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_check(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_check" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->check();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_rebin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  heasp::grouping *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_rebin", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_rebin" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__grouping,  0 );
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_rebin" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_rebin" "', argument " "2"" of type '" "heasp::grouping &""'"); 
  }
  arg2 = reinterpret_cast< heasp::grouping * >(argp2);
  result = (Integer)(arg1)->rebin(*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_write__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string arg2 ;
  std::string arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_write" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arf_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arf_write" "', argument " "3"" of type '" "std::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::arf const *)arg1)->write(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_write__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_write" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arf_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::arf const *)arg1)->write(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_write(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "arf_write", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_arf_write__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arf, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_arf_write__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'arf_write'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::arf::write(std::string const,std::string const) const\n"
    "    heasp::arf::write(std::string const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_arf___imul__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  Real *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Real temp2 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::arf *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf___imul__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf___imul__" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arf___imul__" "', argument " "2"" of type '" "Real""'");
  } 
  temp2 = static_cast< Real >(val2);
  arg2 = &temp2;
  result = (heasp::arf *) &(arg1)->operator *=((Real const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf___iadd__(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  heasp::arf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::arf *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf___iadd__", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf___iadd__" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf___iadd__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf___iadd__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arf * >(argp2);
  result = (heasp::arf *) &(arg1)->operator +=((heasp::arf const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_checkCompatibility(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  heasp::arf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_checkCompatibility", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_checkCompatibility" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_checkCompatibility" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_checkCompatibility" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arf * >(argp2);
  result = (Integer)((heasp::arf const *)arg1)->checkCompatibility((heasp::arf const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_convertUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_convertUnits" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = (Integer)(arg1)->convertUnits();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_NumberEnergyBins(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_NumberEnergyBins" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = (Integer)((heasp::arf const *)arg1)->NumberEnergyBins();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getNumberEnergyBins(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getNumberEnergyBins" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = (Integer)((heasp::arf const *)arg1)->getNumberEnergyBins();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getLowEnergy" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = (RealVector *) &((heasp::arf const *)arg1)->getLowEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setLowEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setLowEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setLowEnergy" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setLowEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_getLowEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getLowEnergyElement" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arf_getLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::arf const *)arg1)->getLowEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setLowEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setLowEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setLowEnergyElement" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arf_setLowEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "arf_setLowEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setLowEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getHighEnergy" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = (RealVector *) &((heasp::arf const *)arg1)->getHighEnergy();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setHighEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setHighEnergy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setHighEnergy" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setHighEnergy((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_getHighEnergyElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getHighEnergyElement" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arf_getHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::arf const *)arg1)->getHighEnergyElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setHighEnergyElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setHighEnergyElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setHighEnergyElement" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arf_setHighEnergyElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "arf_setHighEnergyElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setHighEnergyElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getEffArea(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getEffArea" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = (RealVector *) &((heasp::arf const *)arg1)->getEffArea();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setEffArea(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setEffArea", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setEffArea" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setEffArea((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getEffAreaElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_getEffAreaElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getEffAreaElement" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arf_getEffAreaElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::arf const *)arg1)->getEffAreaElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setEffAreaElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setEffAreaElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setEffAreaElement" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arf_setEffAreaElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "arf_setEffAreaElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setEffAreaElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getEnergyUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getEnergyUnits" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->getEnergyUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setEnergyUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setEnergyUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setEnergyUnits" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_setEnergyUnits" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_setEnergyUnits" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setEnergyUnits((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getEffAreaUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getEffAreaUnits" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->getEffAreaUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setEffAreaUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setEffAreaUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setEffAreaUnits" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_setEffAreaUnits" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_setEffAreaUnits" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setEffAreaUnits((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getTelescope(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getTelescope" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->getTelescope();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setTelescope(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setTelescope", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setTelescope" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_setTelescope" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_setTelescope" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setTelescope((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getInstrument(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getInstrument" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->getInstrument();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setInstrument(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setInstrument", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setInstrument" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_setInstrument" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_setInstrument" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setInstrument((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getDetector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getDetector" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->getDetector();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setDetector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setDetector", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setDetector" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_setDetector" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_setDetector" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setDetector((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getFilter" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->getFilter();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setFilter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setFilter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setFilter" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_setFilter" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_setFilter" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setFilter((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getStokesParameter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getStokesParameter" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->getStokesParameter();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setStokesParameter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setStokesParameter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setStokesParameter" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_setStokesParameter" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_setStokesParameter" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setStokesParameter((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getStokesWeighting(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getStokesWeighting" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->getStokesWeighting();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setStokesWeighting(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setStokesWeighting", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setStokesWeighting" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_setStokesWeighting" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_setStokesWeighting" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setStokesWeighting((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_getExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_getExtensionName" "', argument " "1"" of type '" "heasp::arf const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  result = ((heasp::arf const *)arg1)->getExtensionName();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arf_setExtensionName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = (heasp::arf *) 0 ;
  std::string *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int res2 = SWIG_OLDOBJ ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arf_setExtensionName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arf, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arf_setExtensionName" "', argument " "1"" of type '" "heasp::arf *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    res2 = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arf_setExtensionName" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    if (!ptr) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arf_setExtensionName" "', argument " "2"" of type '" "std::string const &""'"); 
    }
    arg2 = ptr;
  }
  (arg1)->setExtensionName((std::string const &)*arg2);
  resultobj = SWIG_Py_Void();
  if (SWIG_IsNewObj(res2)) delete arg2;
  return resultobj;
fail:
  if (SWIG_IsNewObj(res2)) delete arg2;
  return NULL;
}


SWIGINTERN PyObject *arf_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__arf, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *arf_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap___add____SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = 0 ;
  heasp::arf *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  heasp::arf result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "__add__" "', argument " "1"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__add__" "', argument " "1"" of type '" "heasp::arf const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "__add__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__add__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arf * >(argp2);
  result = heasp::operator +((heasp::arf const &)*arg1,(heasp::arf const &)*arg2);
  resultobj = SWIG_NewPointerObj((new heasp::arf(result)), SWIGTYPE_p_heasp__arf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap___add__(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "__add__", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__pha, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap___add____SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap___add____SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__arf, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__arf, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap___add____SWIG_2(self, argc, argv);
      }
    }
  }
  
fail:
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap___mul____SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arf *arg1 = 0 ;
  Real *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Real temp2 ;
  double val2 ;
  int ecode2 = 0 ;
  heasp::arf result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "__mul__" "', argument " "1"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__mul__" "', argument " "1"" of type '" "heasp::arf const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::arf * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "__mul__" "', argument " "2"" of type '" "Real""'");
  } 
  temp2 = static_cast< Real >(val2);
  arg2 = &temp2;
  result = heasp::operator *((heasp::arf const &)*arg1,(double const &)*arg2);
  resultobj = SWIG_NewPointerObj((new heasp::arf(result)), SWIGTYPE_p_heasp__arf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap___mul____SWIG_5(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  Real *arg1 = 0 ;
  heasp::arf *arg2 = 0 ;
  Real temp1 ;
  double val1 ;
  int ecode1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  heasp::arf result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  ecode1 = SWIG_AsVal_double(swig_obj[0], &val1);
  if (!SWIG_IsOK(ecode1)) {
    SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "__mul__" "', argument " "1"" of type '" "Real""'");
  } 
  temp1 = static_cast< Real >(val1);
  arg1 = &temp1;
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "__mul__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "__mul__" "', argument " "2"" of type '" "heasp::arf const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arf * >(argp2);
  result = heasp::operator *((double const &)*arg1,(heasp::arf const &)*arg2);
  resultobj = SWIG_NewPointerObj((new heasp::arf(result)), SWIGTYPE_p_heasp__arf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  PyErr_Clear();
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap___mul__(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "__mul__", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__arf, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap___mul____SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__arf, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap___mul____SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_double(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap___mul____SWIG_2(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__arf, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_double(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap___mul____SWIG_4(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    {
      int res = SWIG_AsVal_double(argv[0], NULL);
      _v = SWIG_CheckState(res);
    }
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__rmf, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap___mul____SWIG_3(self, argc, argv);
      }
    }
  }
  if (argc == 2) {
    int _v = 0;
    {
      int res = SWIG_AsVal_double(argv[0], NULL);
      _v = SWIG_CheckState(res);
    }
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_heasp__arf, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap___mul____SWIG_5(self, argc, argv);
      }
    }
  }
  
fail:
  Py_INCREF(Py_NotImplemented);
  return Py_NotImplemented;
}


SWIGINTERN PyObject *_wrap_ARFspecrespExtensions__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  std::string arg2 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "ARFspecrespExtensions" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "ARFspecrespExtensions" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = heasp::ARFspecrespExtensions(SWIG_STD_MOVE(arg1),SWIG_STD_MOVE(arg2));
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_ARFspecrespExtensions__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > result;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "ARFspecrespExtensions" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = heasp::ARFspecrespExtensions(SWIG_STD_MOVE(arg1));
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((&result)->size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((&result)->data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_ARFspecrespExtensions(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "ARFspecrespExtensions", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_ARFspecrespExtensions__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_ARFspecrespExtensions__SWIG_0(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'ARFspecrespExtensions'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::ARFspecrespExtensions(std::string const,std::string const)\n"
    "    heasp::ARFspecrespExtensions(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_ARFtype__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "ARFtype" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ARFtype" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)heasp::ARFtype(SWIG_STD_MOVE(arg1),arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_ARFtype__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  Integer *arg3 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "ARFtype" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "ARFtype" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_int,  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "ARFtype" "', argument " "3"" of type '" "Integer &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "ARFtype" "', argument " "3"" of type '" "Integer &""'"); 
  }
  arg3 = reinterpret_cast< Integer * >(argp3);
  result = (Integer)heasp::ARFtype(SWIG_STD_MOVE(arg1),arg2,*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_ARFtype(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "ARFtype", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_ARFtype__SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_int, SWIG_POINTER_NO_NULL);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_ARFtype__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'ARFtype'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::ARFtype(std::string const,Integer const)\n"
    "    heasp::ARFtype(std::string const,Integer const,Integer &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_new_arfII__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  heasp::arfII *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (heasp::arfII *)new heasp::arfII();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arfII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arfII__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  heasp::arfII *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_heasp__arfII,  0  | 0);
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_arfII" "', argument " "1"" of type '" "heasp::arfII const &""'"); 
  }
  if (!argp1) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_arfII" "', argument " "1"" of type '" "heasp::arfII const &""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  result = (heasp::arfII *)new heasp::arfII((heasp::arfII const &)*arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arfII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arfII__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  IntegerVector *arg3 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  heasp::arfII *result = 0 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_arfII" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_arfII" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = (heasp::arfII *)new heasp::arfII(arg1,arg2,(IntegerVector const &)*arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arfII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arfII__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  heasp::arfII *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_arfII" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_arfII" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (heasp::arfII *)new heasp::arfII(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arfII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arfII__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  heasp::arfII *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_arfII" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (heasp::arfII *)new heasp::arfII(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arfII, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_arfII(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_arfII", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_arfII__SWIG_0(self, argc, argv);
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_heasp__arfII, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_arfII__SWIG_1(self, argc, argv);
    }
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_arfII__SWIG_4(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_new_arfII__SWIG_3(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_new_arfII__SWIG_2(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_arfII'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::arfII::arfII()\n"
    "    heasp::arfII::arfII(heasp::arfII const &)\n"
    "    heasp::arfII::arfII(std::string const,Integer const,IntegerVector const &)\n"
    "    heasp::arfII::arfII(std::string const,Integer const)\n"
    "    heasp::arfII::arfII(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_delete_arfII(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_arfII" "', argument " "1"" of type '" "heasp::arfII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_read__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  IntegerVector *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  Integer result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_read" "', argument " "1"" of type '" "heasp::arfII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arfII_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "arfII_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  result = (Integer)(arg1)->read(arg2,arg3,(IntegerVector const &)*arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_read__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_read" "', argument " "1"" of type '" "heasp::arfII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arfII_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "arfII_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->read(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_read__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_read" "', argument " "1"" of type '" "heasp::arfII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arfII_read" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->read(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_read(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "arfII_read", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arfII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_arfII_read__SWIG_2(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arfII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_arfII_read__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arfII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_arfII_read__SWIG_0(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'arfII_read'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::arfII::read(std::string const,Integer const,IntegerVector const &)\n"
    "    heasp::arfII::read(std::string const,Integer const)\n"
    "    heasp::arfII::read(std::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_arfII_copy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  heasp::arfII *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::arfII *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "arfII_copy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_copy" "', argument " "1"" of type '" "heasp::arfII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arfII,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arfII_copy" "', argument " "2"" of type '" "heasp::arfII const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arfII_copy" "', argument " "2"" of type '" "heasp::arfII const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::arfII * >(argp2);
  result = (heasp::arfII *) &(arg1)->copy((heasp::arfII const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__arfII, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_get(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::arf result;
  
  if (!SWIG_Python_UnpackTuple(args, "arfII_get", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_get" "', argument " "1"" of type '" "heasp::arfII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arfII_get" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::arfII const *)arg1)->get(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::arf(result)), SWIGTYPE_p_heasp__arf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_push(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  heasp::arf arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "arfII_push", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_push" "', argument " "1"" of type '" "heasp::arfII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__arf,  0  | 0);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arfII_push" "', argument " "2"" of type '" "heasp::arf""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arfII_push" "', argument " "2"" of type '" "heasp::arf""'");
    } else {
      heasp::arf * temp = reinterpret_cast< heasp::arf * >(argp2);
      arg2 = *temp;
      if (SWIG_IsNewObj(res2)) delete temp;
    }
  }
  (arg1)->push(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_disp" "', argument " "1"" of type '" "heasp::arfII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  result = ((heasp::arfII const *)arg1)->disp();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_clear" "', argument " "1"" of type '" "heasp::arfII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_check(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_check" "', argument " "1"" of type '" "heasp::arfII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  result = ((heasp::arfII const *)arg1)->check();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_write__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  std::string arg2 ;
  std::string arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_write" "', argument " "1"" of type '" "heasp::arfII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arfII_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arfII_write" "', argument " "3"" of type '" "std::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::arfII const *)arg1)->write(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_write__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  std::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_write" "', argument " "1"" of type '" "heasp::arfII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "arfII_write" "', argument " "2"" of type '" "std::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::arfII const *)arg1)->write(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_write(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "arfII_write", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arfII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_arfII_write__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__arfII, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_arfII_write__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'arfII_write'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::arfII::write(std::string const,std::string const) const\n"
    "    heasp::arfII::write(std::string const) const\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_arfII_NumberARFs(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_NumberARFs" "', argument " "1"" of type '" "heasp::arfII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  result = (Integer)((heasp::arfII const *)arg1)->NumberARFs();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_getNumberARFs(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_getNumberARFs" "', argument " "1"" of type '" "heasp::arfII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  result = (Integer)((heasp::arfII const *)arg1)->getNumberARFs();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_getarfs(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< heasp::arf,std::allocator< heasp::arf > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_getarfs" "', argument " "1"" of type '" "heasp::arfII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  result = (std::vector< heasp::arf,std::allocator< heasp::arf > > *) &((heasp::arfII const *)arg1)->getarfs();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_heasp__arf_std__allocatorT_heasp__arf_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_setarfs(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  std::vector< heasp::arf,std::allocator< heasp::arf > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arfII_setarfs", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_setarfs" "', argument " "1"" of type '" "heasp::arfII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_heasp__arf_std__allocatorT_heasp__arf_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "arfII_setarfs" "', argument " "2"" of type '" "std::vector< heasp::arf,std::allocator< heasp::arf > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arfII_setarfs" "', argument " "2"" of type '" "std::vector< heasp::arf,std::allocator< heasp::arf > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< heasp::arf,std::allocator< heasp::arf > > * >(argp2);
  result = (Integer)(arg1)->setarfs((std::vector< heasp::arf,std::allocator< heasp::arf > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_getarfsElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::arf result;
  
  if (!SWIG_Python_UnpackTuple(args, "arfII_getarfsElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_getarfsElement" "', argument " "1"" of type '" "heasp::arfII const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arfII_getarfsElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::arfII const *)arg1)->getarfsElement(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::arf(result)), SWIGTYPE_p_heasp__arf, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_arfII_setarfsElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::arfII *arg1 = (heasp::arfII *) 0 ;
  Integer arg2 ;
  heasp::arf *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "arfII_setarfsElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__arfII, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "arfII_setarfsElement" "', argument " "1"" of type '" "heasp::arfII *""'"); 
  }
  arg1 = reinterpret_cast< heasp::arfII * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "arfII_setarfsElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_heasp__arf,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "arfII_setarfsElement" "', argument " "3"" of type '" "heasp::arf const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "arfII_setarfsElement" "', argument " "3"" of type '" "heasp::arf const &""'"); 
  }
  arg3 = reinterpret_cast< heasp::arf * >(argp3);
  result = (Integer)(arg1)->setarfsElement(arg2,(heasp::arf const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *arfII_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__arfII, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *arfII_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_NumberofARFs__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  int val2 ;
  int ecode2 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "NumberofARFs" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "NumberofARFs" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)heasp::NumberofARFs(SWIG_STD_MOVE(arg1),arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_NumberofARFs__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  Integer arg2 ;
  Integer *arg3 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "NumberofARFs" "', argument " "1"" of type '" "std::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "NumberofARFs" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_int,  0 );
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "NumberofARFs" "', argument " "3"" of type '" "Integer &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "NumberofARFs" "', argument " "3"" of type '" "Integer &""'"); 
  }
  arg3 = reinterpret_cast< Integer * >(argp3);
  result = (Integer)heasp::NumberofARFs(SWIG_STD_MOVE(arg1),arg2,*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_NumberofARFs(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "NumberofARFs", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_NumberofARFs__SWIG_0(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        void *vptr = 0;
        int res = SWIG_ConvertPtr(argv[2], &vptr, SWIGTYPE_p_int, SWIG_POINTER_NO_NULL);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_NumberofARFs__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'NumberofARFs'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::NumberofARFs(std::string const,Integer const)\n"
    "    heasp::NumberofARFs(std::string const,Integer const,Integer &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_new_grouping__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  heasp::grouping *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (heasp::grouping *)new heasp::grouping();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_grouping__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > arg1 ;
  SwigValueWrapper< std::vector< int,std::allocator< int > > > arg2 ;
  void *argp1 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  heasp::grouping *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    res1 = SWIG_ConvertPtr(swig_obj[0], &argp1, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t,  0  | 0);
    if (!SWIG_IsOK(res1)) {
      SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "new_grouping" "', argument " "1"" of type '" "IntegerVector""'"); 
    }  
    if (!argp1) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_grouping" "', argument " "1"" of type '" "IntegerVector""'");
    } else {
      IntegerVector * temp = reinterpret_cast< IntegerVector * >(argp1);
      arg1 = *temp;
      if (SWIG_IsNewObj(res1)) delete temp;
    }
  }
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t,  0  | 0);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "new_grouping" "', argument " "2"" of type '" "IntegerVector""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_grouping" "', argument " "2"" of type '" "IntegerVector""'");
    } else {
      IntegerVector * temp = reinterpret_cast< IntegerVector * >(argp2);
      arg2 = *temp;
      if (SWIG_IsNewObj(res2)) delete temp;
    }
  }
  result = (heasp::grouping *)new heasp::grouping(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__grouping, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_grouping(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[3] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_grouping", 0, 2, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_grouping__SWIG_0(self, argc, argv);
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_new_grouping__SWIG_1(self, argc, argv);
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_grouping'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::grouping::grouping()\n"
    "    heasp::grouping::grouping(IntegerVector,IntegerVector)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_delete_grouping(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_grouping" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_disp" "', argument " "1"" of type '" "heasp::grouping const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  result = ((heasp::grouping const *)arg1)->disp();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_clear" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_read__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  Integer result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_read" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "grouping_read" "', argument " "2"" of type '" "std::string""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "grouping_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "grouping_read" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  result = (Integer)(arg1)->read(arg2,arg3,arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_read__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  std::string arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_read" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "grouping_read" "', argument " "2"" of type '" "std::string""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "grouping_read" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->read(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_read(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[5] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "grouping_read", 0, 4, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__grouping, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_grouping_read__SWIG_1(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__grouping, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_grouping_read__SWIG_0(self, argc, argv);
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'grouping_read'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::grouping::read(std::string,Integer const,Integer const)\n"
    "    heasp::grouping::read(std::string,Integer const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_grouping_load__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_load" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "grouping_load" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "grouping_load" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  (arg1)->load(arg2,arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_load__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  IntegerVector *arg4 = 0 ;
  Integer arg5 ;
  Integer arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  int val5 ;
  int ecode5 = 0 ;
  int val6 ;
  int ecode6 = 0 ;
  Integer result;
  
  if ((nobjs < 6) || (nobjs > 6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_load" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "grouping_load" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_int(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "grouping_load" "', argument " "6"" of type '" "Integer""'");
  } 
  arg6 = static_cast< Integer >(val6);
  result = (Integer)(arg1)->load((IntegerVector const &)*arg2,(IntegerVector const &)*arg3,(IntegerVector const &)*arg4,arg5,arg6);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_load__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  IntegerVector *arg4 = 0 ;
  Integer arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  int val5 ;
  int ecode5 = 0 ;
  Integer result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_load" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "grouping_load" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  result = (Integer)(arg1)->load((IntegerVector const &)*arg2,(IntegerVector const &)*arg3,(IntegerVector const &)*arg4,arg5);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_load(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[7] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "grouping_load", 0, 6, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__grouping, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(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_grouping_load__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__grouping, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            {
              int res = SWIG_AsVal_int(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              return _wrap_grouping_load__SWIG_2(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 6) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__grouping, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            {
              int res = SWIG_AsVal_int(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_grouping_load__SWIG_1(self, argc, argv);
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'grouping_load'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::grouping::load(Integer const,Integer const)\n"
    "    heasp::grouping::load(IntegerVector const &,IntegerVector const &,IntegerVector const &,Integer const,Integer const)\n"
    "    heasp::grouping::load(IntegerVector const &,IntegerVector const &,IntegerVector const &,Integer const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_grouping_loadFromVector(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_loadFromVector", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_loadFromVector" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = (Integer)(arg1)->loadFromVector((IntegerVector const &)*arg2,(IntegerVector const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_loadOptimal__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  RealVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  Integer arg4 ;
  Integer arg5 ;
  Integer arg6 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  int val6 ;
  int ecode6 = 0 ;
  Integer result;
  
  if ((nobjs < 6) || (nobjs > 6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_loadOptimal" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "grouping_loadOptimal" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "grouping_loadOptimal" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_int(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "grouping_loadOptimal" "', argument " "6"" of type '" "Integer""'");
  } 
  arg6 = static_cast< Integer >(val6);
  result = (Integer)(arg1)->loadOptimal((RealVector const &)*arg2,(IntegerVector const &)*arg3,arg4,arg5,arg6);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_loadOptimal__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  RealVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  Integer arg4 ;
  Integer arg5 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  Integer result;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_loadOptimal" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "grouping_loadOptimal" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "grouping_loadOptimal" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  result = (Integer)(arg1)->loadOptimal((RealVector const &)*arg2,(IntegerVector const &)*arg3,arg4,arg5);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_loadOptimal__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  RealVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  Integer arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  int val4 ;
  int ecode4 = 0 ;
  Integer result;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_loadOptimal" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "grouping_loadOptimal" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  result = (Integer)(arg1)->loadOptimal((RealVector const &)*arg2,(IntegerVector const &)*arg3,arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_loadOptimal__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  RealVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_loadOptimal" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = (Integer)(arg1)->loadOptimal((RealVector const &)*arg2,(IntegerVector const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_loadOptimal(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[7] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "grouping_loadOptimal", 0, 6, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__grouping, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_grouping_loadOptimal__SWIG_3(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__grouping, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            return _wrap_grouping_loadOptimal__SWIG_2(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__grouping, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_grouping_loadOptimal__SWIG_1(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 6) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__grouping, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_int_std__allocatorT_int_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_AsVal_int(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                return _wrap_grouping_loadOptimal__SWIG_0(self, argc, argv);
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'grouping_loadOptimal'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::grouping::loadOptimal(RealVector const &,IntegerVector const &,Integer const,Integer const,Integer const)\n"
    "    heasp::grouping::loadOptimal(RealVector const &,IntegerVector const &,Integer const,Integer const)\n"
    "    heasp::grouping::loadOptimal(RealVector const &,IntegerVector const &,Integer const)\n"
    "    heasp::grouping::loadOptimal(RealVector const &,IntegerVector const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_grouping_loadOptimalEnergy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  RealVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_loadOptimalEnergy", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_loadOptimalEnergy" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = (Integer)(arg1)->loadOptimalEnergy((RealVector const &)*arg2,(IntegerVector const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_newBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  bool result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_newBin", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_newBin" "', argument " "1"" of type '" "heasp::grouping const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "grouping_newBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (bool)((heasp::grouping const *)arg1)->newBin(arg2);
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_inBin(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  bool result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_inBin", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_inBin" "', argument " "1"" of type '" "heasp::grouping const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "grouping_inBin" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (bool)((heasp::grouping const *)arg1)->inBin(arg2);
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_size(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_size" "', argument " "1"" of type '" "heasp::grouping const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  result = (Integer)((heasp::grouping const *)arg1)->size();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_getGroupingFlag(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  IntegerVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_getGroupingFlag" "', argument " "1"" of type '" "heasp::grouping const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  result = (IntegerVector *) &((heasp::grouping const *)arg1)->getGroupingFlag();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_setGroupingFlag(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  IntegerVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_setGroupingFlag", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_setGroupingFlag" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setGroupingFlag((IntegerVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_getGroupingFlagElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_getGroupingFlagElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_getGroupingFlagElement" "', argument " "1"" of type '" "heasp::grouping const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "grouping_getGroupingFlagElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::grouping const *)arg1)->getGroupingFlagElement(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_setGroupingFlagElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_setGroupingFlagElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_setGroupingFlagElement" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "grouping_setGroupingFlagElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "grouping_setGroupingFlagElement" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->setGroupingFlagElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_getQualityFlag(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  IntegerVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_getQualityFlag" "', argument " "1"" of type '" "heasp::grouping const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  result = (IntegerVector *) &((heasp::grouping const *)arg1)->getQualityFlag();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_INT);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    int* out_data = (int*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<int>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_setQualityFlag(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  IntegerVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_setQualityFlag", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_setQualityFlag" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setQualityFlag((IntegerVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_getQualityFlagElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_getQualityFlagElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_getQualityFlagElement" "', argument " "1"" of type '" "heasp::grouping const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "grouping_getQualityFlagElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::grouping const *)arg1)->getQualityFlagElement(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_grouping_setQualityFlagElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::grouping *arg1 = (heasp::grouping *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "grouping_setQualityFlagElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__grouping, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "grouping_setQualityFlagElement" "', argument " "1"" of type '" "heasp::grouping *""'"); 
  }
  arg1 = reinterpret_cast< heasp::grouping * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "grouping_setQualityFlagElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "grouping_setQualityFlagElement" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Integer)(arg1)->setQualityFlagElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *grouping_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__grouping, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *grouping_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_ReadBinFactors(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  std::string arg1 ;
  IntegerVector *arg2 = 0 ;
  IntegerVector *arg3 = 0 ;
  IntegerVector *arg4 = 0 ;
  std::vector< int,std::allocator< int > > tvec2 ;
  std::vector< int,std::allocator< int > > tvec3 ;
  std::vector< int,std::allocator< int > > tvec4 ;
  PyObject *swig_obj[4] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "ReadBinFactors", 4, 4, swig_obj)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "ReadBinFactors" "', argument " "1"" of type '" "std::string""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<int>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<int>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_INT,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    int* in_data = (int*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<int>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  result = (Integer)heasp::ReadBinFactors(SWIG_STD_MOVE(arg1),*arg2,*arg3,*arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableParameter__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  heasp::tableParameter *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (heasp::tableParameter *)new heasp::tableParameter();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableParameter, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableParameter__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Real arg4 ;
  Real arg5 ;
  Real arg6 ;
  Real arg7 ;
  Real arg8 ;
  Real arg9 ;
  RealVector *arg10 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  double val7 ;
  int ecode7 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  std::vector< double,std::allocator< double > > tvec10 ;
  heasp::tableParameter *result = 0 ;
  
  if ((nobjs < 10) || (nobjs > 10)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_tableParameter" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_tableParameter" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_tableParameter" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_tableParameter" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_tableParameter" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_tableParameter" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  ecode7 = SWIG_AsVal_double(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "new_tableParameter" "', argument " "7"" of type '" "Real""'");
  } 
  arg7 = static_cast< Real >(val7);
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_tableParameter" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_tableParameter" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  {
    // a Python array is in swig_obj[9]. We need to get its size then resize
    // arg10 and copy the contents from swig_obj[9] into (&arg10)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[9], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec10.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec10[i] = static_cast<double>(in_data[i]);
    }
    arg10 = &tvec10;
    
    
  }
  result = (heasp::tableParameter *)new heasp::tableParameter(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,(RealVector const &)*arg10);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableParameter, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableParameter__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Real arg4 ;
  Real arg5 ;
  Real arg6 ;
  Real arg7 ;
  Real arg8 ;
  Real arg9 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  double val7 ;
  int ecode7 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  heasp::tableParameter *result = 0 ;
  
  if ((nobjs < 9) || (nobjs > 9)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_tableParameter" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_tableParameter" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_tableParameter" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_tableParameter" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_tableParameter" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_tableParameter" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  ecode7 = SWIG_AsVal_double(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "new_tableParameter" "', argument " "7"" of type '" "Real""'");
  } 
  arg7 = static_cast< Real >(val7);
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_tableParameter" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_tableParameter" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  result = (heasp::tableParameter *)new heasp::tableParameter(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableParameter, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableParameter__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  Integer arg2 ;
  Real arg3 ;
  Real arg4 ;
  Real arg5 ;
  Real arg6 ;
  Real arg7 ;
  Real arg8 ;
  RealVector *arg9 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  double val7 ;
  int ecode7 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  std::vector< double,std::allocator< double > > tvec9 ;
  heasp::tableParameter *result = 0 ;
  
  if ((nobjs < 9) || (nobjs > 9)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_tableParameter" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_tableParameter" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_tableParameter" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_tableParameter" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_tableParameter" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_tableParameter" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  ecode7 = SWIG_AsVal_double(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "new_tableParameter" "', argument " "7"" of type '" "Real""'");
  } 
  arg7 = static_cast< Real >(val7);
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_tableParameter" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  {
    // a Python array is in swig_obj[8]. We need to get its size then resize
    // arg9 and copy the contents from swig_obj[8] into (&arg9)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[8], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec9.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec9[i] = static_cast<double>(in_data[i]);
    }
    arg9 = &tvec9;
    
    
  }
  result = (heasp::tableParameter *)new heasp::tableParameter(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,(RealVector const &)*arg9);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableParameter, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableParameter__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  Integer arg2 ;
  Real arg3 ;
  Real arg4 ;
  Real arg5 ;
  Real arg6 ;
  Real arg7 ;
  Real arg8 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  double val7 ;
  int ecode7 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  heasp::tableParameter *result = 0 ;
  
  if ((nobjs < 8) || (nobjs > 8)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_tableParameter" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_tableParameter" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_tableParameter" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_tableParameter" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_tableParameter" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_tableParameter" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  ecode7 = SWIG_AsVal_double(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "new_tableParameter" "', argument " "7"" of type '" "Real""'");
  } 
  arg7 = static_cast< Real >(val7);
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_tableParameter" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  result = (heasp::tableParameter *)new heasp::tableParameter(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableParameter, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableParameter(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[11] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_tableParameter", 0, 10, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_tableParameter__SWIG_0(self, argc, argv);
  }
  if (argc == 8) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(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_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_double(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    return _wrap_new_tableParameter__SWIG_4(self, argc, argv);
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 9) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_int(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_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_double(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    int res = SWIG_ConvertPtr(argv[8], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                    _v = SWIG_CheckState(res);
                    if (_v) {
                      return _wrap_new_tableParameter__SWIG_3(self, argc, argv);
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 9) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_double(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      return _wrap_new_tableParameter__SWIG_2(self, argc, argv);
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 10) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_double(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      int res = SWIG_ConvertPtr(argv[9], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                      _v = SWIG_CheckState(res);
                      if (_v) {
                        return _wrap_new_tableParameter__SWIG_1(self, argc, argv);
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_tableParameter'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::tableParameter::tableParameter()\n"
    "    heasp::tableParameter::tableParameter(heasp::string const,heasp::string const,Integer const,Real const,Real const,Real const,Real const,Real const,Real const,RealVector const &)\n"
    "    heasp::tableParameter::tableParameter(heasp::string const,heasp::string const,Integer const,Real const,Real const,Real const,Real const,Real const,Real const)\n"
    "    heasp::tableParameter::tableParameter(heasp::string const,Integer const,Real const,Real const,Real const,Real const,Real const,Real const,RealVector const &)\n"
    "    heasp::tableParameter::tableParameter(heasp::string const,Integer const,Real const,Real const,Real const,Real const,Real const,Real const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_tableParameter_load__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  heasp::string arg2 ;
  heasp::string arg3 ;
  Integer arg4 ;
  Real arg5 ;
  Real arg6 ;
  Real arg7 ;
  Real arg8 ;
  Real arg9 ;
  Real arg10 ;
  RealVector *arg11 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  double val7 ;
  int ecode7 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  std::vector< double,std::allocator< double > > tvec11 ;
  
  if ((nobjs < 11) || (nobjs > 11)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_load" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "tableParameter_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "tableParameter_load" "', argument " "3"" of type '" "heasp::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "tableParameter_load" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "tableParameter_load" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "tableParameter_load" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  ecode7 = SWIG_AsVal_double(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "tableParameter_load" "', argument " "7"" of type '" "Real""'");
  } 
  arg7 = static_cast< Real >(val7);
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "tableParameter_load" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "tableParameter_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "tableParameter_load" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  {
    // a Python array is in swig_obj[10]. We need to get its size then resize
    // arg11 and copy the contents from swig_obj[10] into (&arg11)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[10], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec11.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec11[i] = static_cast<double>(in_data[i]);
    }
    arg11 = &tvec11;
    
    
  }
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,(RealVector const &)*arg11);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_load__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  heasp::string arg2 ;
  heasp::string arg3 ;
  Integer arg4 ;
  Real arg5 ;
  Real arg6 ;
  Real arg7 ;
  Real arg8 ;
  Real arg9 ;
  Real arg10 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  double val7 ;
  int ecode7 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  
  if ((nobjs < 10) || (nobjs > 10)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_load" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "tableParameter_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "tableParameter_load" "', argument " "3"" of type '" "heasp::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "tableParameter_load" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "tableParameter_load" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "tableParameter_load" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  ecode7 = SWIG_AsVal_double(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "tableParameter_load" "', argument " "7"" of type '" "Real""'");
  } 
  arg7 = static_cast< Real >(val7);
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "tableParameter_load" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "tableParameter_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "tableParameter_load" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_load__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Real arg4 ;
  Real arg5 ;
  Real arg6 ;
  Real arg7 ;
  Real arg8 ;
  Real arg9 ;
  RealVector *arg10 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  double val7 ;
  int ecode7 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  std::vector< double,std::allocator< double > > tvec10 ;
  
  if ((nobjs < 10) || (nobjs > 10)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_load" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "tableParameter_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableParameter_load" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "tableParameter_load" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "tableParameter_load" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "tableParameter_load" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  ecode7 = SWIG_AsVal_double(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "tableParameter_load" "', argument " "7"" of type '" "Real""'");
  } 
  arg7 = static_cast< Real >(val7);
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "tableParameter_load" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "tableParameter_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  {
    // a Python array is in swig_obj[9]. We need to get its size then resize
    // arg10 and copy the contents from swig_obj[9] into (&arg10)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[9], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec10.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec10[i] = static_cast<double>(in_data[i]);
    }
    arg10 = &tvec10;
    
    
  }
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,(RealVector const &)*arg10);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_load__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Real arg4 ;
  Real arg5 ;
  Real arg6 ;
  Real arg7 ;
  Real arg8 ;
  Real arg9 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  double val5 ;
  int ecode5 = 0 ;
  double val6 ;
  int ecode6 = 0 ;
  double val7 ;
  int ecode7 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  
  if ((nobjs < 9) || (nobjs > 9)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_load" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "tableParameter_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableParameter_load" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "tableParameter_load" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  ecode5 = SWIG_AsVal_double(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "tableParameter_load" "', argument " "5"" of type '" "Real""'");
  } 
  arg5 = static_cast< Real >(val5);
  ecode6 = SWIG_AsVal_double(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "tableParameter_load" "', argument " "6"" of type '" "Real""'");
  } 
  arg6 = static_cast< Real >(val6);
  ecode7 = SWIG_AsVal_double(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "tableParameter_load" "', argument " "7"" of type '" "Real""'");
  } 
  arg7 = static_cast< Real >(val7);
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "tableParameter_load" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "tableParameter_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_load(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[12] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "tableParameter_load", 0, 11, argv))) SWIG_fail;
  --argc;
  if (argc == 9) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__tableParameter, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_double(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      return _wrap_tableParameter_load__SWIG_3(self, argc, argv);
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 10) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__tableParameter, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(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_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_double(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      int res = SWIG_ConvertPtr(argv[9], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                      _v = SWIG_CheckState(res);
                      if (_v) {
                        return _wrap_tableParameter_load__SWIG_2(self, argc, argv);
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 10) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__tableParameter, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_double(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        return _wrap_tableParameter_load__SWIG_1(self, argc, argv);
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 11) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__tableParameter, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_double(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_double(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        int res = SWIG_ConvertPtr(argv[10], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          return _wrap_tableParameter_load__SWIG_0(self, argc, argv);
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'tableParameter_load'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::tableParameter::load(heasp::string const,heasp::string const,Integer const,Real const,Real const,Real const,Real const,Real const,Real const,RealVector const &)\n"
    "    heasp::tableParameter::load(heasp::string const,heasp::string const,Integer const,Real const,Real const,Real const,Real const,Real const,Real const)\n"
    "    heasp::tableParameter::load(heasp::string const,Integer const,Real const,Real const,Real const,Real const,Real const,Real const,RealVector const &)\n"
    "    heasp::tableParameter::load(heasp::string const,Integer const,Real const,Real const,Real const,Real const,Real const,Real const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_tableParameter_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_disp" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = ((heasp::tableParameter const *)arg1)->disp();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_clear" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_NumberTabulatedValues(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_NumberTabulatedValues" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (Integer)((heasp::tableParameter const *)arg1)->NumberTabulatedValues();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getNumberTabulatedValues(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getNumberTabulatedValues" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (Integer)((heasp::tableParameter const *)arg1)->getNumberTabulatedValues();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getName" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = ((heasp::tableParameter const *)arg1)->getName();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  heasp::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setName" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "tableParameter_setName" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setName(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getUnits" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = ((heasp::tableParameter const *)arg1)->getUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  heasp::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setUnits" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "tableParameter_setUnits" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setUnits(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getInterpolationMethod(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getInterpolationMethod" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (Integer)((heasp::tableParameter const *)arg1)->getInterpolationMethod();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setInterpolationMethod(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setInterpolationMethod", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setInterpolationMethod" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableParameter_setInterpolationMethod" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  (arg1)->setInterpolationMethod(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getInitialValue(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getInitialValue" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (Real)((heasp::tableParameter const *)arg1)->getInitialValue();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setInitialValue(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setInitialValue", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setInitialValue" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableParameter_setInitialValue" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setInitialValue(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getDelta(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getDelta" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (Real)((heasp::tableParameter const *)arg1)->getDelta();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setDelta(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setDelta", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setDelta" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableParameter_setDelta" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setDelta(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getMinimum(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getMinimum" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (Real)((heasp::tableParameter const *)arg1)->getMinimum();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setMinimum(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setMinimum", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setMinimum" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableParameter_setMinimum" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setMinimum(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getBottom(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getBottom" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (Real)((heasp::tableParameter const *)arg1)->getBottom();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setBottom(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setBottom", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setBottom" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableParameter_setBottom" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setBottom(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getTop(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getTop" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (Real)((heasp::tableParameter const *)arg1)->getTop();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setTop(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setTop", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setTop" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableParameter_setTop" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setTop(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getMaximum(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getMaximum" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (Real)((heasp::tableParameter const *)arg1)->getMaximum();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setMaximum(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setMaximum", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setMaximum" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableParameter_setMaximum" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setMaximum(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getTabulatedValues(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getTabulatedValues" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  result = (RealVector *) &((heasp::tableParameter const *)arg1)->getTabulatedValues();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setTabulatedValues(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setTabulatedValues", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setTabulatedValues" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setTabulatedValues((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_getTabulatedValuesElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_getTabulatedValuesElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_getTabulatedValuesElement" "', argument " "1"" of type '" "heasp::tableParameter const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableParameter_getTabulatedValuesElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::tableParameter const *)arg1)->getTabulatedValuesElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableParameter_setTabulatedValuesElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableParameter_setTabulatedValuesElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableParameter_setTabulatedValuesElement" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableParameter_setTabulatedValuesElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableParameter_setTabulatedValuesElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setTabulatedValuesElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_tableParameter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableParameter *arg1 = (heasp::tableParameter *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableParameter, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_tableParameter" "', argument " "1"" of type '" "heasp::tableParameter *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableParameter * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *tableParameter_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__tableParameter, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *tableParameter_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_new_tableSpectrum__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (heasp::tableSpectrum *)new heasp::tableSpectrum();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableSpectrum, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableSpectrum__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  RealVector *arg1 = 0 ;
  RealVector *arg2 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg5 = 0 ;
  std::vector< double,std::allocator< double > > tvec1 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  void *argp5 = 0 ;
  int res5 = 0 ;
  heasp::tableSpectrum *result = 0 ;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  {
    // a Python array is in swig_obj[0]. We need to get its size then resize
    // arg1 and copy the contents from swig_obj[0] into (&arg1)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[0], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec1.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec1[i] = static_cast<double>(in_data[i]);
    }
    arg1 = &tvec1;
    
    
  }
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_tableSpectrum" "', argument " "3"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_tableSpectrum" "', argument " "3"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg3 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp3);
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  res5 = SWIG_ConvertPtr(swig_obj[4], &argp5, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res5)) {
    SWIG_exception_fail(SWIG_ArgError(res5), "in method '" "new_tableSpectrum" "', argument " "5"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp5) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_tableSpectrum" "', argument " "5"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg5 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp5);
  result = (heasp::tableSpectrum *)new heasp::tableSpectrum((RealVector const &)*arg1,(RealVector const &)*arg2,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg3,(RealVector const &)*arg4,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg5);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableSpectrum, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableSpectrum__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  RealVector *arg1 = 0 ;
  RealVector *arg2 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg3 = 0 ;
  RealVector *arg4 = 0 ;
  std::vector< double,std::allocator< double > > tvec1 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  std::vector< double,std::allocator< double > > tvec4 ;
  heasp::tableSpectrum *result = 0 ;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  {
    // a Python array is in swig_obj[0]. We need to get its size then resize
    // arg1 and copy the contents from swig_obj[0] into (&arg1)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[0], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec1.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec1[i] = static_cast<double>(in_data[i]);
    }
    arg1 = &tvec1;
    
    
  }
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_tableSpectrum" "', argument " "3"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_tableSpectrum" "', argument " "3"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg3 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp3);
  {
    // a Python array is in swig_obj[3]. We need to get its size then resize
    // arg4 and copy the contents from swig_obj[3] into (&arg4)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[3], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec4.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec4[i] = static_cast<double>(in_data[i]);
    }
    arg4 = &tvec4;
    
    
  }
  result = (heasp::tableSpectrum *)new heasp::tableSpectrum((RealVector const &)*arg1,(RealVector const &)*arg2,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg3,(RealVector const &)*arg4);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableSpectrum, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableSpectrum__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  RealVector *arg1 = 0 ;
  RealVector *arg2 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg3 = 0 ;
  std::vector< double,std::allocator< double > > tvec1 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  heasp::tableSpectrum *result = 0 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  {
    // a Python array is in swig_obj[0]. We need to get its size then resize
    // arg1 and copy the contents from swig_obj[0] into (&arg1)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[0], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec1.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec1[i] = static_cast<double>(in_data[i]);
    }
    arg1 = &tvec1;
    
    
  }
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "new_tableSpectrum" "', argument " "3"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_tableSpectrum" "', argument " "3"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg3 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp3);
  result = (heasp::tableSpectrum *)new heasp::tableSpectrum((RealVector const &)*arg1,(RealVector const &)*arg2,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg3);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableSpectrum, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableSpectrum__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  RealVector *arg1 = 0 ;
  RealVector *arg2 = 0 ;
  std::vector< double,std::allocator< double > > tvec1 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  heasp::tableSpectrum *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    // a Python array is in swig_obj[0]. We need to get its size then resize
    // arg1 and copy the contents from swig_obj[0] into (&arg1)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[0], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec1.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec1[i] = static_cast<double>(in_data[i]);
    }
    arg1 = &tvec1;
    
    
  }
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (heasp::tableSpectrum *)new heasp::tableSpectrum((RealVector const &)*arg1,(RealVector const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__tableSpectrum, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_tableSpectrum(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[6] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_tableSpectrum", 0, 5, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_tableSpectrum__SWIG_0(self, argc, argv);
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_new_tableSpectrum__SWIG_4(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_new_tableSpectrum__SWIG_3(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_new_tableSpectrum__SWIG_2(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    int res = SWIG_ConvertPtr(argv[0], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              return _wrap_new_tableSpectrum__SWIG_1(self, argc, argv);
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_tableSpectrum'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::tableSpectrum::tableSpectrum()\n"
    "    heasp::tableSpectrum::tableSpectrum(RealVector const &,RealVector const &,std::vector< RealVector,std::allocator< RealVector > > const &,RealVector const &,std::vector< RealVector,std::allocator< RealVector > > const &)\n"
    "    heasp::tableSpectrum::tableSpectrum(RealVector const &,RealVector const &,std::vector< RealVector,std::allocator< RealVector > > const &,RealVector const &)\n"
    "    heasp::tableSpectrum::tableSpectrum(RealVector const &,RealVector const &,std::vector< RealVector,std::allocator< RealVector > > const &)\n"
    "    heasp::tableSpectrum::tableSpectrum(RealVector const &,RealVector const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_load__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg4 = 0 ;
  RealVector *arg5 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg6 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  std::vector< double,std::allocator< double > > tvec5 ;
  void *argp6 = 0 ;
  int res6 = 0 ;
  
  if ((nobjs < 6) || (nobjs > 6)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_load" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "tableSpectrum_load" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "tableSpectrum_load" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg4 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp4);
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<double>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  res6 = SWIG_ConvertPtr(swig_obj[5], &argp6, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res6)) {
    SWIG_exception_fail(SWIG_ArgError(res6), "in method '" "tableSpectrum_load" "', argument " "6"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp6) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "tableSpectrum_load" "', argument " "6"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg6 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp6);
  (arg1)->load((RealVector const &)*arg2,(RealVector const &)*arg3,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg4,(RealVector const &)*arg5,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg6);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_load__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg4 = 0 ;
  RealVector *arg5 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  std::vector< double,std::allocator< double > > tvec5 ;
  
  if ((nobjs < 5) || (nobjs > 5)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_load" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "tableSpectrum_load" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "tableSpectrum_load" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg4 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp4);
  {
    // a Python array is in swig_obj[4]. We need to get its size then resize
    // arg5 and copy the contents from swig_obj[4] into (&arg5)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[4], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec5.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec5[i] = static_cast<double>(in_data[i]);
    }
    arg5 = &tvec5;
    
    
  }
  (arg1)->load((RealVector const &)*arg2,(RealVector const &)*arg3,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg4,(RealVector const &)*arg5);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_load__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg4 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  void *argp4 = 0 ;
  int res4 = 0 ;
  
  if ((nobjs < 4) || (nobjs > 4)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_load" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  res4 = SWIG_ConvertPtr(swig_obj[3], &argp4, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res4)) {
    SWIG_exception_fail(SWIG_ArgError(res4), "in method '" "tableSpectrum_load" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp4) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "tableSpectrum_load" "', argument " "4"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg4 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp4);
  (arg1)->load((RealVector const &)*arg2,(RealVector const &)*arg3,(std::vector< RealVector,std::allocator< RealVector > > const &)*arg4);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_load__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  RealVector *arg2 = 0 ;
  RealVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_load" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  (arg1)->load((RealVector const &)*arg2,(RealVector const &)*arg3);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_load(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[7] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "tableSpectrum_load", 0, 6, argv))) SWIG_fail;
  --argc;
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__tableSpectrum, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          return _wrap_tableSpectrum_load__SWIG_3(self, argc, argv);
        }
      }
    }
  }
  if (argc == 4) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__tableSpectrum, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            return _wrap_tableSpectrum_load__SWIG_2(self, argc, argv);
          }
        }
      }
    }
  }
  if (argc == 5) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__tableSpectrum, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              return _wrap_tableSpectrum_load__SWIG_1(self, argc, argv);
            }
          }
        }
      }
    }
  }
  if (argc == 6) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__tableSpectrum, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_ConvertPtr(argv[1], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_ConvertPtr(argv[2], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
        _v = SWIG_CheckState(res);
        if (_v) {
          int res = SWIG_ConvertPtr(argv[3], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
          _v = SWIG_CheckState(res);
          if (_v) {
            int res = SWIG_ConvertPtr(argv[4], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
            _v = SWIG_CheckState(res);
            if (_v) {
              int res = SWIG_ConvertPtr(argv[5], 0, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, SWIG_POINTER_NO_NULL | 0);
              _v = SWIG_CheckState(res);
              if (_v) {
                return _wrap_tableSpectrum_load__SWIG_0(self, argc, argv);
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'tableSpectrum_load'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::tableSpectrum::load(RealVector const &,RealVector const &,std::vector< RealVector,std::allocator< RealVector > > const &,RealVector const &,std::vector< RealVector,std::allocator< RealVector > > const &)\n"
    "    heasp::tableSpectrum::load(RealVector const &,RealVector const &,std::vector< RealVector,std::allocator< RealVector > > const &,RealVector const &)\n"
    "    heasp::tableSpectrum::load(RealVector const &,RealVector const &,std::vector< RealVector,std::allocator< RealVector > > const &)\n"
    "    heasp::tableSpectrum::load(RealVector const &,RealVector const &)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_pushaddFlux(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  SwigValueWrapper< std::vector< double,std::allocator< double > > > arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_pushaddFlux", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_pushaddFlux" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  {
    res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t,  0  | 0);
    if (!SWIG_IsOK(res2)) {
      SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "tableSpectrum_pushaddFlux" "', argument " "2"" of type '" "RealVector""'"); 
    }  
    if (!argp2) {
      SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "tableSpectrum_pushaddFlux" "', argument " "2"" of type '" "RealVector""'");
    } else {
      RealVector * temp = reinterpret_cast< RealVector * >(argp2);
      arg2 = *temp;
      if (SWIG_IsNewObj(res2)) delete temp;
    }
  }
  (arg1)->pushaddFlux(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_disp" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = ((heasp::tableSpectrum const *)arg1)->disp();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_clear" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_NumberFluxes(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_NumberFluxes" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->NumberFluxes();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getNumberFluxes(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getNumberFluxes" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->getNumberFluxes();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_NumberFluxErrors(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_NumberFluxErrors" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->NumberFluxErrors();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getNumberFluxErrors(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getNumberFluxErrors" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->getNumberFluxErrors();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_NumberParameterValues(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_NumberParameterValues" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->NumberParameterValues();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getNumberParameterValues(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getNumberParameterValues" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->getNumberParameterValues();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_NumberAdditiveParameters(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_NumberAdditiveParameters" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->NumberAdditiveParameters();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getNumberAdditiveParameters(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getNumberAdditiveParameters" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->getNumberAdditiveParameters();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_NumberAdditiveFluxes(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_NumberAdditiveFluxes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_NumberAdditiveFluxes" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_NumberAdditiveFluxes" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->NumberAdditiveFluxes(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getNumberAdditiveFluxes(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_getNumberAdditiveFluxes", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getNumberAdditiveFluxes" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_getNumberAdditiveFluxes" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->getNumberAdditiveFluxes(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_NumberAdditiveFluxErrors(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_NumberAdditiveFluxErrors", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_NumberAdditiveFluxErrors" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_NumberAdditiveFluxErrors" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->NumberAdditiveFluxErrors(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getNumberAdditiveFluxErrors(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_getNumberAdditiveFluxErrors", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getNumberAdditiveFluxErrors" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_getNumberAdditiveFluxErrors" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Integer)((heasp::tableSpectrum const *)arg1)->getNumberAdditiveFluxErrors(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getFlux(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getFlux" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (RealVector *) &((heasp::tableSpectrum const *)arg1)->getFlux();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setFlux(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setFlux", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setFlux" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setFlux((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getFluxElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_getFluxElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getFluxElement" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_getFluxElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::tableSpectrum const *)arg1)->getFluxElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setFluxElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setFluxElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setFluxElement" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_setFluxElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableSpectrum_setFluxElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setFluxElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getFluxError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getFluxError" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (RealVector *) &((heasp::tableSpectrum const *)arg1)->getFluxError();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setFluxError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setFluxError", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setFluxError" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setFluxError((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getFluxErrorElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_getFluxErrorElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getFluxErrorElement" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_getFluxErrorElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::tableSpectrum const *)arg1)->getFluxErrorElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setFluxErrorElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setFluxErrorElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setFluxErrorElement" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_setFluxErrorElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableSpectrum_setFluxErrorElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setFluxErrorElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getParameterValues(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getParameterValues" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (RealVector *) &((heasp::tableSpectrum const *)arg1)->getParameterValues();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setParameterValues(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setParameterValues", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setParameterValues" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setParameterValues((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getParameterValuesElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_getParameterValuesElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getParameterValuesElement" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_getParameterValuesElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::tableSpectrum const *)arg1)->getParameterValuesElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setParameterValuesElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setParameterValuesElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setParameterValuesElement" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_setParameterValuesElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableSpectrum_setParameterValuesElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setParameterValuesElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getaddFlux(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< RealVector,std::allocator< RealVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getaddFlux" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (std::vector< RealVector,std::allocator< RealVector > > *) &((heasp::tableSpectrum const *)arg1)->getaddFlux();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setaddFlux(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setaddFlux", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setaddFlux" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "tableSpectrum_setaddFlux" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "tableSpectrum_setaddFlux" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp2);
  result = (Integer)(arg1)->setaddFlux((std::vector< RealVector,std::allocator< RealVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getaddFluxElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  RealVector *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_getaddFluxElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getaddFluxElement" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_getaddFluxElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (RealVector *) &((heasp::tableSpectrum const *)arg1)->getaddFluxElement(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setaddFluxElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  RealVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setaddFluxElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setaddFluxElement" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_setaddFluxElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = (Integer)(arg1)->setaddFluxElement(arg2,(RealVector const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getaddFluxElementElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_getaddFluxElementElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getaddFluxElementElement" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_getaddFluxElementElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableSpectrum_getaddFluxElementElement" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Real)((heasp::tableSpectrum const *)arg1)->getaddFluxElementElement(arg2,arg3);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setaddFluxElementElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Real arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setaddFluxElementElement", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setaddFluxElementElement" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_setaddFluxElementElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableSpectrum_setaddFluxElementElement" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "tableSpectrum_setaddFluxElementElement" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  result = (Integer)(arg1)->setaddFluxElementElement(arg2,arg3,arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getaddFluxError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< RealVector,std::allocator< RealVector > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getaddFluxError" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  result = (std::vector< RealVector,std::allocator< RealVector > > *) &((heasp::tableSpectrum const *)arg1)->getaddFluxError();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setaddFluxError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  std::vector< RealVector,std::allocator< RealVector > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setaddFluxError", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setaddFluxError" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "tableSpectrum_setaddFluxError" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "tableSpectrum_setaddFluxError" "', argument " "2"" of type '" "std::vector< RealVector,std::allocator< RealVector > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< RealVector,std::allocator< RealVector > > * >(argp2);
  result = (Integer)(arg1)->setaddFluxError((std::vector< RealVector,std::allocator< RealVector > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getaddFluxErrorElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  RealVector *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_getaddFluxErrorElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getaddFluxErrorElement" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_getaddFluxErrorElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (RealVector *) &((heasp::tableSpectrum const *)arg1)->getaddFluxErrorElement(arg2);
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setaddFluxErrorElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  RealVector *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  std::vector< double,std::allocator< double > > tvec3 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setaddFluxErrorElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setaddFluxErrorElement" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_setaddFluxErrorElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  {
    // a Python array is in swig_obj[2]. We need to get its size then resize
    // arg3 and copy the contents from swig_obj[2] into (&arg3)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[2], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec3.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec3[i] = static_cast<double>(in_data[i]);
    }
    arg3 = &tvec3;
    
    
  }
  result = (Integer)(arg1)->setaddFluxErrorElement(arg2,(RealVector const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_getaddFluxErrorElementElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_getaddFluxErrorElementElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_getaddFluxErrorElementElement" "', argument " "1"" of type '" "heasp::tableSpectrum const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_getaddFluxErrorElementElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableSpectrum_getaddFluxErrorElementElement" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  result = (Real)((heasp::tableSpectrum const *)arg1)->getaddFluxErrorElementElement(arg2,arg3);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_tableSpectrum_setaddFluxErrorElementElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  Integer arg2 ;
  Integer arg3 ;
  Real arg4 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  double val4 ;
  int ecode4 = 0 ;
  PyObject *swig_obj[4] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "tableSpectrum_setaddFluxErrorElementElement", 4, 4, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "tableSpectrum_setaddFluxErrorElementElement" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "tableSpectrum_setaddFluxErrorElementElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "tableSpectrum_setaddFluxErrorElementElement" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_double(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "tableSpectrum_setaddFluxErrorElementElement" "', argument " "4"" of type '" "Real""'");
  } 
  arg4 = static_cast< Real >(val4);
  result = (Integer)(arg1)->setaddFluxErrorElementElement(arg2,arg3,arg4);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_tableSpectrum(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::tableSpectrum *arg1 = (heasp::tableSpectrum *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__tableSpectrum, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_tableSpectrum" "', argument " "1"" of type '" "heasp::tableSpectrum *""'"); 
  }
  arg1 = reinterpret_cast< heasp::tableSpectrum * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *tableSpectrum_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__tableSpectrum, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *tableSpectrum_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

SWIGINTERN PyObject *_wrap_new_table__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **SWIGUNUSEDPARM(swig_obj)) {
  PyObject *resultobj = 0;
  heasp::table *result = 0 ;
  
  if ((nobjs < 0) || (nobjs > 0)) SWIG_fail;
  result = (heasp::table *)new heasp::table();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_table__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  bool arg2 ;
  bool val2 ;
  int ecode2 = 0 ;
  heasp::table *result = 0 ;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode2 = SWIG_AsVal_bool(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "new_table" "', argument " "2"" of type '" "bool""'");
  } 
  arg2 = static_cast< bool >(val2);
  result = (heasp::table *)new heasp::table(arg1,arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_table__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  heasp::table *result = 0 ;
  
  if ((nobjs < 1) || (nobjs > 1)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (heasp::table *)new heasp::table(arg1);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_table__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  bool arg5 ;
  bool arg6 ;
  heasp::string arg7 ;
  Real arg8 ;
  Real arg9 ;
  heasp::string arg10 ;
  RealVector *arg11 = 0 ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *arg12 = 0 ;
  std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *arg13 = 0 ;
  bool arg14 ;
  bool arg15 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  bool val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  std::vector< double,std::allocator< double > > tvec11 ;
  void *argp12 = 0 ;
  int res12 = 0 ;
  void *argp13 = 0 ;
  int res13 = 0 ;
  bool val14 ;
  int ecode14 = 0 ;
  bool val15 ;
  int ecode15 = 0 ;
  heasp::table *result = 0 ;
  
  if ((nobjs < 15) || (nobjs > 15)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_table" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_table" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_bool(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_table" "', argument " "5"" of type '" "bool""'");
  } 
  arg5 = static_cast< bool >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_table" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[6], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "7"" of type '" "heasp::string const""'"); 
    }
    arg7 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_table" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_table" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[9], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "10"" of type '" "heasp::string const""'"); 
    }
    arg10 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[10]. We need to get its size then resize
    // arg11 and copy the contents from swig_obj[10] into (&arg11)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[10], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec11.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec11[i] = static_cast<double>(in_data[i]);
    }
    arg11 = &tvec11;
    
    
  }
  res12 = SWIG_ConvertPtr(swig_obj[11], &argp12, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,  0  | 0);
  if (!SWIG_IsOK(res12)) {
    SWIG_exception_fail(SWIG_ArgError(res12), "in method '" "new_table" "', argument " "12"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  if (!argp12) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_table" "', argument " "12"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  arg12 = reinterpret_cast< std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > * >(argp12);
  res13 = SWIG_ConvertPtr(swig_obj[12], &argp13, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t,  0  | 0);
  if (!SWIG_IsOK(res13)) {
    SWIG_exception_fail(SWIG_ArgError(res13), "in method '" "new_table" "', argument " "13"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  if (!argp13) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_table" "', argument " "13"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  arg13 = reinterpret_cast< std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > * >(argp13);
  ecode14 = SWIG_AsVal_bool(swig_obj[13], &val14);
  if (!SWIG_IsOK(ecode14)) {
    SWIG_exception_fail(SWIG_ArgError(ecode14), "in method '" "new_table" "', argument " "14"" of type '" "bool""'");
  } 
  arg14 = static_cast< bool >(val14);
  ecode15 = SWIG_AsVal_bool(swig_obj[14], &val15);
  if (!SWIG_IsOK(ecode15)) {
    SWIG_exception_fail(SWIG_ArgError(ecode15), "in method '" "new_table" "', argument " "15"" of type '" "bool""'");
  } 
  arg15 = static_cast< bool >(val15);
  result = (heasp::table *)new heasp::table(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,(RealVector const &)*arg11,(std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)*arg12,(std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &)*arg13,arg14,arg15);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_table__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  bool arg5 ;
  bool arg6 ;
  heasp::string arg7 ;
  Real arg8 ;
  Real arg9 ;
  heasp::string arg10 ;
  RealVector *arg11 = 0 ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *arg12 = 0 ;
  std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *arg13 = 0 ;
  bool arg14 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  bool val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  std::vector< double,std::allocator< double > > tvec11 ;
  void *argp12 = 0 ;
  int res12 = 0 ;
  void *argp13 = 0 ;
  int res13 = 0 ;
  bool val14 ;
  int ecode14 = 0 ;
  heasp::table *result = 0 ;
  
  if ((nobjs < 14) || (nobjs > 14)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_table" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_table" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_bool(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_table" "', argument " "5"" of type '" "bool""'");
  } 
  arg5 = static_cast< bool >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_table" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[6], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "7"" of type '" "heasp::string const""'"); 
    }
    arg7 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_table" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_table" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[9], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "10"" of type '" "heasp::string const""'"); 
    }
    arg10 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[10]. We need to get its size then resize
    // arg11 and copy the contents from swig_obj[10] into (&arg11)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[10], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec11.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec11[i] = static_cast<double>(in_data[i]);
    }
    arg11 = &tvec11;
    
    
  }
  res12 = SWIG_ConvertPtr(swig_obj[11], &argp12, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,  0  | 0);
  if (!SWIG_IsOK(res12)) {
    SWIG_exception_fail(SWIG_ArgError(res12), "in method '" "new_table" "', argument " "12"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  if (!argp12) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_table" "', argument " "12"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  arg12 = reinterpret_cast< std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > * >(argp12);
  res13 = SWIG_ConvertPtr(swig_obj[12], &argp13, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t,  0  | 0);
  if (!SWIG_IsOK(res13)) {
    SWIG_exception_fail(SWIG_ArgError(res13), "in method '" "new_table" "', argument " "13"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  if (!argp13) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_table" "', argument " "13"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  arg13 = reinterpret_cast< std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > * >(argp13);
  ecode14 = SWIG_AsVal_bool(swig_obj[13], &val14);
  if (!SWIG_IsOK(ecode14)) {
    SWIG_exception_fail(SWIG_ArgError(ecode14), "in method '" "new_table" "', argument " "14"" of type '" "bool""'");
  } 
  arg14 = static_cast< bool >(val14);
  result = (heasp::table *)new heasp::table(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,(RealVector const &)*arg11,(std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)*arg12,(std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &)*arg13,arg14);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_table__SWIG_5(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  bool arg5 ;
  bool arg6 ;
  heasp::string arg7 ;
  Real arg8 ;
  Real arg9 ;
  heasp::string arg10 ;
  RealVector *arg11 = 0 ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *arg12 = 0 ;
  std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *arg13 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  bool val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  std::vector< double,std::allocator< double > > tvec11 ;
  void *argp12 = 0 ;
  int res12 = 0 ;
  void *argp13 = 0 ;
  int res13 = 0 ;
  heasp::table *result = 0 ;
  
  if ((nobjs < 13) || (nobjs > 13)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_table" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_table" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_bool(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_table" "', argument " "5"" of type '" "bool""'");
  } 
  arg5 = static_cast< bool >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_table" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[6], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "7"" of type '" "heasp::string const""'"); 
    }
    arg7 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_table" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_table" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[9], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "10"" of type '" "heasp::string const""'"); 
    }
    arg10 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[10]. We need to get its size then resize
    // arg11 and copy the contents from swig_obj[10] into (&arg11)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[10], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec11.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec11[i] = static_cast<double>(in_data[i]);
    }
    arg11 = &tvec11;
    
    
  }
  res12 = SWIG_ConvertPtr(swig_obj[11], &argp12, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,  0  | 0);
  if (!SWIG_IsOK(res12)) {
    SWIG_exception_fail(SWIG_ArgError(res12), "in method '" "new_table" "', argument " "12"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  if (!argp12) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_table" "', argument " "12"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  arg12 = reinterpret_cast< std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > * >(argp12);
  res13 = SWIG_ConvertPtr(swig_obj[12], &argp13, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t,  0  | 0);
  if (!SWIG_IsOK(res13)) {
    SWIG_exception_fail(SWIG_ArgError(res13), "in method '" "new_table" "', argument " "13"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  if (!argp13) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_table" "', argument " "13"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  arg13 = reinterpret_cast< std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > * >(argp13);
  result = (heasp::table *)new heasp::table(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,(RealVector const &)*arg11,(std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)*arg12,(std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &)*arg13);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_table__SWIG_6(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  bool arg5 ;
  bool arg6 ;
  heasp::string arg7 ;
  Real arg8 ;
  Real arg9 ;
  heasp::string arg10 ;
  RealVector *arg11 = 0 ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *arg12 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  bool val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  std::vector< double,std::allocator< double > > tvec11 ;
  void *argp12 = 0 ;
  int res12 = 0 ;
  heasp::table *result = 0 ;
  
  if ((nobjs < 12) || (nobjs > 12)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_table" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_table" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_bool(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_table" "', argument " "5"" of type '" "bool""'");
  } 
  arg5 = static_cast< bool >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_table" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[6], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "7"" of type '" "heasp::string const""'"); 
    }
    arg7 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_table" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_table" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[9], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "10"" of type '" "heasp::string const""'"); 
    }
    arg10 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[10]. We need to get its size then resize
    // arg11 and copy the contents from swig_obj[10] into (&arg11)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[10], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec11.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec11[i] = static_cast<double>(in_data[i]);
    }
    arg11 = &tvec11;
    
    
  }
  res12 = SWIG_ConvertPtr(swig_obj[11], &argp12, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,  0  | 0);
  if (!SWIG_IsOK(res12)) {
    SWIG_exception_fail(SWIG_ArgError(res12), "in method '" "new_table" "', argument " "12"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  if (!argp12) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "new_table" "', argument " "12"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  arg12 = reinterpret_cast< std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > * >(argp12);
  result = (heasp::table *)new heasp::table(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,(RealVector const &)*arg11,(std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)*arg12);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_table__SWIG_7(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  bool arg5 ;
  bool arg6 ;
  heasp::string arg7 ;
  Real arg8 ;
  Real arg9 ;
  heasp::string arg10 ;
  RealVector *arg11 = 0 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  bool val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  std::vector< double,std::allocator< double > > tvec11 ;
  heasp::table *result = 0 ;
  
  if ((nobjs < 11) || (nobjs > 11)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_table" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_table" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_bool(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_table" "', argument " "5"" of type '" "bool""'");
  } 
  arg5 = static_cast< bool >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_table" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[6], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "7"" of type '" "heasp::string const""'"); 
    }
    arg7 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_table" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_table" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[9], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "10"" of type '" "heasp::string const""'"); 
    }
    arg10 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[10]. We need to get its size then resize
    // arg11 and copy the contents from swig_obj[10] into (&arg11)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[10], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec11.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec11[i] = static_cast<double>(in_data[i]);
    }
    arg11 = &tvec11;
    
    
  }
  result = (heasp::table *)new heasp::table(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,(RealVector const &)*arg11);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_table__SWIG_8(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::string arg1 ;
  heasp::string arg2 ;
  Integer arg3 ;
  Integer arg4 ;
  bool arg5 ;
  bool arg6 ;
  heasp::string arg7 ;
  Real arg8 ;
  Real arg9 ;
  heasp::string arg10 ;
  int val3 ;
  int ecode3 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  bool val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  double val8 ;
  int ecode8 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  heasp::table *result = 0 ;
  
  if ((nobjs < 10) || (nobjs > 10)) SWIG_fail;
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[0], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "1"" of type '" "heasp::string const""'"); 
    }
    arg1 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_int(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "new_table" "', argument " "3"" of type '" "Integer""'");
  } 
  arg3 = static_cast< Integer >(val3);
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "new_table" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_bool(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "new_table" "', argument " "5"" of type '" "bool""'");
  } 
  arg5 = static_cast< bool >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "new_table" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[6], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "7"" of type '" "heasp::string const""'"); 
    }
    arg7 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode8 = SWIG_AsVal_double(swig_obj[7], &val8);
  if (!SWIG_IsOK(ecode8)) {
    SWIG_exception_fail(SWIG_ArgError(ecode8), "in method '" "new_table" "', argument " "8"" of type '" "Real""'");
  } 
  arg8 = static_cast< Real >(val8);
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "new_table" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[9], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "new_table" "', argument " "10"" of type '" "heasp::string const""'"); 
    }
    arg10 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (heasp::table *)new heasp::table(arg1,arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, SWIG_POINTER_NEW |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_new_table(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[16] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "new_table", 0, 15, argv))) SWIG_fail;
  --argc;
  if (argc == 0) {
    return _wrap_new_table__SWIG_0(self, argc, argv);
  }
  if (argc == 1) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      return _wrap_new_table__SWIG_2(self, argc, argv);
    }
  }
  if (argc == 2) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      {
        int res = SWIG_AsVal_bool(argv[1], NULL);
        _v = SWIG_CheckState(res);
      }
      if (_v) {
        return _wrap_new_table__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 10) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          {
            int res = SWIG_AsVal_int(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            {
              int res = SWIG_AsVal_bool(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              {
                int res = SWIG_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                int res = SWIG_AsPtr_std_string(argv[6], (std::string**)(0));
                _v = SWIG_CheckState(res);
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      int res = SWIG_AsPtr_std_string(argv[9], (std::string**)(0));
                      _v = SWIG_CheckState(res);
                      if (_v) {
                        return _wrap_new_table__SWIG_8(self, argc, argv);
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 11) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          {
            int res = SWIG_AsVal_int(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            {
              int res = SWIG_AsVal_bool(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              {
                int res = SWIG_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                int res = SWIG_AsPtr_std_string(argv[6], (std::string**)(0));
                _v = SWIG_CheckState(res);
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      int res = SWIG_AsPtr_std_string(argv[9], (std::string**)(0));
                      _v = SWIG_CheckState(res);
                      if (_v) {
                        int res = SWIG_ConvertPtr(argv[10], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          return _wrap_new_table__SWIG_7(self, argc, argv);
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 12) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          {
            int res = SWIG_AsVal_int(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            {
              int res = SWIG_AsVal_bool(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              {
                int res = SWIG_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                int res = SWIG_AsPtr_std_string(argv[6], (std::string**)(0));
                _v = SWIG_CheckState(res);
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      int res = SWIG_AsPtr_std_string(argv[9], (std::string**)(0));
                      _v = SWIG_CheckState(res);
                      if (_v) {
                        int res = SWIG_ConvertPtr(argv[10], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          int res = SWIG_ConvertPtr(argv[11], 0, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, SWIG_POINTER_NO_NULL | 0);
                          _v = SWIG_CheckState(res);
                          if (_v) {
                            return _wrap_new_table__SWIG_6(self, argc, argv);
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 13) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          {
            int res = SWIG_AsVal_int(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            {
              int res = SWIG_AsVal_bool(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              {
                int res = SWIG_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                int res = SWIG_AsPtr_std_string(argv[6], (std::string**)(0));
                _v = SWIG_CheckState(res);
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      int res = SWIG_AsPtr_std_string(argv[9], (std::string**)(0));
                      _v = SWIG_CheckState(res);
                      if (_v) {
                        int res = SWIG_ConvertPtr(argv[10], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          int res = SWIG_ConvertPtr(argv[11], 0, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, SWIG_POINTER_NO_NULL | 0);
                          _v = SWIG_CheckState(res);
                          if (_v) {
                            int res = SWIG_ConvertPtr(argv[12], 0, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t, SWIG_POINTER_NO_NULL | 0);
                            _v = SWIG_CheckState(res);
                            if (_v) {
                              return _wrap_new_table__SWIG_5(self, argc, argv);
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 14) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          {
            int res = SWIG_AsVal_int(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            {
              int res = SWIG_AsVal_bool(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              {
                int res = SWIG_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                int res = SWIG_AsPtr_std_string(argv[6], (std::string**)(0));
                _v = SWIG_CheckState(res);
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      int res = SWIG_AsPtr_std_string(argv[9], (std::string**)(0));
                      _v = SWIG_CheckState(res);
                      if (_v) {
                        int res = SWIG_ConvertPtr(argv[10], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          int res = SWIG_ConvertPtr(argv[11], 0, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, SWIG_POINTER_NO_NULL | 0);
                          _v = SWIG_CheckState(res);
                          if (_v) {
                            int res = SWIG_ConvertPtr(argv[12], 0, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t, SWIG_POINTER_NO_NULL | 0);
                            _v = SWIG_CheckState(res);
                            if (_v) {
                              {
                                int res = SWIG_AsVal_bool(argv[13], NULL);
                                _v = SWIG_CheckState(res);
                              }
                              if (_v) {
                                return _wrap_new_table__SWIG_4(self, argc, argv);
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 15) {
    int _v = 0;
    int res = SWIG_AsPtr_std_string(argv[0], (std::string**)(0));
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_int(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          {
            int res = SWIG_AsVal_int(argv[3], NULL);
            _v = SWIG_CheckState(res);
          }
          if (_v) {
            {
              int res = SWIG_AsVal_bool(argv[4], NULL);
              _v = SWIG_CheckState(res);
            }
            if (_v) {
              {
                int res = SWIG_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                int res = SWIG_AsPtr_std_string(argv[6], (std::string**)(0));
                _v = SWIG_CheckState(res);
                if (_v) {
                  {
                    int res = SWIG_AsVal_double(argv[7], NULL);
                    _v = SWIG_CheckState(res);
                  }
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      int res = SWIG_AsPtr_std_string(argv[9], (std::string**)(0));
                      _v = SWIG_CheckState(res);
                      if (_v) {
                        int res = SWIG_ConvertPtr(argv[10], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          int res = SWIG_ConvertPtr(argv[11], 0, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, SWIG_POINTER_NO_NULL | 0);
                          _v = SWIG_CheckState(res);
                          if (_v) {
                            int res = SWIG_ConvertPtr(argv[12], 0, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t, SWIG_POINTER_NO_NULL | 0);
                            _v = SWIG_CheckState(res);
                            if (_v) {
                              {
                                int res = SWIG_AsVal_bool(argv[13], NULL);
                                _v = SWIG_CheckState(res);
                              }
                              if (_v) {
                                {
                                  int res = SWIG_AsVal_bool(argv[14], NULL);
                                  _v = SWIG_CheckState(res);
                                }
                                if (_v) {
                                  return _wrap_new_table__SWIG_3(self, argc, argv);
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'new_table'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::table::table()\n"
    "    heasp::table::table(heasp::string const,bool)\n"
    "    heasp::table::table(heasp::string const)\n"
    "    heasp::table::table(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &,std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &,std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &,bool const,bool const)\n"
    "    heasp::table::table(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &,std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &,std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &,bool const)\n"
    "    heasp::table::table(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &,std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &,std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &)\n"
    "    heasp::table::table(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &,std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)\n"
    "    heasp::table::table(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &)\n"
    "    heasp::table::table(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_table_load__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  heasp::string arg3 ;
  Integer arg4 ;
  Integer arg5 ;
  bool arg6 ;
  bool arg7 ;
  heasp::string arg8 ;
  Real arg9 ;
  Real arg10 ;
  heasp::string arg11 ;
  RealVector *arg12 = 0 ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *arg13 = 0 ;
  std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *arg14 = 0 ;
  bool arg15 ;
  bool arg16 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  bool val7 ;
  int ecode7 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  std::vector< double,std::allocator< double > > tvec12 ;
  void *argp13 = 0 ;
  int res13 = 0 ;
  void *argp14 = 0 ;
  int res14 = 0 ;
  bool val15 ;
  int ecode15 = 0 ;
  bool val16 ;
  int ecode16 = 0 ;
  
  if ((nobjs < 16) || (nobjs > 16)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_load" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "3"" of type '" "heasp::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "table_load" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "table_load" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "table_load" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  ecode7 = SWIG_AsVal_bool(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "table_load" "', argument " "7"" of type '" "bool""'");
  } 
  arg7 = static_cast< bool >(val7);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[7], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "8"" of type '" "heasp::string const""'"); 
    }
    arg8 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "table_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "table_load" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[10], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "11"" of type '" "heasp::string const""'"); 
    }
    arg11 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[11]. We need to get its size then resize
    // arg12 and copy the contents from swig_obj[11] into (&arg12)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[11], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec12.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec12[i] = static_cast<double>(in_data[i]);
    }
    arg12 = &tvec12;
    
    
  }
  res13 = SWIG_ConvertPtr(swig_obj[12], &argp13, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,  0  | 0);
  if (!SWIG_IsOK(res13)) {
    SWIG_exception_fail(SWIG_ArgError(res13), "in method '" "table_load" "', argument " "13"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  if (!argp13) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_load" "', argument " "13"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  arg13 = reinterpret_cast< std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > * >(argp13);
  res14 = SWIG_ConvertPtr(swig_obj[13], &argp14, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t,  0  | 0);
  if (!SWIG_IsOK(res14)) {
    SWIG_exception_fail(SWIG_ArgError(res14), "in method '" "table_load" "', argument " "14"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  if (!argp14) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_load" "', argument " "14"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  arg14 = reinterpret_cast< std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > * >(argp14);
  ecode15 = SWIG_AsVal_bool(swig_obj[14], &val15);
  if (!SWIG_IsOK(ecode15)) {
    SWIG_exception_fail(SWIG_ArgError(ecode15), "in method '" "table_load" "', argument " "15"" of type '" "bool""'");
  } 
  arg15 = static_cast< bool >(val15);
  ecode16 = SWIG_AsVal_bool(swig_obj[15], &val16);
  if (!SWIG_IsOK(ecode16)) {
    SWIG_exception_fail(SWIG_ArgError(ecode16), "in method '" "table_load" "', argument " "16"" of type '" "bool""'");
  } 
  arg16 = static_cast< bool >(val16);
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,(RealVector const &)*arg12,(std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)*arg13,(std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &)*arg14,arg15,arg16);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_load__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  heasp::string arg3 ;
  Integer arg4 ;
  Integer arg5 ;
  bool arg6 ;
  bool arg7 ;
  heasp::string arg8 ;
  Real arg9 ;
  Real arg10 ;
  heasp::string arg11 ;
  RealVector *arg12 = 0 ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *arg13 = 0 ;
  std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *arg14 = 0 ;
  bool arg15 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  bool val7 ;
  int ecode7 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  std::vector< double,std::allocator< double > > tvec12 ;
  void *argp13 = 0 ;
  int res13 = 0 ;
  void *argp14 = 0 ;
  int res14 = 0 ;
  bool val15 ;
  int ecode15 = 0 ;
  
  if ((nobjs < 15) || (nobjs > 15)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_load" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "3"" of type '" "heasp::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "table_load" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "table_load" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "table_load" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  ecode7 = SWIG_AsVal_bool(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "table_load" "', argument " "7"" of type '" "bool""'");
  } 
  arg7 = static_cast< bool >(val7);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[7], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "8"" of type '" "heasp::string const""'"); 
    }
    arg8 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "table_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "table_load" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[10], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "11"" of type '" "heasp::string const""'"); 
    }
    arg11 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[11]. We need to get its size then resize
    // arg12 and copy the contents from swig_obj[11] into (&arg12)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[11], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec12.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec12[i] = static_cast<double>(in_data[i]);
    }
    arg12 = &tvec12;
    
    
  }
  res13 = SWIG_ConvertPtr(swig_obj[12], &argp13, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,  0  | 0);
  if (!SWIG_IsOK(res13)) {
    SWIG_exception_fail(SWIG_ArgError(res13), "in method '" "table_load" "', argument " "13"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  if (!argp13) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_load" "', argument " "13"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  arg13 = reinterpret_cast< std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > * >(argp13);
  res14 = SWIG_ConvertPtr(swig_obj[13], &argp14, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t,  0  | 0);
  if (!SWIG_IsOK(res14)) {
    SWIG_exception_fail(SWIG_ArgError(res14), "in method '" "table_load" "', argument " "14"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  if (!argp14) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_load" "', argument " "14"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  arg14 = reinterpret_cast< std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > * >(argp14);
  ecode15 = SWIG_AsVal_bool(swig_obj[14], &val15);
  if (!SWIG_IsOK(ecode15)) {
    SWIG_exception_fail(SWIG_ArgError(ecode15), "in method '" "table_load" "', argument " "15"" of type '" "bool""'");
  } 
  arg15 = static_cast< bool >(val15);
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,(RealVector const &)*arg12,(std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)*arg13,(std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &)*arg14,arg15);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_load__SWIG_2(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  heasp::string arg3 ;
  Integer arg4 ;
  Integer arg5 ;
  bool arg6 ;
  bool arg7 ;
  heasp::string arg8 ;
  Real arg9 ;
  Real arg10 ;
  heasp::string arg11 ;
  RealVector *arg12 = 0 ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *arg13 = 0 ;
  std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *arg14 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  bool val7 ;
  int ecode7 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  std::vector< double,std::allocator< double > > tvec12 ;
  void *argp13 = 0 ;
  int res13 = 0 ;
  void *argp14 = 0 ;
  int res14 = 0 ;
  
  if ((nobjs < 14) || (nobjs > 14)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_load" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "3"" of type '" "heasp::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "table_load" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "table_load" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "table_load" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  ecode7 = SWIG_AsVal_bool(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "table_load" "', argument " "7"" of type '" "bool""'");
  } 
  arg7 = static_cast< bool >(val7);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[7], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "8"" of type '" "heasp::string const""'"); 
    }
    arg8 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "table_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "table_load" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[10], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "11"" of type '" "heasp::string const""'"); 
    }
    arg11 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[11]. We need to get its size then resize
    // arg12 and copy the contents from swig_obj[11] into (&arg12)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[11], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec12.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec12[i] = static_cast<double>(in_data[i]);
    }
    arg12 = &tvec12;
    
    
  }
  res13 = SWIG_ConvertPtr(swig_obj[12], &argp13, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,  0  | 0);
  if (!SWIG_IsOK(res13)) {
    SWIG_exception_fail(SWIG_ArgError(res13), "in method '" "table_load" "', argument " "13"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  if (!argp13) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_load" "', argument " "13"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  arg13 = reinterpret_cast< std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > * >(argp13);
  res14 = SWIG_ConvertPtr(swig_obj[13], &argp14, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t,  0  | 0);
  if (!SWIG_IsOK(res14)) {
    SWIG_exception_fail(SWIG_ArgError(res14), "in method '" "table_load" "', argument " "14"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  if (!argp14) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_load" "', argument " "14"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  arg14 = reinterpret_cast< std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > * >(argp14);
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,(RealVector const &)*arg12,(std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)*arg13,(std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &)*arg14);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_load__SWIG_3(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  heasp::string arg3 ;
  Integer arg4 ;
  Integer arg5 ;
  bool arg6 ;
  bool arg7 ;
  heasp::string arg8 ;
  Real arg9 ;
  Real arg10 ;
  heasp::string arg11 ;
  RealVector *arg12 = 0 ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *arg13 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  bool val7 ;
  int ecode7 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  std::vector< double,std::allocator< double > > tvec12 ;
  void *argp13 = 0 ;
  int res13 = 0 ;
  
  if ((nobjs < 13) || (nobjs > 13)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_load" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "3"" of type '" "heasp::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "table_load" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "table_load" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "table_load" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  ecode7 = SWIG_AsVal_bool(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "table_load" "', argument " "7"" of type '" "bool""'");
  } 
  arg7 = static_cast< bool >(val7);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[7], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "8"" of type '" "heasp::string const""'"); 
    }
    arg8 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "table_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "table_load" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[10], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "11"" of type '" "heasp::string const""'"); 
    }
    arg11 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[11]. We need to get its size then resize
    // arg12 and copy the contents from swig_obj[11] into (&arg12)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[11], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec12.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec12[i] = static_cast<double>(in_data[i]);
    }
    arg12 = &tvec12;
    
    
  }
  res13 = SWIG_ConvertPtr(swig_obj[12], &argp13, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,  0  | 0);
  if (!SWIG_IsOK(res13)) {
    SWIG_exception_fail(SWIG_ArgError(res13), "in method '" "table_load" "', argument " "13"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  if (!argp13) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_load" "', argument " "13"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  arg13 = reinterpret_cast< std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > * >(argp13);
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,(RealVector const &)*arg12,(std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)*arg13);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_load__SWIG_4(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  heasp::string arg3 ;
  Integer arg4 ;
  Integer arg5 ;
  bool arg6 ;
  bool arg7 ;
  heasp::string arg8 ;
  Real arg9 ;
  Real arg10 ;
  heasp::string arg11 ;
  RealVector *arg12 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  bool val7 ;
  int ecode7 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  std::vector< double,std::allocator< double > > tvec12 ;
  
  if ((nobjs < 12) || (nobjs > 12)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_load" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "3"" of type '" "heasp::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "table_load" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "table_load" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "table_load" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  ecode7 = SWIG_AsVal_bool(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "table_load" "', argument " "7"" of type '" "bool""'");
  } 
  arg7 = static_cast< bool >(val7);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[7], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "8"" of type '" "heasp::string const""'"); 
    }
    arg8 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "table_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "table_load" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[10], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "11"" of type '" "heasp::string const""'"); 
    }
    arg11 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    // a Python array is in swig_obj[11]. We need to get its size then resize
    // arg12 and copy the contents from swig_obj[11] into (&arg12)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[11], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec12.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec12[i] = static_cast<double>(in_data[i]);
    }
    arg12 = &tvec12;
    
    
  }
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11,(RealVector const &)*arg12);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_load__SWIG_5(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  heasp::string arg3 ;
  Integer arg4 ;
  Integer arg5 ;
  bool arg6 ;
  bool arg7 ;
  heasp::string arg8 ;
  Real arg9 ;
  Real arg10 ;
  heasp::string arg11 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val4 ;
  int ecode4 = 0 ;
  int val5 ;
  int ecode5 = 0 ;
  bool val6 ;
  int ecode6 = 0 ;
  bool val7 ;
  int ecode7 = 0 ;
  double val9 ;
  int ecode9 = 0 ;
  double val10 ;
  int ecode10 = 0 ;
  
  if ((nobjs < 11) || (nobjs > 11)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_load" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[2], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "3"" of type '" "heasp::string const""'"); 
    }
    arg3 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode4 = SWIG_AsVal_int(swig_obj[3], &val4);
  if (!SWIG_IsOK(ecode4)) {
    SWIG_exception_fail(SWIG_ArgError(ecode4), "in method '" "table_load" "', argument " "4"" of type '" "Integer""'");
  } 
  arg4 = static_cast< Integer >(val4);
  ecode5 = SWIG_AsVal_int(swig_obj[4], &val5);
  if (!SWIG_IsOK(ecode5)) {
    SWIG_exception_fail(SWIG_ArgError(ecode5), "in method '" "table_load" "', argument " "5"" of type '" "Integer""'");
  } 
  arg5 = static_cast< Integer >(val5);
  ecode6 = SWIG_AsVal_bool(swig_obj[5], &val6);
  if (!SWIG_IsOK(ecode6)) {
    SWIG_exception_fail(SWIG_ArgError(ecode6), "in method '" "table_load" "', argument " "6"" of type '" "bool""'");
  } 
  arg6 = static_cast< bool >(val6);
  ecode7 = SWIG_AsVal_bool(swig_obj[6], &val7);
  if (!SWIG_IsOK(ecode7)) {
    SWIG_exception_fail(SWIG_ArgError(ecode7), "in method '" "table_load" "', argument " "7"" of type '" "bool""'");
  } 
  arg7 = static_cast< bool >(val7);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[7], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "8"" of type '" "heasp::string const""'"); 
    }
    arg8 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode9 = SWIG_AsVal_double(swig_obj[8], &val9);
  if (!SWIG_IsOK(ecode9)) {
    SWIG_exception_fail(SWIG_ArgError(ecode9), "in method '" "table_load" "', argument " "9"" of type '" "Real""'");
  } 
  arg9 = static_cast< Real >(val9);
  ecode10 = SWIG_AsVal_double(swig_obj[9], &val10);
  if (!SWIG_IsOK(ecode10)) {
    SWIG_exception_fail(SWIG_ArgError(ecode10), "in method '" "table_load" "', argument " "10"" of type '" "Real""'");
  } 
  arg10 = static_cast< Real >(val10);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[10], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_load" "', argument " "11"" of type '" "heasp::string const""'"); 
    }
    arg11 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->load(arg2,arg3,arg4,arg5,arg6,arg7,arg8,arg9,arg10,arg11);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_load(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[17] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "table_load", 0, 16, argv))) SWIG_fail;
  --argc;
  if (argc == 11) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__table, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_bool(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  int res = SWIG_AsPtr_std_string(argv[7], (std::string**)(0));
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        int res = SWIG_AsPtr_std_string(argv[10], (std::string**)(0));
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          return _wrap_table_load__SWIG_5(self, argc, argv);
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 12) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__table, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_bool(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  int res = SWIG_AsPtr_std_string(argv[7], (std::string**)(0));
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        int res = SWIG_AsPtr_std_string(argv[10], (std::string**)(0));
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          int res = SWIG_ConvertPtr(argv[11], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                          _v = SWIG_CheckState(res);
                          if (_v) {
                            return _wrap_table_load__SWIG_4(self, argc, argv);
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 13) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__table, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_bool(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  int res = SWIG_AsPtr_std_string(argv[7], (std::string**)(0));
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        int res = SWIG_AsPtr_std_string(argv[10], (std::string**)(0));
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          int res = SWIG_ConvertPtr(argv[11], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                          _v = SWIG_CheckState(res);
                          if (_v) {
                            int res = SWIG_ConvertPtr(argv[12], 0, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, SWIG_POINTER_NO_NULL | 0);
                            _v = SWIG_CheckState(res);
                            if (_v) {
                              return _wrap_table_load__SWIG_3(self, argc, argv);
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 14) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__table, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_bool(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  int res = SWIG_AsPtr_std_string(argv[7], (std::string**)(0));
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        int res = SWIG_AsPtr_std_string(argv[10], (std::string**)(0));
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          int res = SWIG_ConvertPtr(argv[11], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                          _v = SWIG_CheckState(res);
                          if (_v) {
                            int res = SWIG_ConvertPtr(argv[12], 0, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, SWIG_POINTER_NO_NULL | 0);
                            _v = SWIG_CheckState(res);
                            if (_v) {
                              int res = SWIG_ConvertPtr(argv[13], 0, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t, SWIG_POINTER_NO_NULL | 0);
                              _v = SWIG_CheckState(res);
                              if (_v) {
                                return _wrap_table_load__SWIG_2(self, argc, argv);
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 15) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__table, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_bool(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  int res = SWIG_AsPtr_std_string(argv[7], (std::string**)(0));
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        int res = SWIG_AsPtr_std_string(argv[10], (std::string**)(0));
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          int res = SWIG_ConvertPtr(argv[11], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                          _v = SWIG_CheckState(res);
                          if (_v) {
                            int res = SWIG_ConvertPtr(argv[12], 0, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, SWIG_POINTER_NO_NULL | 0);
                            _v = SWIG_CheckState(res);
                            if (_v) {
                              int res = SWIG_ConvertPtr(argv[13], 0, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t, SWIG_POINTER_NO_NULL | 0);
                              _v = SWIG_CheckState(res);
                              if (_v) {
                                {
                                  int res = SWIG_AsVal_bool(argv[14], NULL);
                                  _v = SWIG_CheckState(res);
                                }
                                if (_v) {
                                  return _wrap_table_load__SWIG_1(self, argc, argv);
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  if (argc == 16) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__table, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        int res = SWIG_AsPtr_std_string(argv[2], (std::string**)(0));
        _v = SWIG_CheckState(res);
        if (_v) {
          {
            int res = SWIG_AsVal_int(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_AsVal_bool(argv[5], NULL);
                _v = SWIG_CheckState(res);
              }
              if (_v) {
                {
                  int res = SWIG_AsVal_bool(argv[6], NULL);
                  _v = SWIG_CheckState(res);
                }
                if (_v) {
                  int res = SWIG_AsPtr_std_string(argv[7], (std::string**)(0));
                  _v = SWIG_CheckState(res);
                  if (_v) {
                    {
                      int res = SWIG_AsVal_double(argv[8], NULL);
                      _v = SWIG_CheckState(res);
                    }
                    if (_v) {
                      {
                        int res = SWIG_AsVal_double(argv[9], NULL);
                        _v = SWIG_CheckState(res);
                      }
                      if (_v) {
                        int res = SWIG_AsPtr_std_string(argv[10], (std::string**)(0));
                        _v = SWIG_CheckState(res);
                        if (_v) {
                          int res = SWIG_ConvertPtr(argv[11], 0, SWIGTYPE_p_std__vectorT_double_std__allocatorT_double_t_t, SWIG_POINTER_NO_NULL | 0);
                          _v = SWIG_CheckState(res);
                          if (_v) {
                            int res = SWIG_ConvertPtr(argv[12], 0, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, SWIG_POINTER_NO_NULL | 0);
                            _v = SWIG_CheckState(res);
                            if (_v) {
                              int res = SWIG_ConvertPtr(argv[13], 0, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t, SWIG_POINTER_NO_NULL | 0);
                              _v = SWIG_CheckState(res);
                              if (_v) {
                                {
                                  int res = SWIG_AsVal_bool(argv[14], NULL);
                                  _v = SWIG_CheckState(res);
                                }
                                if (_v) {
                                  {
                                    int res = SWIG_AsVal_bool(argv[15], NULL);
                                    _v = SWIG_CheckState(res);
                                  }
                                  if (_v) {
                                    return _wrap_table_load__SWIG_0(self, argc, argv);
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'table_load'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::table::load(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &,std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &,std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &,bool const,bool const)\n"
    "    heasp::table::load(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &,std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &,std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &,bool const)\n"
    "    heasp::table::load(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &,std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &,std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &)\n"
    "    heasp::table::load(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &,std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)\n"
    "    heasp::table::load(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const,RealVector const &)\n"
    "    heasp::table::load(heasp::string const,heasp::string const,Integer const,Integer const,bool const,bool const,heasp::string const,Real const,Real const,heasp::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_table_read__SWIG_0(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  bool arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  bool val3 ;
  int ecode3 = 0 ;
  Integer result;
  
  if ((nobjs < 3) || (nobjs > 3)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_read" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_read" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  ecode3 = SWIG_AsVal_bool(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "table_read" "', argument " "3"" of type '" "bool""'");
  } 
  arg3 = static_cast< bool >(val3);
  result = (Integer)(arg1)->read(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_read__SWIG_1(PyObject *self, Py_ssize_t nobjs, PyObject **swig_obj) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  Integer result;
  
  if ((nobjs < 2) || (nobjs > 2)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_read" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_read" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)(arg1)->read(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_read(PyObject *self, PyObject *args) {
  Py_ssize_t argc;
  PyObject *argv[4] = {
    0
  };
  
  if (!(argc = SWIG_Python_UnpackTuple(args, "table_read", 0, 3, argv))) SWIG_fail;
  --argc;
  if (argc == 2) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__table, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        return _wrap_table_read__SWIG_1(self, argc, argv);
      }
    }
  }
  if (argc == 3) {
    int _v = 0;
    void *vptr = 0;
    int res = SWIG_ConvertPtr(argv[0], &vptr, SWIGTYPE_p_heasp__table, 0);
    _v = SWIG_CheckState(res);
    if (_v) {
      int res = SWIG_AsPtr_std_string(argv[1], (std::string**)(0));
      _v = SWIG_CheckState(res);
      if (_v) {
        {
          int res = SWIG_AsVal_bool(argv[2], NULL);
          _v = SWIG_CheckState(res);
        }
        if (_v) {
          return _wrap_table_read__SWIG_0(self, argc, argv);
        }
      }
    }
  }
  
fail:
  SWIG_Python_RaiseOrModifyTypeError("Wrong number or type of arguments for overloaded function 'table_read'.\n"
    "  Possible C/C++ prototypes are:\n"
    "    heasp::table::read(heasp::string const,bool)\n"
    "    heasp::table::read(heasp::string const)\n");
  return 0;
}


SWIGINTERN PyObject *_wrap_table_pushParameter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::tableParameter *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_pushParameter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_pushParameter" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__tableParameter,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "table_pushParameter" "', argument " "2"" of type '" "heasp::tableParameter const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_pushParameter" "', argument " "2"" of type '" "heasp::tableParameter const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::tableParameter * >(argp2);
  (arg1)->pushParameter((heasp::tableParameter const &)*arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_pushSpectrum(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::tableSpectrum *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_pushSpectrum", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_pushSpectrum" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__tableSpectrum,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "table_pushSpectrum" "', argument " "2"" of type '" "heasp::tableSpectrum const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_pushSpectrum" "', argument " "2"" of type '" "heasp::tableSpectrum const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::tableSpectrum * >(argp2);
  (arg1)->pushSpectrum((heasp::tableSpectrum const &)*arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getParameter(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::tableParameter result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_getParameter", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getParameter" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_getParameter" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::table const *)arg1)->getParameter(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::tableParameter(result)), SWIGTYPE_p_heasp__tableParameter, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getSpectrum(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::tableSpectrum result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_getSpectrum", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getSpectrum" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_getSpectrum" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::table const *)arg1)->getSpectrum(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::tableSpectrum(result)), SWIGTYPE_p_heasp__tableSpectrum, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_copy(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::table *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::table *result = 0 ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_copy", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_copy" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_heasp__table,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "table_copy" "', argument " "2"" of type '" "heasp::table const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_copy" "', argument " "2"" of type '" "heasp::table const &""'"); 
  }
  arg2 = reinterpret_cast< heasp::table * >(argp2);
  result = (heasp::table *) &(arg1)->copy((heasp::table const &)*arg2);
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_heasp__table, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_disp(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  bool arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  bool val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::string result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_disp", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_disp" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_bool(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_disp" "', argument " "2"" of type '" "bool""'");
  } 
  arg2 = static_cast< bool >(val2);
  result = ((heasp::table const *)arg1)->disp(arg2);
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_clear(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_clear" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  (arg1)->clear();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_check(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_check" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = ((heasp::table const *)arg1)->check();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_convertUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_convertUnits" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Integer)(arg1)->convertUnits();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_reverseRows(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_reverseRows" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  (arg1)->reverseRows();
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_write(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_write", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_write" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_write" "', argument " "2"" of type '" "heasp::string""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  result = (Integer)((heasp::table const *)arg1)->write(arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_NumberParameters(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_NumberParameters" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Integer)((heasp::table const *)arg1)->NumberParameters();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getNumberParameters(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getNumberParameters" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Integer)((heasp::table const *)arg1)->getNumberParameters();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_NumberSpectra(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_NumberSpectra" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Integer)((heasp::table const *)arg1)->NumberSpectra();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getNumberSpectra(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getNumberSpectra" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Integer)((heasp::table const *)arg1)->getNumberSpectra();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_NumberEnergies(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_NumberEnergies" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Integer)((heasp::table const *)arg1)->NumberEnergies();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getNumberEnergies(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getNumberEnergies" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Integer)((heasp::table const *)arg1)->getNumberEnergies();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getParameters(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getParameters" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *) &((heasp::table const *)arg1)->getParameters();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setParameters(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setParameters", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setParameters" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "table_setParameters" "', argument " "2"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_setParameters" "', argument " "2"" of type '" "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > * >(argp2);
  result = (Integer)(arg1)->setParameters((std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getParametersElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::tableParameter result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_getParametersElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getParametersElement" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_getParametersElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::table const *)arg1)->getParametersElement(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::tableParameter(result)), SWIGTYPE_p_heasp__tableParameter, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setParametersElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  heasp::tableParameter *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setParametersElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setParametersElement" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setParametersElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_heasp__tableParameter,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "table_setParametersElement" "', argument " "3"" of type '" "heasp::tableParameter const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_setParametersElement" "', argument " "3"" of type '" "heasp::tableParameter const &""'"); 
  }
  arg3 = reinterpret_cast< heasp::tableParameter * >(argp3);
  result = (Integer)(arg1)->setParametersElement(arg2,(heasp::tableParameter const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getSpectra(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getSpectra" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *) &((heasp::table const *)arg1)->getSpectra();
  resultobj = SWIG_NewPointerObj(SWIG_as_voidptr(result), SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t, 0 |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setSpectra(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  void *argp2 = 0 ;
  int res2 = 0 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setSpectra", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setSpectra" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  res2 = SWIG_ConvertPtr(swig_obj[1], &argp2, SWIGTYPE_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t,  0  | 0);
  if (!SWIG_IsOK(res2)) {
    SWIG_exception_fail(SWIG_ArgError(res2), "in method '" "table_setSpectra" "', argument " "2"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  if (!argp2) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_setSpectra" "', argument " "2"" of type '" "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &""'"); 
  }
  arg2 = reinterpret_cast< std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > * >(argp2);
  result = (Integer)(arg1)->setSpectra((std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getSpectraElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  heasp::tableSpectrum result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_getSpectraElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getSpectraElement" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_getSpectraElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = ((heasp::table const *)arg1)->getSpectraElement(arg2);
  resultobj = SWIG_NewPointerObj((new heasp::tableSpectrum(result)), SWIGTYPE_p_heasp__tableSpectrum, SWIG_POINTER_OWN |  0 );
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setSpectraElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  heasp::tableSpectrum *arg3 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  void *argp3 = 0 ;
  int res3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setSpectraElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setSpectraElement" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setSpectraElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  res3 = SWIG_ConvertPtr(swig_obj[2], &argp3, SWIGTYPE_p_heasp__tableSpectrum,  0  | 0);
  if (!SWIG_IsOK(res3)) {
    SWIG_exception_fail(SWIG_ArgError(res3), "in method '" "table_setSpectraElement" "', argument " "3"" of type '" "heasp::tableSpectrum const &""'"); 
  }
  if (!argp3) {
    SWIG_exception_fail(SWIG_ValueError, "invalid null reference " "in method '" "table_setSpectraElement" "', argument " "3"" of type '" "heasp::tableSpectrum const &""'"); 
  }
  arg3 = reinterpret_cast< heasp::tableSpectrum * >(argp3);
  result = (Integer)(arg1)->setSpectraElement(arg2,(heasp::tableSpectrum const &)*arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getModelName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getModelName" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = ((heasp::table const *)arg1)->getModelName();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setModelName(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setModelName", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setModelName" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_setModelName" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setModelName(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getModelUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getModelUnits" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = ((heasp::table const *)arg1)->getModelUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setModelUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setModelUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setModelUnits" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_setModelUnits" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setModelUnits(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getNumIntParams(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getNumIntParams" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Integer)((heasp::table const *)arg1)->getNumIntParams();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setNumIntParams(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setNumIntParams", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setNumIntParams" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setNumIntParams" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  (arg1)->setNumIntParams(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getNumAddParams(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Integer result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getNumAddParams" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Integer)((heasp::table const *)arg1)->getNumAddParams();
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setNumAddParams(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setNumAddParams", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setNumAddParams" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setNumAddParams" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  (arg1)->setNumAddParams(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getisError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  bool result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getisError" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (bool)((heasp::table const *)arg1)->getisError();
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setisError(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  bool arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  bool val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setisError", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setisError" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_bool(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setisError" "', argument " "2"" of type '" "bool""'");
  } 
  arg2 = static_cast< bool >(val2);
  (arg1)->setisError(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getisRedshift(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  bool result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getisRedshift" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (bool)((heasp::table const *)arg1)->getisRedshift();
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setisRedshift(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  bool arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  bool val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setisRedshift", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setisRedshift" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_bool(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setisRedshift" "', argument " "2"" of type '" "bool""'");
  } 
  arg2 = static_cast< bool >(val2);
  (arg1)->setisRedshift(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getisAdditive(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  bool result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getisAdditive" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (bool)((heasp::table const *)arg1)->getisAdditive();
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setisAdditive(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  bool arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  bool val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setisAdditive", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setisAdditive" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_bool(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setisAdditive" "', argument " "2"" of type '" "bool""'");
  } 
  arg2 = static_cast< bool >(val2);
  (arg1)->setisAdditive(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getisEscale(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  bool result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getisEscale" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (bool)((heasp::table const *)arg1)->getisEscale();
  resultobj = SWIG_From_bool(static_cast< bool >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setisEscale(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  bool arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  bool val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setisEscale", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setisEscale" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_bool(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setisEscale" "', argument " "2"" of type '" "bool""'");
  } 
  arg2 = static_cast< bool >(val2);
  (arg1)->setisEscale(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getEnergies(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  RealVector *result = 0 ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getEnergies" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (RealVector *) &((heasp::table const *)arg1)->getEnergies();
  {
    // create python array of appropriate shape
    npy_intp sz = static_cast<npy_intp>((*result).size());
    npy_intp dims[] = {
      sz
    };
    PyObject* out_array = PyArray_SimpleNew(1, dims, NPY_DOUBLE);
    
    if (! out_array) {
      PyErr_SetString(PyExc_ValueError,
        "vector wrap: unable to create the output array.");
      return NULL;
    }
    
    // copy data from vect into numpy array
    double* out_data = (double*) array_data(out_array);
    for (size_t i = 0; i < sz; i++) {
      out_data[i] = static_cast<double>((*result).data()[i]);
    }
    
    resultobj = out_array;
  }
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setEnergies(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  RealVector *arg2 = 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  std::vector< double,std::allocator< double > > tvec2 ;
  PyObject *swig_obj[2] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setEnergies", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setEnergies" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    // a Python array is in swig_obj[1]. We need to get its size then resize
    // arg2 and copy the contents from swig_obj[1] into (&arg2)->
    int is_new_object = 0;
    PyArrayObject* array = obj_to_array_contiguous_allow_conversion(swig_obj[1], NPY_DOUBLE,
      &is_new_object);
    if (!array || !require_dimensions(array, 1)) SWIG_fail;
    
    size_t size = array_size(array, 0);
    tvec2.resize(size);
    
    // copy data from numpy array into vector
    double* in_data = (double*) array_data(array);
    for (size_t i = 0; i < size; i++) {
      tvec2[i] = static_cast<double>(in_data[i]);
    }
    arg2 = &tvec2;
    
    
  }
  result = (Integer)(arg1)->setEnergies((RealVector const &)*arg2);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getEnergiesElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  Real result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_getEnergiesElement", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getEnergiesElement" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_getEnergiesElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  result = (Real)((heasp::table const *)arg1)->getEnergiesElement(arg2);
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setEnergiesElement(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Integer arg2 ;
  Real arg3 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  int val2 ;
  int ecode2 = 0 ;
  double val3 ;
  int ecode3 = 0 ;
  PyObject *swig_obj[3] ;
  Integer result;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setEnergiesElement", 3, 3, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setEnergiesElement" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_int(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setEnergiesElement" "', argument " "2"" of type '" "Integer""'");
  } 
  arg2 = static_cast< Integer >(val2);
  ecode3 = SWIG_AsVal_double(swig_obj[2], &val3);
  if (!SWIG_IsOK(ecode3)) {
    SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "table_setEnergiesElement" "', argument " "3"" of type '" "Real""'");
  } 
  arg3 = static_cast< Real >(val3);
  result = (Integer)(arg1)->setEnergiesElement(arg2,arg3);
  resultobj = SWIG_From_int(static_cast< int >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getEnergyUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getEnergyUnits" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = ((heasp::table const *)arg1)->getEnergyUnits();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setEnergyUnits(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setEnergyUnits", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setEnergyUnits" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_setEnergyUnits" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setEnergyUnits(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getLowEnergyLimit(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getLowEnergyLimit" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Real)((heasp::table const *)arg1)->getLowEnergyLimit();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setLowEnergyLimit(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setLowEnergyLimit", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setLowEnergyLimit" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setLowEnergyLimit" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setLowEnergyLimit(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getHighEnergyLimit(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  Real result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getHighEnergyLimit" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = (Real)((heasp::table const *)arg1)->getHighEnergyLimit();
  resultobj = SWIG_From_double(static_cast< double >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setHighEnergyLimit(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  Real arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  double val2 ;
  int ecode2 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setHighEnergyLimit", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setHighEnergyLimit" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  ecode2 = SWIG_AsVal_double(swig_obj[1], &val2);
  if (!SWIG_IsOK(ecode2)) {
    SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "table_setHighEnergyLimit" "', argument " "2"" of type '" "Real""'");
  } 
  arg2 = static_cast< Real >(val2);
  (arg1)->setHighEnergyLimit(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getFilename(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  heasp::string result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getFilename" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = ((heasp::table const *)arg1)->getFilename();
  resultobj = SWIG_From_std_string(static_cast< std::string >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setFilename(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  heasp::string arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setFilename", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setFilename" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::string *ptr = (std::string *)0;
    int res = SWIG_AsPtr_std_string(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_setFilename" "', argument " "2"" of type '" "heasp::string const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setFilename(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_getFiltExps(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  SwigValueWrapper< std::vector< std::string,std::allocator< std::string > > > result;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_getFiltExps" "', argument " "1"" of type '" "heasp::table const *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  result = ((heasp::table const *)arg1)->getFiltExps();
  resultobj = swig::from(static_cast< std::vector< std::string,std::allocator< std::string > > >(result));
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_table_setFiltExps(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  SwigValueWrapper< std::vector< std::string,std::allocator< std::string > > > arg2 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[2] ;
  
  if (!SWIG_Python_UnpackTuple(args, "table_setFiltExps", 2, 2, swig_obj)) SWIG_fail;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, 0 |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "table_setFiltExps" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  {
    std::vector< std::string,std::allocator< std::string > > *ptr = (std::vector< std::string,std::allocator< std::string > > *)0;
    int res = swig::asptr(swig_obj[1], &ptr);
    if (!SWIG_IsOK(res) || !ptr) {
      SWIG_exception_fail(SWIG_ArgError((ptr ? res : SWIG_TypeError)), "in method '" "table_setFiltExps" "', argument " "2"" of type '" "StringVector const""'"); 
    }
    arg2 = *ptr;
    if (SWIG_IsNewObj(res)) delete ptr;
  }
  (arg1)->setFiltExps(arg2);
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *_wrap_delete_table(PyObject *self, PyObject *args) {
  PyObject *resultobj = 0;
  heasp::table *arg1 = (heasp::table *) 0 ;
  void *argp1 = 0 ;
  int res1 = 0 ;
  PyObject *swig_obj[1] ;
  
  if (!args) SWIG_fail;
  swig_obj[0] = args;
  res1 = SWIG_ConvertPtr(swig_obj[0], &argp1,SWIGTYPE_p_heasp__table, SWIG_POINTER_DISOWN |  0 );
  if (!SWIG_IsOK(res1)) {
    SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_table" "', argument " "1"" of type '" "heasp::table *""'"); 
  }
  arg1 = reinterpret_cast< heasp::table * >(argp1);
  delete arg1;
  resultobj = SWIG_Py_Void();
  return resultobj;
fail:
  return NULL;
}


SWIGINTERN PyObject *table_swigregister(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  PyObject *obj;
  if (!SWIG_Python_UnpackTuple(args, "swigregister", 1, 1, &obj)) return NULL;
  SWIG_TypeNewClientData(SWIGTYPE_p_heasp__table, SWIG_NewClientData(obj));
  return SWIG_Py_Void();
}

SWIGINTERN PyObject *table_swiginit(PyObject *SWIGUNUSEDPARM(self), PyObject *args) {
  return SWIG_Python_InitShadowInstance(args);
}

static PyMethodDef SwigMethods[] = {
	 { "delete_SwigPyIterator", _wrap_delete_SwigPyIterator, METH_O, NULL},
	 { "SwigPyIterator_value", _wrap_SwigPyIterator_value, METH_O, NULL},
	 { "SwigPyIterator_incr", _wrap_SwigPyIterator_incr, METH_VARARGS, NULL},
	 { "SwigPyIterator_decr", _wrap_SwigPyIterator_decr, METH_VARARGS, NULL},
	 { "SwigPyIterator_distance", _wrap_SwigPyIterator_distance, METH_VARARGS, NULL},
	 { "SwigPyIterator_equal", _wrap_SwigPyIterator_equal, METH_VARARGS, NULL},
	 { "SwigPyIterator_copy", _wrap_SwigPyIterator_copy, METH_O, NULL},
	 { "SwigPyIterator_next", _wrap_SwigPyIterator_next, METH_O, NULL},
	 { "SwigPyIterator___next__", _wrap_SwigPyIterator___next__, METH_O, NULL},
	 { "SwigPyIterator_previous", _wrap_SwigPyIterator_previous, METH_O, NULL},
	 { "SwigPyIterator_advance", _wrap_SwigPyIterator_advance, METH_VARARGS, NULL},
	 { "SwigPyIterator___eq__", _wrap_SwigPyIterator___eq__, METH_VARARGS, NULL},
	 { "SwigPyIterator___ne__", _wrap_SwigPyIterator___ne__, METH_VARARGS, NULL},
	 { "SwigPyIterator___iadd__", _wrap_SwigPyIterator___iadd__, METH_VARARGS, NULL},
	 { "SwigPyIterator___isub__", _wrap_SwigPyIterator___isub__, METH_VARARGS, NULL},
	 { "SwigPyIterator___add__", _wrap_SwigPyIterator___add__, METH_VARARGS, NULL},
	 { "SwigPyIterator___sub__", _wrap_SwigPyIterator___sub__, METH_VARARGS, NULL},
	 { "SwigPyIterator_swigregister", SwigPyIterator_swigregister, METH_O, NULL},
	 { "StringVector_iterator", _wrap_StringVector_iterator, METH_O, NULL},
	 { "StringVector___nonzero__", _wrap_StringVector___nonzero__, METH_O, NULL},
	 { "StringVector___bool__", _wrap_StringVector___bool__, METH_O, NULL},
	 { "StringVector___len__", _wrap_StringVector___len__, METH_O, NULL},
	 { "StringVector___getslice__", _wrap_StringVector___getslice__, METH_VARARGS, NULL},
	 { "StringVector___setslice__", _wrap_StringVector___setslice__, METH_VARARGS, NULL},
	 { "StringVector___delslice__", _wrap_StringVector___delslice__, METH_VARARGS, NULL},
	 { "StringVector___delitem__", _wrap_StringVector___delitem__, METH_VARARGS, NULL},
	 { "StringVector___getitem__", _wrap_StringVector___getitem__, METH_VARARGS, NULL},
	 { "StringVector___setitem__", _wrap_StringVector___setitem__, METH_VARARGS, NULL},
	 { "StringVector_pop", _wrap_StringVector_pop, METH_O, NULL},
	 { "StringVector_append", _wrap_StringVector_append, METH_VARARGS, NULL},
	 { "StringVector_empty", _wrap_StringVector_empty, METH_O, NULL},
	 { "StringVector_size", _wrap_StringVector_size, METH_O, NULL},
	 { "StringVector_swap", _wrap_StringVector_swap, METH_VARARGS, NULL},
	 { "StringVector_begin", _wrap_StringVector_begin, METH_O, NULL},
	 { "StringVector_end", _wrap_StringVector_end, METH_O, NULL},
	 { "StringVector_rbegin", _wrap_StringVector_rbegin, METH_O, NULL},
	 { "StringVector_rend", _wrap_StringVector_rend, METH_O, NULL},
	 { "StringVector_clear", _wrap_StringVector_clear, METH_O, NULL},
	 { "StringVector_get_allocator", _wrap_StringVector_get_allocator, METH_O, NULL},
	 { "StringVector_pop_back", _wrap_StringVector_pop_back, METH_O, NULL},
	 { "StringVector_erase", _wrap_StringVector_erase, METH_VARARGS, NULL},
	 { "new_StringVector", _wrap_new_StringVector, METH_VARARGS, NULL},
	 { "StringVector_push_back", _wrap_StringVector_push_back, METH_VARARGS, NULL},
	 { "StringVector_front", _wrap_StringVector_front, METH_O, NULL},
	 { "StringVector_back", _wrap_StringVector_back, METH_O, NULL},
	 { "StringVector_assign", _wrap_StringVector_assign, METH_VARARGS, NULL},
	 { "StringVector_resize", _wrap_StringVector_resize, METH_VARARGS, NULL},
	 { "StringVector_insert", _wrap_StringVector_insert, METH_VARARGS, NULL},
	 { "StringVector_reserve", _wrap_StringVector_reserve, METH_VARARGS, NULL},
	 { "StringVector_capacity", _wrap_StringVector_capacity, METH_O, NULL},
	 { "delete_StringVector", _wrap_delete_StringVector, METH_O, NULL},
	 { "StringVector_swigregister", StringVector_swigregister, METH_O, NULL},
	 { "StringVector_swiginit", StringVector_swiginit, METH_VARARGS, NULL},
	 { "new_pha", _wrap_new_pha, METH_VARARGS, NULL},
	 { "delete_pha", _wrap_delete_pha, METH_O, NULL},
	 { "pha_read", _wrap_pha_read, METH_VARARGS, NULL},
	 { "pha_load", _wrap_pha_load, METH_VARARGS, NULL},
	 { "pha_copy", _wrap_pha_copy, METH_VARARGS, NULL},
	 { "pha_disp", _wrap_pha_disp, METH_O, NULL},
	 { "pha_clear", _wrap_pha_clear, METH_O, NULL},
	 { "pha_check", _wrap_pha_check, METH_O, NULL},
	 { "pha_write", _wrap_pha_write, METH_VARARGS, NULL},
	 { "pha___imul__", _wrap_pha___imul__, METH_VARARGS, NULL},
	 { "pha___iadd__", _wrap_pha___iadd__, METH_VARARGS, NULL},
	 { "pha_checkCompatibility", _wrap_pha_checkCompatibility, METH_VARARGS, NULL},
	 { "pha_selectChannels", _wrap_pha_selectChannels, METH_VARARGS, NULL},
	 { "pha_setGrouping", _wrap_pha_setGrouping, METH_VARARGS, NULL},
	 { "pha_getGrouping", _wrap_pha_getGrouping, METH_O, NULL},
	 { "pha_getMinCountsGrouping", _wrap_pha_getMinCountsGrouping, METH_VARARGS, NULL},
	 { "pha_getMinSNGrouping", _wrap_pha_getMinSNGrouping, METH_VARARGS, NULL},
	 { "pha_getMinSNOptimalGrouping", _wrap_pha_getMinSNOptimalGrouping, METH_VARARGS, NULL},
	 { "pha_calcSignalAndNoise", _wrap_pha_calcSignalAndNoise, METH_VARARGS, NULL},
	 { "pha_rebinChannels", _wrap_pha_rebinChannels, METH_VARARGS, NULL},
	 { "pha_shiftChannels", _wrap_pha_shiftChannels, METH_VARARGS, NULL},
	 { "pha_convertUnits", _wrap_pha_convertUnits, METH_VARARGS, NULL},
	 { "pha_NumberChannels", _wrap_pha_NumberChannels, METH_O, NULL},
	 { "pha_getNumberChannels", _wrap_pha_getNumberChannels, METH_O, NULL},
	 { "pha_getFirstChannel", _wrap_pha_getFirstChannel, METH_O, NULL},
	 { "pha_setFirstChannel", _wrap_pha_setFirstChannel, METH_VARARGS, NULL},
	 { "pha_getPha", _wrap_pha_getPha, METH_O, NULL},
	 { "pha_setPha", _wrap_pha_setPha, METH_VARARGS, NULL},
	 { "pha_getPhaElement", _wrap_pha_getPhaElement, METH_VARARGS, NULL},
	 { "pha_setPhaElement", _wrap_pha_setPhaElement, METH_VARARGS, NULL},
	 { "pha_getStatError", _wrap_pha_getStatError, METH_O, NULL},
	 { "pha_setStatError", _wrap_pha_setStatError, METH_VARARGS, NULL},
	 { "pha_getStatErrorElement", _wrap_pha_getStatErrorElement, METH_VARARGS, NULL},
	 { "pha_setStatErrorElement", _wrap_pha_setStatErrorElement, METH_VARARGS, NULL},
	 { "pha_getSysError", _wrap_pha_getSysError, METH_O, NULL},
	 { "pha_setSysError", _wrap_pha_setSysError, METH_VARARGS, NULL},
	 { "pha_getSysErrorElement", _wrap_pha_getSysErrorElement, METH_VARARGS, NULL},
	 { "pha_setSysErrorElement", _wrap_pha_setSysErrorElement, METH_VARARGS, NULL},
	 { "pha_getChannel", _wrap_pha_getChannel, METH_O, NULL},
	 { "pha_setChannel", _wrap_pha_setChannel, METH_VARARGS, NULL},
	 { "pha_getChannelElement", _wrap_pha_getChannelElement, METH_VARARGS, NULL},
	 { "pha_setChannelElement", _wrap_pha_setChannelElement, METH_VARARGS, NULL},
	 { "pha_getQuality", _wrap_pha_getQuality, METH_O, NULL},
	 { "pha_setQuality", _wrap_pha_setQuality, METH_VARARGS, NULL},
	 { "pha_getQualityElement", _wrap_pha_getQualityElement, METH_VARARGS, NULL},
	 { "pha_setQualityElement", _wrap_pha_setQualityElement, METH_VARARGS, NULL},
	 { "pha_getGroup", _wrap_pha_getGroup, METH_O, NULL},
	 { "pha_setGroup", _wrap_pha_setGroup, METH_VARARGS, NULL},
	 { "pha_getGroupElement", _wrap_pha_getGroupElement, METH_VARARGS, NULL},
	 { "pha_setGroupElement", _wrap_pha_setGroupElement, METH_VARARGS, NULL},
	 { "pha_getAreaScaling", _wrap_pha_getAreaScaling, METH_O, NULL},
	 { "pha_setAreaScaling", _wrap_pha_setAreaScaling, METH_VARARGS, NULL},
	 { "pha_getAreaScalingElement", _wrap_pha_getAreaScalingElement, METH_VARARGS, NULL},
	 { "pha_setAreaScalingElement", _wrap_pha_setAreaScalingElement, METH_VARARGS, NULL},
	 { "pha_getBackScaling", _wrap_pha_getBackScaling, METH_O, NULL},
	 { "pha_setBackScaling", _wrap_pha_setBackScaling, METH_VARARGS, NULL},
	 { "pha_getBackScalingElement", _wrap_pha_getBackScalingElement, METH_VARARGS, NULL},
	 { "pha_setBackScalingElement", _wrap_pha_setBackScalingElement, METH_VARARGS, NULL},
	 { "pha_getExposure", _wrap_pha_getExposure, METH_O, NULL},
	 { "pha_setExposure", _wrap_pha_setExposure, METH_VARARGS, NULL},
	 { "pha_getCorrectionScaling", _wrap_pha_getCorrectionScaling, METH_O, NULL},
	 { "pha_setCorrectionScaling", _wrap_pha_setCorrectionScaling, METH_VARARGS, NULL},
	 { "pha_getDetChans", _wrap_pha_getDetChans, METH_O, NULL},
	 { "pha_setDetChans", _wrap_pha_setDetChans, METH_VARARGS, NULL},
	 { "pha_getPoisserr", _wrap_pha_getPoisserr, METH_O, NULL},
	 { "pha_setPoisserr", _wrap_pha_setPoisserr, METH_VARARGS, NULL},
	 { "pha_getDatatype", _wrap_pha_getDatatype, METH_O, NULL},
	 { "pha_setDatatype", _wrap_pha_setDatatype, METH_VARARGS, NULL},
	 { "pha_getSpectrumtype", _wrap_pha_getSpectrumtype, METH_O, NULL},
	 { "pha_setSpectrumtype", _wrap_pha_setSpectrumtype, METH_VARARGS, NULL},
	 { "pha_getResponseFile", _wrap_pha_getResponseFile, METH_O, NULL},
	 { "pha_setResponseFile", _wrap_pha_setResponseFile, METH_VARARGS, NULL},
	 { "pha_getAncillaryFile", _wrap_pha_getAncillaryFile, METH_O, NULL},
	 { "pha_setAncillaryFile", _wrap_pha_setAncillaryFile, METH_VARARGS, NULL},
	 { "pha_getBackgroundFile", _wrap_pha_getBackgroundFile, METH_O, NULL},
	 { "pha_setBackgroundFile", _wrap_pha_setBackgroundFile, METH_VARARGS, NULL},
	 { "pha_getCorrectionFile", _wrap_pha_getCorrectionFile, METH_O, NULL},
	 { "pha_setCorrectionFile", _wrap_pha_setCorrectionFile, METH_VARARGS, NULL},
	 { "pha_getFluxUnits", _wrap_pha_getFluxUnits, METH_O, NULL},
	 { "pha_setFluxUnits", _wrap_pha_setFluxUnits, METH_VARARGS, NULL},
	 { "pha_getChannelType", _wrap_pha_getChannelType, METH_O, NULL},
	 { "pha_setChannelType", _wrap_pha_setChannelType, METH_VARARGS, NULL},
	 { "pha_getTelescope", _wrap_pha_getTelescope, METH_O, NULL},
	 { "pha_setTelescope", _wrap_pha_setTelescope, METH_VARARGS, NULL},
	 { "pha_getInstrument", _wrap_pha_getInstrument, METH_O, NULL},
	 { "pha_setInstrument", _wrap_pha_setInstrument, METH_VARARGS, NULL},
	 { "pha_getDetector", _wrap_pha_getDetector, METH_O, NULL},
	 { "pha_setDetector", _wrap_pha_setDetector, METH_VARARGS, NULL},
	 { "pha_getFilter", _wrap_pha_getFilter, METH_O, NULL},
	 { "pha_setFilter", _wrap_pha_setFilter, METH_VARARGS, NULL},
	 { "pha_getDatamode", _wrap_pha_getDatamode, METH_O, NULL},
	 { "pha_setDatamode", _wrap_pha_setDatamode, METH_VARARGS, NULL},
	 { "pha_getStokesParameter", _wrap_pha_getStokesParameter, METH_O, NULL},
	 { "pha_setStokesParameter", _wrap_pha_setStokesParameter, METH_VARARGS, NULL},
	 { "pha_getStokesWeighting", _wrap_pha_getStokesWeighting, METH_O, NULL},
	 { "pha_setStokesWeighting", _wrap_pha_setStokesWeighting, METH_VARARGS, NULL},
	 { "pha_getXSPECFilter", _wrap_pha_getXSPECFilter, METH_O, NULL},
	 { "pha_setXSPECFilter", _wrap_pha_setXSPECFilter, METH_VARARGS, NULL},
	 { "pha_getXSPECFilterElement", _wrap_pha_getXSPECFilterElement, METH_VARARGS, NULL},
	 { "pha_setXSPECFilterElement", _wrap_pha_setXSPECFilterElement, METH_VARARGS, NULL},
	 { "pha_swigregister", pha_swigregister, METH_O, NULL},
	 { "pha_swiginit", pha_swiginit, METH_VARARGS, NULL},
	 { "PHAtype", _wrap_PHAtype, METH_VARARGS, NULL},
	 { "IsPHAcounts", _wrap_IsPHAcounts, METH_VARARGS, NULL},
	 { "NumberofSpectra", _wrap_NumberofSpectra, METH_VARARGS, NULL},
	 { "SpectrumExtensions", _wrap_SpectrumExtensions, METH_VARARGS, NULL},
	 { "new_phaII", _wrap_new_phaII, METH_VARARGS, NULL},
	 { "delete_phaII", _wrap_delete_phaII, METH_O, NULL},
	 { "phaII_read", _wrap_phaII_read, METH_VARARGS, NULL},
	 { "phaII_copy", _wrap_phaII_copy, METH_VARARGS, NULL},
	 { "phaII_get", _wrap_phaII_get, METH_VARARGS, NULL},
	 { "phaII_push", _wrap_phaII_push, METH_VARARGS, NULL},
	 { "phaII_disp", _wrap_phaII_disp, METH_O, NULL},
	 { "phaII_clear", _wrap_phaII_clear, METH_O, NULL},
	 { "phaII_check", _wrap_phaII_check, METH_O, NULL},
	 { "phaII_write", _wrap_phaII_write, METH_VARARGS, NULL},
	 { "phaII_NumberSpectra", _wrap_phaII_NumberSpectra, METH_O, NULL},
	 { "phaII_getNumberSpectra", _wrap_phaII_getNumberSpectra, METH_O, NULL},
	 { "phaII_getphas", _wrap_phaII_getphas, METH_O, NULL},
	 { "phaII_setphas", _wrap_phaII_setphas, METH_VARARGS, NULL},
	 { "phaII_getphasElement", _wrap_phaII_getphasElement, METH_VARARGS, NULL},
	 { "phaII_setphasElement", _wrap_phaII_setphasElement, METH_VARARGS, NULL},
	 { "phaII_swigregister", phaII_swigregister, METH_O, NULL},
	 { "phaII_swiginit", phaII_swiginit, METH_VARARGS, NULL},
	 { "new_rmf", _wrap_new_rmf, METH_VARARGS, NULL},
	 { "delete_rmf", _wrap_delete_rmf, METH_O, NULL},
	 { "rmf_read", _wrap_rmf_read, METH_VARARGS, NULL},
	 { "rmf_readMatrix", _wrap_rmf_readMatrix, METH_VARARGS, NULL},
	 { "rmf_readChannelBounds", _wrap_rmf_readChannelBounds, METH_VARARGS, NULL},
	 { "rmf_load", _wrap_rmf_load, METH_VARARGS, NULL},
	 { "rmf_initialize", _wrap_rmf_initialize, METH_VARARGS, NULL},
	 { "rmf_loadDiagonalResponse", _wrap_rmf_loadDiagonalResponse, METH_VARARGS, NULL},
	 { "rmf_ElementValue", _wrap_rmf_ElementValue, METH_VARARGS, NULL},
	 { "rmf_RowValues", _wrap_rmf_RowValues, METH_VARARGS, NULL},
	 { "rmf_RandomChannels", _wrap_rmf_RandomChannels, METH_VARARGS, NULL},
	 { "rmf_disp", _wrap_rmf_disp, METH_O, NULL},
	 { "rmf_clear", _wrap_rmf_clear, METH_O, NULL},
	 { "rmf_clearMatrix", _wrap_rmf_clearMatrix, METH_O, NULL},
	 { "rmf_check", _wrap_rmf_check, METH_O, NULL},
	 { "rmf_normalize", _wrap_rmf_normalize, METH_O, NULL},
	 { "rmf_changeFirstChannel", _wrap_rmf_changeFirstChannel, METH_VARARGS, NULL},
	 { "rmf_compress", _wrap_rmf_compress, METH_VARARGS, NULL},
	 { "rmf_uncompress", _wrap_rmf_uncompress, METH_O, NULL},
	 { "rmf_rebinChannels", _wrap_rmf_rebinChannels, METH_VARARGS, NULL},
	 { "rmf_rebinEnergies", _wrap_rmf_rebinEnergies, METH_VARARGS, NULL},
	 { "rmf_shiftChannels", _wrap_rmf_shiftChannels, METH_VARARGS, NULL},
	 { "rmf_shiftEnergies", _wrap_rmf_shiftEnergies, METH_VARARGS, NULL},
	 { "rmf_remapEnergies", _wrap_rmf_remapEnergies, METH_VARARGS, NULL},
	 { "rmf_interpolateAndMultiply", _wrap_rmf_interpolateAndMultiply, METH_VARARGS, NULL},
	 { "rmf_write", _wrap_rmf_write, METH_VARARGS, NULL},
	 { "rmf_writeMatrix", _wrap_rmf_writeMatrix, METH_VARARGS, NULL},
	 { "rmf_writeChannelBounds", _wrap_rmf_writeChannelBounds, METH_VARARGS, NULL},
	 { "rmf___imul__", _wrap_rmf___imul__, METH_VARARGS, NULL},
	 { "rmf___iadd__", _wrap_rmf___iadd__, METH_VARARGS, NULL},
	 { "rmf_checkCompatibility", _wrap_rmf_checkCompatibility, METH_VARARGS, NULL},
	 { "rmf_convertUnits", _wrap_rmf_convertUnits, METH_O, NULL},
	 { "rmf_reverseRows", _wrap_rmf_reverseRows, METH_O, NULL},
	 { "rmf_addRow", _wrap_rmf_addRow, METH_VARARGS, NULL},
	 { "rmf_substituteRow", _wrap_rmf_substituteRow, METH_VARARGS, NULL},
	 { "rmf_multiplyByModel", _wrap_rmf_multiplyByModel, METH_VARARGS, NULL},
	 { "rmf_estimatedFWHM", _wrap_rmf_estimatedFWHM, METH_O, NULL},
	 { "rmf_estimatedFWHMperChannel", _wrap_rmf_estimatedFWHMperChannel, METH_O, NULL},
	 { "rmf_NumberChannels", _wrap_rmf_NumberChannels, METH_O, NULL},
	 { "rmf_getNumberChannels", _wrap_rmf_getNumberChannels, METH_O, NULL},
	 { "rmf_NumberEnergyBins", _wrap_rmf_NumberEnergyBins, METH_O, NULL},
	 { "rmf_getNumberEnergyBins", _wrap_rmf_getNumberEnergyBins, METH_O, NULL},
	 { "rmf_NumberTotalGroups", _wrap_rmf_NumberTotalGroups, METH_O, NULL},
	 { "rmf_getNumberTotalGroups", _wrap_rmf_getNumberTotalGroups, METH_O, NULL},
	 { "rmf_NumberTotalElements", _wrap_rmf_NumberTotalElements, METH_O, NULL},
	 { "rmf_getNumberTotalElements", _wrap_rmf_getNumberTotalElements, METH_O, NULL},
	 { "rmf_getFirstChannel", _wrap_rmf_getFirstChannel, METH_O, NULL},
	 { "rmf_setFirstChannel", _wrap_rmf_setFirstChannel, METH_VARARGS, NULL},
	 { "rmf_getNumberGroups", _wrap_rmf_getNumberGroups, METH_O, NULL},
	 { "rmf_setNumberGroups", _wrap_rmf_setNumberGroups, METH_VARARGS, NULL},
	 { "rmf_getNumberGroupsForEnergyBin", _wrap_rmf_getNumberGroupsForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_setNumberGroupsForEnergyBin", _wrap_rmf_setNumberGroupsForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_getFirstChannelGroup", _wrap_rmf_getFirstChannelGroup, METH_O, NULL},
	 { "rmf_setFirstChannelGroup", _wrap_rmf_setFirstChannelGroup, METH_VARARGS, NULL},
	 { "rmf_getFirstChannelGroupForEnergyBin", _wrap_rmf_getFirstChannelGroupForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_setFirstChannelGroupForEnergyBin", _wrap_rmf_setFirstChannelGroupForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_getNumberChannelsGroup", _wrap_rmf_getNumberChannelsGroup, METH_O, NULL},
	 { "rmf_setNumberChannelsGroup", _wrap_rmf_setNumberChannelsGroup, METH_VARARGS, NULL},
	 { "rmf_getNumberChannelsGroupForEnergyBin", _wrap_rmf_getNumberChannelsGroupForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_setNumberChannelsGroupForEnergyBin", _wrap_rmf_setNumberChannelsGroupForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_getOrderGroup", _wrap_rmf_getOrderGroup, METH_O, NULL},
	 { "rmf_setOrderGroup", _wrap_rmf_setOrderGroup, METH_VARARGS, NULL},
	 { "rmf_getOrderGroupForEnergyBin", _wrap_rmf_getOrderGroupForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_setOrderGroupForEnergyBin", _wrap_rmf_setOrderGroupForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_getLowEnergy", _wrap_rmf_getLowEnergy, METH_O, NULL},
	 { "rmf_setLowEnergy", _wrap_rmf_setLowEnergy, METH_VARARGS, NULL},
	 { "rmf_getLowEnergyElement", _wrap_rmf_getLowEnergyElement, METH_VARARGS, NULL},
	 { "rmf_setLowEnergyElement", _wrap_rmf_setLowEnergyElement, METH_VARARGS, NULL},
	 { "rmf_getHighEnergy", _wrap_rmf_getHighEnergy, METH_O, NULL},
	 { "rmf_setHighEnergy", _wrap_rmf_setHighEnergy, METH_VARARGS, NULL},
	 { "rmf_getHighEnergyElement", _wrap_rmf_getHighEnergyElement, METH_VARARGS, NULL},
	 { "rmf_setHighEnergyElement", _wrap_rmf_setHighEnergyElement, METH_VARARGS, NULL},
	 { "rmf_getMatrix", _wrap_rmf_getMatrix, METH_O, NULL},
	 { "rmf_setMatrix", _wrap_rmf_setMatrix, METH_VARARGS, NULL},
	 { "rmf_getMatrixForEnergyBin", _wrap_rmf_getMatrixForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_setMatrixForEnergyBin", _wrap_rmf_setMatrixForEnergyBin, METH_VARARGS, NULL},
	 { "rmf_getChannelLowEnergy", _wrap_rmf_getChannelLowEnergy, METH_O, NULL},
	 { "rmf_setChannelLowEnergy", _wrap_rmf_setChannelLowEnergy, METH_VARARGS, NULL},
	 { "rmf_getChannelLowEnergyElement", _wrap_rmf_getChannelLowEnergyElement, METH_VARARGS, NULL},
	 { "rmf_setChannelLowEnergyElement", _wrap_rmf_setChannelLowEnergyElement, METH_VARARGS, NULL},
	 { "rmf_getChannelHighEnergy", _wrap_rmf_getChannelHighEnergy, METH_O, NULL},
	 { "rmf_setChannelHighEnergy", _wrap_rmf_setChannelHighEnergy, METH_VARARGS, NULL},
	 { "rmf_getChannelHighEnergyElement", _wrap_rmf_getChannelHighEnergyElement, METH_VARARGS, NULL},
	 { "rmf_setChannelHighEnergyElement", _wrap_rmf_setChannelHighEnergyElement, METH_VARARGS, NULL},
	 { "rmf_getAreaScaling", _wrap_rmf_getAreaScaling, METH_O, NULL},
	 { "rmf_setAreaScaling", _wrap_rmf_setAreaScaling, METH_VARARGS, NULL},
	 { "rmf_getResponseThreshold", _wrap_rmf_getResponseThreshold, METH_O, NULL},
	 { "rmf_setResponseThreshold", _wrap_rmf_setResponseThreshold, METH_VARARGS, NULL},
	 { "rmf_getEnergyUnits", _wrap_rmf_getEnergyUnits, METH_O, NULL},
	 { "rmf_setEnergyUnits", _wrap_rmf_setEnergyUnits, METH_VARARGS, NULL},
	 { "rmf_getRMFUnits", _wrap_rmf_getRMFUnits, METH_O, NULL},
	 { "rmf_setRMFUnits", _wrap_rmf_setRMFUnits, METH_VARARGS, NULL},
	 { "rmf_getChannelType", _wrap_rmf_getChannelType, METH_O, NULL},
	 { "rmf_setChannelType", _wrap_rmf_setChannelType, METH_VARARGS, NULL},
	 { "rmf_getTelescope", _wrap_rmf_getTelescope, METH_O, NULL},
	 { "rmf_setTelescope", _wrap_rmf_setTelescope, METH_VARARGS, NULL},
	 { "rmf_getInstrument", _wrap_rmf_getInstrument, METH_O, NULL},
	 { "rmf_setInstrument", _wrap_rmf_setInstrument, METH_VARARGS, NULL},
	 { "rmf_getDetector", _wrap_rmf_getDetector, METH_O, NULL},
	 { "rmf_setDetector", _wrap_rmf_setDetector, METH_VARARGS, NULL},
	 { "rmf_getFilter", _wrap_rmf_getFilter, METH_O, NULL},
	 { "rmf_setFilter", _wrap_rmf_setFilter, METH_VARARGS, NULL},
	 { "rmf_getRMFType", _wrap_rmf_getRMFType, METH_O, NULL},
	 { "rmf_setRMFType", _wrap_rmf_setRMFType, METH_VARARGS, NULL},
	 { "rmf_getRMFExtensionName", _wrap_rmf_getRMFExtensionName, METH_O, NULL},
	 { "rmf_setRMFExtensionName", _wrap_rmf_setRMFExtensionName, METH_VARARGS, NULL},
	 { "rmf_getEBDExtensionName", _wrap_rmf_getEBDExtensionName, METH_O, NULL},
	 { "rmf_setEBDExtensionName", _wrap_rmf_setEBDExtensionName, METH_VARARGS, NULL},
	 { "rmf_getStokesParameter", _wrap_rmf_getStokesParameter, METH_O, NULL},
	 { "rmf_setStokesParameter", _wrap_rmf_setStokesParameter, METH_VARARGS, NULL},
	 { "rmf_getStokesWeighting", _wrap_rmf_getStokesWeighting, METH_O, NULL},
	 { "rmf_setStokesWeighting", _wrap_rmf_setStokesWeighting, METH_VARARGS, NULL},
	 { "rmf_swigregister", rmf_swigregister, METH_O, NULL},
	 { "rmf_swiginit", rmf_swiginit, METH_VARARGS, NULL},
	 { "RMFeboundsExtensions", _wrap_RMFeboundsExtensions, METH_VARARGS, NULL},
	 { "RMFmatrixExtensions", _wrap_RMFmatrixExtensions, METH_VARARGS, NULL},
	 { "calcGaussResp", _wrap_calcGaussResp, METH_VARARGS, NULL},
	 { "binarySearch", _wrap_binarySearch, METH_VARARGS, NULL},
	 { "new_rmft", _wrap_new_rmft, METH_NOARGS, NULL},
	 { "delete_rmft", _wrap_delete_rmft, METH_O, NULL},
	 { "rmft_load", _wrap_rmft_load, METH_VARARGS, NULL},
	 { "rmft_ElementValue", _wrap_rmft_ElementValue, METH_VARARGS, NULL},
	 { "rmft_RowValues", _wrap_rmft_RowValues, METH_VARARGS, NULL},
	 { "rmft_disp", _wrap_rmft_disp, METH_O, NULL},
	 { "rmft_clear", _wrap_rmft_clear, METH_O, NULL},
	 { "rmft_NumberChannels", _wrap_rmft_NumberChannels, METH_O, NULL},
	 { "rmft_getNumberChannels", _wrap_rmft_getNumberChannels, METH_O, NULL},
	 { "rmft_NumberEnergyBins", _wrap_rmft_NumberEnergyBins, METH_O, NULL},
	 { "rmft_getNumberEnergyBins", _wrap_rmft_getNumberEnergyBins, METH_O, NULL},
	 { "rmft_NumberTotalGroups", _wrap_rmft_NumberTotalGroups, METH_O, NULL},
	 { "rmft_getNumberTotalGroups", _wrap_rmft_getNumberTotalGroups, METH_O, NULL},
	 { "rmft_NumberTotalElements", _wrap_rmft_NumberTotalElements, METH_O, NULL},
	 { "rmft_getNumberTotalElements", _wrap_rmft_getNumberTotalElements, METH_O, NULL},
	 { "rmft_getFirstChannel", _wrap_rmft_getFirstChannel, METH_O, NULL},
	 { "rmft_setFirstChannel", _wrap_rmft_setFirstChannel, METH_VARARGS, NULL},
	 { "rmft_getNumberGroups", _wrap_rmft_getNumberGroups, METH_O, NULL},
	 { "rmft_setNumberGroups", _wrap_rmft_setNumberGroups, METH_VARARGS, NULL},
	 { "rmft_getNumberGroupsForChannel", _wrap_rmft_getNumberGroupsForChannel, METH_VARARGS, NULL},
	 { "rmft_setNumberGroupsForChannel", _wrap_rmft_setNumberGroupsForChannel, METH_VARARGS, NULL},
	 { "rmft_getFirstEnergyGroup", _wrap_rmft_getFirstEnergyGroup, METH_O, NULL},
	 { "rmft_setFirstEnergyGroup", _wrap_rmft_setFirstEnergyGroup, METH_VARARGS, NULL},
	 { "rmft_getFirstEnergyGroupForChannel", _wrap_rmft_getFirstEnergyGroupForChannel, METH_VARARGS, NULL},
	 { "rmft_setFirstEnergyGroupForChannel", _wrap_rmft_setFirstEnergyGroupForChannel, METH_VARARGS, NULL},
	 { "rmft_getNumberEnergiesGroup", _wrap_rmft_getNumberEnergiesGroup, METH_O, NULL},
	 { "rmft_setNumberEnergiesGroup", _wrap_rmft_setNumberEnergiesGroup, METH_VARARGS, NULL},
	 { "rmft_getNumberEnergiesGroupForChannel", _wrap_rmft_getNumberEnergiesGroupForChannel, METH_VARARGS, NULL},
	 { "rmft_setNumberEnergiesGroupForChannel", _wrap_rmft_setNumberEnergiesGroupForChannel, METH_VARARGS, NULL},
	 { "rmft_getOrderGroup", _wrap_rmft_getOrderGroup, METH_O, NULL},
	 { "rmft_setOrderGroup", _wrap_rmft_setOrderGroup, METH_VARARGS, NULL},
	 { "rmft_getOrderGroupForChannel", _wrap_rmft_getOrderGroupForChannel, METH_VARARGS, NULL},
	 { "rmft_setOrderGroupForChannel", _wrap_rmft_setOrderGroupForChannel, METH_VARARGS, NULL},
	 { "rmft_getLowEnergy", _wrap_rmft_getLowEnergy, METH_O, NULL},
	 { "rmft_setLowEnergy", _wrap_rmft_setLowEnergy, METH_VARARGS, NULL},
	 { "rmft_getLowEnergyElement", _wrap_rmft_getLowEnergyElement, METH_VARARGS, NULL},
	 { "rmft_setLowEnergyElement", _wrap_rmft_setLowEnergyElement, METH_VARARGS, NULL},
	 { "rmft_getHighEnergy", _wrap_rmft_getHighEnergy, METH_O, NULL},
	 { "rmft_setHighEnergy", _wrap_rmft_setHighEnergy, METH_VARARGS, NULL},
	 { "rmft_getHighEnergyElement", _wrap_rmft_getHighEnergyElement, METH_VARARGS, NULL},
	 { "rmft_setHighEnergyElement", _wrap_rmft_setHighEnergyElement, METH_VARARGS, NULL},
	 { "rmft_getMatrix", _wrap_rmft_getMatrix, METH_O, NULL},
	 { "rmft_setMatrix", _wrap_rmft_setMatrix, METH_VARARGS, NULL},
	 { "rmft_getMatrixForChannel", _wrap_rmft_getMatrixForChannel, METH_VARARGS, NULL},
	 { "rmft_setMatrixForChannel", _wrap_rmft_setMatrixForChannel, METH_VARARGS, NULL},
	 { "rmft_getChannelLowEnergy", _wrap_rmft_getChannelLowEnergy, METH_O, NULL},
	 { "rmft_setChannelLowEnergy", _wrap_rmft_setChannelLowEnergy, METH_VARARGS, NULL},
	 { "rmft_getChannelLowEnergyElement", _wrap_rmft_getChannelLowEnergyElement, METH_VARARGS, NULL},
	 { "rmft_setChannelLowEnergyElement", _wrap_rmft_setChannelLowEnergyElement, METH_VARARGS, NULL},
	 { "rmft_getChannelHighEnergy", _wrap_rmft_getChannelHighEnergy, METH_O, NULL},
	 { "rmft_setChannelHighEnergy", _wrap_rmft_setChannelHighEnergy, METH_VARARGS, NULL},
	 { "rmft_getChannelHighEnergyElement", _wrap_rmft_getChannelHighEnergyElement, METH_VARARGS, NULL},
	 { "rmft_setChannelHighEnergyElement", _wrap_rmft_setChannelHighEnergyElement, METH_VARARGS, NULL},
	 { "rmft_getAreaScaling", _wrap_rmft_getAreaScaling, METH_O, NULL},
	 { "rmft_setAreaScaling", _wrap_rmft_setAreaScaling, METH_VARARGS, NULL},
	 { "rmft_getResponseThreshold", _wrap_rmft_getResponseThreshold, METH_O, NULL},
	 { "rmft_setResponseThreshold", _wrap_rmft_setResponseThreshold, METH_VARARGS, NULL},
	 { "rmft_getEnergyUnits", _wrap_rmft_getEnergyUnits, METH_O, NULL},
	 { "rmft_setEnergyUnits", _wrap_rmft_setEnergyUnits, METH_VARARGS, NULL},
	 { "rmft_getRMFUnits", _wrap_rmft_getRMFUnits, METH_O, NULL},
	 { "rmft_setRMFUnits", _wrap_rmft_setRMFUnits, METH_VARARGS, NULL},
	 { "rmft_getChannelType", _wrap_rmft_getChannelType, METH_O, NULL},
	 { "rmft_setChannelType", _wrap_rmft_setChannelType, METH_VARARGS, NULL},
	 { "rmft_getTelescope", _wrap_rmft_getTelescope, METH_O, NULL},
	 { "rmft_setTelescope", _wrap_rmft_setTelescope, METH_VARARGS, NULL},
	 { "rmft_getInstrument", _wrap_rmft_getInstrument, METH_O, NULL},
	 { "rmft_setInstrument", _wrap_rmft_setInstrument, METH_VARARGS, NULL},
	 { "rmft_getDetector", _wrap_rmft_getDetector, METH_O, NULL},
	 { "rmft_setDetector", _wrap_rmft_setDetector, METH_VARARGS, NULL},
	 { "rmft_getFilter", _wrap_rmft_getFilter, METH_O, NULL},
	 { "rmft_setFilter", _wrap_rmft_setFilter, METH_VARARGS, NULL},
	 { "rmft_getRMFType", _wrap_rmft_getRMFType, METH_O, NULL},
	 { "rmft_setRMFType", _wrap_rmft_setRMFType, METH_VARARGS, NULL},
	 { "rmft_getRMFExtensionName", _wrap_rmft_getRMFExtensionName, METH_O, NULL},
	 { "rmft_setRMFExtensionName", _wrap_rmft_setRMFExtensionName, METH_VARARGS, NULL},
	 { "rmft_getEBDExtensionName", _wrap_rmft_getEBDExtensionName, METH_O, NULL},
	 { "rmft_setEBDExtensionName", _wrap_rmft_setEBDExtensionName, METH_VARARGS, NULL},
	 { "rmft_swigregister", rmft_swigregister, METH_O, NULL},
	 { "rmft_swiginit", rmft_swiginit, METH_VARARGS, NULL},
	 { "new_arf", _wrap_new_arf, METH_VARARGS, NULL},
	 { "delete_arf", _wrap_delete_arf, METH_O, NULL},
	 { "arf_read", _wrap_arf_read, METH_VARARGS, NULL},
	 { "arf_copy", _wrap_arf_copy, METH_VARARGS, NULL},
	 { "arf_disp", _wrap_arf_disp, METH_O, NULL},
	 { "arf_clear", _wrap_arf_clear, METH_O, NULL},
	 { "arf_check", _wrap_arf_check, METH_O, NULL},
	 { "arf_rebin", _wrap_arf_rebin, METH_VARARGS, NULL},
	 { "arf_write", _wrap_arf_write, METH_VARARGS, NULL},
	 { "arf___imul__", _wrap_arf___imul__, METH_VARARGS, NULL},
	 { "arf___iadd__", _wrap_arf___iadd__, METH_VARARGS, NULL},
	 { "arf_checkCompatibility", _wrap_arf_checkCompatibility, METH_VARARGS, NULL},
	 { "arf_convertUnits", _wrap_arf_convertUnits, METH_O, NULL},
	 { "arf_NumberEnergyBins", _wrap_arf_NumberEnergyBins, METH_O, NULL},
	 { "arf_getNumberEnergyBins", _wrap_arf_getNumberEnergyBins, METH_O, NULL},
	 { "arf_getLowEnergy", _wrap_arf_getLowEnergy, METH_O, NULL},
	 { "arf_setLowEnergy", _wrap_arf_setLowEnergy, METH_VARARGS, NULL},
	 { "arf_getLowEnergyElement", _wrap_arf_getLowEnergyElement, METH_VARARGS, NULL},
	 { "arf_setLowEnergyElement", _wrap_arf_setLowEnergyElement, METH_VARARGS, NULL},
	 { "arf_getHighEnergy", _wrap_arf_getHighEnergy, METH_O, NULL},
	 { "arf_setHighEnergy", _wrap_arf_setHighEnergy, METH_VARARGS, NULL},
	 { "arf_getHighEnergyElement", _wrap_arf_getHighEnergyElement, METH_VARARGS, NULL},
	 { "arf_setHighEnergyElement", _wrap_arf_setHighEnergyElement, METH_VARARGS, NULL},
	 { "arf_getEffArea", _wrap_arf_getEffArea, METH_O, NULL},
	 { "arf_setEffArea", _wrap_arf_setEffArea, METH_VARARGS, NULL},
	 { "arf_getEffAreaElement", _wrap_arf_getEffAreaElement, METH_VARARGS, NULL},
	 { "arf_setEffAreaElement", _wrap_arf_setEffAreaElement, METH_VARARGS, NULL},
	 { "arf_getEnergyUnits", _wrap_arf_getEnergyUnits, METH_O, NULL},
	 { "arf_setEnergyUnits", _wrap_arf_setEnergyUnits, METH_VARARGS, NULL},
	 { "arf_getEffAreaUnits", _wrap_arf_getEffAreaUnits, METH_O, NULL},
	 { "arf_setEffAreaUnits", _wrap_arf_setEffAreaUnits, METH_VARARGS, NULL},
	 { "arf_getTelescope", _wrap_arf_getTelescope, METH_O, NULL},
	 { "arf_setTelescope", _wrap_arf_setTelescope, METH_VARARGS, NULL},
	 { "arf_getInstrument", _wrap_arf_getInstrument, METH_O, NULL},
	 { "arf_setInstrument", _wrap_arf_setInstrument, METH_VARARGS, NULL},
	 { "arf_getDetector", _wrap_arf_getDetector, METH_O, NULL},
	 { "arf_setDetector", _wrap_arf_setDetector, METH_VARARGS, NULL},
	 { "arf_getFilter", _wrap_arf_getFilter, METH_O, NULL},
	 { "arf_setFilter", _wrap_arf_setFilter, METH_VARARGS, NULL},
	 { "arf_getStokesParameter", _wrap_arf_getStokesParameter, METH_O, NULL},
	 { "arf_setStokesParameter", _wrap_arf_setStokesParameter, METH_VARARGS, NULL},
	 { "arf_getStokesWeighting", _wrap_arf_getStokesWeighting, METH_O, NULL},
	 { "arf_setStokesWeighting", _wrap_arf_setStokesWeighting, METH_VARARGS, NULL},
	 { "arf_getExtensionName", _wrap_arf_getExtensionName, METH_O, NULL},
	 { "arf_setExtensionName", _wrap_arf_setExtensionName, METH_VARARGS, NULL},
	 { "arf_swigregister", arf_swigregister, METH_O, NULL},
	 { "arf_swiginit", arf_swiginit, METH_VARARGS, NULL},
	 { "__add__", _wrap___add__, METH_VARARGS, NULL},
	 { "__mul__", _wrap___mul__, METH_VARARGS, NULL},
	 { "ARFspecrespExtensions", _wrap_ARFspecrespExtensions, METH_VARARGS, NULL},
	 { "ARFtype", _wrap_ARFtype, METH_VARARGS, NULL},
	 { "new_arfII", _wrap_new_arfII, METH_VARARGS, NULL},
	 { "delete_arfII", _wrap_delete_arfII, METH_O, NULL},
	 { "arfII_read", _wrap_arfII_read, METH_VARARGS, NULL},
	 { "arfII_copy", _wrap_arfII_copy, METH_VARARGS, NULL},
	 { "arfII_get", _wrap_arfII_get, METH_VARARGS, NULL},
	 { "arfII_push", _wrap_arfII_push, METH_VARARGS, NULL},
	 { "arfII_disp", _wrap_arfII_disp, METH_O, NULL},
	 { "arfII_clear", _wrap_arfII_clear, METH_O, NULL},
	 { "arfII_check", _wrap_arfII_check, METH_O, NULL},
	 { "arfII_write", _wrap_arfII_write, METH_VARARGS, NULL},
	 { "arfII_NumberARFs", _wrap_arfII_NumberARFs, METH_O, NULL},
	 { "arfII_getNumberARFs", _wrap_arfII_getNumberARFs, METH_O, NULL},
	 { "arfII_getarfs", _wrap_arfII_getarfs, METH_O, NULL},
	 { "arfII_setarfs", _wrap_arfII_setarfs, METH_VARARGS, NULL},
	 { "arfII_getarfsElement", _wrap_arfII_getarfsElement, METH_VARARGS, NULL},
	 { "arfII_setarfsElement", _wrap_arfII_setarfsElement, METH_VARARGS, NULL},
	 { "arfII_swigregister", arfII_swigregister, METH_O, NULL},
	 { "arfII_swiginit", arfII_swiginit, METH_VARARGS, NULL},
	 { "NumberofARFs", _wrap_NumberofARFs, METH_VARARGS, NULL},
	 { "new_grouping", _wrap_new_grouping, METH_VARARGS, NULL},
	 { "delete_grouping", _wrap_delete_grouping, METH_O, NULL},
	 { "grouping_disp", _wrap_grouping_disp, METH_O, NULL},
	 { "grouping_clear", _wrap_grouping_clear, METH_O, NULL},
	 { "grouping_read", _wrap_grouping_read, METH_VARARGS, NULL},
	 { "grouping_load", _wrap_grouping_load, METH_VARARGS, NULL},
	 { "grouping_loadFromVector", _wrap_grouping_loadFromVector, METH_VARARGS, NULL},
	 { "grouping_loadOptimal", _wrap_grouping_loadOptimal, METH_VARARGS, NULL},
	 { "grouping_loadOptimalEnergy", _wrap_grouping_loadOptimalEnergy, METH_VARARGS, NULL},
	 { "grouping_newBin", _wrap_grouping_newBin, METH_VARARGS, NULL},
	 { "grouping_inBin", _wrap_grouping_inBin, METH_VARARGS, NULL},
	 { "grouping_size", _wrap_grouping_size, METH_O, NULL},
	 { "grouping_getGroupingFlag", _wrap_grouping_getGroupingFlag, METH_O, NULL},
	 { "grouping_setGroupingFlag", _wrap_grouping_setGroupingFlag, METH_VARARGS, NULL},
	 { "grouping_getGroupingFlagElement", _wrap_grouping_getGroupingFlagElement, METH_VARARGS, NULL},
	 { "grouping_setGroupingFlagElement", _wrap_grouping_setGroupingFlagElement, METH_VARARGS, NULL},
	 { "grouping_getQualityFlag", _wrap_grouping_getQualityFlag, METH_O, NULL},
	 { "grouping_setQualityFlag", _wrap_grouping_setQualityFlag, METH_VARARGS, NULL},
	 { "grouping_getQualityFlagElement", _wrap_grouping_getQualityFlagElement, METH_VARARGS, NULL},
	 { "grouping_setQualityFlagElement", _wrap_grouping_setQualityFlagElement, METH_VARARGS, NULL},
	 { "grouping_swigregister", grouping_swigregister, METH_O, NULL},
	 { "grouping_swiginit", grouping_swiginit, METH_VARARGS, NULL},
	 { "ReadBinFactors", _wrap_ReadBinFactors, METH_VARARGS, NULL},
	 { "new_tableParameter", _wrap_new_tableParameter, METH_VARARGS, NULL},
	 { "tableParameter_load", _wrap_tableParameter_load, METH_VARARGS, NULL},
	 { "tableParameter_disp", _wrap_tableParameter_disp, METH_O, NULL},
	 { "tableParameter_clear", _wrap_tableParameter_clear, METH_O, NULL},
	 { "tableParameter_NumberTabulatedValues", _wrap_tableParameter_NumberTabulatedValues, METH_O, NULL},
	 { "tableParameter_getNumberTabulatedValues", _wrap_tableParameter_getNumberTabulatedValues, METH_O, NULL},
	 { "tableParameter_getName", _wrap_tableParameter_getName, METH_O, NULL},
	 { "tableParameter_setName", _wrap_tableParameter_setName, METH_VARARGS, NULL},
	 { "tableParameter_getUnits", _wrap_tableParameter_getUnits, METH_O, NULL},
	 { "tableParameter_setUnits", _wrap_tableParameter_setUnits, METH_VARARGS, NULL},
	 { "tableParameter_getInterpolationMethod", _wrap_tableParameter_getInterpolationMethod, METH_O, NULL},
	 { "tableParameter_setInterpolationMethod", _wrap_tableParameter_setInterpolationMethod, METH_VARARGS, NULL},
	 { "tableParameter_getInitialValue", _wrap_tableParameter_getInitialValue, METH_O, NULL},
	 { "tableParameter_setInitialValue", _wrap_tableParameter_setInitialValue, METH_VARARGS, NULL},
	 { "tableParameter_getDelta", _wrap_tableParameter_getDelta, METH_O, NULL},
	 { "tableParameter_setDelta", _wrap_tableParameter_setDelta, METH_VARARGS, NULL},
	 { "tableParameter_getMinimum", _wrap_tableParameter_getMinimum, METH_O, NULL},
	 { "tableParameter_setMinimum", _wrap_tableParameter_setMinimum, METH_VARARGS, NULL},
	 { "tableParameter_getBottom", _wrap_tableParameter_getBottom, METH_O, NULL},
	 { "tableParameter_setBottom", _wrap_tableParameter_setBottom, METH_VARARGS, NULL},
	 { "tableParameter_getTop", _wrap_tableParameter_getTop, METH_O, NULL},
	 { "tableParameter_setTop", _wrap_tableParameter_setTop, METH_VARARGS, NULL},
	 { "tableParameter_getMaximum", _wrap_tableParameter_getMaximum, METH_O, NULL},
	 { "tableParameter_setMaximum", _wrap_tableParameter_setMaximum, METH_VARARGS, NULL},
	 { "tableParameter_getTabulatedValues", _wrap_tableParameter_getTabulatedValues, METH_O, NULL},
	 { "tableParameter_setTabulatedValues", _wrap_tableParameter_setTabulatedValues, METH_VARARGS, NULL},
	 { "tableParameter_getTabulatedValuesElement", _wrap_tableParameter_getTabulatedValuesElement, METH_VARARGS, NULL},
	 { "tableParameter_setTabulatedValuesElement", _wrap_tableParameter_setTabulatedValuesElement, METH_VARARGS, NULL},
	 { "delete_tableParameter", _wrap_delete_tableParameter, METH_O, NULL},
	 { "tableParameter_swigregister", tableParameter_swigregister, METH_O, NULL},
	 { "tableParameter_swiginit", tableParameter_swiginit, METH_VARARGS, NULL},
	 { "new_tableSpectrum", _wrap_new_tableSpectrum, METH_VARARGS, NULL},
	 { "tableSpectrum_load", _wrap_tableSpectrum_load, METH_VARARGS, NULL},
	 { "tableSpectrum_pushaddFlux", _wrap_tableSpectrum_pushaddFlux, METH_VARARGS, NULL},
	 { "tableSpectrum_disp", _wrap_tableSpectrum_disp, METH_O, NULL},
	 { "tableSpectrum_clear", _wrap_tableSpectrum_clear, METH_O, NULL},
	 { "tableSpectrum_NumberFluxes", _wrap_tableSpectrum_NumberFluxes, METH_O, NULL},
	 { "tableSpectrum_getNumberFluxes", _wrap_tableSpectrum_getNumberFluxes, METH_O, NULL},
	 { "tableSpectrum_NumberFluxErrors", _wrap_tableSpectrum_NumberFluxErrors, METH_O, NULL},
	 { "tableSpectrum_getNumberFluxErrors", _wrap_tableSpectrum_getNumberFluxErrors, METH_O, NULL},
	 { "tableSpectrum_NumberParameterValues", _wrap_tableSpectrum_NumberParameterValues, METH_O, NULL},
	 { "tableSpectrum_getNumberParameterValues", _wrap_tableSpectrum_getNumberParameterValues, METH_O, NULL},
	 { "tableSpectrum_NumberAdditiveParameters", _wrap_tableSpectrum_NumberAdditiveParameters, METH_O, NULL},
	 { "tableSpectrum_getNumberAdditiveParameters", _wrap_tableSpectrum_getNumberAdditiveParameters, METH_O, NULL},
	 { "tableSpectrum_NumberAdditiveFluxes", _wrap_tableSpectrum_NumberAdditiveFluxes, METH_VARARGS, NULL},
	 { "tableSpectrum_getNumberAdditiveFluxes", _wrap_tableSpectrum_getNumberAdditiveFluxes, METH_VARARGS, NULL},
	 { "tableSpectrum_NumberAdditiveFluxErrors", _wrap_tableSpectrum_NumberAdditiveFluxErrors, METH_VARARGS, NULL},
	 { "tableSpectrum_getNumberAdditiveFluxErrors", _wrap_tableSpectrum_getNumberAdditiveFluxErrors, METH_VARARGS, NULL},
	 { "tableSpectrum_getFlux", _wrap_tableSpectrum_getFlux, METH_O, NULL},
	 { "tableSpectrum_setFlux", _wrap_tableSpectrum_setFlux, METH_VARARGS, NULL},
	 { "tableSpectrum_getFluxElement", _wrap_tableSpectrum_getFluxElement, METH_VARARGS, NULL},
	 { "tableSpectrum_setFluxElement", _wrap_tableSpectrum_setFluxElement, METH_VARARGS, NULL},
	 { "tableSpectrum_getFluxError", _wrap_tableSpectrum_getFluxError, METH_O, NULL},
	 { "tableSpectrum_setFluxError", _wrap_tableSpectrum_setFluxError, METH_VARARGS, NULL},
	 { "tableSpectrum_getFluxErrorElement", _wrap_tableSpectrum_getFluxErrorElement, METH_VARARGS, NULL},
	 { "tableSpectrum_setFluxErrorElement", _wrap_tableSpectrum_setFluxErrorElement, METH_VARARGS, NULL},
	 { "tableSpectrum_getParameterValues", _wrap_tableSpectrum_getParameterValues, METH_O, NULL},
	 { "tableSpectrum_setParameterValues", _wrap_tableSpectrum_setParameterValues, METH_VARARGS, NULL},
	 { "tableSpectrum_getParameterValuesElement", _wrap_tableSpectrum_getParameterValuesElement, METH_VARARGS, NULL},
	 { "tableSpectrum_setParameterValuesElement", _wrap_tableSpectrum_setParameterValuesElement, METH_VARARGS, NULL},
	 { "tableSpectrum_getaddFlux", _wrap_tableSpectrum_getaddFlux, METH_O, NULL},
	 { "tableSpectrum_setaddFlux", _wrap_tableSpectrum_setaddFlux, METH_VARARGS, NULL},
	 { "tableSpectrum_getaddFluxElement", _wrap_tableSpectrum_getaddFluxElement, METH_VARARGS, NULL},
	 { "tableSpectrum_setaddFluxElement", _wrap_tableSpectrum_setaddFluxElement, METH_VARARGS, NULL},
	 { "tableSpectrum_getaddFluxElementElement", _wrap_tableSpectrum_getaddFluxElementElement, METH_VARARGS, NULL},
	 { "tableSpectrum_setaddFluxElementElement", _wrap_tableSpectrum_setaddFluxElementElement, METH_VARARGS, NULL},
	 { "tableSpectrum_getaddFluxError", _wrap_tableSpectrum_getaddFluxError, METH_O, NULL},
	 { "tableSpectrum_setaddFluxError", _wrap_tableSpectrum_setaddFluxError, METH_VARARGS, NULL},
	 { "tableSpectrum_getaddFluxErrorElement", _wrap_tableSpectrum_getaddFluxErrorElement, METH_VARARGS, NULL},
	 { "tableSpectrum_setaddFluxErrorElement", _wrap_tableSpectrum_setaddFluxErrorElement, METH_VARARGS, NULL},
	 { "tableSpectrum_getaddFluxErrorElementElement", _wrap_tableSpectrum_getaddFluxErrorElementElement, METH_VARARGS, NULL},
	 { "tableSpectrum_setaddFluxErrorElementElement", _wrap_tableSpectrum_setaddFluxErrorElementElement, METH_VARARGS, NULL},
	 { "delete_tableSpectrum", _wrap_delete_tableSpectrum, METH_O, NULL},
	 { "tableSpectrum_swigregister", tableSpectrum_swigregister, METH_O, NULL},
	 { "tableSpectrum_swiginit", tableSpectrum_swiginit, METH_VARARGS, NULL},
	 { "new_table", _wrap_new_table, METH_VARARGS, NULL},
	 { "table_load", _wrap_table_load, METH_VARARGS, NULL},
	 { "table_read", _wrap_table_read, METH_VARARGS, NULL},
	 { "table_pushParameter", _wrap_table_pushParameter, METH_VARARGS, NULL},
	 { "table_pushSpectrum", _wrap_table_pushSpectrum, METH_VARARGS, NULL},
	 { "table_getParameter", _wrap_table_getParameter, METH_VARARGS, NULL},
	 { "table_getSpectrum", _wrap_table_getSpectrum, METH_VARARGS, NULL},
	 { "table_copy", _wrap_table_copy, METH_VARARGS, NULL},
	 { "table_disp", _wrap_table_disp, METH_VARARGS, NULL},
	 { "table_clear", _wrap_table_clear, METH_O, NULL},
	 { "table_check", _wrap_table_check, METH_O, NULL},
	 { "table_convertUnits", _wrap_table_convertUnits, METH_O, NULL},
	 { "table_reverseRows", _wrap_table_reverseRows, METH_O, NULL},
	 { "table_write", _wrap_table_write, METH_VARARGS, NULL},
	 { "table_NumberParameters", _wrap_table_NumberParameters, METH_O, NULL},
	 { "table_getNumberParameters", _wrap_table_getNumberParameters, METH_O, NULL},
	 { "table_NumberSpectra", _wrap_table_NumberSpectra, METH_O, NULL},
	 { "table_getNumberSpectra", _wrap_table_getNumberSpectra, METH_O, NULL},
	 { "table_NumberEnergies", _wrap_table_NumberEnergies, METH_O, NULL},
	 { "table_getNumberEnergies", _wrap_table_getNumberEnergies, METH_O, NULL},
	 { "table_getParameters", _wrap_table_getParameters, METH_O, NULL},
	 { "table_setParameters", _wrap_table_setParameters, METH_VARARGS, NULL},
	 { "table_getParametersElement", _wrap_table_getParametersElement, METH_VARARGS, NULL},
	 { "table_setParametersElement", _wrap_table_setParametersElement, METH_VARARGS, NULL},
	 { "table_getSpectra", _wrap_table_getSpectra, METH_O, NULL},
	 { "table_setSpectra", _wrap_table_setSpectra, METH_VARARGS, NULL},
	 { "table_getSpectraElement", _wrap_table_getSpectraElement, METH_VARARGS, NULL},
	 { "table_setSpectraElement", _wrap_table_setSpectraElement, METH_VARARGS, NULL},
	 { "table_getModelName", _wrap_table_getModelName, METH_O, NULL},
	 { "table_setModelName", _wrap_table_setModelName, METH_VARARGS, NULL},
	 { "table_getModelUnits", _wrap_table_getModelUnits, METH_O, NULL},
	 { "table_setModelUnits", _wrap_table_setModelUnits, METH_VARARGS, NULL},
	 { "table_getNumIntParams", _wrap_table_getNumIntParams, METH_O, NULL},
	 { "table_setNumIntParams", _wrap_table_setNumIntParams, METH_VARARGS, NULL},
	 { "table_getNumAddParams", _wrap_table_getNumAddParams, METH_O, NULL},
	 { "table_setNumAddParams", _wrap_table_setNumAddParams, METH_VARARGS, NULL},
	 { "table_getisError", _wrap_table_getisError, METH_O, NULL},
	 { "table_setisError", _wrap_table_setisError, METH_VARARGS, NULL},
	 { "table_getisRedshift", _wrap_table_getisRedshift, METH_O, NULL},
	 { "table_setisRedshift", _wrap_table_setisRedshift, METH_VARARGS, NULL},
	 { "table_getisAdditive", _wrap_table_getisAdditive, METH_O, NULL},
	 { "table_setisAdditive", _wrap_table_setisAdditive, METH_VARARGS, NULL},
	 { "table_getisEscale", _wrap_table_getisEscale, METH_O, NULL},
	 { "table_setisEscale", _wrap_table_setisEscale, METH_VARARGS, NULL},
	 { "table_getEnergies", _wrap_table_getEnergies, METH_O, NULL},
	 { "table_setEnergies", _wrap_table_setEnergies, METH_VARARGS, NULL},
	 { "table_getEnergiesElement", _wrap_table_getEnergiesElement, METH_VARARGS, NULL},
	 { "table_setEnergiesElement", _wrap_table_setEnergiesElement, METH_VARARGS, NULL},
	 { "table_getEnergyUnits", _wrap_table_getEnergyUnits, METH_O, NULL},
	 { "table_setEnergyUnits", _wrap_table_setEnergyUnits, METH_VARARGS, NULL},
	 { "table_getLowEnergyLimit", _wrap_table_getLowEnergyLimit, METH_O, NULL},
	 { "table_setLowEnergyLimit", _wrap_table_setLowEnergyLimit, METH_VARARGS, NULL},
	 { "table_getHighEnergyLimit", _wrap_table_getHighEnergyLimit, METH_O, NULL},
	 { "table_setHighEnergyLimit", _wrap_table_setHighEnergyLimit, METH_VARARGS, NULL},
	 { "table_getFilename", _wrap_table_getFilename, METH_O, NULL},
	 { "table_setFilename", _wrap_table_setFilename, METH_VARARGS, NULL},
	 { "table_getFiltExps", _wrap_table_getFiltExps, METH_O, NULL},
	 { "table_setFiltExps", _wrap_table_setFiltExps, METH_VARARGS, NULL},
	 { "delete_table", _wrap_delete_table, METH_O, NULL},
	 { "table_swigregister", table_swigregister, METH_O, NULL},
	 { "table_swiginit", table_swiginit, METH_VARARGS, NULL},
	 { NULL, NULL, 0, NULL }
};


/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (BEGIN) -------- */

static swig_type_info _swigt__p_allocator_type = {"_p_allocator_type", "allocator_type *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_char = {"_p_char", "char *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_difference_type = {"_p_difference_type", "difference_type *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_double = {"_p_double", "Real *|double *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__arf = {"_p_heasp__arf", "heasp::arf *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__arfII = {"_p_heasp__arfII", "heasp::arfII *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__grouping = {"_p_heasp__grouping", "heasp::grouping *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__pha = {"_p_heasp__pha", "heasp::pha *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__phaII = {"_p_heasp__phaII", "heasp::phaII *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__rmf = {"_p_heasp__rmf", "heasp::rmf *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__rmft = {"_p_heasp__rmft", "heasp::rmft *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__table = {"_p_heasp__table", "heasp::table *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__tableParameter = {"_p_heasp__tableParameter", "heasp::tableParameter *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_heasp__tableSpectrum = {"_p_heasp__tableSpectrum", "heasp::tableSpectrum *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_int = {"_p_int", "Integer *|int *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_p_PyObject = {"_p_p_PyObject", "PyObject **", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_size_type = {"_p_size_type", "size_type *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__allocatorT_std__string_t = {"_p_std__allocatorT_std__string_t", "std::vector< std::string >::allocator_type *|std::allocator< std::string > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__invalid_argument = {"_p_std__invalid_argument", "std::invalid_argument *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__mapT_std__string_std__string_t = {"_p_std__mapT_std__string_std__string_t", "std::map< std::string,std::string > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__string = {"_p_std__string", "std::string *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__valarrayT_double_t = {"_p_std__valarrayT_double_t", "RealArray *|std::valarray< double > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__vectorT_double_std__allocatorT_double_t_t = {"_p_std__vectorT_double_std__allocatorT_double_t_t", "RealVector *|std::vector< double,std::allocator< double > > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__vectorT_heasp__arf_std__allocatorT_heasp__arf_t_t = {"_p_std__vectorT_heasp__arf_std__allocatorT_heasp__arf_t_t", "std::vector< heasp::arf,std::allocator< heasp::arf > > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__vectorT_heasp__pha_std__allocatorT_heasp__pha_t_t = {"_p_std__vectorT_heasp__pha_std__allocatorT_heasp__pha_t_t", "std::vector< heasp::pha,std::allocator< heasp::pha > > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t = {"_p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t", "std::vector< heasp::tableParameter,std::allocator< heasp::tableParameter > > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t = {"_p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t", "std::vector< heasp::tableSpectrum,std::allocator< heasp::tableSpectrum > > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__vectorT_int_std__allocatorT_int_t_t = {"_p_std__vectorT_int_std__allocatorT_int_t_t", "IntegerVector *|std::vector< int,std::allocator< int > > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__vectorT_std__string_std__allocatorT_std__string_t_t = {"_p_std__vectorT_std__string_std__allocatorT_std__string_t_t", "StringVector *|std::vector< std::string,std::allocator< std::string > > *|std::vector< std::string > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t = {"_p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t", "std::vector< RealVector,std::allocator< RealVector > > *|std::vector< std::vector< double,std::allocator< double > >,std::allocator< std::vector< double,std::allocator< double > > > > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t = {"_p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t", "std::vector< IntegerVector,std::allocator< IntegerVector > > *|std::vector< std::vector< int,std::allocator< int > >,std::allocator< std::vector< int,std::allocator< int > > > > *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_swig__SwigPyIterator = {"_p_swig__SwigPyIterator", "swig::SwigPyIterator *", 0, 0, (void*)0, 0};
static swig_type_info _swigt__p_value_type = {"_p_value_type", "value_type *", 0, 0, (void*)0, 0};

static swig_type_info *swig_type_initial[] = {
  &_swigt__p_allocator_type,
  &_swigt__p_char,
  &_swigt__p_difference_type,
  &_swigt__p_double,
  &_swigt__p_heasp__arf,
  &_swigt__p_heasp__arfII,
  &_swigt__p_heasp__grouping,
  &_swigt__p_heasp__pha,
  &_swigt__p_heasp__phaII,
  &_swigt__p_heasp__rmf,
  &_swigt__p_heasp__rmft,
  &_swigt__p_heasp__table,
  &_swigt__p_heasp__tableParameter,
  &_swigt__p_heasp__tableSpectrum,
  &_swigt__p_int,
  &_swigt__p_p_PyObject,
  &_swigt__p_size_type,
  &_swigt__p_std__allocatorT_std__string_t,
  &_swigt__p_std__invalid_argument,
  &_swigt__p_std__mapT_std__string_std__string_t,
  &_swigt__p_std__string,
  &_swigt__p_std__valarrayT_double_t,
  &_swigt__p_std__vectorT_double_std__allocatorT_double_t_t,
  &_swigt__p_std__vectorT_heasp__arf_std__allocatorT_heasp__arf_t_t,
  &_swigt__p_std__vectorT_heasp__pha_std__allocatorT_heasp__pha_t_t,
  &_swigt__p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,
  &_swigt__p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t,
  &_swigt__p_std__vectorT_int_std__allocatorT_int_t_t,
  &_swigt__p_std__vectorT_std__string_std__allocatorT_std__string_t_t,
  &_swigt__p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,
  &_swigt__p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,
  &_swigt__p_swig__SwigPyIterator,
  &_swigt__p_value_type,
};

static swig_cast_info _swigc__p_allocator_type[] = {  {&_swigt__p_allocator_type, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_char[] = {  {&_swigt__p_char, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_difference_type[] = {  {&_swigt__p_difference_type, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_double[] = {  {&_swigt__p_double, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__arf[] = {  {&_swigt__p_heasp__arf, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__arfII[] = {  {&_swigt__p_heasp__arfII, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__grouping[] = {  {&_swigt__p_heasp__grouping, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__pha[] = {  {&_swigt__p_heasp__pha, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__phaII[] = {  {&_swigt__p_heasp__phaII, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__rmf[] = {  {&_swigt__p_heasp__rmf, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__rmft[] = {  {&_swigt__p_heasp__rmft, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__table[] = {  {&_swigt__p_heasp__table, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__tableParameter[] = {  {&_swigt__p_heasp__tableParameter, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_heasp__tableSpectrum[] = {  {&_swigt__p_heasp__tableSpectrum, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_int[] = {  {&_swigt__p_int, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_p_PyObject[] = {  {&_swigt__p_p_PyObject, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_size_type[] = {  {&_swigt__p_size_type, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__allocatorT_std__string_t[] = {  {&_swigt__p_std__allocatorT_std__string_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__invalid_argument[] = {  {&_swigt__p_std__invalid_argument, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__mapT_std__string_std__string_t[] = {  {&_swigt__p_std__mapT_std__string_std__string_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__string[] = {  {&_swigt__p_std__string, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__valarrayT_double_t[] = {  {&_swigt__p_std__valarrayT_double_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__vectorT_double_std__allocatorT_double_t_t[] = {  {&_swigt__p_std__vectorT_double_std__allocatorT_double_t_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__vectorT_heasp__arf_std__allocatorT_heasp__arf_t_t[] = {  {&_swigt__p_std__vectorT_heasp__arf_std__allocatorT_heasp__arf_t_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__vectorT_heasp__pha_std__allocatorT_heasp__pha_t_t[] = {  {&_swigt__p_std__vectorT_heasp__pha_std__allocatorT_heasp__pha_t_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t[] = {  {&_swigt__p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t[] = {  {&_swigt__p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__vectorT_int_std__allocatorT_int_t_t[] = {  {&_swigt__p_std__vectorT_int_std__allocatorT_int_t_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__vectorT_std__string_std__allocatorT_std__string_t_t[] = {  {&_swigt__p_std__vectorT_std__string_std__allocatorT_std__string_t_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t[] = {  {&_swigt__p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t[] = {  {&_swigt__p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_swig__SwigPyIterator[] = {  {&_swigt__p_swig__SwigPyIterator, 0, 0, 0},{0, 0, 0, 0}};
static swig_cast_info _swigc__p_value_type[] = {  {&_swigt__p_value_type, 0, 0, 0},{0, 0, 0, 0}};

static swig_cast_info *swig_cast_initial[] = {
  _swigc__p_allocator_type,
  _swigc__p_char,
  _swigc__p_difference_type,
  _swigc__p_double,
  _swigc__p_heasp__arf,
  _swigc__p_heasp__arfII,
  _swigc__p_heasp__grouping,
  _swigc__p_heasp__pha,
  _swigc__p_heasp__phaII,
  _swigc__p_heasp__rmf,
  _swigc__p_heasp__rmft,
  _swigc__p_heasp__table,
  _swigc__p_heasp__tableParameter,
  _swigc__p_heasp__tableSpectrum,
  _swigc__p_int,
  _swigc__p_p_PyObject,
  _swigc__p_size_type,
  _swigc__p_std__allocatorT_std__string_t,
  _swigc__p_std__invalid_argument,
  _swigc__p_std__mapT_std__string_std__string_t,
  _swigc__p_std__string,
  _swigc__p_std__valarrayT_double_t,
  _swigc__p_std__vectorT_double_std__allocatorT_double_t_t,
  _swigc__p_std__vectorT_heasp__arf_std__allocatorT_heasp__arf_t_t,
  _swigc__p_std__vectorT_heasp__pha_std__allocatorT_heasp__pha_t_t,
  _swigc__p_std__vectorT_heasp__tableParameter_std__allocatorT_heasp__tableParameter_t_t,
  _swigc__p_std__vectorT_heasp__tableSpectrum_std__allocatorT_heasp__tableSpectrum_t_t,
  _swigc__p_std__vectorT_int_std__allocatorT_int_t_t,
  _swigc__p_std__vectorT_std__string_std__allocatorT_std__string_t_t,
  _swigc__p_std__vectorT_std__vectorT_double_std__allocatorT_double_t_t_std__allocatorT_std__vectorT_double_std__allocatorT_double_t_t_t_t,
  _swigc__p_std__vectorT_std__vectorT_int_std__allocatorT_int_t_t_std__allocatorT_std__vectorT_int_std__allocatorT_int_t_t_t_t,
  _swigc__p_swig__SwigPyIterator,
  _swigc__p_value_type,
};


/* -------- TYPE CONVERSION AND EQUIVALENCE RULES (END) -------- */

static swig_const_info swig_const_table[] = {
{0, 0, 0, 0.0, 0, 0}};

#ifdef __cplusplus
}
#endif
/* -----------------------------------------------------------------------------
 * Type initialization:
 * This problem is tough by the requirement that no dynamic
 * memory is used. Also, since swig_type_info structures store pointers to
 * swig_cast_info structures and swig_cast_info structures store pointers back
 * to swig_type_info structures, we need some lookup code at initialization.
 * The idea is that swig generates all the structures that are needed.
 * The runtime then collects these partially filled structures.
 * The SWIG_InitializeModule function takes these initial arrays out of
 * swig_module, and does all the lookup, filling in the swig_module.types
 * array with the correct data and linking the correct swig_cast_info
 * structures together.
 *
 * The generated swig_type_info structures are assigned statically to an initial
 * array. We just loop through that array, and handle each type individually.
 * First we lookup if this type has been already loaded, and if so, use the
 * loaded structure instead of the generated one. Then we have to fill in the
 * cast linked list. The cast data is initially stored in something like a
 * two-dimensional array. Each row corresponds to a type (there are the same
 * number of rows as there are in the swig_type_initial array). Each entry in
 * a column is one of the swig_cast_info structures for that type.
 * The cast_initial array is actually an array of arrays, because each row has
 * a variable number of columns. So to actually build the cast linked list,
 * we find the array of casts associated with the type, and loop through it
 * adding the casts to the list. The one last trick we need to do is making
 * sure the type pointer in the swig_cast_info struct is correct.
 *
 * First off, we lookup the cast->type name to see if it is already loaded.
 * There are three cases to handle:
 *  1) If the cast->type has already been loaded AND the type we are adding
 *     casting info to has not been loaded (it is in this module), THEN we
 *     replace the cast->type pointer with the type pointer that has already
 *     been loaded.
 *  2) If BOTH types (the one we are adding casting info to, and the
 *     cast->type) are loaded, THEN the cast info has already been loaded by
 *     the previous module so we just ignore it.
 *  3) Finally, if cast->type has not already been loaded, then we add that
 *     swig_cast_info to the linked list (because the cast->type) pointer will
 *     be correct.
 * ----------------------------------------------------------------------------- */

#ifdef __cplusplus
extern "C" {
#if 0
} /* c-mode */
#endif
#endif

#if 0
#define SWIGRUNTIME_DEBUG
#endif

#ifndef SWIG_INIT_CLIENT_DATA_TYPE
#define SWIG_INIT_CLIENT_DATA_TYPE void *
#endif

SWIGRUNTIME void
SWIG_InitializeModule(SWIG_INIT_CLIENT_DATA_TYPE clientdata) {
  size_t i;
  swig_module_info *module_head, *iter;
  int init;
  
  /* check to see if the circular list has been setup, if not, set it up */
  if (swig_module.next==0) {
    /* Initialize the swig_module */
    swig_module.type_initial = swig_type_initial;
    swig_module.cast_initial = swig_cast_initial;
    swig_module.next = &swig_module;
    init = 1;
  } else {
    init = 0;
  }
  
  /* Try and load any already created modules */
  module_head = SWIG_GetModule(clientdata);
  if (!module_head) {
    /* This is the first module loaded for this interpreter */
    /* so set the swig module into the interpreter */
    SWIG_SetModule(clientdata, &swig_module);
  } else {
    /* the interpreter has loaded a SWIG module, but has it loaded this one? */
    iter=module_head;
    do {
      if (iter==&swig_module) {
        /* Our module is already in the list, so there's nothing more to do. */
        return;
      }
      iter=iter->next;
    } while (iter!= module_head);
    
    /* otherwise we must add our module into the list */
    swig_module.next = module_head->next;
    module_head->next = &swig_module;
  }
  
  /* When multiple interpreters are used, a module could have already been initialized in
       a different interpreter, but not yet have a pointer in this interpreter.
       In this case, we do not want to continue adding types... everything should be
       set up already */
  if (init == 0) return;
  
  /* Now work on filling in swig_module.types */
#ifdef SWIGRUNTIME_DEBUG
  printf("SWIG_InitializeModule: size %lu\n", (unsigned long)swig_module.size);
#endif
  for (i = 0; i < swig_module.size; ++i) {
    swig_type_info *type = 0;
    swig_type_info *ret;
    swig_cast_info *cast;
    
#ifdef SWIGRUNTIME_DEBUG
    printf("SWIG_InitializeModule: type %lu %s\n", (unsigned long)i, swig_module.type_initial[i]->name);
#endif
    
    /* if there is another module already loaded */
    if (swig_module.next != &swig_module) {
      type = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, swig_module.type_initial[i]->name);
    }
    if (type) {
      /* Overwrite clientdata field */
#ifdef SWIGRUNTIME_DEBUG
      printf("SWIG_InitializeModule: found type %s\n", type->name);
#endif
      if (swig_module.type_initial[i]->clientdata) {
        type->clientdata = swig_module.type_initial[i]->clientdata;
#ifdef SWIGRUNTIME_DEBUG
        printf("SWIG_InitializeModule: found and overwrite type %s \n", type->name);
#endif
      }
    } else {
      type = swig_module.type_initial[i];
    }
    
    /* Insert casting types */
    cast = swig_module.cast_initial[i];
    while (cast->type) {
      /* Don't need to add information already in the list */
      ret = 0;
#ifdef SWIGRUNTIME_DEBUG
      printf("SWIG_InitializeModule: look cast %s\n", cast->type->name);
#endif
      if (swig_module.next != &swig_module) {
        ret = SWIG_MangledTypeQueryModule(swig_module.next, &swig_module, cast->type->name);
#ifdef SWIGRUNTIME_DEBUG
        if (ret) printf("SWIG_InitializeModule: found cast %s\n", ret->name);
#endif
      }
      if (ret) {
        if (type == swig_module.type_initial[i]) {
#ifdef SWIGRUNTIME_DEBUG
          printf("SWIG_InitializeModule: skip old type %s\n", ret->name);
#endif
          cast->type = ret;
          ret = 0;
        } else {
          /* Check for casting already in the list */
          swig_cast_info *ocast = SWIG_TypeCheck(ret->name, type);
#ifdef SWIGRUNTIME_DEBUG
          if (ocast) printf("SWIG_InitializeModule: skip old cast %s\n", ret->name);
#endif
          if (!ocast) ret = 0;
        }
      }
      
      if (!ret) {
#ifdef SWIGRUNTIME_DEBUG
        printf("SWIG_InitializeModule: adding cast %s\n", cast->type->name);
#endif
        if (type->cast) {
          type->cast->prev = cast;
          cast->next = type->cast;
        }
        type->cast = cast;
      }
      cast++;
    }
    /* Set entry in modules->types array equal to the type */
    swig_module.types[i] = type;
  }
  swig_module.types[i] = 0;
  
#ifdef SWIGRUNTIME_DEBUG
  printf("**** SWIG_InitializeModule: Cast List ******\n");
  for (i = 0; i < swig_module.size; ++i) {
    int j = 0;
    swig_cast_info *cast = swig_module.cast_initial[i];
    printf("SWIG_InitializeModule: type %lu %s\n", (unsigned long)i, swig_module.type_initial[i]->name);
    while (cast->type) {
      printf("SWIG_InitializeModule: cast type %s\n", cast->type->name);
      cast++;
      ++j;
    }
    printf("---- Total casts: %d\n",j);
  }
  printf("**** SWIG_InitializeModule: Cast List ******\n");
#endif
}

/* This function will propagate the clientdata field of type to
* any new swig_type_info structures that have been added into the list
* of equivalent types.  It is like calling
* SWIG_TypeClientData(type, clientdata) a second time.
*/
SWIGRUNTIME void
SWIG_PropagateClientData(void) {
  size_t i;
  swig_cast_info *equiv;
  static int init_run = 0;
  
  if (init_run) return;
  init_run = 1;
  
  for (i = 0; i < swig_module.size; i++) {
    if (swig_module.types[i]->clientdata) {
      equiv = swig_module.types[i]->cast;
      while (equiv) {
        if (!equiv->converter) {
          if (equiv->type && !equiv->type->clientdata)
          SWIG_TypeClientData(equiv->type, swig_module.types[i]->clientdata);
        }
        equiv = equiv->next;
      }
    }
  }
}

#ifdef __cplusplus
#if 0
{
  /* c-mode */
#endif
}
#endif



#ifdef __cplusplus
extern "C" {
#endif
  
  /* -----------------------------------------------------------------------------
   * constants/methods manipulation
   * ----------------------------------------------------------------------------- */
  
  /* Install Constants */
  SWIGINTERN void
  SWIG_Python_InstallConstants(PyObject *d, swig_const_info constants[]) {
    PyObject *obj = 0;
    size_t i;
    for (i = 0; constants[i].type; ++i) {
      switch(constants[i].type) {
      case SWIG_PY_POINTER:
        obj = SWIG_InternalNewPointerObj(constants[i].pvalue, *(constants[i]).ptype,0);
        break;
      case SWIG_PY_BINARY:
        obj = SWIG_NewPackedObj(constants[i].pvalue, constants[i].lvalue, *(constants[i].ptype));
        break;
      default:
        obj = 0;
        break;
      }
      if (obj) {
        PyDict_SetItemString(d, constants[i].name, obj);
        Py_DECREF(obj);
      }
    }
  }
  
  /* -----------------------------------------------------------------------------
   * Patch %callback methods' docstrings to hold the callback ptrs
   * -----------------------------------------------------------------------------*/
  
  SWIGINTERN void
  SWIG_Python_FixMethods(PyMethodDef *methods, const swig_const_info *const_table, swig_type_info **types, swig_type_info **types_initial) {
    size_t i;
    for (i = 0; methods[i].ml_name; ++i) {
      const char *c = methods[i].ml_doc;
      if (!c) continue;
      c = strstr(c, "swig_ptr: ");
      if (c) {
        int j;
        const swig_const_info *ci = 0;
        const char *name = c + 10;
        for (j = 0; const_table[j].type; ++j) {
          if (strncmp(const_table[j].name, name, 
              strlen(const_table[j].name)) == 0) {
            ci = &(const_table[j]);
            break;
          }
        }
        if (ci) {
          void *ptr = (ci->type == SWIG_PY_POINTER) ? ci->pvalue : 0;
          if (ptr) {
            size_t shift = (ci->ptype) - types;
            swig_type_info *ty = types_initial[shift];
            size_t ldoc = (c - methods[i].ml_doc);
            size_t lptr = strlen(ty->name)+2*sizeof(void*)+2;
            char *ndoc = (char*)malloc(ldoc + lptr + 10);
            if (ndoc) {
              char *buff = ndoc;
              memcpy(buff, methods[i].ml_doc, ldoc);
              buff += ldoc;
              memcpy(buff, "swig_ptr: ", 10);
              buff += 10;
              SWIG_PackVoidPtr(buff, ptr, ty->name, lptr);
              methods[i].ml_doc = ndoc;
            }
          }
        }
      }
    }
  } 
  
#ifdef __cplusplus
}
#endif




/* -----------------------------------------------------------------------------*
 *  Partial Init method
 * -----------------------------------------------------------------------------*/

#ifdef __cplusplus
extern "C"
#endif

SWIGEXPORT 
#if PY_VERSION_HEX >= 0x03000000
PyObject*
#else
void
#endif
SWIG_init(void) {
  PyObject *m, *d, *md, *globals;
  
#if PY_VERSION_HEX >= 0x03000000
  static struct PyModuleDef SWIG_module = {
    PyModuleDef_HEAD_INIT,
    SWIG_name,
    NULL,
    -1,
    SwigMethods,
    NULL,
    NULL,
    NULL,
    NULL
  };
#endif
  
#if defined(SWIGPYTHON_BUILTIN)
  static SwigPyClientData SwigPyObject_clientdata = {
    0, 0, 0, 0, 0, 0, 0
  };
  static PyGetSetDef this_getset_def = {
    (char *)"this", &SwigPyBuiltin_ThisClosure, NULL, NULL, NULL
  };
  static SwigPyGetSet thisown_getset_closure = {
    SwigPyObject_own,
    SwigPyObject_own
  };
  static PyGetSetDef thisown_getset_def = {
    (char *)"thisown", SwigPyBuiltin_GetterClosure, SwigPyBuiltin_SetterClosure, NULL, &thisown_getset_closure
  };
  PyTypeObject *builtin_pytype;
  int builtin_base_count;
  swig_type_info *builtin_basetype;
  PyObject *tuple;
  PyGetSetDescrObject *static_getset;
  PyTypeObject *metatype;
  PyTypeObject *swigpyobject;
  SwigPyClientData *cd;
  PyObject *public_interface, *public_symbol;
  PyObject *this_descr;
  PyObject *thisown_descr;
  PyObject *self = 0;
  int i;
  
  (void)builtin_pytype;
  (void)builtin_base_count;
  (void)builtin_basetype;
  (void)tuple;
  (void)static_getset;
  (void)self;
  
  /* Metaclass is used to implement static member variables */
  metatype = SwigPyObjectType();
  assert(metatype);
#endif
  
  (void)globals;
  
  /* Create singletons now to avoid potential deadlocks with multi-threaded usage after module initialization */
  SWIG_This();
  SWIG_Python_TypeCache();
  SwigPyPacked_type();
#ifndef SWIGPYTHON_BUILTIN
  SwigPyObject_type();
#endif
  
  /* Fix SwigMethods to carry the callback ptrs when needed */
  SWIG_Python_FixMethods(SwigMethods, swig_const_table, swig_types, swig_type_initial);
  
#if PY_VERSION_HEX >= 0x03000000
  m = PyModule_Create(&SWIG_module);
#else
  m = Py_InitModule(SWIG_name, SwigMethods);
#endif
  
  md = d = PyModule_GetDict(m);
  (void)md;
  
  SWIG_InitializeModule(0);
  
#ifdef SWIGPYTHON_BUILTIN
  swigpyobject = SwigPyObject_TypeOnce();
  
  SwigPyObject_stype = SWIG_MangledTypeQuery("_p_SwigPyObject");
  assert(SwigPyObject_stype);
  cd = (SwigPyClientData*) SwigPyObject_stype->clientdata;
  if (!cd) {
    SwigPyObject_stype->clientdata = &SwigPyObject_clientdata;
    SwigPyObject_clientdata.pytype = swigpyobject;
  } else if (swigpyobject->tp_basicsize != cd->pytype->tp_basicsize) {
    PyErr_SetString(PyExc_RuntimeError, "Import error: attempted to load two incompatible swig-generated modules.");
# if PY_VERSION_HEX >= 0x03000000
    return NULL;
# else
    return;
# endif
  }
  
  /* All objects have a 'this' attribute */
  this_descr = PyDescr_NewGetSet(SwigPyObject_type(), &this_getset_def);
  (void)this_descr;
  
  /* All objects have a 'thisown' attribute */
  thisown_descr = PyDescr_NewGetSet(SwigPyObject_type(), &thisown_getset_def);
  (void)thisown_descr;
  
  public_interface = PyList_New(0);
  public_symbol = 0;
  (void)public_symbol;
  
  PyDict_SetItemString(md, "__all__", public_interface);
  Py_DECREF(public_interface);
  for (i = 0; SwigMethods[i].ml_name != NULL; ++i)
  SwigPyBuiltin_AddPublicSymbol(public_interface, SwigMethods[i].ml_name);
  for (i = 0; swig_const_table[i].name != 0; ++i)
  SwigPyBuiltin_AddPublicSymbol(public_interface, swig_const_table[i].name);
#endif
  
  SWIG_InstallConstants(d,swig_const_table);
  
  SWIG_Python_SetConstant(d, "OK",SWIG_From_int(static_cast< int >(OK)));
  SWIG_Python_SetConstant(d, "NoSuchFile",SWIG_From_int(static_cast< int >(NoSuchFile)));
  SWIG_Python_SetConstant(d, "NoData",SWIG_From_int(static_cast< int >(NoData)));
  SWIG_Python_SetConstant(d, "NoChannelData",SWIG_From_int(static_cast< int >(NoChannelData)));
  SWIG_Python_SetConstant(d, "NoStatError",SWIG_From_int(static_cast< int >(NoStatError)));
  SWIG_Python_SetConstant(d, "CannotCreate",SWIG_From_int(static_cast< int >(CannotCreate)));
  SWIG_Python_SetConstant(d, "NoEnergLo",SWIG_From_int(static_cast< int >(NoEnergLo)));
  SWIG_Python_SetConstant(d, "NoEnergHi",SWIG_From_int(static_cast< int >(NoEnergHi)));
  SWIG_Python_SetConstant(d, "NoSpecresp",SWIG_From_int(static_cast< int >(NoSpecresp)));
  SWIG_Python_SetConstant(d, "NoEboundsExt",SWIG_From_int(static_cast< int >(NoEboundsExt)));
  SWIG_Python_SetConstant(d, "NoEmin",SWIG_From_int(static_cast< int >(NoEmin)));
  SWIG_Python_SetConstant(d, "NoEmax",SWIG_From_int(static_cast< int >(NoEmax)));
  SWIG_Python_SetConstant(d, "NoMatrixExt",SWIG_From_int(static_cast< int >(NoMatrixExt)));
  SWIG_Python_SetConstant(d, "NoNgrp",SWIG_From_int(static_cast< int >(NoNgrp)));
  SWIG_Python_SetConstant(d, "NoFchan",SWIG_From_int(static_cast< int >(NoFchan)));
  SWIG_Python_SetConstant(d, "NoNchan",SWIG_From_int(static_cast< int >(NoNchan)));
  SWIG_Python_SetConstant(d, "NoMatrix",SWIG_From_int(static_cast< int >(NoMatrix)));
  SWIG_Python_SetConstant(d, "CannotCreateMatrixExt",SWIG_From_int(static_cast< int >(CannotCreateMatrixExt)));
  SWIG_Python_SetConstant(d, "CannotCreateEboundsExt",SWIG_From_int(static_cast< int >(CannotCreateEboundsExt)));
  SWIG_Python_SetConstant(d, "InconsistentGrouping",SWIG_From_int(static_cast< int >(InconsistentGrouping)));
  SWIG_Python_SetConstant(d, "InconsistentEnergies",SWIG_From_int(static_cast< int >(InconsistentEnergies)));
  SWIG_Python_SetConstant(d, "InconsistentChannels",SWIG_From_int(static_cast< int >(InconsistentChannels)));
  SWIG_Python_SetConstant(d, "InconsistentUnits",SWIG_From_int(static_cast< int >(InconsistentUnits)));
  SWIG_Python_SetConstant(d, "UnknownXUnits",SWIG_From_int(static_cast< int >(UnknownXUnits)));
  SWIG_Python_SetConstant(d, "UnknownYUnits",SWIG_From_int(static_cast< int >(UnknownYUnits)));
  SWIG_Python_SetConstant(d, "InconsistentNumelt",SWIG_From_int(static_cast< int >(InconsistentNumelt)));
  SWIG_Python_SetConstant(d, "InconsistentNumgrp",SWIG_From_int(static_cast< int >(InconsistentNumgrp)));
  SWIG_Python_SetConstant(d, "InconsistentNumTableParams",SWIG_From_int(static_cast< int >(InconsistentNumTableParams)));
  SWIG_Python_SetConstant(d, "TableParamValueOutsideRange",SWIG_From_int(static_cast< int >(TableParamValueOutsideRange)));
  SWIG_Python_SetConstant(d, "VectorIndexOutsideRange",SWIG_From_int(static_cast< int >(VectorIndexOutsideRange)));
  SWIG_Python_SetConstant(d, "InconsistentKeywordValues",SWIG_From_int(static_cast< int >(InconsistentKeywordValues)));
  SWIG_Python_SetConstant(d, "CannotCopyColumn",SWIG_From_int(static_cast< int >(CannotCopyColumn)));
  SWIG_Python_SetConstant(d, "CannotWriteMatrix",SWIG_From_int(static_cast< int >(CannotWriteMatrix)));
  SWIG_Python_SetConstant(d, "InconsistentTableFilter",SWIG_From_int(static_cast< int >(InconsistentTableFilter)));
  SWIG_Python_SetConstant(d, "NoChannels",SWIG_From_int(static_cast< int >(NoChannels)));
  SWIG_Python_SetConstant(d, "InconsistentChannelMin",SWIG_From_int(static_cast< int >(InconsistentChannelMin)));
  SWIG_Python_SetConstant(d, "InconsistentFChan",SWIG_From_int(static_cast< int >(InconsistentFChan)));
  SWIG_Python_SetConstant(d, "InconsistentNChan",SWIG_From_int(static_cast< int >(InconsistentNChan)));
  globals = SWIG_globals();
  if (!globals) {
    PyErr_SetString(PyExc_TypeError, "Failure to create SWIG globals.");
#if PY_VERSION_HEX >= 0x03000000
    return NULL;
#else
    return;
#endif
  }
  PyDict_SetItemString(md, "cvar", globals);
  SWIG_addvarlink(globals, "SPerrorNames", Swig_var_SPerrorNames_get, Swig_var_SPerrorNames_set);
  SWIG_addvarlink(globals, "SPerrorStack", Swig_var_SPerrorStack_get, Swig_var_SPerrorStack_set);
  SWIG_addvarlink(globals, "FUZZY", Swig_var_FUZZY_get, Swig_var_FUZZY_set);
  SWIG_addvarlink(globals, "BlankStr", Swig_var_BlankStr_get, Swig_var_BlankStr_set);
  
  import_array();
  
  
  // thread safe initialization
  swig::container_owner_attribute();
  
  SWIG_Python_SetConstant(d, "HAVE_pha",SWIG_From_int(static_cast< int >(1)));
  SWIG_Python_SetConstant(d, "HAVE_phaII",SWIG_From_int(static_cast< int >(1)));
  SWIG_Python_SetConstant(d, "HAVE_rmf",SWIG_From_int(static_cast< int >(1)));
  SWIG_Python_SetConstant(d, "HAVE_rmft",SWIG_From_int(static_cast< int >(1)));
  SWIG_Python_SetConstant(d, "HAVE_arf",SWIG_From_int(static_cast< int >(1)));
  SWIG_Python_SetConstant(d, "HAVE_arfII",SWIG_From_int(static_cast< int >(1)));
  SWIG_Python_SetConstant(d, "HAVE_grouping",SWIG_From_int(static_cast< int >(1)));
  SWIG_Python_SetConstant(d, "SumMode",SWIG_From_int(static_cast< int >(heasp::SumMode)));
  SWIG_Python_SetConstant(d, "SumQuadMode",SWIG_From_int(static_cast< int >(heasp::SumQuadMode)));
  SWIG_Python_SetConstant(d, "MeanMode",SWIG_From_int(static_cast< int >(heasp::MeanMode)));
  SWIG_Python_SetConstant(d, "FirstEltMode",SWIG_From_int(static_cast< int >(heasp::FirstEltMode)));
  SWIG_Python_SetConstant(d, "LastEltMode",SWIG_From_int(static_cast< int >(heasp::LastEltMode)));
  SWIG_Python_SetConstant(d, "HAVE_table",SWIG_From_int(static_cast< int >(1)));
#if PY_VERSION_HEX >= 0x03000000
  return m;
#else
  return;
#endif
}

