3 #ifndef PY_SSIZE_T_CLEAN
4 #define PY_SSIZE_T_CLEAN
8 #error Python headers needed to compile C extensions, please install development version of Python.
9 #elif PY_VERSION_HEX < 0x02060000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03030000)
10 #error Cython requires Python 2.6+ or Python 3.3+.
12 #define CYTHON_ABI "0_29_30"
13 #define CYTHON_HEX_VERSION 0x001D1EF0
14 #define CYTHON_FUTURE_DIVISION 0
17 #define offsetof(type, member) ( (size_t) & ((type*)0) -> member )
19 #if !defined(WIN32) && !defined(MS_WINDOWS)
31 #define DL_IMPORT(t) t
34 #define DL_EXPORT(t) t
37 #ifndef HAVE_LONG_LONG
38 #if PY_VERSION_HEX >= 0x02070000
39 #define HAVE_LONG_LONG
43 #define PY_LONG_LONG LONG_LONG
46 #define Py_HUGE_VAL HUGE_VAL
49 #define CYTHON_COMPILING_IN_PYPY 1
50 #define CYTHON_COMPILING_IN_PYSTON 0
51 #define CYTHON_COMPILING_IN_CPYTHON 0
52 #undef CYTHON_USE_TYPE_SLOTS
53 #define CYTHON_USE_TYPE_SLOTS 0
54 #undef CYTHON_USE_PYTYPE_LOOKUP
55 #define CYTHON_USE_PYTYPE_LOOKUP 0
56 #if PY_VERSION_HEX < 0x03050000
57 #undef CYTHON_USE_ASYNC_SLOTS
58 #define CYTHON_USE_ASYNC_SLOTS 0
59 #elif !defined(CYTHON_USE_ASYNC_SLOTS)
60 #define CYTHON_USE_ASYNC_SLOTS 1
62 #undef CYTHON_USE_PYLIST_INTERNALS
63 #define CYTHON_USE_PYLIST_INTERNALS 0
64 #undef CYTHON_USE_UNICODE_INTERNALS
65 #define CYTHON_USE_UNICODE_INTERNALS 0
66 #undef CYTHON_USE_UNICODE_WRITER
67 #define CYTHON_USE_UNICODE_WRITER 0
68 #undef CYTHON_USE_PYLONG_INTERNALS
69 #define CYTHON_USE_PYLONG_INTERNALS 0
70 #undef CYTHON_AVOID_BORROWED_REFS
71 #define CYTHON_AVOID_BORROWED_REFS 1
72 #undef CYTHON_ASSUME_SAFE_MACROS
73 #define CYTHON_ASSUME_SAFE_MACROS 0
74 #undef CYTHON_UNPACK_METHODS
75 #define CYTHON_UNPACK_METHODS 0
76 #undef CYTHON_FAST_THREAD_STATE
77 #define CYTHON_FAST_THREAD_STATE 0
78 #undef CYTHON_FAST_PYCALL
79 #define CYTHON_FAST_PYCALL 0
80 #undef CYTHON_PEP489_MULTI_PHASE_INIT
81 #define CYTHON_PEP489_MULTI_PHASE_INIT 0
82 #undef CYTHON_USE_TP_FINALIZE
83 #define CYTHON_USE_TP_FINALIZE 0
84 #undef CYTHON_USE_DICT_VERSIONS
85 #define CYTHON_USE_DICT_VERSIONS 0
86 #undef CYTHON_USE_EXC_INFO_STACK
87 #define CYTHON_USE_EXC_INFO_STACK 0
88 #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
89 #define CYTHON_UPDATE_DESCRIPTOR_DOC (PYPY_VERSION_HEX >= 0x07030900)
91 #elif defined(PYSTON_VERSION)
92 #define CYTHON_COMPILING_IN_PYPY 0
93 #define CYTHON_COMPILING_IN_PYSTON 1
94 #define CYTHON_COMPILING_IN_CPYTHON 0
95 #ifndef CYTHON_USE_TYPE_SLOTS
96 #define CYTHON_USE_TYPE_SLOTS 1
98 #undef CYTHON_USE_PYTYPE_LOOKUP
99 #define CYTHON_USE_PYTYPE_LOOKUP 0
100 #undef CYTHON_USE_ASYNC_SLOTS
101 #define CYTHON_USE_ASYNC_SLOTS 0
102 #undef CYTHON_USE_PYLIST_INTERNALS
103 #define CYTHON_USE_PYLIST_INTERNALS 0
104 #ifndef CYTHON_USE_UNICODE_INTERNALS
105 #define CYTHON_USE_UNICODE_INTERNALS 1
107 #undef CYTHON_USE_UNICODE_WRITER
108 #define CYTHON_USE_UNICODE_WRITER 0
109 #undef CYTHON_USE_PYLONG_INTERNALS
110 #define CYTHON_USE_PYLONG_INTERNALS 0
111 #ifndef CYTHON_AVOID_BORROWED_REFS
112 #define CYTHON_AVOID_BORROWED_REFS 0
114 #ifndef CYTHON_ASSUME_SAFE_MACROS
115 #define CYTHON_ASSUME_SAFE_MACROS 1
117 #ifndef CYTHON_UNPACK_METHODS
118 #define CYTHON_UNPACK_METHODS 1
120 #undef CYTHON_FAST_THREAD_STATE
121 #define CYTHON_FAST_THREAD_STATE 0
122 #undef CYTHON_FAST_PYCALL
123 #define CYTHON_FAST_PYCALL 0
124 #undef CYTHON_PEP489_MULTI_PHASE_INIT
125 #define CYTHON_PEP489_MULTI_PHASE_INIT 0
126 #undef CYTHON_USE_TP_FINALIZE
127 #define CYTHON_USE_TP_FINALIZE 0
128 #undef CYTHON_USE_DICT_VERSIONS
129 #define CYTHON_USE_DICT_VERSIONS 0
130 #undef CYTHON_USE_EXC_INFO_STACK
131 #define CYTHON_USE_EXC_INFO_STACK 0
132 #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
133 #define CYTHON_UPDATE_DESCRIPTOR_DOC 0
136 #define CYTHON_COMPILING_IN_PYPY 0
137 #define CYTHON_COMPILING_IN_PYSTON 0
138 #define CYTHON_COMPILING_IN_CPYTHON 1
139 #ifndef CYTHON_USE_TYPE_SLOTS
140 #define CYTHON_USE_TYPE_SLOTS 1
142 #if PY_VERSION_HEX < 0x02070000
143 #undef CYTHON_USE_PYTYPE_LOOKUP
144 #define CYTHON_USE_PYTYPE_LOOKUP 0
145 #elif !defined(CYTHON_USE_PYTYPE_LOOKUP)
146 #define CYTHON_USE_PYTYPE_LOOKUP 1
148 #if PY_MAJOR_VERSION < 3
149 #undef CYTHON_USE_ASYNC_SLOTS
150 #define CYTHON_USE_ASYNC_SLOTS 0
151 #elif !defined(CYTHON_USE_ASYNC_SLOTS)
152 #define CYTHON_USE_ASYNC_SLOTS 1
154 #if PY_VERSION_HEX < 0x02070000
155 #undef CYTHON_USE_PYLONG_INTERNALS
156 #define CYTHON_USE_PYLONG_INTERNALS 0
157 #elif !defined(CYTHON_USE_PYLONG_INTERNALS)
158 #define CYTHON_USE_PYLONG_INTERNALS 1
160 #ifndef CYTHON_USE_PYLIST_INTERNALS
161 #define CYTHON_USE_PYLIST_INTERNALS 1
163 #ifndef CYTHON_USE_UNICODE_INTERNALS
164 #define CYTHON_USE_UNICODE_INTERNALS 1
166 #if PY_VERSION_HEX < 0x030300F0 || PY_VERSION_HEX >= 0x030B00A2
167 #undef CYTHON_USE_UNICODE_WRITER
168 #define CYTHON_USE_UNICODE_WRITER 0
169 #elif !defined(CYTHON_USE_UNICODE_WRITER)
170 #define CYTHON_USE_UNICODE_WRITER 1
172 #ifndef CYTHON_AVOID_BORROWED_REFS
173 #define CYTHON_AVOID_BORROWED_REFS 0
175 #ifndef CYTHON_ASSUME_SAFE_MACROS
176 #define CYTHON_ASSUME_SAFE_MACROS 1
178 #ifndef CYTHON_UNPACK_METHODS
179 #define CYTHON_UNPACK_METHODS 1
181 #if PY_VERSION_HEX >= 0x030B00A4
182 #undef CYTHON_FAST_THREAD_STATE
183 #define CYTHON_FAST_THREAD_STATE 0
184 #elif !defined(CYTHON_FAST_THREAD_STATE)
185 #define CYTHON_FAST_THREAD_STATE 1
187 #ifndef CYTHON_FAST_PYCALL
188 #define CYTHON_FAST_PYCALL (PY_VERSION_HEX < 0x030A0000)
190 #ifndef CYTHON_PEP489_MULTI_PHASE_INIT
191 #define CYTHON_PEP489_MULTI_PHASE_INIT (PY_VERSION_HEX >= 0x03050000)
193 #ifndef CYTHON_USE_TP_FINALIZE
194 #define CYTHON_USE_TP_FINALIZE (PY_VERSION_HEX >= 0x030400a1)
196 #ifndef CYTHON_USE_DICT_VERSIONS
197 #define CYTHON_USE_DICT_VERSIONS (PY_VERSION_HEX >= 0x030600B1)
199 #if PY_VERSION_HEX >= 0x030B00A4
200 #undef CYTHON_USE_EXC_INFO_STACK
201 #define CYTHON_USE_EXC_INFO_STACK 0
202 #elif !defined(CYTHON_USE_EXC_INFO_STACK)
203 #define CYTHON_USE_EXC_INFO_STACK (PY_VERSION_HEX >= 0x030700A3)
205 #ifndef CYTHON_UPDATE_DESCRIPTOR_DOC
206 #define CYTHON_UPDATE_DESCRIPTOR_DOC 1
209 #if !defined(CYTHON_FAST_PYCCALL)
210 #define CYTHON_FAST_PYCCALL (CYTHON_FAST_PYCALL && PY_VERSION_HEX >= 0x030600B1)
212 #if CYTHON_USE_PYLONG_INTERNALS
213 #if PY_MAJOR_VERSION < 3
214 #include "longintrepr.h"
220 enum { __pyx_check_sizeof_voidp = 1 / (int)(SIZEOF_VOID_P ==
sizeof(
void*)) };
223 #ifndef __has_attribute
224 #define __has_attribute(x) 0
226 #ifndef __has_cpp_attribute
227 #define __has_cpp_attribute(x) 0
229 #ifndef CYTHON_RESTRICT
230 #if defined(__GNUC__)
231 #define CYTHON_RESTRICT __restrict__
232 #elif defined(_MSC_VER) && _MSC_VER >= 1400
233 #define CYTHON_RESTRICT __restrict
234 #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
235 #define CYTHON_RESTRICT restrict
237 #define CYTHON_RESTRICT
240 #ifndef CYTHON_UNUSED
241 # if defined(__GNUC__)
242 # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
243 # define CYTHON_UNUSED __attribute__ ((__unused__))
245 # define CYTHON_UNUSED
247 # elif defined(__ICC) || (defined(__INTEL_COMPILER) && !defined(_MSC_VER))
248 # define CYTHON_UNUSED __attribute__ ((__unused__))
250 # define CYTHON_UNUSED
253 #ifndef CYTHON_MAYBE_UNUSED_VAR
254 # if defined(__cplusplus)
255 template<
class T>
void CYTHON_MAYBE_UNUSED_VAR(
const T& ) { }
257 # define CYTHON_MAYBE_UNUSED_VAR(x) (void)(x)
260 #ifndef CYTHON_NCP_UNUSED
261 # if CYTHON_COMPILING_IN_CPYTHON
262 # define CYTHON_NCP_UNUSED
264 # define CYTHON_NCP_UNUSED CYTHON_UNUSED
267 #define __Pyx_void_to_None(void_result) ((void)(void_result), Py_INCREF(Py_None), Py_None)
269 #ifndef _MSC_STDINT_H_
271 typedef unsigned char uint8_t;
272 typedef unsigned int uint32_t;
274 typedef unsigned __int8 uint8_t;
275 typedef unsigned __int32 uint32_t;
281 #ifndef CYTHON_FALLTHROUGH
282 #if defined(__cplusplus) && __cplusplus >= 201103L
283 #if __has_cpp_attribute(fallthrough)
284 #define CYTHON_FALLTHROUGH [[fallthrough]]
285 #elif __has_cpp_attribute(clang::fallthrough)
286 #define CYTHON_FALLTHROUGH [[clang::fallthrough]]
287 #elif __has_cpp_attribute(gnu::fallthrough)
288 #define CYTHON_FALLTHROUGH [[gnu::fallthrough]]
291 #ifndef CYTHON_FALLTHROUGH
292 #if __has_attribute(fallthrough)
293 #define CYTHON_FALLTHROUGH __attribute__((fallthrough))
295 #define CYTHON_FALLTHROUGH
298 #if defined(__clang__ ) && defined(__apple_build_version__)
299 #if __apple_build_version__ < 7000000
300 #undef CYTHON_FALLTHROUGH
301 #define CYTHON_FALLTHROUGH
307 #error "Cython files generated with the C++ option must be compiled with a C++ compiler."
309 #ifndef CYTHON_INLINE
310 #if defined(__clang__)
311 #define CYTHON_INLINE __inline__ __attribute__ ((__unused__))
313 #define CYTHON_INLINE inline
317 void __Pyx_call_destructor(
T& x) {
321 class __Pyx_FakeReference {
323 __Pyx_FakeReference() : ptr(NULL) { }
324 __Pyx_FakeReference(
const T& ref) : ptr(const_cast<
T*>(&ref)) { }
325 T *operator->() {
return ptr; }
326 T *operator&() {
return ptr; }
327 operator T&() {
return *ptr; }
328 template<
typename U>
bool operator ==(
U other) {
return *ptr == other; }
329 template<
typename U>
bool operator !=(
U other) {
return *ptr != other; }
334 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX < 0x02070600 && !defined(Py_OptimizeFlag)
335 #define Py_OptimizeFlag 0
337 #define __PYX_BUILD_PY_SSIZE_T "n"
338 #define CYTHON_FORMAT_SSIZE_T "z"
339 #if PY_MAJOR_VERSION < 3
340 #define __Pyx_BUILTIN_MODULE_NAME "__builtin__"
341 #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
342 PyCode_New(a+k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
343 #define __Pyx_DefaultClassType PyClass_Type
345 #define __Pyx_BUILTIN_MODULE_NAME "builtins"
346 #define __Pyx_DefaultClassType PyType_Type
347 #if PY_VERSION_HEX >= 0x030B00A1
348 static CYTHON_INLINE PyCodeObject* __Pyx_PyCode_New(
int a,
int k,
int l,
int s,
int f,
349 PyObject *code, PyObject *
c, PyObject*
n, PyObject *
v,
350 PyObject *fv, PyObject *cell, PyObject* fn,
351 PyObject *name,
int fline, PyObject *lnos) {
352 PyObject *kwds=NULL, *argcount=NULL, *posonlyargcount=NULL, *kwonlyargcount=NULL;
353 PyObject *nlocals=NULL, *stacksize=NULL, *flags=NULL, *replace=NULL, *call_result=NULL, *empty=NULL;
354 const char *fn_cstr=NULL;
355 const char *name_cstr=NULL;
356 PyCodeObject* co=NULL;
357 PyObject *type, *value, *traceback;
358 PyErr_Fetch(&type, &value, &traceback);
359 if (!(kwds=PyDict_New()))
goto end;
360 if (!(argcount=PyLong_FromLong(a)))
goto end;
361 if (PyDict_SetItemString(kwds,
"co_argcount", argcount) != 0)
goto end;
362 if (!(posonlyargcount=PyLong_FromLong(0)))
goto end;
363 if (PyDict_SetItemString(kwds,
"co_posonlyargcount", posonlyargcount) != 0)
goto end;
364 if (!(kwonlyargcount=PyLong_FromLong(k)))
goto end;
365 if (PyDict_SetItemString(kwds,
"co_kwonlyargcount", kwonlyargcount) != 0)
goto end;
366 if (!(nlocals=PyLong_FromLong(l)))
goto end;
367 if (PyDict_SetItemString(kwds,
"co_nlocals", nlocals) != 0)
goto end;
368 if (!(stacksize=PyLong_FromLong(
s)))
goto end;
369 if (PyDict_SetItemString(kwds,
"co_stacksize", stacksize) != 0)
goto end;
370 if (!(flags=PyLong_FromLong(
f)))
goto end;
371 if (PyDict_SetItemString(kwds,
"co_flags", flags) != 0)
goto end;
372 if (PyDict_SetItemString(kwds,
"co_code", code) != 0)
goto end;
373 if (PyDict_SetItemString(kwds,
"co_consts",
c) != 0)
goto end;
374 if (PyDict_SetItemString(kwds,
"co_names",
n) != 0)
goto end;
375 if (PyDict_SetItemString(kwds,
"co_varnames",
v) != 0)
goto end;
376 if (PyDict_SetItemString(kwds,
"co_freevars", fv) != 0)
goto end;
377 if (PyDict_SetItemString(kwds,
"co_cellvars", cell) != 0)
goto end;
378 if (PyDict_SetItemString(kwds,
"co_linetable", lnos) != 0)
goto end;
379 if (!(fn_cstr=PyUnicode_AsUTF8AndSize(fn, NULL)))
goto end;
380 if (!(name_cstr=PyUnicode_AsUTF8AndSize(name, NULL)))
goto end;
381 if (!(co = PyCode_NewEmpty(fn_cstr, name_cstr, fline)))
goto end;
382 if (!(replace = PyObject_GetAttrString((PyObject*)co,
"replace")))
goto cleanup_code_too;
383 if (!(empty = PyTuple_New(0)))
goto cleanup_code_too;
384 if (!(call_result = PyObject_Call(replace, empty, kwds)))
goto cleanup_code_too;
385 Py_XDECREF((PyObject*)co);
386 co = (PyCodeObject*)call_result;
390 Py_XDECREF((PyObject*)co);
395 Py_XDECREF(argcount);
396 Py_XDECREF(posonlyargcount);
397 Py_XDECREF(kwonlyargcount);
399 Py_XDECREF(stacksize);
401 Py_XDECREF(call_result);
404 PyErr_Restore(type, value, traceback);
409 #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
410 PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
412 #define __Pyx_DefaultClassType PyType_Type
414 #ifndef Py_TPFLAGS_CHECKTYPES
415 #define Py_TPFLAGS_CHECKTYPES 0
417 #ifndef Py_TPFLAGS_HAVE_INDEX
418 #define Py_TPFLAGS_HAVE_INDEX 0
420 #ifndef Py_TPFLAGS_HAVE_NEWBUFFER
421 #define Py_TPFLAGS_HAVE_NEWBUFFER 0
423 #ifndef Py_TPFLAGS_HAVE_FINALIZE
424 #define Py_TPFLAGS_HAVE_FINALIZE 0
426 #ifndef METH_STACKLESS
427 #define METH_STACKLESS 0
429 #if PY_VERSION_HEX <= 0x030700A3 || !defined(METH_FASTCALL)
430 #ifndef METH_FASTCALL
431 #define METH_FASTCALL 0x80
433 typedef PyObject *(*__Pyx_PyCFunctionFast) (PyObject *
self, PyObject *
const *args, Py_ssize_t nargs);
434 typedef PyObject *(*__Pyx_PyCFunctionFastWithKeywords) (PyObject *
self, PyObject *
const *args,
435 Py_ssize_t nargs, PyObject *kwnames);
437 #define __Pyx_PyCFunctionFast _PyCFunctionFast
438 #define __Pyx_PyCFunctionFastWithKeywords _PyCFunctionFastWithKeywords
440 #if CYTHON_FAST_PYCCALL
441 #define __Pyx_PyFastCFunction_Check(func)\
442 ((PyCFunction_Check(func) && (METH_FASTCALL == (PyCFunction_GET_FLAGS(func) & ~(METH_CLASS | METH_STATIC | METH_COEXIST | METH_KEYWORDS | METH_STACKLESS)))))
444 #define __Pyx_PyFastCFunction_Check(func) 0
446 #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Malloc)
447 #define PyObject_Malloc(s) PyMem_Malloc(s)
448 #define PyObject_Free(p) PyMem_Free(p)
449 #define PyObject_Realloc(p) PyMem_Realloc(p)
451 #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030400A1
452 #define PyMem_RawMalloc(n) PyMem_Malloc(n)
453 #define PyMem_RawRealloc(p, n) PyMem_Realloc(p, n)
454 #define PyMem_RawFree(p) PyMem_Free(p)
456 #if CYTHON_COMPILING_IN_PYSTON
457 #define __Pyx_PyCode_HasFreeVars(co) PyCode_HasFreeVars(co)
458 #define __Pyx_PyFrame_SetLineNumber(frame, lineno) PyFrame_SetLineNumber(frame, lineno)
460 #define __Pyx_PyCode_HasFreeVars(co) (PyCode_GetNumFree(co) > 0)
461 #define __Pyx_PyFrame_SetLineNumber(frame, lineno) (frame)->f_lineno = (lineno)
463 #if !CYTHON_FAST_THREAD_STATE || PY_VERSION_HEX < 0x02070000
464 #define __Pyx_PyThreadState_Current PyThreadState_GET()
465 #elif PY_VERSION_HEX >= 0x03060000
466 #define __Pyx_PyThreadState_Current _PyThreadState_UncheckedGet()
467 #elif PY_VERSION_HEX >= 0x03000000
468 #define __Pyx_PyThreadState_Current PyThreadState_GET()
470 #define __Pyx_PyThreadState_Current _PyThreadState_Current
472 #if PY_VERSION_HEX < 0x030700A2 && !defined(PyThread_tss_create) && !defined(Py_tss_NEEDS_INIT)
473 #include "pythread.h"
474 #define Py_tss_NEEDS_INIT 0
475 typedef int Py_tss_t;
476 static CYTHON_INLINE
int PyThread_tss_create(Py_tss_t *key) {
477 *key = PyThread_create_key();
480 static CYTHON_INLINE Py_tss_t * PyThread_tss_alloc(
void) {
481 Py_tss_t *key = (Py_tss_t *)PyObject_Malloc(
sizeof(Py_tss_t));
482 *key = Py_tss_NEEDS_INIT;
485 static CYTHON_INLINE
void PyThread_tss_free(Py_tss_t *key) {
488 static CYTHON_INLINE
int PyThread_tss_is_created(Py_tss_t *key) {
489 return *key != Py_tss_NEEDS_INIT;
491 static CYTHON_INLINE
void PyThread_tss_delete(Py_tss_t *key) {
492 PyThread_delete_key(*key);
493 *key = Py_tss_NEEDS_INIT;
495 static CYTHON_INLINE
int PyThread_tss_set(Py_tss_t *key,
void *value) {
496 return PyThread_set_key_value(*key, value);
498 static CYTHON_INLINE
void * PyThread_tss_get(Py_tss_t *key) {
499 return PyThread_get_key_value(*key);
502 #if CYTHON_COMPILING_IN_CPYTHON || defined(_PyDict_NewPresized)
503 #define __Pyx_PyDict_NewPresized(n) ((n <= 8) ? PyDict_New() : _PyDict_NewPresized(n))
505 #define __Pyx_PyDict_NewPresized(n) PyDict_New()
507 #if PY_MAJOR_VERSION >= 3 || CYTHON_FUTURE_DIVISION
508 #define __Pyx_PyNumber_Divide(x,y) PyNumber_TrueDivide(x,y)
509 #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceTrueDivide(x,y)
511 #define __Pyx_PyNumber_Divide(x,y) PyNumber_Divide(x,y)
512 #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceDivide(x,y)
514 #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030500A1 && CYTHON_USE_UNICODE_INTERNALS
515 #define __Pyx_PyDict_GetItemStr(dict, name) _PyDict_GetItem_KnownHash(dict, name, ((PyASCIIObject *) name)->hash)
517 #define __Pyx_PyDict_GetItemStr(dict, name) PyDict_GetItem(dict, name)
519 #if PY_VERSION_HEX > 0x03030000 && defined(PyUnicode_KIND)
520 #define CYTHON_PEP393_ENABLED 1
521 #if defined(PyUnicode_IS_READY)
522 #define __Pyx_PyUnicode_READY(op) (likely(PyUnicode_IS_READY(op)) ?\
523 0 : _PyUnicode_Ready((PyObject *)(op)))
525 #define __Pyx_PyUnicode_READY(op) (0)
527 #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_LENGTH(u)
528 #define __Pyx_PyUnicode_READ_CHAR(u, i) PyUnicode_READ_CHAR(u, i)
529 #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u) PyUnicode_MAX_CHAR_VALUE(u)
530 #define __Pyx_PyUnicode_KIND(u) PyUnicode_KIND(u)
531 #define __Pyx_PyUnicode_DATA(u) PyUnicode_DATA(u)
532 #define __Pyx_PyUnicode_READ(k, d, i) PyUnicode_READ(k, d, i)
533 #define __Pyx_PyUnicode_WRITE(k, d, i, ch) PyUnicode_WRITE(k, d, i, ch)
534 #if defined(PyUnicode_IS_READY) && defined(PyUnicode_GET_SIZE)
535 #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x03090000
536 #define __Pyx_PyUnicode_IS_TRUE(u) (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : ((PyCompactUnicodeObject *)(u))->wstr_length))
538 #define __Pyx_PyUnicode_IS_TRUE(u) (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : PyUnicode_GET_SIZE(u)))
541 #define __Pyx_PyUnicode_IS_TRUE(u) (0 != PyUnicode_GET_LENGTH(u))
544 #define CYTHON_PEP393_ENABLED 0
545 #define PyUnicode_1BYTE_KIND 1
546 #define PyUnicode_2BYTE_KIND 2
547 #define PyUnicode_4BYTE_KIND 4
548 #define __Pyx_PyUnicode_READY(op) (0)
549 #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_SIZE(u)
550 #define __Pyx_PyUnicode_READ_CHAR(u, i) ((Py_UCS4)(PyUnicode_AS_UNICODE(u)[i]))
551 #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u) ((sizeof(Py_UNICODE) == 2) ? 65535 : 1114111)
552 #define __Pyx_PyUnicode_KIND(u) (sizeof(Py_UNICODE))
553 #define __Pyx_PyUnicode_DATA(u) ((void*)PyUnicode_AS_UNICODE(u))
554 #define __Pyx_PyUnicode_READ(k, d, i) ((void)(k), (Py_UCS4)(((Py_UNICODE*)d)[i]))
555 #define __Pyx_PyUnicode_WRITE(k, d, i, ch) (((void)(k)), ((Py_UNICODE*)d)[i] = ch)
556 #define __Pyx_PyUnicode_IS_TRUE(u) (0 != PyUnicode_GET_SIZE(u))
558 #if CYTHON_COMPILING_IN_PYPY
559 #define __Pyx_PyUnicode_Concat(a, b) PyNumber_Add(a, b)
560 #define __Pyx_PyUnicode_ConcatSafe(a, b) PyNumber_Add(a, b)
562 #define __Pyx_PyUnicode_Concat(a, b) PyUnicode_Concat(a, b)
563 #define __Pyx_PyUnicode_ConcatSafe(a, b) ((unlikely((a) == Py_None) || unlikely((b) == Py_None)) ?\
564 PyNumber_Add(a, b) : __Pyx_PyUnicode_Concat(a, b))
566 #if CYTHON_COMPILING_IN_PYPY && !defined(PyUnicode_Contains)
567 #define PyUnicode_Contains(u, s) PySequence_Contains(u, s)
569 #if CYTHON_COMPILING_IN_PYPY && !defined(PyByteArray_Check)
570 #define PyByteArray_Check(obj) PyObject_TypeCheck(obj, &PyByteArray_Type)
572 #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Format)
573 #define PyObject_Format(obj, fmt) PyObject_CallMethod(obj, "__format__", "O", fmt)
575 #define __Pyx_PyString_FormatSafe(a, b) ((unlikely((a) == Py_None || (PyString_Check(b) && !PyString_CheckExact(b)))) ? PyNumber_Remainder(a, b) : __Pyx_PyString_Format(a, b))
576 #define __Pyx_PyUnicode_FormatSafe(a, b) ((unlikely((a) == Py_None || (PyUnicode_Check(b) && !PyUnicode_CheckExact(b)))) ? PyNumber_Remainder(a, b) : PyUnicode_Format(a, b))
577 #if PY_MAJOR_VERSION >= 3
578 #define __Pyx_PyString_Format(a, b) PyUnicode_Format(a, b)
580 #define __Pyx_PyString_Format(a, b) PyString_Format(a, b)
582 #if PY_MAJOR_VERSION < 3 && !defined(PyObject_ASCII)
583 #define PyObject_ASCII(o) PyObject_Repr(o)
585 #if PY_MAJOR_VERSION >= 3
586 #define PyBaseString_Type PyUnicode_Type
587 #define PyStringObject PyUnicodeObject
588 #define PyString_Type PyUnicode_Type
589 #define PyString_Check PyUnicode_Check
590 #define PyString_CheckExact PyUnicode_CheckExact
591 #ifndef PyObject_Unicode
592 #define PyObject_Unicode PyObject_Str
595 #if PY_MAJOR_VERSION >= 3
596 #define __Pyx_PyBaseString_Check(obj) PyUnicode_Check(obj)
597 #define __Pyx_PyBaseString_CheckExact(obj) PyUnicode_CheckExact(obj)
599 #define __Pyx_PyBaseString_Check(obj) (PyString_Check(obj) || PyUnicode_Check(obj))
600 #define __Pyx_PyBaseString_CheckExact(obj) (PyString_CheckExact(obj) || PyUnicode_CheckExact(obj))
602 #ifndef PySet_CheckExact
603 #define PySet_CheckExact(obj) (Py_TYPE(obj) == &PySet_Type)
605 #if PY_VERSION_HEX >= 0x030900A4
606 #define __Pyx_SET_REFCNT(obj, refcnt) Py_SET_REFCNT(obj, refcnt)
607 #define __Pyx_SET_SIZE(obj, size) Py_SET_SIZE(obj, size)
609 #define __Pyx_SET_REFCNT(obj, refcnt) Py_REFCNT(obj) = (refcnt)
610 #define __Pyx_SET_SIZE(obj, size) Py_SIZE(obj) = (size)
612 #if CYTHON_ASSUME_SAFE_MACROS
613 #define __Pyx_PySequence_SIZE(seq) Py_SIZE(seq)
615 #define __Pyx_PySequence_SIZE(seq) PySequence_Size(seq)
617 #if PY_MAJOR_VERSION >= 3
618 #define PyIntObject PyLongObject
619 #define PyInt_Type PyLong_Type
620 #define PyInt_Check(op) PyLong_Check(op)
621 #define PyInt_CheckExact(op) PyLong_CheckExact(op)
622 #define PyInt_FromString PyLong_FromString
623 #define PyInt_FromUnicode PyLong_FromUnicode
624 #define PyInt_FromLong PyLong_FromLong
625 #define PyInt_FromSize_t PyLong_FromSize_t
626 #define PyInt_FromSsize_t PyLong_FromSsize_t
627 #define PyInt_AsLong PyLong_AsLong
628 #define PyInt_AS_LONG PyLong_AS_LONG
629 #define PyInt_AsSsize_t PyLong_AsSsize_t
630 #define PyInt_AsUnsignedLongMask PyLong_AsUnsignedLongMask
631 #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask
632 #define PyNumber_Int PyNumber_Long
634 #if PY_MAJOR_VERSION >= 3
635 #define PyBoolObject PyLongObject
637 #if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY
638 #ifndef PyUnicode_InternFromString
639 #define PyUnicode_InternFromString(s) PyUnicode_FromString(s)
642 #if PY_VERSION_HEX < 0x030200A4
643 typedef long Py_hash_t;
644 #define __Pyx_PyInt_FromHash_t PyInt_FromLong
645 #define __Pyx_PyInt_AsHash_t __Pyx_PyIndex_AsHash_t
647 #define __Pyx_PyInt_FromHash_t PyInt_FromSsize_t
648 #define __Pyx_PyInt_AsHash_t __Pyx_PyIndex_AsSsize_t
650 #if PY_MAJOR_VERSION >= 3
651 #define __Pyx_PyMethod_New(func, self, klass) ((self) ? ((void)(klass), PyMethod_New(func, self)) : __Pyx_NewRef(func))
653 #define __Pyx_PyMethod_New(func, self, klass) PyMethod_New(func, self, klass)
655 #if CYTHON_USE_ASYNC_SLOTS
656 #if PY_VERSION_HEX >= 0x030500B1
657 #define __Pyx_PyAsyncMethodsStruct PyAsyncMethods
658 #define __Pyx_PyType_AsAsync(obj) (Py_TYPE(obj)->tp_as_async)
660 #define __Pyx_PyType_AsAsync(obj) ((__Pyx_PyAsyncMethodsStruct*) (Py_TYPE(obj)->tp_reserved))
663 #define __Pyx_PyType_AsAsync(obj) NULL
665 #ifndef __Pyx_PyAsyncMethodsStruct
670 } __Pyx_PyAsyncMethodsStruct;
673 #if defined(_WIN32) || defined(WIN32) || defined(MS_WINDOWS)
674 #if !defined(_USE_MATH_DEFINES)
675 #define _USE_MATH_DEFINES
680 #define __PYX_NAN() ((float) NAN)
682 static CYTHON_INLINE
float __PYX_NAN() {
684 memset(&value, 0xFF,
sizeof(value));
688 #if defined(__CYGWIN__) && defined(_LDBL_EQ_DBL)
689 #define __Pyx_truncl trunc
691 #define __Pyx_truncl truncl
694 #define __PYX_MARK_ERR_POS(f_index, lineno) \
695 { __pyx_filename = __pyx_f[f_index]; (void)__pyx_filename; __pyx_lineno = lineno; (void)__pyx_lineno; __pyx_clineno = __LINE__; (void)__pyx_clineno; }
696 #define __PYX_ERR(f_index, lineno, Ln_error) \
697 { __PYX_MARK_ERR_POS(f_index, lineno) goto Ln_error; }
699 #ifndef __PYX_EXTERN_C
701 #define __PYX_EXTERN_C extern "C"
703 #define __PYX_EXTERN_C extern
707 #define __PYX_HAVE__cmeshTools
708 #define __PYX_HAVE_API__cmeshTools
712 #include "numpy/arrayobject.h"
713 #include "numpy/ndarrayobject.h"
714 #include "numpy/ndarraytypes.h"
715 #include "numpy/arrayscalars.h"
716 #include "numpy/ufuncobject.h"
721 #include "pythread.h"
728 #if defined(PYREX_WITHOUT_ASSERTIONS) && !defined(CYTHON_WITHOUT_ASSERTIONS)
729 #define CYTHON_WITHOUT_ASSERTIONS
732 typedef struct {PyObject **p;
const char *
s;
const Py_ssize_t
n;
const char* encoding;
733 const char is_unicode;
const char is_str;
const char intern; } __Pyx_StringTabEntry;
735 #define __PYX_DEFAULT_STRING_ENCODING_IS_ASCII 0
736 #define __PYX_DEFAULT_STRING_ENCODING_IS_UTF8 0
737 #define __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT (PY_MAJOR_VERSION >= 3 && __PYX_DEFAULT_STRING_ENCODING_IS_UTF8)
738 #define __PYX_DEFAULT_STRING_ENCODING ""
739 #define __Pyx_PyObject_FromString __Pyx_PyBytes_FromString
740 #define __Pyx_PyObject_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
741 #define __Pyx_uchar_cast(c) ((unsigned char)c)
742 #define __Pyx_long_cast(x) ((long)x)
743 #define __Pyx_fits_Py_ssize_t(v, type, is_signed) (\
744 (sizeof(type) < sizeof(Py_ssize_t)) ||\
745 (sizeof(type) > sizeof(Py_ssize_t) &&\
746 likely(v < (type)PY_SSIZE_T_MAX ||\
747 v == (type)PY_SSIZE_T_MAX) &&\
748 (!is_signed || likely(v > (type)PY_SSIZE_T_MIN ||\
749 v == (type)PY_SSIZE_T_MIN))) ||\
750 (sizeof(type) == sizeof(Py_ssize_t) &&\
751 (is_signed || likely(v < (type)PY_SSIZE_T_MAX ||\
752 v == (type)PY_SSIZE_T_MAX))) )
753 static CYTHON_INLINE
int __Pyx_is_valid_index(Py_ssize_t i, Py_ssize_t limit) {
754 return (
size_t) i < (size_t) limit;
756 #if defined (__cplusplus) && __cplusplus >= 201103L
758 #define __Pyx_sst_abs(value) std::abs(value)
759 #elif SIZEOF_INT >= SIZEOF_SIZE_T
760 #define __Pyx_sst_abs(value) abs(value)
761 #elif SIZEOF_LONG >= SIZEOF_SIZE_T
762 #define __Pyx_sst_abs(value) labs(value)
763 #elif defined (_MSC_VER)
764 #define __Pyx_sst_abs(value) ((Py_ssize_t)_abs64(value))
765 #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
766 #define __Pyx_sst_abs(value) llabs(value)
767 #elif defined (__GNUC__)
768 #define __Pyx_sst_abs(value) __builtin_llabs(value)
770 #define __Pyx_sst_abs(value) ((value<0) ? -value : value)
772 static CYTHON_INLINE
const char* __Pyx_PyObject_AsString(PyObject*);
773 static CYTHON_INLINE
const char* __Pyx_PyObject_AsStringAndSize(PyObject*, Py_ssize_t* length);
774 #define __Pyx_PyByteArray_FromString(s) PyByteArray_FromStringAndSize((const char*)s, strlen((const char*)s))
775 #define __Pyx_PyByteArray_FromStringAndSize(s, l) PyByteArray_FromStringAndSize((const char*)s, l)
776 #define __Pyx_PyBytes_FromString PyBytes_FromString
777 #define __Pyx_PyBytes_FromStringAndSize PyBytes_FromStringAndSize
778 static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(
const char*);
779 #if PY_MAJOR_VERSION < 3
780 #define __Pyx_PyStr_FromString __Pyx_PyBytes_FromString
781 #define __Pyx_PyStr_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
783 #define __Pyx_PyStr_FromString __Pyx_PyUnicode_FromString
784 #define __Pyx_PyStr_FromStringAndSize __Pyx_PyUnicode_FromStringAndSize
786 #define __Pyx_PyBytes_AsWritableString(s) ((char*) PyBytes_AS_STRING(s))
787 #define __Pyx_PyBytes_AsWritableSString(s) ((signed char*) PyBytes_AS_STRING(s))
788 #define __Pyx_PyBytes_AsWritableUString(s) ((unsigned char*) PyBytes_AS_STRING(s))
789 #define __Pyx_PyBytes_AsString(s) ((const char*) PyBytes_AS_STRING(s))
790 #define __Pyx_PyBytes_AsSString(s) ((const signed char*) PyBytes_AS_STRING(s))
791 #define __Pyx_PyBytes_AsUString(s) ((const unsigned char*) PyBytes_AS_STRING(s))
792 #define __Pyx_PyObject_AsWritableString(s) ((char*) __Pyx_PyObject_AsString(s))
793 #define __Pyx_PyObject_AsWritableSString(s) ((signed char*) __Pyx_PyObject_AsString(s))
794 #define __Pyx_PyObject_AsWritableUString(s) ((unsigned char*) __Pyx_PyObject_AsString(s))
795 #define __Pyx_PyObject_AsSString(s) ((const signed char*) __Pyx_PyObject_AsString(s))
796 #define __Pyx_PyObject_AsUString(s) ((const unsigned char*) __Pyx_PyObject_AsString(s))
797 #define __Pyx_PyObject_FromCString(s) __Pyx_PyObject_FromString((const char*)s)
798 #define __Pyx_PyBytes_FromCString(s) __Pyx_PyBytes_FromString((const char*)s)
799 #define __Pyx_PyByteArray_FromCString(s) __Pyx_PyByteArray_FromString((const char*)s)
800 #define __Pyx_PyStr_FromCString(s) __Pyx_PyStr_FromString((const char*)s)
801 #define __Pyx_PyUnicode_FromCString(s) __Pyx_PyUnicode_FromString((const char*)s)
802 static CYTHON_INLINE
size_t __Pyx_Py_UNICODE_strlen(
const Py_UNICODE *
u) {
803 const Py_UNICODE *u_end =
u;
805 return (
size_t)(u_end -
u - 1);
807 #define __Pyx_PyUnicode_FromUnicode(u) PyUnicode_FromUnicode(u, __Pyx_Py_UNICODE_strlen(u))
808 #define __Pyx_PyUnicode_FromUnicodeAndLength PyUnicode_FromUnicode
809 #define __Pyx_PyUnicode_AsUnicode PyUnicode_AsUnicode
810 #define __Pyx_NewRef(obj) (Py_INCREF(obj), obj)
811 #define __Pyx_Owned_Py_None(b) __Pyx_NewRef(Py_None)
812 static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(
long b);
813 static CYTHON_INLINE
int __Pyx_PyObject_IsTrue(PyObject*);
814 static CYTHON_INLINE
int __Pyx_PyObject_IsTrueAndDecref(PyObject*);
815 static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x);
816 #define __Pyx_PySequence_Tuple(obj)\
817 (likely(PyTuple_CheckExact(obj)) ? __Pyx_NewRef(obj) : PySequence_Tuple(obj))
818 static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject*);
819 static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(
size_t);
820 static CYTHON_INLINE Py_hash_t __Pyx_PyIndex_AsHash_t(PyObject*);
821 #if CYTHON_ASSUME_SAFE_MACROS
822 #define __pyx_PyFloat_AsDouble(x) (PyFloat_CheckExact(x) ? PyFloat_AS_DOUBLE(x) : PyFloat_AsDouble(x))
824 #define __pyx_PyFloat_AsDouble(x) PyFloat_AsDouble(x)
826 #define __pyx_PyFloat_AsFloat(x) ((float) __pyx_PyFloat_AsDouble(x))
827 #if PY_MAJOR_VERSION >= 3
828 #define __Pyx_PyNumber_Int(x) (PyLong_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Long(x))
830 #define __Pyx_PyNumber_Int(x) (PyInt_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Int(x))
832 #define __Pyx_PyNumber_Float(x) (PyFloat_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Float(x))
833 #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
834 static int __Pyx_sys_getdefaultencoding_not_ascii;
835 static int __Pyx_init_sys_getdefaultencoding_params(
void) {
837 PyObject* default_encoding = NULL;
838 PyObject* ascii_chars_u = NULL;
839 PyObject* ascii_chars_b = NULL;
840 const char* default_encoding_c;
841 sys = PyImport_ImportModule(
"sys");
843 default_encoding = PyObject_CallMethod(sys, (
char*)
"getdefaultencoding", NULL);
845 if (!default_encoding)
goto bad;
846 default_encoding_c = PyBytes_AsString(default_encoding);
847 if (!default_encoding_c)
goto bad;
848 if (strcmp(default_encoding_c,
"ascii") == 0) {
849 __Pyx_sys_getdefaultencoding_not_ascii = 0;
851 char ascii_chars[128];
853 for (
c = 0;
c < 128;
c++) {
856 __Pyx_sys_getdefaultencoding_not_ascii = 1;
857 ascii_chars_u = PyUnicode_DecodeASCII(ascii_chars, 128, NULL);
858 if (!ascii_chars_u)
goto bad;
859 ascii_chars_b = PyUnicode_AsEncodedString(ascii_chars_u, default_encoding_c, NULL);
860 if (!ascii_chars_b || !PyBytes_Check(ascii_chars_b) || memcmp(ascii_chars, PyBytes_AS_STRING(ascii_chars_b), 128) != 0) {
863 "This module compiled with c_string_encoding=ascii, but default encoding '%.200s' is not a superset of ascii.",
867 Py_DECREF(ascii_chars_u);
868 Py_DECREF(ascii_chars_b);
870 Py_DECREF(default_encoding);
873 Py_XDECREF(default_encoding);
874 Py_XDECREF(ascii_chars_u);
875 Py_XDECREF(ascii_chars_b);
879 #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT && PY_MAJOR_VERSION >= 3
880 #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_DecodeUTF8(c_str, size, NULL)
882 #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_Decode(c_str, size, __PYX_DEFAULT_STRING_ENCODING, NULL)
883 #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
884 static char* __PYX_DEFAULT_STRING_ENCODING;
885 static int __Pyx_init_sys_getdefaultencoding_params(
void) {
887 PyObject* default_encoding = NULL;
888 char* default_encoding_c;
889 sys = PyImport_ImportModule(
"sys");
891 default_encoding = PyObject_CallMethod(sys, (
char*) (
const char*)
"getdefaultencoding", NULL);
893 if (!default_encoding)
goto bad;
894 default_encoding_c = PyBytes_AsString(default_encoding);
895 if (!default_encoding_c)
goto bad;
896 __PYX_DEFAULT_STRING_ENCODING = (
char*) malloc(strlen(default_encoding_c) + 1);
897 if (!__PYX_DEFAULT_STRING_ENCODING)
goto bad;
898 strcpy(__PYX_DEFAULT_STRING_ENCODING, default_encoding_c);
899 Py_DECREF(default_encoding);
902 Py_XDECREF(default_encoding);
910 #if defined(__GNUC__) && (__GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95)))
911 #define likely(x) __builtin_expect(!!(x), 1)
912 #define unlikely(x) __builtin_expect(!!(x), 0)
914 #define likely(x) (x)
915 #define unlikely(x) (x)
917 static CYTHON_INLINE
void __Pyx_pretend_to_initialize(
void* ptr) { (void)ptr; }
919 static PyObject *__pyx_m = NULL;
920 static PyObject *__pyx_d;
921 static PyObject *__pyx_b;
922 static PyObject *__pyx_cython_runtime = NULL;
923 static PyObject *__pyx_empty_tuple;
924 static PyObject *__pyx_empty_bytes;
925 static PyObject *__pyx_empty_unicode;
926 static int __pyx_lineno;
927 static int __pyx_clineno = 0;
928 static const char * __pyx_cfilenm= __FILE__;
929 static const char *__pyx_filename;
932 #if !defined(CYTHON_CCOMPLEX)
933 #if defined(__cplusplus)
934 #define CYTHON_CCOMPLEX 1
935 #elif defined(_Complex_I)
936 #define CYTHON_CCOMPLEX 1
938 #define CYTHON_CCOMPLEX 0
948 #if CYTHON_CCOMPLEX && !defined(__cplusplus) && defined(__sun__) && defined(__GNUC__)
950 #define _Complex_I 1.0fj
954 static const char *__pyx_f[] = {
956 "proteus/cmeshTools.pyx",
957 "proteus/cmeshTools.pxd",
962 #ifndef __PYX_FORCE_INIT_THREADS
963 #define __PYX_FORCE_INIT_THREADS 0
967 #define __Pyx_PyGILState_Ensure PyGILState_Ensure
968 #define __Pyx_PyGILState_Release PyGILState_Release
969 #define __Pyx_FastGIL_Remember()
970 #define __Pyx_FastGIL_Forget()
971 #define __Pyx_FastGilFuncInit()
974 #define IS_UNSIGNED(type) (((type) -1) > 0)
975 struct __Pyx_StructField_;
976 #define __PYX_BUF_FLAGS_PACKED_STRUCT (1 << 0)
979 struct __Pyx_StructField_* fields;
987 typedef struct __Pyx_StructField_ {
988 __Pyx_TypeInfo* type;
993 __Pyx_StructField* field;
994 size_t parent_offset;
995 } __Pyx_BufFmt_StackElem;
997 __Pyx_StructField root;
998 __Pyx_BufFmt_StackElem* head;
1000 size_t new_count, enc_count;
1001 size_t struct_alignment;
1006 char is_valid_array;
1007 } __Pyx_BufFmt_Context;
1010 #include <pythread.h>
1011 #ifndef CYTHON_ATOMICS
1012 #define CYTHON_ATOMICS 1
1014 #define __pyx_atomic_int_type int
1015 #if CYTHON_ATOMICS && __GNUC__ >= 4 && (__GNUC_MINOR__ > 1 ||\
1016 (__GNUC_MINOR__ == 1 && __GNUC_PATCHLEVEL >= 2)) &&\
1018 #define __pyx_atomic_incr_aligned(value, lock) __sync_fetch_and_add(value, 1)
1019 #define __pyx_atomic_decr_aligned(value, lock) __sync_fetch_and_sub(value, 1)
1020 #ifdef __PYX_DEBUG_ATOMICS
1021 #warning "Using GNU atomics"
1023 #elif CYTHON_ATOMICS && defined(_MSC_VER) && 0
1024 #include <Windows.h>
1025 #undef __pyx_atomic_int_type
1026 #define __pyx_atomic_int_type LONG
1027 #define __pyx_atomic_incr_aligned(value, lock) InterlockedIncrement(value)
1028 #define __pyx_atomic_decr_aligned(value, lock) InterlockedDecrement(value)
1029 #ifdef __PYX_DEBUG_ATOMICS
1030 #pragma message ("Using MSVC atomics")
1032 #elif CYTHON_ATOMICS && (defined(__ICC) || defined(__INTEL_COMPILER)) && 0
1033 #define __pyx_atomic_incr_aligned(value, lock) _InterlockedIncrement(value)
1034 #define __pyx_atomic_decr_aligned(value, lock) _InterlockedDecrement(value)
1035 #ifdef __PYX_DEBUG_ATOMICS
1036 #warning "Using Intel atomics"
1039 #undef CYTHON_ATOMICS
1040 #define CYTHON_ATOMICS 0
1041 #ifdef __PYX_DEBUG_ATOMICS
1042 #warning "Not using atomics"
1045 typedef volatile __pyx_atomic_int_type __pyx_atomic_int;
1047 #define __pyx_add_acquisition_count(memview)\
1048 __pyx_atomic_incr_aligned(__pyx_get_slice_count_pointer(memview), memview->lock)
1049 #define __pyx_sub_acquisition_count(memview)\
1050 __pyx_atomic_decr_aligned(__pyx_get_slice_count_pointer(memview), memview->lock)
1052 #define __pyx_add_acquisition_count(memview)\
1053 __pyx_add_acquisition_count_locked(__pyx_get_slice_count_pointer(memview), memview->lock)
1054 #define __pyx_sub_acquisition_count(memview)\
1055 __pyx_sub_acquisition_count_locked(__pyx_get_slice_count_pointer(memview), memview->lock)
1059 struct __pyx_memoryview_obj;
1061 struct __pyx_memoryview_obj *memview;
1063 Py_ssize_t shape[8];
1064 Py_ssize_t strides[8];
1065 Py_ssize_t suboffsets[8];
1066 } __Pyx_memviewslice;
1067 #define __Pyx_MemoryView_Len(m) (m.shape[0])
1077 typedef npy_int8 __pyx_t_5numpy_int8_t;
1086 typedef npy_int16 __pyx_t_5numpy_int16_t;
1095 typedef npy_int32 __pyx_t_5numpy_int32_t;
1104 typedef npy_int64 __pyx_t_5numpy_int64_t;
1113 typedef npy_uint8 __pyx_t_5numpy_uint8_t;
1122 typedef npy_uint16 __pyx_t_5numpy_uint16_t;
1131 typedef npy_uint32 __pyx_t_5numpy_uint32_t;
1140 typedef npy_uint64 __pyx_t_5numpy_uint64_t;
1149 typedef npy_float32 __pyx_t_5numpy_float32_t;
1158 typedef npy_float64 __pyx_t_5numpy_float64_t;
1167 typedef npy_long __pyx_t_5numpy_int_t;
1176 typedef npy_longlong __pyx_t_5numpy_long_t;
1185 typedef npy_longlong __pyx_t_5numpy_longlong_t;
1194 typedef npy_ulong __pyx_t_5numpy_uint_t;
1203 typedef npy_ulonglong __pyx_t_5numpy_ulong_t;
1212 typedef npy_ulonglong __pyx_t_5numpy_ulonglong_t;
1221 typedef npy_intp __pyx_t_5numpy_intp_t;
1230 typedef npy_uintp __pyx_t_5numpy_uintp_t;
1239 typedef npy_double __pyx_t_5numpy_float_t;
1248 typedef npy_double __pyx_t_5numpy_double_t;
1257 typedef npy_longdouble __pyx_t_5numpy_longdouble_t;
1261 typedef ::std::complex< float > __pyx_t_float_complex;
1263 typedef float _Complex __pyx_t_float_complex;
1266 typedef struct {
float real, imag; } __pyx_t_float_complex;
1268 static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(
float,
float);
1273 typedef ::std::complex< double > __pyx_t_double_complex;
1275 typedef double _Complex __pyx_t_double_complex;
1278 typedef struct {
double real, imag; } __pyx_t_double_complex;
1280 static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(
double,
double);
1284 struct __pyx_obj_10cmeshTools_CMesh;
1285 struct __pyx_obj_10cmeshTools_CMultilevelMesh;
1286 struct __pyx_array_obj;
1287 struct __pyx_MemviewEnum_obj;
1288 struct __pyx_memoryview_obj;
1289 struct __pyx_memoryviewslice_obj;
1298 typedef npy_cfloat __pyx_t_5numpy_cfloat_t;
1307 typedef npy_cdouble __pyx_t_5numpy_cdouble_t;
1316 typedef npy_clongdouble __pyx_t_5numpy_clongdouble_t;
1325 typedef npy_cdouble __pyx_t_5numpy_complex_t;
1334 struct __pyx_obj_10cmeshTools_CMesh {
1397 struct __pyx_obj_10cmeshTools_CMultilevelMesh {
1401 PyObject *cmeshList;
1402 PyObject *elementParentsArrayList;
1403 PyObject *elementChildrenArrayList;
1404 PyObject *elementChildrenOffsetsList;
1415 struct __pyx_array_obj {
1417 struct __pyx_vtabstruct_array *__pyx_vtab;
1423 Py_ssize_t *_strides;
1424 Py_ssize_t itemsize;
1427 void (*callback_free_data)(
void *);
1429 int dtype_is_object;
1440 struct __pyx_MemviewEnum_obj {
1453 struct __pyx_memoryview_obj {
1455 struct __pyx_vtabstruct_memoryview *__pyx_vtab;
1458 PyObject *_array_interface;
1459 PyThread_type_lock lock;
1460 __pyx_atomic_int acquisition_count[2];
1461 __pyx_atomic_int *acquisition_count_aligned_p;
1464 int dtype_is_object;
1465 __Pyx_TypeInfo *typeinfo;
1476 struct __pyx_memoryviewslice_obj {
1477 struct __pyx_memoryview_obj __pyx_base;
1478 __Pyx_memviewslice from_slice;
1479 PyObject *from_object;
1480 PyObject *(*to_object_func)(
char *);
1481 int (*to_dtype_func)(
char *, PyObject *);
1494 struct __pyx_vtabstruct_array {
1495 PyObject *(*get_memview)(
struct __pyx_array_obj *);
1497 static struct __pyx_vtabstruct_array *__pyx_vtabptr_array;
1508 struct __pyx_vtabstruct_memoryview {
1509 char *(*get_item_pointer)(
struct __pyx_memoryview_obj *, PyObject *);
1510 PyObject *(*is_slice)(
struct __pyx_memoryview_obj *, PyObject *);
1511 PyObject *(*setitem_slice_assignment)(
struct __pyx_memoryview_obj *, PyObject *, PyObject *);
1512 PyObject *(*setitem_slice_assign_scalar)(
struct __pyx_memoryview_obj *,
struct __pyx_memoryview_obj *, PyObject *);
1513 PyObject *(*setitem_indexed)(
struct __pyx_memoryview_obj *, PyObject *, PyObject *);
1514 PyObject *(*convert_item_to_object)(
struct __pyx_memoryview_obj *,
char *);
1515 PyObject *(*assign_item_from_object)(
struct __pyx_memoryview_obj *,
char *, PyObject *);
1517 static struct __pyx_vtabstruct_memoryview *__pyx_vtabptr_memoryview;
1528 struct __pyx_vtabstruct__memoryviewslice {
1529 struct __pyx_vtabstruct_memoryview __pyx_base;
1531 static struct __pyx_vtabstruct__memoryviewslice *__pyx_vtabptr__memoryviewslice;
1535 #ifndef CYTHON_REFNANNY
1536 #define CYTHON_REFNANNY 0
1540 void (*INCREF)(
void*, PyObject*, int);
1541 void (*DECREF)(
void*, PyObject*, int);
1542 void (*GOTREF)(
void*, PyObject*, int);
1543 void (*GIVEREF)(
void*, PyObject*, int);
1544 void* (*SetupContext)(
const char*, int,
const char*);
1545 void (*FinishContext)(
void**);
1546 } __Pyx_RefNannyAPIStruct;
1547 static __Pyx_RefNannyAPIStruct *__Pyx_RefNanny = NULL;
1548 static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(
const char *modname);
1549 #define __Pyx_RefNannyDeclarations void *__pyx_refnanny = NULL;
1551 #define __Pyx_RefNannySetupContext(name, acquire_gil)\
1553 PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\
1554 __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
1555 PyGILState_Release(__pyx_gilstate_save);\
1557 __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
1560 #define __Pyx_RefNannySetupContext(name, acquire_gil)\
1561 __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__)
1563 #define __Pyx_RefNannyFinishContext()\
1564 __Pyx_RefNanny->FinishContext(&__pyx_refnanny)
1565 #define __Pyx_INCREF(r) __Pyx_RefNanny->INCREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1566 #define __Pyx_DECREF(r) __Pyx_RefNanny->DECREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1567 #define __Pyx_GOTREF(r) __Pyx_RefNanny->GOTREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1568 #define __Pyx_GIVEREF(r) __Pyx_RefNanny->GIVEREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
1569 #define __Pyx_XINCREF(r) do { if((r) != NULL) {__Pyx_INCREF(r); }} while(0)
1570 #define __Pyx_XDECREF(r) do { if((r) != NULL) {__Pyx_DECREF(r); }} while(0)
1571 #define __Pyx_XGOTREF(r) do { if((r) != NULL) {__Pyx_GOTREF(r); }} while(0)
1572 #define __Pyx_XGIVEREF(r) do { if((r) != NULL) {__Pyx_GIVEREF(r);}} while(0)
1574 #define __Pyx_RefNannyDeclarations
1575 #define __Pyx_RefNannySetupContext(name, acquire_gil)
1576 #define __Pyx_RefNannyFinishContext()
1577 #define __Pyx_INCREF(r) Py_INCREF(r)
1578 #define __Pyx_DECREF(r) Py_DECREF(r)
1579 #define __Pyx_GOTREF(r)
1580 #define __Pyx_GIVEREF(r)
1581 #define __Pyx_XINCREF(r) Py_XINCREF(r)
1582 #define __Pyx_XDECREF(r) Py_XDECREF(r)
1583 #define __Pyx_XGOTREF(r)
1584 #define __Pyx_XGIVEREF(r)
1586 #define __Pyx_XDECREF_SET(r, v) do {\
1587 PyObject *tmp = (PyObject *) r;\
1588 r = v; __Pyx_XDECREF(tmp);\
1590 #define __Pyx_DECREF_SET(r, v) do {\
1591 PyObject *tmp = (PyObject *) r;\
1592 r = v; __Pyx_DECREF(tmp);\
1594 #define __Pyx_CLEAR(r) do { PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);} while(0)
1595 #define __Pyx_XCLEAR(r) do { if((r) != NULL) {PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);}} while(0)
1598 #if CYTHON_USE_TYPE_SLOTS
1599 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name);
1601 #define __Pyx_PyObject_GetAttrStr(o,n) PyObject_GetAttr(o,n)
1605 static PyObject *__Pyx_GetBuiltinName(PyObject *name);
1608 static void __Pyx_RaiseArgtupleInvalid(
const char* func_name,
int exact,
1609 Py_ssize_t num_min, Py_ssize_t num_max, Py_ssize_t num_found);
1612 static int __Pyx_CheckKeywordStrings(PyObject *kwdict,
const char* function_name,
int kw_allowed);
1615 #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
1616 #define __PYX_DICT_VERSION_INIT ((PY_UINT64_T) -1)
1617 #define __PYX_GET_DICT_VERSION(dict) (((PyDictObject*)(dict))->ma_version_tag)
1618 #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)\
1619 (version_var) = __PYX_GET_DICT_VERSION(dict);\
1620 (cache_var) = (value);
1621 #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) {\
1622 static PY_UINT64_T __pyx_dict_version = 0;\
1623 static PyObject *__pyx_dict_cached_value = NULL;\
1624 if (likely(__PYX_GET_DICT_VERSION(DICT) == __pyx_dict_version)) {\
1625 (VAR) = __pyx_dict_cached_value;\
1627 (VAR) = __pyx_dict_cached_value = (LOOKUP);\
1628 __pyx_dict_version = __PYX_GET_DICT_VERSION(DICT);\
1631 static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj);
1632 static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj);
1633 static CYTHON_INLINE
int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version);
1635 #define __PYX_GET_DICT_VERSION(dict) (0)
1636 #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)
1637 #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) (VAR) = (LOOKUP);
1641 #if CYTHON_USE_DICT_VERSIONS
1642 #define __Pyx_GetModuleGlobalName(var, name) {\
1643 static PY_UINT64_T __pyx_dict_version = 0;\
1644 static PyObject *__pyx_dict_cached_value = NULL;\
1645 (var) = (likely(__pyx_dict_version == __PYX_GET_DICT_VERSION(__pyx_d))) ?\
1646 (likely(__pyx_dict_cached_value) ? __Pyx_NewRef(__pyx_dict_cached_value) : __Pyx_GetBuiltinName(name)) :\
1647 __Pyx__GetModuleGlobalName(name, &__pyx_dict_version, &__pyx_dict_cached_value);\
1649 #define __Pyx_GetModuleGlobalNameUncached(var, name) {\
1650 PY_UINT64_T __pyx_dict_version;\
1651 PyObject *__pyx_dict_cached_value;\
1652 (var) = __Pyx__GetModuleGlobalName(name, &__pyx_dict_version, &__pyx_dict_cached_value);\
1654 static PyObject *__Pyx__GetModuleGlobalName(PyObject *name, PY_UINT64_T *dict_version, PyObject **dict_cached_value);
1656 #define __Pyx_GetModuleGlobalName(var, name) (var) = __Pyx__GetModuleGlobalName(name)
1657 #define __Pyx_GetModuleGlobalNameUncached(var, name) (var) = __Pyx__GetModuleGlobalName(name)
1658 static CYTHON_INLINE PyObject *__Pyx__GetModuleGlobalName(PyObject *name);
1662 #if CYTHON_FAST_PYCCALL
1663 static CYTHON_INLINE PyObject *__Pyx_PyCFunction_FastCall(PyObject *func, PyObject **args, Py_ssize_t nargs);
1665 #define __Pyx_PyCFunction_FastCall(func, args, nargs) (assert(0), NULL)
1669 #if CYTHON_FAST_PYCALL
1670 #define __Pyx_PyFunction_FastCall(func, args, nargs)\
1671 __Pyx_PyFunction_FastCallDict((func), (args), (nargs), NULL)
1672 #if 1 || PY_VERSION_HEX < 0x030600B1
1673 static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, Py_ssize_t nargs, PyObject *kwargs);
1675 #define __Pyx_PyFunction_FastCallDict(func, args, nargs, kwargs) _PyFunction_FastCallDict(func, args, nargs, kwargs)
1677 #define __Pyx_BUILD_ASSERT_EXPR(cond)\
1678 (sizeof(char [1 - 2*!(cond)]) - 1)
1679 #ifndef Py_MEMBER_SIZE
1680 #define Py_MEMBER_SIZE(type, member) sizeof(((type *)0)->member)
1682 #if CYTHON_FAST_PYCALL
1683 static size_t __pyx_pyframe_localsplus_offset = 0;
1684 #include "frameobject.h"
1685 #if PY_VERSION_HEX >= 0x030b00a6
1686 #ifndef Py_BUILD_CORE
1687 #define Py_BUILD_CORE 1
1689 #include "internal/pycore_frame.h"
1691 #define __Pxy_PyFrame_Initialize_Offsets()\
1692 ((void)__Pyx_BUILD_ASSERT_EXPR(sizeof(PyFrameObject) == offsetof(PyFrameObject, f_localsplus) + Py_MEMBER_SIZE(PyFrameObject, f_localsplus)),\
1693 (void)(__pyx_pyframe_localsplus_offset = ((size_t)PyFrame_Type.tp_basicsize) - Py_MEMBER_SIZE(PyFrameObject, f_localsplus)))
1694 #define __Pyx_PyFrame_GetLocalsplus(frame)\
1695 (assert(__pyx_pyframe_localsplus_offset), (PyObject **)(((char *)(frame)) + __pyx_pyframe_localsplus_offset))
1696 #endif // CYTHON_FAST_PYCALL
1700 #if CYTHON_COMPILING_IN_CPYTHON
1701 static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw);
1703 #define __Pyx_PyObject_Call(func, arg, kw) PyObject_Call(func, arg, kw)
1707 static CYTHON_UNUSED PyObject* __Pyx_PyObject_Call2Args(PyObject*
function, PyObject* arg1, PyObject* arg2);
1710 #if CYTHON_COMPILING_IN_CPYTHON
1711 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg);
1715 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg);
1718 static CYTHON_INLINE
int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type);
1721 #if CYTHON_FAST_THREAD_STATE
1722 #define __Pyx_PyThreadState_declare PyThreadState *__pyx_tstate;
1723 #define __Pyx_PyThreadState_assign __pyx_tstate = __Pyx_PyThreadState_Current;
1724 #define __Pyx_PyErr_Occurred() __pyx_tstate->curexc_type
1726 #define __Pyx_PyThreadState_declare
1727 #define __Pyx_PyThreadState_assign
1728 #define __Pyx_PyErr_Occurred() PyErr_Occurred()
1732 #if CYTHON_FAST_THREAD_STATE
1733 #define __Pyx_PyErr_Clear() __Pyx_ErrRestore(NULL, NULL, NULL)
1734 #define __Pyx_ErrRestoreWithState(type, value, tb) __Pyx_ErrRestoreInState(PyThreadState_GET(), type, value, tb)
1735 #define __Pyx_ErrFetchWithState(type, value, tb) __Pyx_ErrFetchInState(PyThreadState_GET(), type, value, tb)
1736 #define __Pyx_ErrRestore(type, value, tb) __Pyx_ErrRestoreInState(__pyx_tstate, type, value, tb)
1737 #define __Pyx_ErrFetch(type, value, tb) __Pyx_ErrFetchInState(__pyx_tstate, type, value, tb)
1738 static CYTHON_INLINE
void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
1739 static CYTHON_INLINE
void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1740 #if CYTHON_COMPILING_IN_CPYTHON
1741 #define __Pyx_PyErr_SetNone(exc) (Py_INCREF(exc), __Pyx_ErrRestore((exc), NULL, NULL))
1743 #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
1746 #define __Pyx_PyErr_Clear() PyErr_Clear()
1747 #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
1748 #define __Pyx_ErrRestoreWithState(type, value, tb) PyErr_Restore(type, value, tb)
1749 #define __Pyx_ErrFetchWithState(type, value, tb) PyErr_Fetch(type, value, tb)
1750 #define __Pyx_ErrRestoreInState(tstate, type, value, tb) PyErr_Restore(type, value, tb)
1751 #define __Pyx_ErrFetchInState(tstate, type, value, tb) PyErr_Fetch(type, value, tb)
1752 #define __Pyx_ErrRestore(type, value, tb) PyErr_Restore(type, value, tb)
1753 #define __Pyx_ErrFetch(type, value, tb) PyErr_Fetch(type, value, tb)
1757 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause);
1760 #if CYTHON_COMPILING_IN_CPYTHON
1761 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func);
1763 #define __Pyx_PyObject_CallNoArg(func) __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL)
1767 static void __Pyx_RaiseDoubleKeywordsError(
const char* func_name, PyObject* kw_name);
1770 static int __Pyx_ParseOptionalKeywords(PyObject *kwds, PyObject **argnames[],\
1771 PyObject *kwds2, PyObject *values[], Py_ssize_t num_pos_args,\
1772 const char* function_name);
1775 #define __Pyx_ArgTypeTest(obj, type, none_allowed, name, exact)\
1776 ((likely((Py_TYPE(obj) == type) | (none_allowed && (obj == Py_None)))) ? 1 :\
1777 __Pyx__ArgTypeTest(obj, type, name, exact))
1778 static int __Pyx__ArgTypeTest(PyObject *obj, PyTypeObject *type,
const char *name,
int exact);
1781 #if !CYTHON_COMPILING_IN_PYPY
1782 static PyObject* __Pyx_PyInt_SubtractObjC(PyObject *op1, PyObject *op2,
long intval,
int inplace,
int zerodivision_check);
1784 #define __Pyx_PyInt_SubtractObjC(op1, op2, intval, inplace, zerodivision_check)\
1785 (inplace ? PyNumber_InPlaceSubtract(op1, op2) : PyNumber_Subtract(op1, op2))
1789 static CYTHON_INLINE PyObject* __Pyx_PyInt_EqObjC(PyObject *op1, PyObject *op2,
long intval,
long inplace);
1792 static void __Pyx_WriteUnraisable(
const char *name,
int clineno,
1793 int lineno,
const char *filename,
1794 int full_traceback,
int nogil);
1797 #if CYTHON_USE_EXC_INFO_STACK
1798 static _PyErr_StackItem * __Pyx_PyErr_GetTopmostException(PyThreadState *tstate);
1802 #if CYTHON_FAST_THREAD_STATE
1803 #define __Pyx_ExceptionSave(type, value, tb) __Pyx__ExceptionSave(__pyx_tstate, type, value, tb)
1804 static CYTHON_INLINE
void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1805 #define __Pyx_ExceptionReset(type, value, tb) __Pyx__ExceptionReset(__pyx_tstate, type, value, tb)
1806 static CYTHON_INLINE
void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
1808 #define __Pyx_ExceptionSave(type, value, tb) PyErr_GetExcInfo(type, value, tb)
1809 #define __Pyx_ExceptionReset(type, value, tb) PyErr_SetExcInfo(type, value, tb)
1813 #if CYTHON_FAST_THREAD_STATE
1814 #define __Pyx_PyErr_ExceptionMatches(err) __Pyx_PyErr_ExceptionMatchesInState(__pyx_tstate, err)
1815 static CYTHON_INLINE
int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err);
1817 #define __Pyx_PyErr_ExceptionMatches(err) PyErr_ExceptionMatches(err)
1821 #if CYTHON_FAST_THREAD_STATE
1822 #define __Pyx_GetException(type, value, tb) __Pyx__GetException(__pyx_tstate, type, value, tb)
1823 static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1825 static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb);
1832 static CYTHON_INLINE
int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2,
int equals);
1835 static CYTHON_INLINE
int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2,
int equals);
1838 #if PY_MAJOR_VERSION >= 3
1839 #define __Pyx_PyString_Equals __Pyx_PyUnicode_Equals
1841 #define __Pyx_PyString_Equals __Pyx_PyBytes_Equals
1845 static CYTHON_INLINE Py_ssize_t __Pyx_div_Py_ssize_t(Py_ssize_t, Py_ssize_t);
1848 #define UNARY_NEG_WOULD_OVERFLOW(x)\
1849 (((x) < 0) & ((unsigned long)(x) == 0-(unsigned long)(x)))
1851 static CYTHON_UNUSED
int __pyx_array_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags);
1852 static PyObject *__pyx_array_get_memview(
struct __pyx_array_obj *);
1854 static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *, PyObject *);
1857 #define __Pyx_GetItemInt(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
1858 (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
1859 __Pyx_GetItemInt_Fast(o, (Py_ssize_t)i, is_list, wraparound, boundscheck) :\
1860 (is_list ? (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL) :\
1861 __Pyx_GetItemInt_Generic(o, to_py_func(i))))
1862 #define __Pyx_GetItemInt_List(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
1863 (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
1864 __Pyx_GetItemInt_List_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
1865 (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL))
1866 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
1867 int wraparound,
int boundscheck);
1868 #define __Pyx_GetItemInt_Tuple(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
1869 (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
1870 __Pyx_GetItemInt_Tuple_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
1871 (PyErr_SetString(PyExc_IndexError, "tuple index out of range"), (PyObject*)NULL))
1872 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
1873 int wraparound,
int boundscheck);
1874 static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j);
1875 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i,
1876 int is_list,
int wraparound,
int boundscheck);
1879 #if CYTHON_USE_TYPE_SLOTS
1880 static CYTHON_INLINE PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject* key);
1882 #define __Pyx_PyObject_GetItem(obj, key) PyObject_GetItem(obj, key)
1886 static CYTHON_INLINE PyObject *__Pyx_PyUnicode_DecodeUTF16(
const char *
s, Py_ssize_t size,
const char *errors) {
1888 return PyUnicode_DecodeUTF16(
s, size, errors, &byteorder);
1890 static CYTHON_INLINE PyObject *__Pyx_PyUnicode_DecodeUTF16LE(
const char *
s, Py_ssize_t size,
const char *errors) {
1892 return PyUnicode_DecodeUTF16(
s, size, errors, &byteorder);
1894 static CYTHON_INLINE PyObject *__Pyx_PyUnicode_DecodeUTF16BE(
const char *
s, Py_ssize_t size,
const char *errors) {
1896 return PyUnicode_DecodeUTF16(
s, size, errors, &byteorder);
1900 static CYTHON_INLINE PyObject* __Pyx_decode_c_string(
1901 const char* cstring, Py_ssize_t start, Py_ssize_t stop,
1902 const char* encoding,
const char* errors,
1903 PyObject* (*decode_func)(
const char *
s, Py_ssize_t size,
const char *errors));
1906 static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *, PyObject *, PyObject *);
1909 static CYTHON_INLINE
void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected);
1912 static CYTHON_INLINE
void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index);
1915 static CYTHON_INLINE
void __Pyx_RaiseNoneNotIterableError(
void);
1918 #if CYTHON_FAST_THREAD_STATE
1919 #define __Pyx_ExceptionSwap(type, value, tb) __Pyx__ExceptionSwap(__pyx_tstate, type, value, tb)
1920 static CYTHON_INLINE
void __Pyx__ExceptionSwap(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
1922 static CYTHON_INLINE
void __Pyx_ExceptionSwap(PyObject **type, PyObject **value, PyObject **tb);
1926 static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list,
int level);
1929 #if CYTHON_COMPILING_IN_CPYTHON
1930 #define __Pyx_TypeCheck(obj, type) __Pyx_IsSubtype(Py_TYPE(obj), (PyTypeObject *)type)
1931 static CYTHON_INLINE
int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b);
1932 static CYTHON_INLINE
int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject *type);
1933 static CYTHON_INLINE
int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *type1, PyObject *type2);
1935 #define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type)
1936 #define __Pyx_PyErr_GivenExceptionMatches(err, type) PyErr_GivenExceptionMatches(err, type)
1937 #define __Pyx_PyErr_GivenExceptionMatches2(err, type1, type2) (PyErr_GivenExceptionMatches(err, type1) || PyErr_GivenExceptionMatches(err, type2))
1939 #define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception)
1941 static CYTHON_UNUSED
int __pyx_memoryview_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags);
1943 #if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS
1944 static CYTHON_INLINE
int __Pyx_ListComp_Append(PyObject* list, PyObject* x) {
1945 PyListObject*
L = (PyListObject*) list;
1946 Py_ssize_t len = Py_SIZE(list);
1947 if (likely(
L->allocated > len)) {
1949 PyList_SET_ITEM(list, len, x);
1950 __Pyx_SET_SIZE(list, len + 1);
1953 return PyList_Append(list, x);
1956 #define __Pyx_ListComp_Append(L,x) PyList_Append(L,x)
1960 #if !CYTHON_COMPILING_IN_PYPY
1961 static PyObject* __Pyx_PyInt_AddObjC(PyObject *op1, PyObject *op2,
long intval,
int inplace,
int zerodivision_check);
1963 #define __Pyx_PyInt_AddObjC(op1, op2, intval, inplace, zerodivision_check)\
1964 (inplace ? PyNumber_InPlaceAdd(op1, op2) : PyNumber_Add(op1, op2))
1968 static CYTHON_INLINE
int __Pyx_PyList_Extend(PyObject*
L, PyObject*
v) {
1969 #if CYTHON_COMPILING_IN_CPYTHON
1970 PyObject* none = _PyList_Extend((PyListObject*)
L,
v);
1971 if (unlikely(!none))
1976 return PyList_SetSlice(
L, PY_SSIZE_T_MAX, PY_SSIZE_T_MAX,
v);
1981 #if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS
1982 static CYTHON_INLINE
int __Pyx_PyList_Append(PyObject* list, PyObject* x) {
1983 PyListObject*
L = (PyListObject*) list;
1984 Py_ssize_t len = Py_SIZE(list);
1985 if (likely(
L->allocated > len) & likely(len > (
L->allocated >> 1))) {
1987 PyList_SET_ITEM(list, len, x);
1988 __Pyx_SET_SIZE(list, len + 1);
1991 return PyList_Append(list, x);
1994 #define __Pyx_PyList_Append(L,x) PyList_Append(L,x)
1998 static CYTHON_INLINE
void __Pyx_RaiseUnboundLocalError(
const char *varname);
2001 static CYTHON_INLINE
long __Pyx_div_long(
long,
long);
2004 static CYTHON_INLINE
int __Pyx_PySequence_ContainsTF(PyObject* item, PyObject* seq,
int eq) {
2005 int result = PySequence_Contains(seq, item);
2006 return unlikely(result < 0) ? result : (result == (eq == Py_EQ));
2010 static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name);
2013 static CYTHON_INLINE
int __Pyx_HasAttr(PyObject *, PyObject *);
2016 #if PY_MAJOR_VERSION < 3
2017 #define __Pyx_PyString_Join __Pyx_PyBytes_Join
2018 #define __Pyx_PyBaseString_Join(s, v) (PyUnicode_CheckExact(s) ? PyUnicode_Join(s, v) : __Pyx_PyBytes_Join(s, v))
2020 #define __Pyx_PyString_Join PyUnicode_Join
2021 #define __Pyx_PyBaseString_Join PyUnicode_Join
2023 #if CYTHON_COMPILING_IN_CPYTHON
2024 #if PY_MAJOR_VERSION < 3
2025 #define __Pyx_PyBytes_Join _PyString_Join
2027 #define __Pyx_PyBytes_Join _PyBytes_Join
2030 static CYTHON_INLINE PyObject* __Pyx_PyBytes_Join(PyObject* sep, PyObject* values);
2034 #if PY_MAJOR_VERSION >= 3
2035 #define __Pyx_PyObject_Unicode(obj)\
2036 (likely(PyUnicode_CheckExact(obj)) ? __Pyx_NewRef(obj) : PyObject_Str(obj))
2038 #define __Pyx_PyObject_Unicode(obj)\
2039 (likely(PyUnicode_CheckExact(obj)) ? __Pyx_NewRef(obj) : PyObject_Unicode(obj))
2043 #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
2044 static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name);
2046 #define __Pyx_PyObject_GenericGetAttrNoDict PyObject_GenericGetAttr
2050 #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
2051 static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name);
2053 #define __Pyx_PyObject_GenericGetAttr PyObject_GenericGetAttr
2057 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name);
2060 static int __Pyx_setup_reduce(PyObject* type_obj);
2063 static int __Pyx_SetVtable(PyObject *dict,
void *vtable);
2066 #ifndef __PYX_HAVE_RT_ImportType_proto
2067 #define __PYX_HAVE_RT_ImportType_proto
2068 enum __Pyx_ImportType_CheckSize {
2069 __Pyx_ImportType_CheckSize_Error = 0,
2070 __Pyx_ImportType_CheckSize_Warn = 1,
2071 __Pyx_ImportType_CheckSize_Ignore = 2
2073 static PyTypeObject *__Pyx_ImportType(PyObject* module,
const char *module_name,
const char *class_name,
size_t size,
enum __Pyx_ImportType_CheckSize check_size);
2077 #ifdef CYTHON_CLINE_IN_TRACEBACK
2078 #define __Pyx_CLineForTraceback(tstate, c_line) (((CYTHON_CLINE_IN_TRACEBACK)) ? c_line : 0)
2080 static int __Pyx_CLineForTraceback(PyThreadState *tstate,
int c_line);
2085 PyCodeObject* code_object;
2087 } __Pyx_CodeObjectCacheEntry;
2088 struct __Pyx_CodeObjectCache {
2091 __Pyx_CodeObjectCacheEntry* entries;
2093 static struct __Pyx_CodeObjectCache __pyx_code_cache = {0,0,NULL};
2094 static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries,
int count,
int code_line);
2095 static PyCodeObject *__pyx_find_code_object(
int code_line);
2096 static void __pyx_insert_code_object(
int code_line, PyCodeObject* code_object);
2099 static void __Pyx_AddTraceback(
const char *funcname,
int c_line,
2100 int py_line,
const char *filename);
2103 #if defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6))
2104 #define __Pyx_HAS_GCC_DIAGNOSTIC
2108 static CYTHON_INLINE PyObject *__pyx_memview_get_int(
const char *itemp);
2109 static CYTHON_INLINE
int __pyx_memview_set_int(
const char *itemp, PyObject *obj);
2112 static CYTHON_INLINE PyObject *__pyx_memview_get_double(
const char *itemp);
2113 static CYTHON_INLINE
int __pyx_memview_set_double(
const char *itemp, PyObject *obj);
2116 static int __Pyx_Print(PyObject*, PyObject *,
int);
2117 #if CYTHON_COMPILING_IN_PYPY || PY_MAJOR_VERSION >= 3
2118 static PyObject* __pyx_print = 0;
2119 static PyObject* __pyx_print_kwargs = 0;
2125 #define __Pyx_CREAL(z) ((z).real())
2126 #define __Pyx_CIMAG(z) ((z).imag())
2128 #define __Pyx_CREAL(z) (__real__(z))
2129 #define __Pyx_CIMAG(z) (__imag__(z))
2132 #define __Pyx_CREAL(z) ((z).real)
2133 #define __Pyx_CIMAG(z) ((z).imag)
2135 #if defined(__cplusplus) && CYTHON_CCOMPLEX\
2136 && (defined(_WIN32) || defined(__clang__) || (defined(__GNUC__) && (__GNUC__ >= 5 || __GNUC__ == 4 && __GNUC_MINOR__ >= 4 )) || __cplusplus >= 201103)
2137 #define __Pyx_SET_CREAL(z,x) ((z).real(x))
2138 #define __Pyx_SET_CIMAG(z,y) ((z).imag(y))
2140 #define __Pyx_SET_CREAL(z,x) __Pyx_CREAL(z) = (x)
2141 #define __Pyx_SET_CIMAG(z,y) __Pyx_CIMAG(z) = (y)
2146 #define __Pyx_c_eq_float(a, b) ((a)==(b))
2147 #define __Pyx_c_sum_float(a, b) ((a)+(b))
2148 #define __Pyx_c_diff_float(a, b) ((a)-(b))
2149 #define __Pyx_c_prod_float(a, b) ((a)*(b))
2150 #define __Pyx_c_quot_float(a, b) ((a)/(b))
2151 #define __Pyx_c_neg_float(a) (-(a))
2153 #define __Pyx_c_is_zero_float(z) ((z)==(float)0)
2154 #define __Pyx_c_conj_float(z) (::std::conj(z))
2156 #define __Pyx_c_abs_float(z) (::std::abs(z))
2157 #define __Pyx_c_pow_float(a, b) (::std::pow(a, b))
2160 #define __Pyx_c_is_zero_float(z) ((z)==0)
2161 #define __Pyx_c_conj_float(z) (conjf(z))
2163 #define __Pyx_c_abs_float(z) (cabsf(z))
2164 #define __Pyx_c_pow_float(a, b) (cpowf(a, b))
2168 static CYTHON_INLINE
int __Pyx_c_eq_float(__pyx_t_float_complex, __pyx_t_float_complex);
2169 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_sum_float(__pyx_t_float_complex, __pyx_t_float_complex);
2170 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_diff_float(__pyx_t_float_complex, __pyx_t_float_complex);
2171 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_prod_float(__pyx_t_float_complex, __pyx_t_float_complex);
2172 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex, __pyx_t_float_complex);
2173 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_neg_float(__pyx_t_float_complex);
2174 static CYTHON_INLINE
int __Pyx_c_is_zero_float(__pyx_t_float_complex);
2175 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_conj_float(__pyx_t_float_complex);
2177 static CYTHON_INLINE
float __Pyx_c_abs_float(__pyx_t_float_complex);
2178 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_pow_float(__pyx_t_float_complex, __pyx_t_float_complex);
2184 #define __Pyx_c_eq_double(a, b) ((a)==(b))
2185 #define __Pyx_c_sum_double(a, b) ((a)+(b))
2186 #define __Pyx_c_diff_double(a, b) ((a)-(b))
2187 #define __Pyx_c_prod_double(a, b) ((a)*(b))
2188 #define __Pyx_c_quot_double(a, b) ((a)/(b))
2189 #define __Pyx_c_neg_double(a) (-(a))
2191 #define __Pyx_c_is_zero_double(z) ((z)==(double)0)
2192 #define __Pyx_c_conj_double(z) (::std::conj(z))
2194 #define __Pyx_c_abs_double(z) (::std::abs(z))
2195 #define __Pyx_c_pow_double(a, b) (::std::pow(a, b))
2198 #define __Pyx_c_is_zero_double(z) ((z)==0)
2199 #define __Pyx_c_conj_double(z) (conj(z))
2201 #define __Pyx_c_abs_double(z) (cabs(z))
2202 #define __Pyx_c_pow_double(a, b) (cpow(a, b))
2206 static CYTHON_INLINE
int __Pyx_c_eq_double(__pyx_t_double_complex, __pyx_t_double_complex);
2207 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_sum_double(__pyx_t_double_complex, __pyx_t_double_complex);
2208 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_diff_double(__pyx_t_double_complex, __pyx_t_double_complex);
2209 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_prod_double(__pyx_t_double_complex, __pyx_t_double_complex);
2210 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex, __pyx_t_double_complex);
2211 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_neg_double(__pyx_t_double_complex);
2212 static CYTHON_INLINE
int __Pyx_c_is_zero_double(__pyx_t_double_complex);
2213 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_conj_double(__pyx_t_double_complex);
2215 static CYTHON_INLINE
double __Pyx_c_abs_double(__pyx_t_double_complex);
2216 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_pow_double(__pyx_t_double_complex, __pyx_t_double_complex);
2220 #if PY_MAJOR_VERSION < 3
2221 static int __Pyx_GetBuffer(PyObject *obj, Py_buffer *view,
int flags);
2222 static void __Pyx_ReleaseBuffer(Py_buffer *view);
2224 #define __Pyx_GetBuffer PyObject_GetBuffer
2225 #define __Pyx_ReleaseBuffer PyBuffer_Release
2231 Py_ssize_t shape, strides, suboffsets;
2232 } __Pyx_Buf_DimInfo;
2238 __Pyx_Buffer *rcbuffer;
2240 __Pyx_Buf_DimInfo diminfo[8];
2241 } __Pyx_LocalBuf_ND;
2244 static int __pyx_memviewslice_is_contig(
const __Pyx_memviewslice mvs,
char order,
int ndim);
2247 static int __pyx_slices_overlap(__Pyx_memviewslice *slice1,
2248 __Pyx_memviewslice *slice2,
2249 int ndim,
size_t itemsize);
2252 static CYTHON_INLINE PyObject *__pyx_capsule_create(
void *p,
const char *sig);
2255 static CYTHON_INLINE
int __Pyx_PyInt_As_int(PyObject *);
2258 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(
int value);
2261 struct __pyx_typeinfo_string {
2264 static struct __pyx_typeinfo_string __Pyx_TypeInfoToFormat(__Pyx_TypeInfo *type);
2267 static int __Pyx_PrintOne(PyObject* stream, PyObject *o);
2270 static __Pyx_memviewslice
2271 __pyx_memoryview_copy_new_contig(
const __Pyx_memviewslice *from_mvs,
2272 const char *mode,
int ndim,
2273 size_t sizeof_dtype,
int contig_flag,
2274 int dtype_is_object);
2277 #define __Pyx_BUF_MAX_NDIMS %(BUF_MAX_NDIMS)d
2278 #define __Pyx_MEMVIEW_DIRECT 1
2279 #define __Pyx_MEMVIEW_PTR 2
2280 #define __Pyx_MEMVIEW_FULL 4
2281 #define __Pyx_MEMVIEW_CONTIG 8
2282 #define __Pyx_MEMVIEW_STRIDED 16
2283 #define __Pyx_MEMVIEW_FOLLOW 32
2284 #define __Pyx_IS_C_CONTIG 1
2285 #define __Pyx_IS_F_CONTIG 2
2286 static int __Pyx_init_memviewslice(
2287 struct __pyx_memoryview_obj *memview,
2289 __Pyx_memviewslice *memviewslice,
2290 int memview_is_new_reference);
2291 static CYTHON_INLINE
int __pyx_add_acquisition_count_locked(
2292 __pyx_atomic_int *acquisition_count, PyThread_type_lock lock);
2293 static CYTHON_INLINE
int __pyx_sub_acquisition_count_locked(
2294 __pyx_atomic_int *acquisition_count, PyThread_type_lock lock);
2295 #define __pyx_get_slice_count_pointer(memview) (memview->acquisition_count_aligned_p)
2296 #define __pyx_get_slice_count(memview) (*__pyx_get_slice_count_pointer(memview))
2297 #define __PYX_INC_MEMVIEW(slice, have_gil) __Pyx_INC_MEMVIEW(slice, have_gil, __LINE__)
2298 #define __PYX_XDEC_MEMVIEW(slice, have_gil) __Pyx_XDEC_MEMVIEW(slice, have_gil, __LINE__)
2299 static CYTHON_INLINE
void __Pyx_INC_MEMVIEW(__Pyx_memviewslice *,
int,
int);
2300 static CYTHON_INLINE
void __Pyx_XDEC_MEMVIEW(__Pyx_memviewslice *,
int,
int);
2303 static CYTHON_INLINE
long __Pyx_PyInt_As_long(PyObject *);
2306 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(
long value);
2309 static CYTHON_INLINE
char __Pyx_PyInt_As_char(PyObject *);
2312 static int __Pyx_check_binary_version(
void);
2315 static int __Pyx_InitStrings(__Pyx_StringTabEntry *t);
2317 static PyObject *__pyx_array_get_memview(
struct __pyx_array_obj *__pyx_v_self);
2318 static char *__pyx_memoryview_get_item_pointer(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index);
2319 static PyObject *__pyx_memoryview_is_slice(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_obj);
2320 static PyObject *__pyx_memoryview_setitem_slice_assignment(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_dst, PyObject *__pyx_v_src);
2321 static PyObject *__pyx_memoryview_setitem_slice_assign_scalar(
struct __pyx_memoryview_obj *__pyx_v_self,
struct __pyx_memoryview_obj *__pyx_v_dst, PyObject *__pyx_v_value);
2322 static PyObject *__pyx_memoryview_setitem_indexed(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value);
2323 static PyObject *__pyx_memoryview_convert_item_to_object(
struct __pyx_memoryview_obj *__pyx_v_self,
char *__pyx_v_itemp);
2324 static PyObject *__pyx_memoryview_assign_item_from_object(
struct __pyx_memoryview_obj *__pyx_v_self,
char *__pyx_v_itemp, PyObject *__pyx_v_value);
2325 static PyObject *__pyx_memoryviewslice_convert_item_to_object(
struct __pyx_memoryviewslice_obj *__pyx_v_self,
char *__pyx_v_itemp);
2326 static PyObject *__pyx_memoryviewslice_assign_item_from_object(
struct __pyx_memoryviewslice_obj *__pyx_v_self,
char *__pyx_v_itemp, PyObject *__pyx_v_value);
2337 static PyTypeObject *__pyx_ptype_7cpython_4type_type = 0;
2350 static PyTypeObject *__pyx_ptype_5numpy_dtype = 0;
2351 static PyTypeObject *__pyx_ptype_5numpy_flatiter = 0;
2352 static PyTypeObject *__pyx_ptype_5numpy_broadcast = 0;
2353 static PyTypeObject *__pyx_ptype_5numpy_ndarray = 0;
2354 static PyTypeObject *__pyx_ptype_5numpy_generic = 0;
2355 static PyTypeObject *__pyx_ptype_5numpy_number = 0;
2356 static PyTypeObject *__pyx_ptype_5numpy_integer = 0;
2357 static PyTypeObject *__pyx_ptype_5numpy_signedinteger = 0;
2358 static PyTypeObject *__pyx_ptype_5numpy_unsignedinteger = 0;
2359 static PyTypeObject *__pyx_ptype_5numpy_inexact = 0;
2360 static PyTypeObject *__pyx_ptype_5numpy_floating = 0;
2361 static PyTypeObject *__pyx_ptype_5numpy_complexfloating = 0;
2362 static PyTypeObject *__pyx_ptype_5numpy_flexible = 0;
2363 static PyTypeObject *__pyx_ptype_5numpy_character = 0;
2364 static PyTypeObject *__pyx_ptype_5numpy_ufunc = 0;
2371 static struct __pyx_array_obj *__pyx_array_new(PyObject *, Py_ssize_t,
char *,
char *,
char *);
2376 static PyTypeObject *__pyx_ptype_10cmeshTools_CMesh = 0;
2377 static PyTypeObject *__pyx_ptype_10cmeshTools_CMultilevelMesh = 0;
2378 static PyTypeObject *__pyx_array_type = 0;
2379 static PyTypeObject *__pyx_MemviewEnum_type = 0;
2380 static PyTypeObject *__pyx_memoryview_type = 0;
2381 static PyTypeObject *__pyx_memoryviewslice_type = 0;
2382 static PyObject *
generic = 0;
2383 static PyObject *strided = 0;
2384 static PyObject *indirect = 0;
2385 static PyObject *contiguous = 0;
2386 static PyObject *indirect_contiguous = 0;
2387 static int __pyx_memoryview_thread_locks_used;
2388 static PyThread_type_lock __pyx_memoryview_thread_locks[8];
2389 static struct __pyx_obj_10cmeshTools_CMesh *__pyx_f_10cmeshTools_CMesh_FromMesh(
struct Mesh);
2390 static void __pyx_f_10cmeshTools_generateTetrahedralMeshFromRectangularGrid(
int,
int,
int,
double,
double,
double,
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2391 static void __pyx_f_10cmeshTools_cmeshToolsComputeGeometricInfo_tetrahedron(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2392 static void __pyx_f_10cmeshTools_generateFromTriangleFiles(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2393 static void __pyx_f_10cmeshTools_writeTriangleFiles(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2394 static void __pyx_f_10cmeshTools_generateFromTetgenFiles(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2395 static void __pyx_f_10cmeshTools_generateFromTetgenFilesParallel(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2396 static void __pyx_f_10cmeshTools_writeTetgenFiles(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2397 static void __pyx_f_10cmeshTools_write3dmFiles(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2398 static void __pyx_f_10cmeshTools_write2dmFiles(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2399 static void __pyx_f_10cmeshTools_generateFromHexFile(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2400 static void __pyx_f_10cmeshTools_generateFrom3DMFile(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2401 static void __pyx_f_10cmeshTools_generateFrom2DMFile(
struct __pyx_obj_10cmeshTools_CMesh *, PyObject *,
int,
int __pyx_skip_dispatch);
2402 static void __pyx_f_10cmeshTools_computeGeometricInfo_tetrahedron(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2403 static void __pyx_f_10cmeshTools_allocateGeometricInfo_tetrahedron(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2404 static void __pyx_f_10cmeshTools_allocateNodeAndElementNodeDataStructures(
struct __pyx_obj_10cmeshTools_CMesh *,
int,
int,
int,
int __pyx_skip_dispatch);
2405 static void __pyx_f_10cmeshTools_constructElementBoundaryElementsArray(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2406 static void __pyx_f_10cmeshTools_generateTriangularMeshFromRectangularGrid(
int,
int,
double,
double,
struct __pyx_obj_10cmeshTools_CMesh *,
int,
int __pyx_skip_dispatch);
2407 static void __pyx_f_10cmeshTools_generateHexahedralMeshFromRectangularGrid(
int,
int,
int,
int,
int,
int,
double,
double,
double,
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2408 static void __pyx_f_10cmeshTools_generateQuadrilateralMeshFromRectangularGrid(
int,
int,
int,
int,
double,
double,
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2409 static void __pyx_f_10cmeshTools_computeGeometricInfo_triangle(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2410 static void __pyx_f_10cmeshTools_allocateGeometricInfo_triangle(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2411 static void __pyx_f_10cmeshTools_generateEdgeMeshFromRectangularGrid(
int,
double,
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2412 static void __pyx_f_10cmeshTools_computeGeometricInfo_edge(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2413 static void __pyx_f_10cmeshTools_allocateGeometricInfo_edge(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2414 static void __pyx_f_10cmeshTools_computeGeometricInfo_hexahedron(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2415 static void __pyx_f_10cmeshTools_computeGeometricInfo_quadrilateral(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2416 static void __pyx_f_10cmeshTools_allocateGeometricInfo_hexahedron(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2417 static void __pyx_f_10cmeshTools_allocateGeometricInfo_quadrilateral(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2418 static void __pyx_f_10cmeshTools_computeGeometricInfo_NURBS(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2419 static void __pyx_f_10cmeshTools_allocateGeometricInfo_NURBS(
struct __pyx_obj_10cmeshTools_CMesh *,
int __pyx_skip_dispatch);
2420 static struct __pyx_array_obj *__pyx_array_new(PyObject *, Py_ssize_t,
char *,
char *,
char *);
2421 static void *__pyx_align_pointer(
void *,
size_t);
2422 static PyObject *__pyx_memoryview_new(PyObject *,
int,
int, __Pyx_TypeInfo *);
2423 static CYTHON_INLINE
int __pyx_memoryview_check(PyObject *);
2424 static PyObject *_unellipsify(PyObject *,
int);
2425 static PyObject *assert_direct_dimensions(Py_ssize_t *,
int);
2426 static struct __pyx_memoryview_obj *__pyx_memview_slice(
struct __pyx_memoryview_obj *, PyObject *);
2427 static int __pyx_memoryview_slice_memviewslice(__Pyx_memviewslice *, Py_ssize_t, Py_ssize_t, Py_ssize_t,
int,
int,
int *, Py_ssize_t, Py_ssize_t, Py_ssize_t,
int,
int,
int,
int);
2428 static char *__pyx_pybuffer_index(Py_buffer *,
char *, Py_ssize_t, Py_ssize_t);
2429 static int __pyx_memslice_transpose(__Pyx_memviewslice *);
2430 static PyObject *__pyx_memoryview_fromslice(__Pyx_memviewslice,
int, PyObject *(*)(
char *),
int (*)(
char *, PyObject *),
int);
2431 static __Pyx_memviewslice *__pyx_memoryview_get_slice_from_memoryview(
struct __pyx_memoryview_obj *, __Pyx_memviewslice *);
2432 static void __pyx_memoryview_slice_copy(
struct __pyx_memoryview_obj *, __Pyx_memviewslice *);
2433 static PyObject *__pyx_memoryview_copy_object(
struct __pyx_memoryview_obj *);
2434 static PyObject *__pyx_memoryview_copy_object_from_slice(
struct __pyx_memoryview_obj *, __Pyx_memviewslice *);
2435 static Py_ssize_t abs_py_ssize_t(Py_ssize_t);
2436 static char __pyx_get_best_slice_order(__Pyx_memviewslice *,
int);
2437 static void _copy_strided_to_strided(
char *, Py_ssize_t *,
char *, Py_ssize_t *, Py_ssize_t *, Py_ssize_t *,
int,
size_t);
2438 static void copy_strided_to_strided(__Pyx_memviewslice *, __Pyx_memviewslice *,
int,
size_t);
2439 static Py_ssize_t __pyx_memoryview_slice_get_size(__Pyx_memviewslice *,
int);
2440 static Py_ssize_t __pyx_fill_contig_strides_array(Py_ssize_t *, Py_ssize_t *, Py_ssize_t,
int,
char);
2441 static void *__pyx_memoryview_copy_data_to_temp(__Pyx_memviewslice *, __Pyx_memviewslice *,
char,
int);
2442 static int __pyx_memoryview_err_extents(
int, Py_ssize_t, Py_ssize_t);
2443 static int __pyx_memoryview_err_dim(PyObject *,
char *,
int);
2444 static int __pyx_memoryview_err(PyObject *,
char *);
2445 static int __pyx_memoryview_copy_contents(__Pyx_memviewslice, __Pyx_memviewslice,
int,
int,
int);
2446 static void __pyx_memoryview_broadcast_leading(__Pyx_memviewslice *,
int,
int);
2447 static void __pyx_memoryview_refcount_copying(__Pyx_memviewslice *,
int,
int,
int);
2448 static void __pyx_memoryview_refcount_objects_in_slice_with_gil(
char *, Py_ssize_t *, Py_ssize_t *,
int,
int);
2449 static void __pyx_memoryview_refcount_objects_in_slice(
char *, Py_ssize_t *, Py_ssize_t *,
int,
int);
2450 static void __pyx_memoryview_slice_assign_scalar(__Pyx_memviewslice *,
int,
size_t,
void *,
int);
2451 static void __pyx_memoryview__slice_assign_scalar(
char *, Py_ssize_t *, Py_ssize_t *,
int,
size_t,
void *);
2452 static PyObject *__pyx_unpickle_Enum__set_state(
struct __pyx_MemviewEnum_obj *, PyObject *);
2453 static PyObject *__pyx_format_from_typeinfo(__Pyx_TypeInfo *);
2454 static __Pyx_TypeInfo __Pyx_TypeInfo_int = {
"int", NULL,
sizeof(int), { 0 }, 0, IS_UNSIGNED(
int) ?
'U' :
'I', IS_UNSIGNED(
int), 0 };
2455 static __Pyx_TypeInfo __Pyx_TypeInfo_double = {
"double", NULL,
sizeof(double), { 0 }, 0,
'R', 0, 0 };
2456 #define __Pyx_MODULE_NAME "cmeshTools"
2457 extern int __pyx_module_is_main_cmeshTools;
2458 int __pyx_module_is_main_cmeshTools = 0;
2461 static PyObject *__pyx_builtin_TypeError;
2462 static PyObject *__pyx_builtin_range;
2463 static PyObject *__pyx_builtin_ImportError;
2464 static PyObject *__pyx_builtin_ValueError;
2465 static PyObject *__pyx_builtin_MemoryError;
2466 static PyObject *__pyx_builtin_enumerate;
2467 static PyObject *__pyx_builtin_Ellipsis;
2468 static PyObject *__pyx_builtin_id;
2469 static PyObject *__pyx_builtin_IndexError;
2470 static const char __pyx_k_O[] =
"O";
2471 static const char __pyx_k_T[] =
"T{";
2472 static const char __pyx_k_c[] =
"c";
2473 static const char __pyx_k_h[] =
"h";
2474 static const char __pyx_k_s[] =
"(%s)";
2475 static const char __pyx_k_Lx[] =
"Lx";
2476 static const char __pyx_k_Ly[] =
"Ly";
2477 static const char __pyx_k_Lz[] =
"Lz";
2478 static const char __pyx_k_id[] =
"id";
2479 static const char __pyx_k_np[] =
"np";
2480 static const char __pyx_k_nx[] =
"nx";
2481 static const char __pyx_k_ny[] =
"ny";
2482 static const char __pyx_k_nz[] =
"nz";
2483 static const char __pyx_k_px[] =
"px";
2484 static const char __pyx_k_py[] =
"py";
2485 static const char __pyx_k_pz[] =
"pz";
2486 static const char __pyx_k_MPI[] =
"MPI";
2487 static const char __pyx_k__27[] =
"^";
2488 static const char __pyx_k__28[] =
"";
2489 static const char __pyx_k__29[] =
":";
2490 static const char __pyx_k__30[] =
"}";
2491 static const char __pyx_k__31[] =
",";
2492 static const char __pyx_k_end[] =
"end";
2493 static const char __pyx_k_new[] =
"__new__";
2494 static const char __pyx_k_obj[] =
"obj";
2495 static const char __pyx_k_Comm[] =
"Comm";
2496 static const char __pyx_k_base[] =
"base";
2497 static const char __pyx_k_dict[] =
"__dict__";
2498 static const char __pyx_k_file[] =
"file";
2499 static const char __pyx_k_hMin[] =
"hMin";
2500 static const char __pyx_k_join[] =
"join";
2501 static const char __pyx_k_main[] =
"__main__";
2502 static const char __pyx_k_mode[] =
"mode";
2503 static const char __pyx_k_name[] =
"name";
2504 static const char __pyx_k_ndim[] =
"ndim";
2505 static const char __pyx_k_pack[] =
"pack";
2506 static const char __pyx_k_size[] =
"size";
2507 static const char __pyx_k_step[] =
"step";
2508 static const char __pyx_k_stop[] =
"stop";
2509 static const char __pyx_k_test[] =
"__test__";
2510 static const char __pyx_k_ASCII[] =
"ASCII";
2511 static const char __pyx_k_CMesh[] =
"CMesh";
2512 static const char __pyx_k_class[] =
"__class__";
2513 static const char __pyx_k_cmesh[] =
"cmesh";
2514 static const char __pyx_k_dtype[] =
"dtype";
2515 static const char __pyx_k_empty[] =
"empty";
2516 static const char __pyx_k_error[] =
"error";
2517 static const char __pyx_k_flags[] =
"flags";
2518 static const char __pyx_k_int32[] =
"int32";
2519 static const char __pyx_k_numpy[] =
"numpy";
2520 static const char __pyx_k_print[] =
"print";
2521 static const char __pyx_k_range[] =
"range";
2522 static const char __pyx_k_shape[] =
"shape";
2523 static const char __pyx_k_start[] =
"start";
2524 static const char __pyx_k_zeros[] =
"zeros";
2525 static const char __pyx_k_U_KNOT[] =
"U_KNOT";
2526 static const char __pyx_k_V_KNOT[] =
"V_KNOT";
2527 static const char __pyx_k_W_KNOT[] =
"W_KNOT";
2528 static const char __pyx_k_encode[] =
"encode";
2529 static const char __pyx_k_failed[] =
"failed";
2530 static const char __pyx_k_format[] =
"format";
2531 static const char __pyx_k_import[] =
"__import__";
2532 static const char __pyx_k_mpi4py[] =
"mpi4py";
2533 static const char __pyx_k_nSpace[] =
"nSpace";
2534 static const char __pyx_k_name_2[] =
"__name__";
2535 static const char __pyx_k_pickle[] =
"pickle";
2536 static const char __pyx_k_reduce[] =
"__reduce__";
2537 static const char __pyx_k_struct[] =
"struct";
2538 static const char __pyx_k_unpack[] =
"unpack";
2539 static const char __pyx_k_update[] =
"update";
2540 static const char __pyx_k_volume[] =
"volume";
2541 static const char __pyx_k_asarray[] =
"asarray";
2542 static const char __pyx_k_fortran[] =
"fortran";
2543 static const char __pyx_k_memview[] =
"memview";
2544 static const char __pyx_k_nLevels[] =
"nLevels";
2545 static const char __pyx_k_proteus[] =
"proteus";
2546 static const char __pyx_k_weights[] =
"weights";
2547 static const char __pyx_k_Ellipsis[] =
"Ellipsis";
2548 static const char __pyx_k_filebase[] =
"filebase";
2549 static const char __pyx_k_getstate[] =
"__getstate__";
2550 static const char __pyx_k_itemsize[] =
"itemsize";
2551 static const char __pyx_k_pyx_type[] =
"__pyx_type";
2552 static const char __pyx_k_setstate[] =
"__setstate__";
2553 static const char __pyx_k_sigmaMax[] =
"sigmaMax";
2554 static const char __pyx_k_TypeError[] =
"TypeError";
2555 static const char __pyx_k_cmeshList[] =
"cmeshList";
2556 static const char __pyx_k_enumerate[] =
"enumerate";
2557 static const char __pyx_k_nodeArray[] =
"nodeArray";
2558 static const char __pyx_k_pyx_state[] =
"__pyx_state";
2559 static const char __pyx_k_reduce_ex[] =
"__reduce_ex__";
2560 static const char __pyx_k_IndexError[] =
"IndexError";
2561 static const char __pyx_k_ValueError[] =
"ValueError";
2562 static const char __pyx_k_cmeshTools[] =
"cmeshTools";
2563 static const char __pyx_k_elementIJK[] =
"elementIJK";
2564 static const char __pyx_k_pyx_result[] =
"__pyx_result";
2565 static const char __pyx_k_pyx_vtable[] =
"__pyx_vtable__";
2566 static const char __pyx_k_ImportError[] =
"ImportError";
2567 static const char __pyx_k_MemoryError[] =
"MemoryError";
2568 static const char __pyx_k_PickleError[] =
"PickleError";
2569 static const char __pyx_k_finestLevel[] =
"finestLevel";
2570 static const char __pyx_k_pyx_checksum[] =
"__pyx_checksum";
2571 static const char __pyx_k_stringsource[] =
"stringsource";
2572 static const char __pyx_k_triangleFlag[] =
"triangleFlag";
2573 static const char __pyx_k_nEdges_global[] =
"nEdges_global";
2574 static const char __pyx_k_nNodes_global[] =
"nNodes_global";
2575 static const char __pyx_k_nodeStarArray[] =
"nodeStarArray";
2576 static const char __pyx_k_pyx_getbuffer[] =
"__pyx_getbuffer";
2577 static const char __pyx_k_reduce_cython[] =
"__reduce_cython__";
2578 static const char __pyx_k_wrong_nLevels[] =
"wrong nLevels";
2579 static const char __pyx_k_edgeNodesArray[] =
"edgeNodesArray";
2580 static const char __pyx_k_nNodes_element[] =
"nNodes_element";
2581 static const char __pyx_k_refineTypeFlag[] =
"refineTypeFlag";
2582 static const char __pyx_k_CMultilevelMesh[] =
"CMultilevelMesh";
2583 static const char __pyx_k_View_MemoryView[] =
"View.MemoryView";
2584 static const char __pyx_k_allocate_buffer[] =
"allocate_buffer";
2585 static const char __pyx_k_cmultilevelMesh[] =
"cmultilevelMesh";
2586 static const char __pyx_k_dtype_is_object[] =
"dtype_is_object";
2587 static const char __pyx_k_elementTagArray[] =
"elementTagArray";
2588 static const char __pyx_k_nodeStarOffsets[] =
"nodeStarOffsets";
2589 static const char __pyx_k_pyx_PickleError[] =
"__pyx_PickleError";
2590 static const char __pyx_k_setstate_cython[] =
"__setstate_cython__";
2591 static const char __pyx_k_nElements_global[] =
"nElements_global";
2592 static const char __pyx_k_nodeSupportArray[] =
"nodeSupportArray";
2593 static const char __pyx_k_elementNodesArray[] =
"elementNodesArray";
2594 static const char __pyx_k_nodeElementsArray[] =
"nodeElementsArray";
2595 static const char __pyx_k_nodeMaterialTypes[] =
"nodeMaterialTypes";
2596 static const char __pyx_k_pyx_unpickle_Enum[] =
"__pyx_unpickle_Enum";
2597 static const char __pyx_k_cline_in_traceback[] =
"cline_in_traceback";
2598 static const char __pyx_k_max_nElements_node[] =
"max_nElements_node";
2599 static const char __pyx_k_nodeDiametersArray[] =
"nodeDiametersArray";
2600 static const char __pyx_k_nodeElementOffsets[] =
"nodeElementOffsets";
2601 static const char __pyx_k_setNewestNodeBases[] =
"setNewestNodeBases";
2602 static const char __pyx_k_strided_and_direct[] =
"<strided and direct>";
2603 static const char __pyx_k_elementMaterialTypes[] =
"elementMaterialTypes";
2604 static const char __pyx_k_strided_and_indirect[] =
"<strided and indirect>";
2605 static const char __pyx_k_contiguous_and_direct[] =
"<contiguous and direct>";
2606 static const char __pyx_k_elementDiametersArray[] =
"elementDiametersArray";
2607 static const char __pyx_k_elementNeighborsArray[] =
"elementNeighborsArray";
2608 static const char __pyx_k_MemoryView_of_r_object[] =
"<MemoryView of %r object>";
2609 static const char __pyx_k_elementBoundariesArray[] =
"elementBoundariesArray";
2610 static const char __pyx_k_nNodes_elementBoundary[] =
"nNodes_elementBoundary";
2611 static const char __pyx_k_proteus_cmeshTools_pyx[] =
"proteus/cmeshTools.pyx";
2612 static const char __pyx_k_MemoryView_of_r_at_0x_x[] =
"<MemoryView of %r at 0x%x>";
2613 static const char __pyx_k_contiguous_and_indirect[] =
"<contiguous and indirect>";
2614 static const char __pyx_k_elementBarycentersArray[] =
"elementBarycentersArray";
2615 static const char __pyx_k_elementParentsArrayList[] =
"elementParentsArrayList";
2616 static const char __pyx_k_max_nNodeNeighbors_node[] =
"max_nNodeNeighbors_node";
2617 static const char __pyx_k_Cannot_index_with_type_s[] =
"Cannot index with type '%s'";
2618 static const char __pyx_k_buildPythonMeshInterface[] =
"buildPythonMeshInterface";
2619 static const char __pyx_k_elementChildrenArrayList[] =
"elementChildrenArrayList";
2620 static const char __pyx_k_Invalid_shape_in_axis_d_d[] =
"Invalid shape in axis %d: %d.";
2621 static const char __pyx_k_elementBoundaryNodesArray[] =
"elementBoundaryNodesArray";
2622 static const char __pyx_k_nElementBoundaries_global[] =
"nElementBoundaries_global";
2623 static const char __pyx_k_elementChildrenOffsetsList[] =
"elementChildrenOffsetsList";
2624 static const char __pyx_k_elementInnerDiametersArray[] =
"elementInnerDiametersArray";
2625 static const char __pyx_k_nElementBoundaries_element[] =
"nElementBoundaries_element";
2626 static const char __pyx_k_itemsize_0_for_cython_array[] =
"itemsize <= 0 for cython.array";
2627 static const char __pyx_k_locallyRefineMultilevelMesh[] =
"locallyRefineMultilevelMesh";
2628 static const char __pyx_k_elementBoundaryElementsArray[] =
"elementBoundaryElementsArray";
2629 static const char __pyx_k_elementBoundaryMaterialTypes[] =
"elementBoundaryMaterialTypes";
2630 static const char __pyx_k_elementBoundaryDiametersArray[] =
"elementBoundaryDiametersArray";
2631 static const char __pyx_k_unable_to_allocate_array_data[] =
"unable to allocate array data.";
2632 static const char __pyx_k_exteriorElementBoundariesArray[] =
"exteriorElementBoundariesArray";
2633 static const char __pyx_k_interiorElementBoundariesArray[] =
"interiorElementBoundariesArray";
2634 static const char __pyx_k_strided_and_direct_or_indirect[] =
"<strided and direct or indirect>";
2635 static const char __pyx_k_elementBoundaryBarycentersArray[] =
"elementBoundaryBarycentersArray";
2636 static const char __pyx_k_numpy_core_multiarray_failed_to[] =
"numpy.core.multiarray failed to import";
2637 static const char __pyx_k_Buffer_view_does_not_expose_stri[] =
"Buffer view does not expose strides";
2638 static const char __pyx_k_Can_only_create_a_buffer_that_is[] =
"Can only create a buffer that is contiguous in memory.";
2639 static const char __pyx_k_Cannot_assign_to_read_only_memor[] =
"Cannot assign to read-only memoryview";
2640 static const char __pyx_k_Cannot_create_writable_memory_vi[] =
"Cannot create writable memory view from read-only memoryview";
2641 static const char __pyx_k_Empty_shape_tuple_for_cython_arr[] =
"Empty shape tuple for cython.array";
2642 static const char __pyx_k_Incompatible_checksums_0x_x_vs_0[] =
"Incompatible checksums (0x%x vs (0xb068931, 0x82a3537, 0x6ae9995) = (name))";
2643 static const char __pyx_k_Indirect_dimensions_not_supporte[] =
"Indirect dimensions not supported";
2644 static const char __pyx_k_Invalid_mode_expected_c_or_fortr[] =
"Invalid mode, expected 'c' or 'fortran', got %s";
2645 static const char __pyx_k_Out_of_bounds_on_buffer_access_a[] =
"Out of bounds on buffer access (axis %d)";
2646 static const char __pyx_k_Unable_to_convert_item_to_object[] =
"Unable to convert item to object";
2647 static const char __pyx_k_buildPythonMeshInterfaceNoArrays[] =
"buildPythonMeshInterfaceNoArrays";
2648 static const char __pyx_k_buildPythonMultilevelMeshInterfa[] =
"buildPythonMultilevelMeshInterface";
2649 static const char __pyx_k_elementBoundaryLocalElementBound[] =
"elementBoundaryLocalElementBoundariesArray";
2650 static const char __pyx_k_got_differing_extents_in_dimensi[] =
"got differing extents in dimension %d (got %d and %d)";
2651 static const char __pyx_k_locallyRefine_nSpace_0_d_not_imp[] =
"locallyRefine nSpace= {0:d} not implemented! Returning.";
2652 static const char __pyx_k_nExteriorElementBoundaries_globa[] =
"nExteriorElementBoundaries_global";
2653 static const char __pyx_k_nInteriorElementBoundaries_globa[] =
"nInteriorElementBoundaries_global";
2654 static const char __pyx_k_no_default___reduce___due_to_non[] =
"no default __reduce__ due to non-trivial __cinit__";
2655 static const char __pyx_k_numpy_core_umath_failed_to_impor[] =
"numpy.core.umath failed to import";
2656 static const char __pyx_k_self_mesh_cannot_be_converted_to[] =
"self.mesh cannot be converted to a Python object for pickling";
2657 static const char __pyx_k_self_multilevelMesh_cannot_be_co[] =
"self.multilevelMesh cannot be converted to a Python object for pickling";
2658 static const char __pyx_k_setNewestNodeBases_0_d_not_imple[] =
"setNewestNodeBases= {0:d} not implemented! Returning";
2659 static const char __pyx_k_unable_to_allocate_shape_and_str[] =
"unable to allocate shape and strides.";
2660 static PyObject *__pyx_n_s_ASCII;
2661 static PyObject *__pyx_kp_s_Buffer_view_does_not_expose_stri;
2662 static PyObject *__pyx_n_s_CMesh;
2663 static PyObject *__pyx_n_s_CMultilevelMesh;
2664 static PyObject *__pyx_kp_s_Can_only_create_a_buffer_that_is;
2665 static PyObject *__pyx_kp_s_Cannot_assign_to_read_only_memor;
2666 static PyObject *__pyx_kp_s_Cannot_create_writable_memory_vi;
2667 static PyObject *__pyx_kp_s_Cannot_index_with_type_s;
2668 static PyObject *__pyx_n_s_Comm;
2669 static PyObject *__pyx_n_s_Ellipsis;
2670 static PyObject *__pyx_kp_s_Empty_shape_tuple_for_cython_arr;
2671 static PyObject *__pyx_n_s_ImportError;
2672 static PyObject *__pyx_kp_s_Incompatible_checksums_0x_x_vs_0;
2673 static PyObject *__pyx_n_s_IndexError;
2674 static PyObject *__pyx_kp_s_Indirect_dimensions_not_supporte;
2675 static PyObject *__pyx_kp_s_Invalid_mode_expected_c_or_fortr;
2676 static PyObject *__pyx_kp_s_Invalid_shape_in_axis_d_d;
2677 static PyObject *__pyx_n_s_Lx;
2678 static PyObject *__pyx_n_s_Ly;
2679 static PyObject *__pyx_n_s_Lz;
2680 static PyObject *__pyx_n_s_MPI;
2681 static PyObject *__pyx_n_s_MemoryError;
2682 static PyObject *__pyx_kp_s_MemoryView_of_r_at_0x_x;
2683 static PyObject *__pyx_kp_s_MemoryView_of_r_object;
2684 static PyObject *__pyx_n_b_O;
2685 static PyObject *__pyx_kp_s_Out_of_bounds_on_buffer_access_a;
2686 static PyObject *__pyx_n_s_PickleError;
2687 static PyObject *__pyx_kp_b_T;
2688 static PyObject *__pyx_n_s_TypeError;
2689 static PyObject *__pyx_n_s_U_KNOT;
2690 static PyObject *__pyx_kp_s_Unable_to_convert_item_to_object;
2691 static PyObject *__pyx_n_s_V_KNOT;
2692 static PyObject *__pyx_n_s_ValueError;
2693 static PyObject *__pyx_n_s_View_MemoryView;
2694 static PyObject *__pyx_n_s_W_KNOT;
2695 static PyObject *__pyx_kp_b__27;
2696 static PyObject *__pyx_kp_b__28;
2697 static PyObject *__pyx_kp_b__29;
2698 static PyObject *__pyx_kp_b__30;
2699 static PyObject *__pyx_kp_u__31;
2700 static PyObject *__pyx_n_s_allocate_buffer;
2701 static PyObject *__pyx_n_s_asarray;
2702 static PyObject *__pyx_n_s_base;
2703 static PyObject *__pyx_n_s_buildPythonMeshInterface;
2704 static PyObject *__pyx_n_s_buildPythonMeshInterfaceNoArrays;
2705 static PyObject *__pyx_n_s_buildPythonMultilevelMeshInterfa;
2706 static PyObject *__pyx_n_s_c;
2707 static PyObject *__pyx_n_u_c;
2708 static PyObject *__pyx_n_s_class;
2709 static PyObject *__pyx_n_s_cline_in_traceback;
2710 static PyObject *__pyx_n_s_cmesh;
2711 static PyObject *__pyx_n_s_cmeshList;
2712 static PyObject *__pyx_n_s_cmeshTools;
2713 static PyObject *__pyx_n_s_cmultilevelMesh;
2714 static PyObject *__pyx_kp_s_contiguous_and_direct;
2715 static PyObject *__pyx_kp_s_contiguous_and_indirect;
2716 static PyObject *__pyx_n_s_dict;
2717 static PyObject *__pyx_n_s_dtype;
2718 static PyObject *__pyx_n_s_dtype_is_object;
2719 static PyObject *__pyx_n_s_edgeNodesArray;
2720 static PyObject *__pyx_n_s_elementBarycentersArray;
2721 static PyObject *__pyx_n_s_elementBoundariesArray;
2722 static PyObject *__pyx_n_s_elementBoundaryBarycentersArray;
2723 static PyObject *__pyx_n_s_elementBoundaryDiametersArray;
2724 static PyObject *__pyx_n_s_elementBoundaryElementsArray;
2725 static PyObject *__pyx_n_s_elementBoundaryLocalElementBound;
2726 static PyObject *__pyx_n_s_elementBoundaryMaterialTypes;
2727 static PyObject *__pyx_n_s_elementBoundaryNodesArray;
2728 static PyObject *__pyx_n_s_elementChildrenArrayList;
2729 static PyObject *__pyx_n_s_elementChildrenOffsetsList;
2730 static PyObject *__pyx_n_s_elementDiametersArray;
2731 static PyObject *__pyx_n_s_elementIJK;
2732 static PyObject *__pyx_n_s_elementInnerDiametersArray;
2733 static PyObject *__pyx_n_s_elementMaterialTypes;
2734 static PyObject *__pyx_n_s_elementNeighborsArray;
2735 static PyObject *__pyx_n_s_elementNodesArray;
2736 static PyObject *__pyx_n_s_elementParentsArrayList;
2737 static PyObject *__pyx_n_s_elementTagArray;
2738 static PyObject *__pyx_n_s_empty;
2739 static PyObject *__pyx_n_s_encode;
2740 static PyObject *__pyx_n_s_end;
2741 static PyObject *__pyx_n_s_enumerate;
2742 static PyObject *__pyx_n_s_error;
2743 static PyObject *__pyx_n_s_exteriorElementBoundariesArray;
2744 static PyObject *__pyx_n_s_failed;
2745 static PyObject *__pyx_n_s_file;
2746 static PyObject *__pyx_n_s_filebase;
2747 static PyObject *__pyx_n_s_finestLevel;
2748 static PyObject *__pyx_n_s_flags;
2749 static PyObject *__pyx_n_s_format;
2750 static PyObject *__pyx_n_s_fortran;
2751 static PyObject *__pyx_n_u_fortran;
2752 static PyObject *__pyx_n_s_getstate;
2753 static PyObject *__pyx_kp_s_got_differing_extents_in_dimensi;
2754 static PyObject *__pyx_n_s_h;
2755 static PyObject *__pyx_n_s_hMin;
2756 static PyObject *__pyx_n_s_id;
2757 static PyObject *__pyx_n_s_import;
2758 static PyObject *__pyx_n_s_int32;
2759 static PyObject *__pyx_n_s_interiorElementBoundariesArray;
2760 static PyObject *__pyx_n_s_itemsize;
2761 static PyObject *__pyx_kp_s_itemsize_0_for_cython_array;
2762 static PyObject *__pyx_n_s_join;
2763 static PyObject *__pyx_n_s_locallyRefineMultilevelMesh;
2764 static PyObject *__pyx_kp_s_locallyRefine_nSpace_0_d_not_imp;
2765 static PyObject *__pyx_n_s_main;
2766 static PyObject *__pyx_n_s_max_nElements_node;
2767 static PyObject *__pyx_n_s_max_nNodeNeighbors_node;
2768 static PyObject *__pyx_n_s_memview;
2769 static PyObject *__pyx_n_s_mode;
2770 static PyObject *__pyx_n_s_mpi4py;
2771 static PyObject *__pyx_n_s_nEdges_global;
2772 static PyObject *__pyx_n_s_nElementBoundaries_element;
2773 static PyObject *__pyx_n_s_nElementBoundaries_global;
2774 static PyObject *__pyx_n_s_nElements_global;
2775 static PyObject *__pyx_n_s_nExteriorElementBoundaries_globa;
2776 static PyObject *__pyx_n_s_nInteriorElementBoundaries_globa;
2777 static PyObject *__pyx_n_s_nLevels;
2778 static PyObject *__pyx_n_s_nNodes_element;
2779 static PyObject *__pyx_n_s_nNodes_elementBoundary;
2780 static PyObject *__pyx_n_s_nNodes_global;
2781 static PyObject *__pyx_n_s_nSpace;
2782 static PyObject *__pyx_n_s_name;
2783 static PyObject *__pyx_n_s_name_2;
2784 static PyObject *__pyx_n_s_ndim;
2785 static PyObject *__pyx_n_s_new;
2786 static PyObject *__pyx_kp_s_no_default___reduce___due_to_non;
2787 static PyObject *__pyx_n_s_nodeArray;
2788 static PyObject *__pyx_n_s_nodeDiametersArray;
2789 static PyObject *__pyx_n_s_nodeElementOffsets;
2790 static PyObject *__pyx_n_s_nodeElementsArray;
2791 static PyObject *__pyx_n_s_nodeMaterialTypes;
2792 static PyObject *__pyx_n_s_nodeStarArray;
2793 static PyObject *__pyx_n_s_nodeStarOffsets;
2794 static PyObject *__pyx_n_s_nodeSupportArray;
2795 static PyObject *__pyx_n_s_np;
2796 static PyObject *__pyx_n_s_numpy;
2797 static PyObject *__pyx_kp_s_numpy_core_multiarray_failed_to;
2798 static PyObject *__pyx_kp_s_numpy_core_umath_failed_to_impor;
2799 static PyObject *__pyx_n_s_nx;
2800 static PyObject *__pyx_n_s_ny;
2801 static PyObject *__pyx_n_s_nz;
2802 static PyObject *__pyx_n_s_obj;
2803 static PyObject *__pyx_n_s_pack;
2804 static PyObject *__pyx_n_s_pickle;
2805 static PyObject *__pyx_n_s_print;
2806 static PyObject *__pyx_n_s_proteus;
2807 static PyObject *__pyx_kp_s_proteus_cmeshTools_pyx;
2808 static PyObject *__pyx_n_s_px;
2809 static PyObject *__pyx_n_s_py;
2810 static PyObject *__pyx_n_s_pyx_PickleError;
2811 static PyObject *__pyx_n_s_pyx_checksum;
2812 static PyObject *__pyx_n_s_pyx_getbuffer;
2813 static PyObject *__pyx_n_s_pyx_result;
2814 static PyObject *__pyx_n_s_pyx_state;
2815 static PyObject *__pyx_n_s_pyx_type;
2816 static PyObject *__pyx_n_s_pyx_unpickle_Enum;
2817 static PyObject *__pyx_n_s_pyx_vtable;
2818 static PyObject *__pyx_n_s_pz;
2819 static PyObject *__pyx_n_s_range;
2820 static PyObject *__pyx_n_s_reduce;
2821 static PyObject *__pyx_n_s_reduce_cython;
2822 static PyObject *__pyx_n_s_reduce_ex;
2823 static PyObject *__pyx_n_s_refineTypeFlag;
2824 static PyObject *__pyx_kp_u_s;
2825 static PyObject *__pyx_kp_s_self_mesh_cannot_be_converted_to;
2826 static PyObject *__pyx_kp_s_self_multilevelMesh_cannot_be_co;
2827 static PyObject *__pyx_n_s_setNewestNodeBases;
2828 static PyObject *__pyx_kp_s_setNewestNodeBases_0_d_not_imple;
2829 static PyObject *__pyx_n_s_setstate;
2830 static PyObject *__pyx_n_s_setstate_cython;
2831 static PyObject *__pyx_n_s_shape;
2832 static PyObject *__pyx_n_s_sigmaMax;
2833 static PyObject *__pyx_n_s_size;
2834 static PyObject *__pyx_n_s_start;
2835 static PyObject *__pyx_n_s_step;
2836 static PyObject *__pyx_n_s_stop;
2837 static PyObject *__pyx_kp_s_strided_and_direct;
2838 static PyObject *__pyx_kp_s_strided_and_direct_or_indirect;
2839 static PyObject *__pyx_kp_s_strided_and_indirect;
2840 static PyObject *__pyx_kp_s_stringsource;
2841 static PyObject *__pyx_n_s_struct;
2842 static PyObject *__pyx_n_s_test;
2843 static PyObject *__pyx_n_s_triangleFlag;
2844 static PyObject *__pyx_kp_s_unable_to_allocate_array_data;
2845 static PyObject *__pyx_kp_s_unable_to_allocate_shape_and_str;
2846 static PyObject *__pyx_n_s_unpack;
2847 static PyObject *__pyx_n_s_update;
2848 static PyObject *__pyx_n_s_volume;
2849 static PyObject *__pyx_n_s_weights;
2850 static PyObject *__pyx_kp_s_wrong_nLevels;
2851 static PyObject *__pyx_n_s_zeros;
2852 static int __pyx_pf_10cmeshTools_5CMesh___init__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2853 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2deleteCMesh(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2854 static PyObject *__pyx_pf_10cmeshTools_5CMesh_4buildPythonMeshInterface(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2855 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6buildPythonMeshInterfaceNoArrays(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2856 static PyObject *__pyx_pf_10cmeshTools_5CMesh_16nElements_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2857 static int __pyx_pf_10cmeshTools_5CMesh_16nElements_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2858 static PyObject *__pyx_pf_10cmeshTools_5CMesh_13nNodes_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2859 static int __pyx_pf_10cmeshTools_5CMesh_13nNodes_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2860 static PyObject *__pyx_pf_10cmeshTools_5CMesh_14nNodes_element___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2861 static int __pyx_pf_10cmeshTools_5CMesh_14nNodes_element_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2862 static PyObject *__pyx_pf_10cmeshTools_5CMesh_22nNodes_elementBoundary___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2863 static int __pyx_pf_10cmeshTools_5CMesh_22nNodes_elementBoundary_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2864 static PyObject *__pyx_pf_10cmeshTools_5CMesh_26nElementBoundaries_element___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2865 static int __pyx_pf_10cmeshTools_5CMesh_26nElementBoundaries_element_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2866 static PyObject *__pyx_pf_10cmeshTools_5CMesh_25nElementBoundaries_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2867 static int __pyx_pf_10cmeshTools_5CMesh_25nElementBoundaries_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2868 static PyObject *__pyx_pf_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2869 static int __pyx_pf_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2870 static PyObject *__pyx_pf_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2871 static int __pyx_pf_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2872 static PyObject *__pyx_pf_10cmeshTools_5CMesh_18max_nElements_node___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2873 static int __pyx_pf_10cmeshTools_5CMesh_18max_nElements_node_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2874 static PyObject *__pyx_pf_10cmeshTools_5CMesh_13nEdges_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2875 static int __pyx_pf_10cmeshTools_5CMesh_13nEdges_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2876 static PyObject *__pyx_pf_10cmeshTools_5CMesh_23max_nNodeNeighbors_node___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2877 static int __pyx_pf_10cmeshTools_5CMesh_23max_nNodeNeighbors_node_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2878 static PyObject *__pyx_pf_10cmeshTools_5CMesh_17elementNodesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2879 static int __pyx_pf_10cmeshTools_5CMesh_17elementNodesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2880 static int __pyx_pf_10cmeshTools_5CMesh_17elementNodesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2881 static PyObject *__pyx_pf_10cmeshTools_5CMesh_17nodeElementsArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2882 static int __pyx_pf_10cmeshTools_5CMesh_17nodeElementsArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2883 static int __pyx_pf_10cmeshTools_5CMesh_17nodeElementsArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2884 static PyObject *__pyx_pf_10cmeshTools_5CMesh_18nodeElementOffsets___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2885 static int __pyx_pf_10cmeshTools_5CMesh_18nodeElementOffsets_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2886 static int __pyx_pf_10cmeshTools_5CMesh_18nodeElementOffsets_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2887 static PyObject *__pyx_pf_10cmeshTools_5CMesh_21elementNeighborsArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2888 static int __pyx_pf_10cmeshTools_5CMesh_21elementNeighborsArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2889 static int __pyx_pf_10cmeshTools_5CMesh_21elementNeighborsArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2890 static PyObject *__pyx_pf_10cmeshTools_5CMesh_22elementBoundariesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2891 static int __pyx_pf_10cmeshTools_5CMesh_22elementBoundariesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2892 static int __pyx_pf_10cmeshTools_5CMesh_22elementBoundariesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2893 static PyObject *__pyx_pf_10cmeshTools_5CMesh_25elementBoundaryNodesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2894 static int __pyx_pf_10cmeshTools_5CMesh_25elementBoundaryNodesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2895 static int __pyx_pf_10cmeshTools_5CMesh_25elementBoundaryNodesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2896 static PyObject *__pyx_pf_10cmeshTools_5CMesh_28elementBoundaryElementsArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2897 static int __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryElementsArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2898 static int __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryElementsArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2899 static PyObject *__pyx_pf_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2900 static int __pyx_pf_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2901 static int __pyx_pf_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2902 static PyObject *__pyx_pf_10cmeshTools_5CMesh_30interiorElementBoundariesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2903 static int __pyx_pf_10cmeshTools_5CMesh_30interiorElementBoundariesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2904 static int __pyx_pf_10cmeshTools_5CMesh_30interiorElementBoundariesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2905 static PyObject *__pyx_pf_10cmeshTools_5CMesh_30exteriorElementBoundariesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2906 static int __pyx_pf_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2907 static int __pyx_pf_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2908 static PyObject *__pyx_pf_10cmeshTools_5CMesh_14edgeNodesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2909 static int __pyx_pf_10cmeshTools_5CMesh_14edgeNodesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2910 static int __pyx_pf_10cmeshTools_5CMesh_14edgeNodesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2911 static PyObject *__pyx_pf_10cmeshTools_5CMesh_13nodeStarArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2912 static int __pyx_pf_10cmeshTools_5CMesh_13nodeStarArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2913 static int __pyx_pf_10cmeshTools_5CMesh_13nodeStarArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2914 static PyObject *__pyx_pf_10cmeshTools_5CMesh_15nodeStarOffsets___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2915 static int __pyx_pf_10cmeshTools_5CMesh_15nodeStarOffsets_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2916 static int __pyx_pf_10cmeshTools_5CMesh_15nodeStarOffsets_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2917 static PyObject *__pyx_pf_10cmeshTools_5CMesh_20elementMaterialTypes___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2918 static int __pyx_pf_10cmeshTools_5CMesh_20elementMaterialTypes_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2919 static int __pyx_pf_10cmeshTools_5CMesh_20elementMaterialTypes_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2920 static PyObject *__pyx_pf_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2921 static int __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2922 static int __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2923 static PyObject *__pyx_pf_10cmeshTools_5CMesh_17nodeMaterialTypes___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2924 static int __pyx_pf_10cmeshTools_5CMesh_17nodeMaterialTypes_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2925 static int __pyx_pf_10cmeshTools_5CMesh_17nodeMaterialTypes_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2926 static PyObject *__pyx_pf_10cmeshTools_5CMesh_9nodeArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2927 static int __pyx_pf_10cmeshTools_5CMesh_9nodeArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2928 static int __pyx_pf_10cmeshTools_5CMesh_9nodeArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2929 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2nx___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2930 static int __pyx_pf_10cmeshTools_5CMesh_2nx_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2931 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2ny___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2932 static int __pyx_pf_10cmeshTools_5CMesh_2ny_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2933 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2nz___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2934 static int __pyx_pf_10cmeshTools_5CMesh_2nz_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2935 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2px___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2936 static int __pyx_pf_10cmeshTools_5CMesh_2px_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2937 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2py___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2938 static int __pyx_pf_10cmeshTools_5CMesh_2py_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2939 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2pz___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2940 static int __pyx_pf_10cmeshTools_5CMesh_2pz_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2941 static PyObject *__pyx_pf_10cmeshTools_5CMesh_10elementIJK___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2942 static int __pyx_pf_10cmeshTools_5CMesh_10elementIJK_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2943 static int __pyx_pf_10cmeshTools_5CMesh_10elementIJK_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2944 static PyObject *__pyx_pf_10cmeshTools_5CMesh_7weights___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2945 static int __pyx_pf_10cmeshTools_5CMesh_7weights_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2946 static int __pyx_pf_10cmeshTools_5CMesh_7weights_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2947 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6U_KNOT___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2948 static int __pyx_pf_10cmeshTools_5CMesh_6U_KNOT_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2949 static int __pyx_pf_10cmeshTools_5CMesh_6U_KNOT_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2950 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6V_KNOT___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2951 static int __pyx_pf_10cmeshTools_5CMesh_6V_KNOT_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2952 static int __pyx_pf_10cmeshTools_5CMesh_6V_KNOT_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2953 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6W_KNOT___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2954 static int __pyx_pf_10cmeshTools_5CMesh_6W_KNOT_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2955 static int __pyx_pf_10cmeshTools_5CMesh_6W_KNOT_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2956 static PyObject *__pyx_pf_10cmeshTools_5CMesh_21elementDiametersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2957 static int __pyx_pf_10cmeshTools_5CMesh_21elementDiametersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2958 static int __pyx_pf_10cmeshTools_5CMesh_21elementDiametersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2959 static PyObject *__pyx_pf_10cmeshTools_5CMesh_26elementInnerDiametersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2960 static int __pyx_pf_10cmeshTools_5CMesh_26elementInnerDiametersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2961 static int __pyx_pf_10cmeshTools_5CMesh_26elementInnerDiametersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2962 static PyObject *__pyx_pf_10cmeshTools_5CMesh_29elementBoundaryDiametersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2963 static int __pyx_pf_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2964 static int __pyx_pf_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2965 static PyObject *__pyx_pf_10cmeshTools_5CMesh_23elementBarycentersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2966 static int __pyx_pf_10cmeshTools_5CMesh_23elementBarycentersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2967 static int __pyx_pf_10cmeshTools_5CMesh_23elementBarycentersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2968 static PyObject *__pyx_pf_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2969 static int __pyx_pf_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2970 static int __pyx_pf_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2971 static PyObject *__pyx_pf_10cmeshTools_5CMesh_18nodeDiametersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2972 static int __pyx_pf_10cmeshTools_5CMesh_18nodeDiametersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2973 static int __pyx_pf_10cmeshTools_5CMesh_18nodeDiametersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2974 static PyObject *__pyx_pf_10cmeshTools_5CMesh_16nodeSupportArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2975 static int __pyx_pf_10cmeshTools_5CMesh_16nodeSupportArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2976 static int __pyx_pf_10cmeshTools_5CMesh_16nodeSupportArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2977 static PyObject *__pyx_pf_10cmeshTools_5CMesh_1h___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2978 static int __pyx_pf_10cmeshTools_5CMesh_1h_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2979 static PyObject *__pyx_pf_10cmeshTools_5CMesh_4hMin___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2980 static int __pyx_pf_10cmeshTools_5CMesh_4hMin_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2981 static PyObject *__pyx_pf_10cmeshTools_5CMesh_8sigmaMax___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2982 static int __pyx_pf_10cmeshTools_5CMesh_8sigmaMax_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2983 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6volume___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2984 static int __pyx_pf_10cmeshTools_5CMesh_6volume_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value);
2985 static PyObject *__pyx_pf_10cmeshTools_5CMesh_8__reduce_cython__(CYTHON_UNUSED
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self);
2986 static PyObject *__pyx_pf_10cmeshTools_5CMesh_10__setstate_cython__(CYTHON_UNUSED
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state);
2987 static PyObject *__pyx_pf_10cmeshTools_buildPythonMeshInterface(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
2988 static PyObject *__pyx_pf_10cmeshTools_2buildPythonMeshInterfaceNoArrays(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
2989 static int __pyx_pf_10cmeshTools_15CMultilevelMesh___init__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_nLevels);
2990 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_2buildPythonMultilevelMeshInterface(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
2991 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_7nLevels___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
2992 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_7nLevels_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value);
2993 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_9cmeshList___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
2994 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_9cmeshList_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value);
2995 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_9cmeshList_4__del__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
2996 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
2997 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value);
2998 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_4__del__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
2999 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
3000 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value);
3001 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_4__del__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
3002 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
3003 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value);
3004 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_4__del__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
3005 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_4__reduce_cython__(CYTHON_UNUSED
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self);
3006 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_6__setstate_cython__(CYTHON_UNUSED
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state);
3007 static PyObject *__pyx_pf_10cmeshTools_4buildPythonMultilevelMeshInterface(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_cmultilevelMesh);
3008 static PyObject *__pyx_pf_10cmeshTools_6generateTetrahedralMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
int __pyx_v_ny,
int __pyx_v_nz,
double __pyx_v_Lx,
double __pyx_v_Ly,
double __pyx_v_Lz,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3009 static PyObject *__pyx_pf_10cmeshTools_8cmeshToolsComputeGeometricInfo_tetrahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3010 static PyObject *__pyx_pf_10cmeshTools_10generateFromTriangleFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3011 static PyObject *__pyx_pf_10cmeshTools_12writeTriangleFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3012 static PyObject *__pyx_pf_10cmeshTools_14generateFromTetgenFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3013 static PyObject *__pyx_pf_10cmeshTools_16generateFromTetgenFilesParallel(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3014 static PyObject *__pyx_pf_10cmeshTools_18writeTetgenFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3015 static PyObject *__pyx_pf_10cmeshTools_20write3dmFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3016 static PyObject *__pyx_pf_10cmeshTools_22write2dmFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3017 static PyObject *__pyx_pf_10cmeshTools_24generateFromHexFile(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3018 static PyObject *__pyx_pf_10cmeshTools_26generateFrom3DMFile(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3019 static PyObject *__pyx_pf_10cmeshTools_28generateFrom2DMFile(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base);
3020 static PyObject *__pyx_pf_10cmeshTools_30computeGeometricInfo_tetrahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3021 static PyObject *__pyx_pf_10cmeshTools_32allocateGeometricInfo_tetrahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3022 static PyObject *__pyx_pf_10cmeshTools_34allocateNodeAndElementNodeDataStructures(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh,
int __pyx_v_nElements_global,
int __pyx_v_nNodes_global,
int __pyx_v_nNodes_element);
3023 static PyObject *__pyx_pf_10cmeshTools_36constructElementBoundaryElementsArray(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3024 static PyObject *__pyx_pf_10cmeshTools_38generateTriangularMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
int __pyx_v_ny,
double __pyx_v_Lx,
double __pyx_v_Ly,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh,
int __pyx_v_triangleFlag);
3025 static PyObject *__pyx_pf_10cmeshTools_40generateHexahedralMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
int __pyx_v_ny,
int __pyx_v_nz,
int __pyx_v_px,
int __pyx_v_py,
int __pyx_v_pz,
double __pyx_v_Lx,
double __pyx_v_Ly,
double __pyx_v_Lz,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3026 static PyObject *__pyx_pf_10cmeshTools_42generateQuadrilateralMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
int __pyx_v_ny,
int __pyx_v_px,
int __pyx_v_py,
double __pyx_v_Lx,
double __pyx_v_Ly,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3027 static PyObject *__pyx_pf_10cmeshTools_44computeGeometricInfo_triangle(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3028 static PyObject *__pyx_pf_10cmeshTools_46allocateGeometricInfo_triangle(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3029 static PyObject *__pyx_pf_10cmeshTools_48generateEdgeMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
double __pyx_v_Lx,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3030 static PyObject *__pyx_pf_10cmeshTools_50computeGeometricInfo_edge(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3031 static PyObject *__pyx_pf_10cmeshTools_52allocateGeometricInfo_edge(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3032 static PyObject *__pyx_pf_10cmeshTools_54computeGeometricInfo_hexahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3033 static PyObject *__pyx_pf_10cmeshTools_56computeGeometricInfo_quadrilateral(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3034 static PyObject *__pyx_pf_10cmeshTools_58allocateGeometricInfo_hexahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3035 static PyObject *__pyx_pf_10cmeshTools_60allocateGeometricInfo_quadrilateral(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3036 static PyObject *__pyx_pf_10cmeshTools_62computeGeometricInfo_NURBS(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3037 static PyObject *__pyx_pf_10cmeshTools_64allocateGeometricInfo_NURBS(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh);
3038 static PyObject *__pyx_pf_10cmeshTools_66locallyRefineMultilevelMesh(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nSpace,
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_cmultilevelMesh, PyArrayObject *__pyx_v_elementTagArray,
int __pyx_v_refineTypeFlag);
3039 static PyObject *__pyx_pf_10cmeshTools_68setNewestNodeBases(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nSpace,
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_cmultilevelMesh);
3040 static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array___cinit__(
struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_shape, Py_ssize_t __pyx_v_itemsize, PyObject *__pyx_v_format, PyObject *__pyx_v_mode,
int __pyx_v_allocate_buffer);
3041 static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array_2__getbuffer__(
struct __pyx_array_obj *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags);
3042 static void __pyx_array___pyx_pf_15View_dot_MemoryView_5array_4__dealloc__(
struct __pyx_array_obj *__pyx_v_self);
3043 static PyObject *__pyx_pf_15View_dot_MemoryView_5array_7memview___get__(
struct __pyx_array_obj *__pyx_v_self);
3044 static Py_ssize_t __pyx_array___pyx_pf_15View_dot_MemoryView_5array_6__len__(
struct __pyx_array_obj *__pyx_v_self);
3045 static PyObject *__pyx_array___pyx_pf_15View_dot_MemoryView_5array_8__getattr__(
struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_attr);
3046 static PyObject *__pyx_array___pyx_pf_15View_dot_MemoryView_5array_10__getitem__(
struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_item);
3047 static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array_12__setitem__(
struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_item, PyObject *__pyx_v_value);
3048 static PyObject *__pyx_pf___pyx_array___reduce_cython__(CYTHON_UNUSED
struct __pyx_array_obj *__pyx_v_self);
3049 static PyObject *__pyx_pf___pyx_array_2__setstate_cython__(CYTHON_UNUSED
struct __pyx_array_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state);
3050 static int __pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum___init__(
struct __pyx_MemviewEnum_obj *__pyx_v_self, PyObject *__pyx_v_name);
3051 static PyObject *__pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum_2__repr__(
struct __pyx_MemviewEnum_obj *__pyx_v_self);
3052 static PyObject *__pyx_pf___pyx_MemviewEnum___reduce_cython__(
struct __pyx_MemviewEnum_obj *__pyx_v_self);
3053 static PyObject *__pyx_pf___pyx_MemviewEnum_2__setstate_cython__(
struct __pyx_MemviewEnum_obj *__pyx_v_self, PyObject *__pyx_v___pyx_state);
3054 static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview___cinit__(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_obj,
int __pyx_v_flags,
int __pyx_v_dtype_is_object);
3055 static void __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_2__dealloc__(
struct __pyx_memoryview_obj *__pyx_v_self);
3056 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_4__getitem__(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index);
3057 static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_6__setitem__(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value);
3058 static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_8__getbuffer__(
struct __pyx_memoryview_obj *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags);
3059 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_1T___get__(
struct __pyx_memoryview_obj *__pyx_v_self);
3060 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4base___get__(
struct __pyx_memoryview_obj *__pyx_v_self);
3061 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_5shape___get__(
struct __pyx_memoryview_obj *__pyx_v_self);
3062 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_7strides___get__(
struct __pyx_memoryview_obj *__pyx_v_self);
3063 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_10suboffsets___get__(
struct __pyx_memoryview_obj *__pyx_v_self);
3064 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4ndim___get__(
struct __pyx_memoryview_obj *__pyx_v_self);
3065 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_8itemsize___get__(
struct __pyx_memoryview_obj *__pyx_v_self);
3066 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_6nbytes___get__(
struct __pyx_memoryview_obj *__pyx_v_self);
3067 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4size___get__(
struct __pyx_memoryview_obj *__pyx_v_self);
3068 static Py_ssize_t __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_10__len__(
struct __pyx_memoryview_obj *__pyx_v_self);
3069 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_12__repr__(
struct __pyx_memoryview_obj *__pyx_v_self);
3070 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_14__str__(
struct __pyx_memoryview_obj *__pyx_v_self);
3071 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_16is_c_contig(
struct __pyx_memoryview_obj *__pyx_v_self);
3072 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_18is_f_contig(
struct __pyx_memoryview_obj *__pyx_v_self);
3073 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_20copy(
struct __pyx_memoryview_obj *__pyx_v_self);
3074 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_22copy_fortran(
struct __pyx_memoryview_obj *__pyx_v_self);
3075 static PyObject *__pyx_pf___pyx_memoryview___reduce_cython__(CYTHON_UNUSED
struct __pyx_memoryview_obj *__pyx_v_self);
3076 static PyObject *__pyx_pf___pyx_memoryview_2__setstate_cython__(CYTHON_UNUSED
struct __pyx_memoryview_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state);
3077 static void __pyx_memoryviewslice___pyx_pf_15View_dot_MemoryView_16_memoryviewslice___dealloc__(
struct __pyx_memoryviewslice_obj *__pyx_v_self);
3078 static PyObject *__pyx_pf_15View_dot_MemoryView_16_memoryviewslice_4base___get__(
struct __pyx_memoryviewslice_obj *__pyx_v_self);
3079 static PyObject *__pyx_pf___pyx_memoryviewslice___reduce_cython__(CYTHON_UNUSED
struct __pyx_memoryviewslice_obj *__pyx_v_self);
3080 static PyObject *__pyx_pf___pyx_memoryviewslice_2__setstate_cython__(CYTHON_UNUSED
struct __pyx_memoryviewslice_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state);
3081 static PyObject *__pyx_pf_15View_dot_MemoryView___pyx_unpickle_Enum(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type,
long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state);
3082 static PyObject *__pyx_tp_new_10cmeshTools_CMesh(PyTypeObject *t, PyObject *a, PyObject *k);
3083 static PyObject *__pyx_tp_new_10cmeshTools_CMultilevelMesh(PyTypeObject *t, PyObject *a, PyObject *k);
3084 static PyObject *__pyx_tp_new_array(PyTypeObject *t, PyObject *a, PyObject *k);
3085 static PyObject *__pyx_tp_new_Enum(PyTypeObject *t, PyObject *a, PyObject *k);
3086 static PyObject *__pyx_tp_new_memoryview(PyTypeObject *t, PyObject *a, PyObject *k);
3087 static PyObject *__pyx_tp_new__memoryviewslice(PyTypeObject *t, PyObject *a, PyObject *k);
3088 static PyObject *__pyx_int_0;
3089 static PyObject *__pyx_int_1;
3090 static PyObject *__pyx_int_112105877;
3091 static PyObject *__pyx_int_136983863;
3092 static PyObject *__pyx_int_184977713;
3093 static PyObject *__pyx_int_neg_1;
3094 static PyObject *__pyx_tuple_;
3095 static PyObject *__pyx_tuple__2;
3096 static PyObject *__pyx_tuple__3;
3097 static PyObject *__pyx_tuple__4;
3098 static PyObject *__pyx_tuple__5;
3099 static PyObject *__pyx_tuple__6;
3100 static PyObject *__pyx_tuple__7;
3101 static PyObject *__pyx_tuple__8;
3102 static PyObject *__pyx_tuple__9;
3103 static PyObject *__pyx_slice__22;
3104 static PyObject *__pyx_tuple__10;
3105 static PyObject *__pyx_tuple__11;
3106 static PyObject *__pyx_tuple__12;
3107 static PyObject *__pyx_tuple__13;
3108 static PyObject *__pyx_tuple__14;
3109 static PyObject *__pyx_tuple__15;
3110 static PyObject *__pyx_tuple__16;
3111 static PyObject *__pyx_tuple__17;
3112 static PyObject *__pyx_tuple__18;
3113 static PyObject *__pyx_tuple__19;
3114 static PyObject *__pyx_tuple__20;
3115 static PyObject *__pyx_tuple__21;
3116 static PyObject *__pyx_tuple__23;
3117 static PyObject *__pyx_tuple__24;
3118 static PyObject *__pyx_tuple__25;
3119 static PyObject *__pyx_tuple__26;
3120 static PyObject *__pyx_tuple__32;
3121 static PyObject *__pyx_tuple__34;
3122 static PyObject *__pyx_tuple__36;
3123 static PyObject *__pyx_tuple__38;
3124 static PyObject *__pyx_tuple__40;
3125 static PyObject *__pyx_tuple__42;
3126 static PyObject *__pyx_tuple__43;
3127 static PyObject *__pyx_tuple__44;
3128 static PyObject *__pyx_tuple__45;
3129 static PyObject *__pyx_tuple__46;
3130 static PyObject *__pyx_tuple__47;
3131 static PyObject *__pyx_codeobj__33;
3132 static PyObject *__pyx_codeobj__35;
3133 static PyObject *__pyx_codeobj__37;
3134 static PyObject *__pyx_codeobj__39;
3135 static PyObject *__pyx_codeobj__41;
3136 static PyObject *__pyx_codeobj__48;
3148 static int __pyx_pw_10cmeshTools_5CMesh_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
3149 static int __pyx_pw_10cmeshTools_5CMesh_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
3151 __Pyx_RefNannyDeclarations
3152 __Pyx_RefNannySetupContext(
"__init__ (wrapper)", 0);
3153 if (unlikely(PyTuple_GET_SIZE(__pyx_args) > 0)) {
3154 __Pyx_RaiseArgtupleInvalid(
"__init__", 1, 0, 0, PyTuple_GET_SIZE(__pyx_args));
return -1;}
3155 if (unlikely(__pyx_kwds) && unlikely(PyDict_Size(__pyx_kwds) > 0) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds,
"__init__", 0)))
return -1;
3156 __pyx_r = __pyx_pf_10cmeshTools_5CMesh___init__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
3159 __Pyx_RefNannyFinishContext();
3163 static int __pyx_pf_10cmeshTools_5CMesh___init__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
3165 __Pyx_RefNannyDeclarations
3166 struct Mesh __pyx_t_1;
3167 __Pyx_RefNannySetupContext(
"__init__", 0);
3176 __pyx_v_self->mesh = __pyx_t_1;
3197 __Pyx_RefNannyFinishContext();
3210 static PyObject *__pyx_pw_10cmeshTools_5CMesh_3deleteCMesh(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
3211 static PyObject *__pyx_pw_10cmeshTools_5CMesh_3deleteCMesh(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
3212 PyObject *__pyx_r = 0;
3213 __Pyx_RefNannyDeclarations
3214 __Pyx_RefNannySetupContext(
"deleteCMesh (wrapper)", 0);
3215 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2deleteCMesh(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
3218 __Pyx_RefNannyFinishContext();
3222 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2deleteCMesh(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
3223 PyObject *__pyx_r = NULL;
3224 __Pyx_RefNannyDeclarations
3225 __Pyx_RefNannySetupContext(
"deleteCMesh", 0);
3245 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
3246 __Pyx_XGIVEREF(__pyx_r);
3247 __Pyx_RefNannyFinishContext();
3260 static PyObject *__pyx_pw_10cmeshTools_5CMesh_5buildPythonMeshInterface(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
3261 static PyObject *__pyx_pw_10cmeshTools_5CMesh_5buildPythonMeshInterface(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
3262 PyObject *__pyx_r = 0;
3263 __Pyx_RefNannyDeclarations
3264 __Pyx_RefNannySetupContext(
"buildPythonMeshInterface (wrapper)", 0);
3265 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_4buildPythonMeshInterface(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
3268 __Pyx_RefNannyFinishContext();
3272 static PyObject *__pyx_pf_10cmeshTools_5CMesh_4buildPythonMeshInterface(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
3273 PyObject *__pyx_r = NULL;
3274 __Pyx_RefNannyDeclarations
3276 PyObject *__pyx_t_2 = NULL;
3277 PyObject *__pyx_t_3 = NULL;
3278 PyObject *__pyx_t_4 = NULL;
3280 struct __pyx_array_obj *__pyx_t_6 = NULL;
3281 PyObject *__pyx_t_7 = NULL;
3285 int __pyx_lineno = 0;
3286 const char *__pyx_filename = NULL;
3287 int __pyx_clineno = 0;
3288 __Pyx_RefNannySetupContext(
"buildPythonMeshInterface", 0);
3297 __pyx_t_1 = __pyx_v_self->mesh.nElements_global;
3298 __pyx_v_self->nElements_global = __pyx_t_1;
3307 __pyx_t_1 = __pyx_v_self->mesh.nNodes_global;
3308 __pyx_v_self->nNodes_global = __pyx_t_1;
3317 __pyx_t_1 = __pyx_v_self->mesh.nNodes_element;
3318 __pyx_v_self->nNodes_element = __pyx_t_1;
3327 __pyx_t_1 = __pyx_v_self->mesh.nNodes_elementBoundary;
3328 __pyx_v_self->nNodes_elementBoundary = __pyx_t_1;
3337 __pyx_t_1 = __pyx_v_self->mesh.nElementBoundaries_element;
3338 __pyx_v_self->nElementBoundaries_element = __pyx_t_1;
3347 __pyx_t_1 = __pyx_v_self->mesh.nElementBoundaries_global;
3348 __pyx_v_self->nElementBoundaries_global = __pyx_t_1;
3357 __pyx_t_1 = __pyx_v_self->mesh.nInteriorElementBoundaries_global;
3358 __pyx_v_self->nInteriorElementBoundaries_global = __pyx_t_1;
3367 __pyx_t_1 = __pyx_v_self->mesh.nExteriorElementBoundaries_global;
3368 __pyx_v_self->nExteriorElementBoundaries_global = __pyx_t_1;
3377 __pyx_t_1 = __pyx_v_self->mesh.max_nElements_node;
3378 __pyx_v_self->max_nElements_node = __pyx_t_1;
3387 __pyx_t_1 = __pyx_v_self->mesh.nEdges_global;
3388 __pyx_v_self->nEdges_global = __pyx_t_1;
3397 __pyx_t_1 = __pyx_v_self->mesh.max_nNodeNeighbors_node;
3398 __pyx_v_self->max_nNodeNeighbors_node = __pyx_t_1;
3407 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 32, __pyx_L1_error)
3408 __Pyx_GOTREF(__pyx_t_3);
3409 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 32, __pyx_L1_error)
3410 __Pyx_GOTREF(__pyx_t_4);
3411 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3412 __pyx_t_5 = __pyx_v_self->mesh.elementNodesArray;
3414 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3415 __PYX_ERR(1, 32, __pyx_L1_error)
3417 __pyx_t_7 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 32, __pyx_L1_error)
3418 __Pyx_GOTREF(__pyx_t_7);
3419 __pyx_t_3 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElements_global), ((Py_ssize_t)__pyx_v_self->mesh.nNodes_element));
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 32, __pyx_L1_error)
3420 __Pyx_GOTREF(__pyx_t_3);
3421 __pyx_t_6 = __pyx_array_new(__pyx_t_3,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_7), (
char *)
"c", (
char *) __pyx_t_5);
3422 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 32, __pyx_L1_error)
3423 __Pyx_GOTREF(__pyx_t_6);
3424 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3425 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3427 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
3428 __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4);
3429 if (likely(__pyx_t_7)) {
3430 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
3431 __Pyx_INCREF(__pyx_t_7);
3432 __Pyx_INCREF(
function);
3433 __Pyx_DECREF_SET(__pyx_t_4,
function);
3436 __pyx_t_2 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_7, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_4, ((PyObject *)__pyx_t_6));
3437 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
3438 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
3439 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 32, __pyx_L1_error)
3440 __Pyx_GOTREF(__pyx_t_2);
3441 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3442 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 32, __pyx_L1_error)
3443 __Pyx_GIVEREF(__pyx_t_2);
3444 __Pyx_GOTREF(__pyx_v_self->elementNodesArray);
3445 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementNodesArray));
3446 __pyx_v_self->elementNodesArray = ((PyArrayObject *)__pyx_t_2);
3456 __pyx_t_8 = ((__pyx_v_self->mesh.nodeElementOffsets != NULL) != 0);
3466 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 34, __pyx_L1_error)
3467 __Pyx_GOTREF(__pyx_t_4);
3468 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 34, __pyx_L1_error)
3469 __Pyx_GOTREF(__pyx_t_7);
3470 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3471 __pyx_t_5 = __pyx_v_self->mesh.nodeElementsArray;
3473 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3474 __PYX_ERR(1, 34, __pyx_L1_error)
3476 __pyx_t_3 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 34, __pyx_L1_error)
3477 __Pyx_GOTREF(__pyx_t_3);
3478 __pyx_t_4 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)(__pyx_v_self->mesh.nodeElementOffsets[__pyx_v_self->mesh.nNodes_global])));
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 34, __pyx_L1_error)
3479 __Pyx_GOTREF(__pyx_t_4);
3480 __pyx_t_6 = __pyx_array_new(__pyx_t_4,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_3), (
char *)
"c", (
char *) __pyx_t_5);
3481 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 34, __pyx_L1_error)
3482 __Pyx_GOTREF(__pyx_t_6);
3483 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3484 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3486 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) {
3487 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_7);
3488 if (likely(__pyx_t_3)) {
3489 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_7);
3490 __Pyx_INCREF(__pyx_t_3);
3491 __Pyx_INCREF(
function);
3492 __Pyx_DECREF_SET(__pyx_t_7,
function);
3495 __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_3, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_7, ((PyObject *)__pyx_t_6));
3496 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
3497 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
3498 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 34, __pyx_L1_error)
3499 __Pyx_GOTREF(__pyx_t_2);
3500 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3501 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 34, __pyx_L1_error)
3502 __Pyx_GIVEREF(__pyx_t_2);
3503 __Pyx_GOTREF(__pyx_v_self->nodeElementsArray);
3504 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeElementsArray));
3505 __pyx_v_self->nodeElementsArray = ((PyArrayObject *)__pyx_t_2);
3515 __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_np);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 35, __pyx_L1_error)
3516 __Pyx_GOTREF(__pyx_t_7);
3517 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 35, __pyx_L1_error)
3518 __Pyx_GOTREF(__pyx_t_3);
3519 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3520 __pyx_t_5 = __pyx_v_self->mesh.nodeElementOffsets;
3522 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3523 __PYX_ERR(1, 35, __pyx_L1_error)
3525 __pyx_t_4 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 35, __pyx_L1_error)
3526 __Pyx_GOTREF(__pyx_t_4);
3527 __pyx_t_7 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)(__pyx_v_self->mesh.nNodes_global + 1)));
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 35, __pyx_L1_error)
3528 __Pyx_GOTREF(__pyx_t_7);
3529 __pyx_t_6 = __pyx_array_new(__pyx_t_7,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_4), (
char *)
"c", (
char *) __pyx_t_5);
3530 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 35, __pyx_L1_error)
3531 __Pyx_GOTREF(__pyx_t_6);
3532 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3533 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3535 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
3536 __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
3537 if (likely(__pyx_t_4)) {
3538 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
3539 __Pyx_INCREF(__pyx_t_4);
3540 __Pyx_INCREF(
function);
3541 __Pyx_DECREF_SET(__pyx_t_3,
function);
3544 __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
3545 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
3546 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
3547 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 35, __pyx_L1_error)
3548 __Pyx_GOTREF(__pyx_t_2);
3549 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3550 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 35, __pyx_L1_error)
3551 __Pyx_GIVEREF(__pyx_t_2);
3552 __Pyx_GOTREF(__pyx_v_self->nodeElementOffsets);
3553 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeElementOffsets));
3554 __pyx_v_self->nodeElementOffsets = ((PyArrayObject *)__pyx_t_2);
3575 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 37, __pyx_L1_error)
3576 __Pyx_GOTREF(__pyx_t_2);
3577 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_empty);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 37, __pyx_L1_error)
3578 __Pyx_GOTREF(__pyx_t_3);
3579 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3580 __pyx_t_2 = __Pyx_PyDict_NewPresized(1);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 37, __pyx_L1_error)
3581 __Pyx_GOTREF(__pyx_t_2);
3582 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 37, __pyx_L1_error)
3583 __Pyx_GOTREF(__pyx_t_4);
3584 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_int32);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 37, __pyx_L1_error)
3585 __Pyx_GOTREF(__pyx_t_7);
3586 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3587 if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_dtype, __pyx_t_7) < 0) __PYX_ERR(1, 37, __pyx_L1_error)
3588 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3589 __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple_, __pyx_t_2);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 37, __pyx_L1_error)
3590 __Pyx_GOTREF(__pyx_t_7);
3591 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3592 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3593 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 37, __pyx_L1_error)
3594 __Pyx_GIVEREF(__pyx_t_7);
3595 __Pyx_GOTREF(__pyx_v_self->nodeElementsArray);
3596 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeElementsArray));
3597 __pyx_v_self->nodeElementsArray = ((PyArrayObject *)__pyx_t_7);
3607 __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_np);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 38, __pyx_L1_error)
3608 __Pyx_GOTREF(__pyx_t_7);
3609 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_empty);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 38, __pyx_L1_error)
3610 __Pyx_GOTREF(__pyx_t_2);
3611 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3612 __pyx_t_7 = __Pyx_PyDict_NewPresized(1);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 38, __pyx_L1_error)
3613 __Pyx_GOTREF(__pyx_t_7);
3614 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 38, __pyx_L1_error)
3615 __Pyx_GOTREF(__pyx_t_3);
3616 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_int32);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 38, __pyx_L1_error)
3617 __Pyx_GOTREF(__pyx_t_4);
3618 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3619 if (PyDict_SetItem(__pyx_t_7, __pyx_n_s_dtype, __pyx_t_4) < 0) __PYX_ERR(1, 38, __pyx_L1_error)
3620 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3621 __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_tuple_, __pyx_t_7);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 38, __pyx_L1_error)
3622 __Pyx_GOTREF(__pyx_t_4);
3623 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3624 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3625 if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 38, __pyx_L1_error)
3626 __Pyx_GIVEREF(__pyx_t_4);
3627 __Pyx_GOTREF(__pyx_v_self->nodeElementOffsets);
3628 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeElementOffsets));
3629 __pyx_v_self->nodeElementOffsets = ((PyArrayObject *)__pyx_t_4);
3641 __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_np);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 40, __pyx_L1_error)
3642 __Pyx_GOTREF(__pyx_t_7);
3643 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 40, __pyx_L1_error)
3644 __Pyx_GOTREF(__pyx_t_2);
3645 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3646 __pyx_t_5 = __pyx_v_self->mesh.elementNeighborsArray;
3648 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3649 __PYX_ERR(1, 40, __pyx_L1_error)
3651 __pyx_t_3 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 40, __pyx_L1_error)
3652 __Pyx_GOTREF(__pyx_t_3);
3653 __pyx_t_7 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElements_global), ((Py_ssize_t)__pyx_v_self->mesh.nElementBoundaries_element));
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 40, __pyx_L1_error)
3654 __Pyx_GOTREF(__pyx_t_7);
3655 __pyx_t_6 = __pyx_array_new(__pyx_t_7,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_3), (
char *)
"c", (
char *) __pyx_t_5);
3656 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 40, __pyx_L1_error)
3657 __Pyx_GOTREF(__pyx_t_6);
3658 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3659 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3661 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
3662 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
3663 if (likely(__pyx_t_3)) {
3664 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
3665 __Pyx_INCREF(__pyx_t_3);
3666 __Pyx_INCREF(
function);
3667 __Pyx_DECREF_SET(__pyx_t_2,
function);
3670 __pyx_t_4 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_t_6));
3671 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
3672 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
3673 if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 40, __pyx_L1_error)
3674 __Pyx_GOTREF(__pyx_t_4);
3675 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3676 if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 40, __pyx_L1_error)
3677 __Pyx_GIVEREF(__pyx_t_4);
3678 __Pyx_GOTREF(__pyx_v_self->elementNeighborsArray);
3679 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementNeighborsArray));
3680 __pyx_v_self->elementNeighborsArray = ((PyArrayObject *)__pyx_t_4);
3690 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 41, __pyx_L1_error)
3691 __Pyx_GOTREF(__pyx_t_2);
3692 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 41, __pyx_L1_error)
3693 __Pyx_GOTREF(__pyx_t_3);
3694 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3695 __pyx_t_5 = __pyx_v_self->mesh.elementBoundariesArray;
3697 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3698 __PYX_ERR(1, 41, __pyx_L1_error)
3700 __pyx_t_7 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 41, __pyx_L1_error)
3701 __Pyx_GOTREF(__pyx_t_7);
3702 __pyx_t_2 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElements_global), ((Py_ssize_t)__pyx_v_self->mesh.nElementBoundaries_element));
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 41, __pyx_L1_error)
3703 __Pyx_GOTREF(__pyx_t_2);
3704 __pyx_t_6 = __pyx_array_new(__pyx_t_2,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_7), (
char *)
"c", (
char *) __pyx_t_5);
3705 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 41, __pyx_L1_error)
3706 __Pyx_GOTREF(__pyx_t_6);
3707 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3708 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3710 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
3711 __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_3);
3712 if (likely(__pyx_t_7)) {
3713 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
3714 __Pyx_INCREF(__pyx_t_7);
3715 __Pyx_INCREF(
function);
3716 __Pyx_DECREF_SET(__pyx_t_3,
function);
3719 __pyx_t_4 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_7, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
3720 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
3721 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
3722 if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 41, __pyx_L1_error)
3723 __Pyx_GOTREF(__pyx_t_4);
3724 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3725 if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 41, __pyx_L1_error)
3726 __Pyx_GIVEREF(__pyx_t_4);
3727 __Pyx_GOTREF(__pyx_v_self->elementBoundariesArray);
3728 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundariesArray));
3729 __pyx_v_self->elementBoundariesArray = ((PyArrayObject *)__pyx_t_4);
3739 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 42, __pyx_L1_error)
3740 __Pyx_GOTREF(__pyx_t_3);
3741 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 42, __pyx_L1_error)
3742 __Pyx_GOTREF(__pyx_t_7);
3743 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3744 __pyx_t_5 = __pyx_v_self->mesh.elementBoundaryNodesArray;
3746 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3747 __PYX_ERR(1, 42, __pyx_L1_error)
3749 __pyx_t_2 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 42, __pyx_L1_error)
3750 __Pyx_GOTREF(__pyx_t_2);
3751 __pyx_t_3 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElementBoundaries_global), ((Py_ssize_t)__pyx_v_self->mesh.nNodes_elementBoundary));
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 42, __pyx_L1_error)
3752 __Pyx_GOTREF(__pyx_t_3);
3753 __pyx_t_6 = __pyx_array_new(__pyx_t_3,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_2), (
char *)
"c", (
char *) __pyx_t_5);
3754 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 42, __pyx_L1_error)
3755 __Pyx_GOTREF(__pyx_t_6);
3756 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3757 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3759 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) {
3760 __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_7);
3761 if (likely(__pyx_t_2)) {
3762 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_7);
3763 __Pyx_INCREF(__pyx_t_2);
3764 __Pyx_INCREF(
function);
3765 __Pyx_DECREF_SET(__pyx_t_7,
function);
3768 __pyx_t_4 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_2, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_7, ((PyObject *)__pyx_t_6));
3769 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
3770 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
3771 if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 42, __pyx_L1_error)
3772 __Pyx_GOTREF(__pyx_t_4);
3773 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3774 if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 42, __pyx_L1_error)
3775 __Pyx_GIVEREF(__pyx_t_4);
3776 __Pyx_GOTREF(__pyx_v_self->elementBoundaryNodesArray);
3777 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryNodesArray));
3778 __pyx_v_self->elementBoundaryNodesArray = ((PyArrayObject *)__pyx_t_4);
3788 __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_np);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 43, __pyx_L1_error)
3789 __Pyx_GOTREF(__pyx_t_7);
3790 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 43, __pyx_L1_error)
3791 __Pyx_GOTREF(__pyx_t_2);
3792 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3793 __pyx_t_5 = __pyx_v_self->mesh.elementBoundaryElementsArray;
3795 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3796 __PYX_ERR(1, 43, __pyx_L1_error)
3798 __pyx_t_3 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 43, __pyx_L1_error)
3799 __Pyx_GOTREF(__pyx_t_3);
3800 __pyx_t_7 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElementBoundaries_global), ((Py_ssize_t)2));
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 43, __pyx_L1_error)
3801 __Pyx_GOTREF(__pyx_t_7);
3802 __pyx_t_6 = __pyx_array_new(__pyx_t_7,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_3), (
char *)
"c", (
char *) __pyx_t_5);
3803 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 43, __pyx_L1_error)
3804 __Pyx_GOTREF(__pyx_t_6);
3805 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3806 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3808 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
3809 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
3810 if (likely(__pyx_t_3)) {
3811 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
3812 __Pyx_INCREF(__pyx_t_3);
3813 __Pyx_INCREF(
function);
3814 __Pyx_DECREF_SET(__pyx_t_2,
function);
3817 __pyx_t_4 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_t_6));
3818 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
3819 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
3820 if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 43, __pyx_L1_error)
3821 __Pyx_GOTREF(__pyx_t_4);
3822 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3823 if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 43, __pyx_L1_error)
3824 __Pyx_GIVEREF(__pyx_t_4);
3825 __Pyx_GOTREF(__pyx_v_self->elementBoundaryElementsArray);
3826 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryElementsArray));
3827 __pyx_v_self->elementBoundaryElementsArray = ((PyArrayObject *)__pyx_t_4);
3837 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 44, __pyx_L1_error)
3838 __Pyx_GOTREF(__pyx_t_2);
3839 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 44, __pyx_L1_error)
3840 __Pyx_GOTREF(__pyx_t_3);
3841 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3842 __pyx_t_5 = __pyx_v_self->mesh.elementBoundaryLocalElementBoundariesArray;
3844 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3845 __PYX_ERR(1, 44, __pyx_L1_error)
3847 __pyx_t_7 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 44, __pyx_L1_error)
3848 __Pyx_GOTREF(__pyx_t_7);
3849 __pyx_t_2 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElementBoundaries_global), ((Py_ssize_t)2));
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 44, __pyx_L1_error)
3850 __Pyx_GOTREF(__pyx_t_2);
3851 __pyx_t_6 = __pyx_array_new(__pyx_t_2,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_7), (
char *)
"c", (
char *) __pyx_t_5);
3852 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 44, __pyx_L1_error)
3853 __Pyx_GOTREF(__pyx_t_6);
3854 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3855 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3857 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
3858 __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_3);
3859 if (likely(__pyx_t_7)) {
3860 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
3861 __Pyx_INCREF(__pyx_t_7);
3862 __Pyx_INCREF(
function);
3863 __Pyx_DECREF_SET(__pyx_t_3,
function);
3866 __pyx_t_4 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_7, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
3867 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
3868 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
3869 if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 44, __pyx_L1_error)
3870 __Pyx_GOTREF(__pyx_t_4);
3871 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3872 if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 44, __pyx_L1_error)
3873 __Pyx_GIVEREF(__pyx_t_4);
3874 __Pyx_GOTREF(__pyx_v_self->elementBoundaryLocalElementBoundariesArray);
3875 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryLocalElementBoundariesArray));
3876 __pyx_v_self->elementBoundaryLocalElementBoundariesArray = ((PyArrayObject *)__pyx_t_4);
3886 __pyx_t_8 = (__pyx_v_self->mesh.nInteriorElementBoundaries_global != 0);
3896 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 46, __pyx_L1_error)
3897 __Pyx_GOTREF(__pyx_t_3);
3898 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 46, __pyx_L1_error)
3899 __Pyx_GOTREF(__pyx_t_7);
3900 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3901 __pyx_t_5 = __pyx_v_self->mesh.interiorElementBoundariesArray;
3903 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3904 __PYX_ERR(1, 46, __pyx_L1_error)
3906 __pyx_t_2 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 46, __pyx_L1_error)
3907 __Pyx_GOTREF(__pyx_t_2);
3908 __pyx_t_3 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nInteriorElementBoundaries_global));
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 46, __pyx_L1_error)
3909 __Pyx_GOTREF(__pyx_t_3);
3910 __pyx_t_6 = __pyx_array_new(__pyx_t_3,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_2), (
char *)
"c", (
char *) __pyx_t_5);
3911 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 46, __pyx_L1_error)
3912 __Pyx_GOTREF(__pyx_t_6);
3913 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3914 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3916 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) {
3917 __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_7);
3918 if (likely(__pyx_t_2)) {
3919 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_7);
3920 __Pyx_INCREF(__pyx_t_2);
3921 __Pyx_INCREF(
function);
3922 __Pyx_DECREF_SET(__pyx_t_7,
function);
3925 __pyx_t_4 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_2, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_7, ((PyObject *)__pyx_t_6));
3926 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
3927 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
3928 if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 46, __pyx_L1_error)
3929 __Pyx_GOTREF(__pyx_t_4);
3930 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3931 if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 46, __pyx_L1_error)
3932 __Pyx_GIVEREF(__pyx_t_4);
3933 __Pyx_GOTREF(__pyx_v_self->interiorElementBoundariesArray);
3934 __Pyx_DECREF(((PyObject *)__pyx_v_self->interiorElementBoundariesArray));
3935 __pyx_v_self->interiorElementBoundariesArray = ((PyArrayObject *)__pyx_t_4);
3956 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 48, __pyx_L1_error)
3957 __Pyx_GOTREF(__pyx_t_4);
3958 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_empty);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 48, __pyx_L1_error)
3959 __Pyx_GOTREF(__pyx_t_7);
3960 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3961 __pyx_t_4 = __Pyx_PyDict_NewPresized(1);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 48, __pyx_L1_error)
3962 __Pyx_GOTREF(__pyx_t_4);
3963 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 48, __pyx_L1_error)
3964 __Pyx_GOTREF(__pyx_t_2);
3965 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_int32);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 48, __pyx_L1_error)
3966 __Pyx_GOTREF(__pyx_t_3);
3967 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
3968 if (PyDict_SetItem(__pyx_t_4, __pyx_n_s_dtype, __pyx_t_3) < 0) __PYX_ERR(1, 48, __pyx_L1_error)
3969 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
3970 __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_tuple_, __pyx_t_4);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 48, __pyx_L1_error)
3971 __Pyx_GOTREF(__pyx_t_3);
3972 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
3973 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3974 if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 48, __pyx_L1_error)
3975 __Pyx_GIVEREF(__pyx_t_3);
3976 __Pyx_GOTREF(__pyx_v_self->interiorElementBoundariesArray);
3977 __Pyx_DECREF(((PyObject *)__pyx_v_self->interiorElementBoundariesArray));
3978 __pyx_v_self->interiorElementBoundariesArray = ((PyArrayObject *)__pyx_t_3);
3990 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 49, __pyx_L1_error)
3991 __Pyx_GOTREF(__pyx_t_4);
3992 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 49, __pyx_L1_error)
3993 __Pyx_GOTREF(__pyx_t_7);
3994 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
3995 __pyx_t_5 = __pyx_v_self->mesh.exteriorElementBoundariesArray;
3997 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
3998 __PYX_ERR(1, 49, __pyx_L1_error)
4000 __pyx_t_2 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 49, __pyx_L1_error)
4001 __Pyx_GOTREF(__pyx_t_2);
4002 __pyx_t_4 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nExteriorElementBoundaries_global));
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 49, __pyx_L1_error)
4003 __Pyx_GOTREF(__pyx_t_4);
4004 __pyx_t_6 = __pyx_array_new(__pyx_t_4,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_2), (
char *)
"c", (
char *) __pyx_t_5);
4005 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 49, __pyx_L1_error)
4006 __Pyx_GOTREF(__pyx_t_6);
4007 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4008 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4010 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) {
4011 __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_7);
4012 if (likely(__pyx_t_2)) {
4013 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_7);
4014 __Pyx_INCREF(__pyx_t_2);
4015 __Pyx_INCREF(
function);
4016 __Pyx_DECREF_SET(__pyx_t_7,
function);
4019 __pyx_t_3 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_2, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_7, ((PyObject *)__pyx_t_6));
4020 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
4021 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4022 if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 49, __pyx_L1_error)
4023 __Pyx_GOTREF(__pyx_t_3);
4024 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4025 if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 49, __pyx_L1_error)
4026 __Pyx_GIVEREF(__pyx_t_3);
4027 __Pyx_GOTREF(__pyx_v_self->exteriorElementBoundariesArray);
4028 __Pyx_DECREF(((PyObject *)__pyx_v_self->exteriorElementBoundariesArray));
4029 __pyx_v_self->exteriorElementBoundariesArray = ((PyArrayObject *)__pyx_t_3);
4039 __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_np);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 50, __pyx_L1_error)
4040 __Pyx_GOTREF(__pyx_t_7);
4041 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 50, __pyx_L1_error)
4042 __Pyx_GOTREF(__pyx_t_2);
4043 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4044 __pyx_t_5 = __pyx_v_self->mesh.edgeNodesArray;
4046 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4047 __PYX_ERR(1, 50, __pyx_L1_error)
4049 __pyx_t_4 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 50, __pyx_L1_error)
4050 __Pyx_GOTREF(__pyx_t_4);
4051 __pyx_t_7 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nEdges_global), ((Py_ssize_t)2));
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 50, __pyx_L1_error)
4052 __Pyx_GOTREF(__pyx_t_7);
4053 __pyx_t_6 = __pyx_array_new(__pyx_t_7,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_4), (
char *)
"c", (
char *) __pyx_t_5);
4054 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 50, __pyx_L1_error)
4055 __Pyx_GOTREF(__pyx_t_6);
4056 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4057 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4059 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
4060 __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2);
4061 if (likely(__pyx_t_4)) {
4062 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
4063 __Pyx_INCREF(__pyx_t_4);
4064 __Pyx_INCREF(
function);
4065 __Pyx_DECREF_SET(__pyx_t_2,
function);
4068 __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_t_6));
4069 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
4070 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4071 if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 50, __pyx_L1_error)
4072 __Pyx_GOTREF(__pyx_t_3);
4073 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4074 if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 50, __pyx_L1_error)
4075 __Pyx_GIVEREF(__pyx_t_3);
4076 __Pyx_GOTREF(__pyx_v_self->edgeNodesArray);
4077 __Pyx_DECREF(((PyObject *)__pyx_v_self->edgeNodesArray));
4078 __pyx_v_self->edgeNodesArray = ((PyArrayObject *)__pyx_t_3);
4088 __pyx_t_8 = ((__pyx_v_self->mesh.nodeStarOffsets != NULL) != 0);
4098 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 52, __pyx_L1_error)
4099 __Pyx_GOTREF(__pyx_t_2);
4100 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 52, __pyx_L1_error)
4101 __Pyx_GOTREF(__pyx_t_4);
4102 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4103 __pyx_t_5 = __pyx_v_self->mesh.nodeStarArray;
4105 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4106 __PYX_ERR(1, 52, __pyx_L1_error)
4108 __pyx_t_7 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 52, __pyx_L1_error)
4109 __Pyx_GOTREF(__pyx_t_7);
4110 __pyx_t_2 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)(__pyx_v_self->mesh.nodeStarOffsets[__pyx_v_self->mesh.nNodes_global])));
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 52, __pyx_L1_error)
4111 __Pyx_GOTREF(__pyx_t_2);
4112 __pyx_t_6 = __pyx_array_new(__pyx_t_2,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_7), (
char *)
"c", (
char *) __pyx_t_5);
4113 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 52, __pyx_L1_error)
4114 __Pyx_GOTREF(__pyx_t_6);
4115 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4116 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4118 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
4119 __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4);
4120 if (likely(__pyx_t_7)) {
4121 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
4122 __Pyx_INCREF(__pyx_t_7);
4123 __Pyx_INCREF(
function);
4124 __Pyx_DECREF_SET(__pyx_t_4,
function);
4127 __pyx_t_3 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_7, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_4, ((PyObject *)__pyx_t_6));
4128 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
4129 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4130 if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 52, __pyx_L1_error)
4131 __Pyx_GOTREF(__pyx_t_3);
4132 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4133 if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 52, __pyx_L1_error)
4134 __Pyx_GIVEREF(__pyx_t_3);
4135 __Pyx_GOTREF(__pyx_v_self->nodeStarArray);
4136 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeStarArray));
4137 __pyx_v_self->nodeStarArray = ((PyArrayObject *)__pyx_t_3);
4158 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 54, __pyx_L1_error)
4159 __Pyx_GOTREF(__pyx_t_3);
4160 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_empty);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 54, __pyx_L1_error)
4161 __Pyx_GOTREF(__pyx_t_4);
4162 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4163 __pyx_t_3 = __Pyx_PyDict_NewPresized(1);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 54, __pyx_L1_error)
4164 __Pyx_GOTREF(__pyx_t_3);
4165 __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_np);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 54, __pyx_L1_error)
4166 __Pyx_GOTREF(__pyx_t_7);
4167 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_int32);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 54, __pyx_L1_error)
4168 __Pyx_GOTREF(__pyx_t_2);
4169 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4170 if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_dtype, __pyx_t_2) < 0) __PYX_ERR(1, 54, __pyx_L1_error)
4171 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4172 __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_tuple_, __pyx_t_3);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 54, __pyx_L1_error)
4173 __Pyx_GOTREF(__pyx_t_2);
4174 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4175 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4176 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 54, __pyx_L1_error)
4177 __Pyx_GIVEREF(__pyx_t_2);
4178 __Pyx_GOTREF(__pyx_v_self->nodeStarArray);
4179 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeStarArray));
4180 __pyx_v_self->nodeStarArray = ((PyArrayObject *)__pyx_t_2);
4192 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 55, __pyx_L1_error)
4193 __Pyx_GOTREF(__pyx_t_3);
4194 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 55, __pyx_L1_error)
4195 __Pyx_GOTREF(__pyx_t_4);
4196 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4197 __pyx_t_5 = __pyx_v_self->mesh.nodeStarOffsets;
4199 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4200 __PYX_ERR(1, 55, __pyx_L1_error)
4202 __pyx_t_7 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 55, __pyx_L1_error)
4203 __Pyx_GOTREF(__pyx_t_7);
4204 __pyx_t_3 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)(__pyx_v_self->mesh.nNodes_global + 1)));
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 55, __pyx_L1_error)
4205 __Pyx_GOTREF(__pyx_t_3);
4206 __pyx_t_6 = __pyx_array_new(__pyx_t_3,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_7), (
char *)
"c", (
char *) __pyx_t_5);
4207 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 55, __pyx_L1_error)
4208 __Pyx_GOTREF(__pyx_t_6);
4209 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4210 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4212 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
4213 __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4);
4214 if (likely(__pyx_t_7)) {
4215 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
4216 __Pyx_INCREF(__pyx_t_7);
4217 __Pyx_INCREF(
function);
4218 __Pyx_DECREF_SET(__pyx_t_4,
function);
4221 __pyx_t_2 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_7, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_4, ((PyObject *)__pyx_t_6));
4222 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
4223 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4224 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 55, __pyx_L1_error)
4225 __Pyx_GOTREF(__pyx_t_2);
4226 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4227 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 55, __pyx_L1_error)
4228 __Pyx_GIVEREF(__pyx_t_2);
4229 __Pyx_GOTREF(__pyx_v_self->nodeStarOffsets);
4230 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeStarOffsets));
4231 __pyx_v_self->nodeStarOffsets = ((PyArrayObject *)__pyx_t_2);
4241 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 56, __pyx_L1_error)
4242 __Pyx_GOTREF(__pyx_t_4);
4243 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 56, __pyx_L1_error)
4244 __Pyx_GOTREF(__pyx_t_7);
4245 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4246 __pyx_t_5 = __pyx_v_self->mesh.elementMaterialTypes;
4248 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4249 __PYX_ERR(1, 56, __pyx_L1_error)
4251 __pyx_t_3 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 56, __pyx_L1_error)
4252 __Pyx_GOTREF(__pyx_t_3);
4253 __pyx_t_4 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElements_global));
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 56, __pyx_L1_error)
4254 __Pyx_GOTREF(__pyx_t_4);
4255 __pyx_t_6 = __pyx_array_new(__pyx_t_4,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_3), (
char *)
"c", (
char *) __pyx_t_5);
4256 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 56, __pyx_L1_error)
4257 __Pyx_GOTREF(__pyx_t_6);
4258 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4259 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4261 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) {
4262 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_7);
4263 if (likely(__pyx_t_3)) {
4264 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_7);
4265 __Pyx_INCREF(__pyx_t_3);
4266 __Pyx_INCREF(
function);
4267 __Pyx_DECREF_SET(__pyx_t_7,
function);
4270 __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_3, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_7, ((PyObject *)__pyx_t_6));
4271 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
4272 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4273 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 56, __pyx_L1_error)
4274 __Pyx_GOTREF(__pyx_t_2);
4275 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4276 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 56, __pyx_L1_error)
4277 __Pyx_GIVEREF(__pyx_t_2);
4278 __Pyx_GOTREF(__pyx_v_self->elementMaterialTypes);
4279 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementMaterialTypes));
4280 __pyx_v_self->elementMaterialTypes = ((PyArrayObject *)__pyx_t_2);
4290 __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_np);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 57, __pyx_L1_error)
4291 __Pyx_GOTREF(__pyx_t_7);
4292 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 57, __pyx_L1_error)
4293 __Pyx_GOTREF(__pyx_t_3);
4294 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4295 __pyx_t_5 = __pyx_v_self->mesh.elementBoundaryMaterialTypes;
4297 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4298 __PYX_ERR(1, 57, __pyx_L1_error)
4300 __pyx_t_4 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 57, __pyx_L1_error)
4301 __Pyx_GOTREF(__pyx_t_4);
4302 __pyx_t_7 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElementBoundaries_global));
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 57, __pyx_L1_error)
4303 __Pyx_GOTREF(__pyx_t_7);
4304 __pyx_t_6 = __pyx_array_new(__pyx_t_7,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_4), (
char *)
"c", (
char *) __pyx_t_5);
4305 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 57, __pyx_L1_error)
4306 __Pyx_GOTREF(__pyx_t_6);
4307 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4308 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4310 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
4311 __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
4312 if (likely(__pyx_t_4)) {
4313 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
4314 __Pyx_INCREF(__pyx_t_4);
4315 __Pyx_INCREF(
function);
4316 __Pyx_DECREF_SET(__pyx_t_3,
function);
4319 __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
4320 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
4321 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4322 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 57, __pyx_L1_error)
4323 __Pyx_GOTREF(__pyx_t_2);
4324 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4325 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 57, __pyx_L1_error)
4326 __Pyx_GIVEREF(__pyx_t_2);
4327 __Pyx_GOTREF(__pyx_v_self->elementBoundaryMaterialTypes);
4328 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryMaterialTypes));
4329 __pyx_v_self->elementBoundaryMaterialTypes = ((PyArrayObject *)__pyx_t_2);
4339 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 58, __pyx_L1_error)
4340 __Pyx_GOTREF(__pyx_t_3);
4341 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 58, __pyx_L1_error)
4342 __Pyx_GOTREF(__pyx_t_4);
4343 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4344 __pyx_t_5 = __pyx_v_self->mesh.nodeMaterialTypes;
4346 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4347 __PYX_ERR(1, 58, __pyx_L1_error)
4349 __pyx_t_7 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 58, __pyx_L1_error)
4350 __Pyx_GOTREF(__pyx_t_7);
4351 __pyx_t_3 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nNodes_global));
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 58, __pyx_L1_error)
4352 __Pyx_GOTREF(__pyx_t_3);
4353 __pyx_t_6 = __pyx_array_new(__pyx_t_3,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_7), (
char *)
"c", (
char *) __pyx_t_5);
4354 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 58, __pyx_L1_error)
4355 __Pyx_GOTREF(__pyx_t_6);
4356 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4357 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4359 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
4360 __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4);
4361 if (likely(__pyx_t_7)) {
4362 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
4363 __Pyx_INCREF(__pyx_t_7);
4364 __Pyx_INCREF(
function);
4365 __Pyx_DECREF_SET(__pyx_t_4,
function);
4368 __pyx_t_2 = (__pyx_t_7) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_7, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_4, ((PyObject *)__pyx_t_6));
4369 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
4370 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4371 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 58, __pyx_L1_error)
4372 __Pyx_GOTREF(__pyx_t_2);
4373 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4374 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 58, __pyx_L1_error)
4375 __Pyx_GIVEREF(__pyx_t_2);
4376 __Pyx_GOTREF(__pyx_v_self->nodeMaterialTypes);
4377 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeMaterialTypes));
4378 __pyx_v_self->nodeMaterialTypes = ((PyArrayObject *)__pyx_t_2);
4388 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 59, __pyx_L1_error)
4389 __Pyx_GOTREF(__pyx_t_4);
4390 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 59, __pyx_L1_error)
4391 __Pyx_GOTREF(__pyx_t_7);
4392 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4393 __pyx_t_9 = __pyx_v_self->mesh.nodeArray;
4395 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4396 __PYX_ERR(1, 59, __pyx_L1_error)
4398 __pyx_t_3 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 59, __pyx_L1_error)
4399 __Pyx_GOTREF(__pyx_t_3);
4400 __pyx_t_4 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nNodes_global), ((Py_ssize_t)3));
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 59, __pyx_L1_error)
4401 __Pyx_GOTREF(__pyx_t_4);
4402 __pyx_t_6 = __pyx_array_new(__pyx_t_4,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_3), (
char *)
"c", (
char *) __pyx_t_9);
4403 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 59, __pyx_L1_error)
4404 __Pyx_GOTREF(__pyx_t_6);
4405 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4406 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4408 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) {
4409 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_7);
4410 if (likely(__pyx_t_3)) {
4411 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_7);
4412 __Pyx_INCREF(__pyx_t_3);
4413 __Pyx_INCREF(
function);
4414 __Pyx_DECREF_SET(__pyx_t_7,
function);
4417 __pyx_t_2 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_3, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_7, ((PyObject *)__pyx_t_6));
4418 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
4419 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4420 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 59, __pyx_L1_error)
4421 __Pyx_GOTREF(__pyx_t_2);
4422 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4423 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 59, __pyx_L1_error)
4424 __Pyx_GIVEREF(__pyx_t_2);
4425 __Pyx_GOTREF(__pyx_v_self->nodeArray);
4426 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeArray));
4427 __pyx_v_self->nodeArray = ((PyArrayObject *)__pyx_t_2);
4437 __pyx_t_1 = __pyx_v_self->mesh.nx;
4438 __pyx_v_self->nx = __pyx_t_1;
4447 __pyx_t_1 = __pyx_v_self->mesh.ny;
4448 __pyx_v_self->ny = __pyx_t_1;
4457 __pyx_t_1 = __pyx_v_self->mesh.nz;
4458 __pyx_v_self->nz = __pyx_t_1;
4467 __pyx_t_1 = __pyx_v_self->mesh.px;
4468 __pyx_v_self->px = __pyx_t_1;
4477 __pyx_t_1 = __pyx_v_self->mesh.py;
4478 __pyx_v_self->py = __pyx_t_1;
4487 __pyx_t_1 = __pyx_v_self->mesh.pz;
4488 __pyx_v_self->pz = __pyx_t_1;
4497 __pyx_t_8 = ((__pyx_v_self->mesh.elementIJK != NULL) != 0);
4507 __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_np);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 67, __pyx_L1_error)
4508 __Pyx_GOTREF(__pyx_t_7);
4509 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 67, __pyx_L1_error)
4510 __Pyx_GOTREF(__pyx_t_3);
4511 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4512 __pyx_t_5 = __pyx_v_self->mesh.elementIJK;
4514 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4515 __PYX_ERR(1, 67, __pyx_L1_error)
4517 __pyx_t_4 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 67, __pyx_L1_error)
4518 __Pyx_GOTREF(__pyx_t_4);
4519 __pyx_t_7 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)(__pyx_v_self->mesh.nElements_global * 3)));
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 67, __pyx_L1_error)
4520 __Pyx_GOTREF(__pyx_t_7);
4521 __pyx_t_6 = __pyx_array_new(__pyx_t_7,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_4), (
char *)
"c", (
char *) __pyx_t_5);
4522 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 67, __pyx_L1_error)
4523 __Pyx_GOTREF(__pyx_t_6);
4524 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4525 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4527 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
4528 __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
4529 if (likely(__pyx_t_4)) {
4530 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
4531 __Pyx_INCREF(__pyx_t_4);
4532 __Pyx_INCREF(
function);
4533 __Pyx_DECREF_SET(__pyx_t_3,
function);
4536 __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
4537 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
4538 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4539 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 67, __pyx_L1_error)
4540 __Pyx_GOTREF(__pyx_t_2);
4541 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4542 if (!(likely(((__pyx_t_2) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 67, __pyx_L1_error)
4543 __Pyx_GIVEREF(__pyx_t_2);
4544 __Pyx_GOTREF(__pyx_v_self->elementIJK);
4545 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementIJK));
4546 __pyx_v_self->elementIJK = ((PyArrayObject *)__pyx_t_2);
4567 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 69, __pyx_L1_error)
4568 __Pyx_GOTREF(__pyx_t_2);
4569 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_empty);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 69, __pyx_L1_error)
4570 __Pyx_GOTREF(__pyx_t_3);
4571 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4572 __pyx_t_2 = __Pyx_PyDict_NewPresized(1);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 69, __pyx_L1_error)
4573 __Pyx_GOTREF(__pyx_t_2);
4574 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 69, __pyx_L1_error)
4575 __Pyx_GOTREF(__pyx_t_4);
4576 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_int32);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 69, __pyx_L1_error)
4577 __Pyx_GOTREF(__pyx_t_7);
4578 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4579 if (PyDict_SetItem(__pyx_t_2, __pyx_n_s_dtype, __pyx_t_7) < 0) __PYX_ERR(1, 69, __pyx_L1_error)
4580 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
4581 __pyx_t_7 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_tuple_, __pyx_t_2);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 69, __pyx_L1_error)
4582 __Pyx_GOTREF(__pyx_t_7);
4583 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4584 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4585 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 69, __pyx_L1_error)
4586 __Pyx_GIVEREF(__pyx_t_7);
4587 __Pyx_GOTREF(__pyx_v_self->elementIJK);
4588 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementIJK));
4589 __pyx_v_self->elementIJK = ((PyArrayObject *)__pyx_t_7);
4601 __pyx_t_8 = ((__pyx_v_self->mesh.weights != NULL) != 0);
4611 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 71, __pyx_L1_error)
4612 __Pyx_GOTREF(__pyx_t_2);
4613 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 71, __pyx_L1_error)
4614 __Pyx_GOTREF(__pyx_t_3);
4615 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4616 __pyx_t_9 = __pyx_v_self->mesh.weights;
4618 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4619 __PYX_ERR(1, 71, __pyx_L1_error)
4621 __pyx_t_4 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 71, __pyx_L1_error)
4622 __Pyx_GOTREF(__pyx_t_4);
4623 __pyx_t_2 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElements_global));
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 71, __pyx_L1_error)
4624 __Pyx_GOTREF(__pyx_t_2);
4625 __pyx_t_6 = __pyx_array_new(__pyx_t_2,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_4), (
char *)
"c", (
char *) __pyx_t_9);
4626 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 71, __pyx_L1_error)
4627 __Pyx_GOTREF(__pyx_t_6);
4628 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4629 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4631 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
4632 __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
4633 if (likely(__pyx_t_4)) {
4634 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
4635 __Pyx_INCREF(__pyx_t_4);
4636 __Pyx_INCREF(
function);
4637 __Pyx_DECREF_SET(__pyx_t_3,
function);
4640 __pyx_t_7 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
4641 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
4642 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4643 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 71, __pyx_L1_error)
4644 __Pyx_GOTREF(__pyx_t_7);
4645 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4646 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 71, __pyx_L1_error)
4647 __Pyx_GIVEREF(__pyx_t_7);
4648 __Pyx_GOTREF(__pyx_v_self->weights);
4649 __Pyx_DECREF(((PyObject *)__pyx_v_self->weights));
4650 __pyx_v_self->weights = ((PyArrayObject *)__pyx_t_7);
4671 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 73, __pyx_L1_error)
4672 __Pyx_GOTREF(__pyx_t_3);
4673 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_empty);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 73, __pyx_L1_error)
4674 __Pyx_GOTREF(__pyx_t_4);
4675 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4677 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
4678 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4);
4679 if (likely(__pyx_t_3)) {
4680 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
4681 __Pyx_INCREF(__pyx_t_3);
4682 __Pyx_INCREF(
function);
4683 __Pyx_DECREF_SET(__pyx_t_4,
function);
4686 __pyx_t_7 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_3, __pyx_int_0) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_int_0);
4687 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
4688 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 73, __pyx_L1_error)
4689 __Pyx_GOTREF(__pyx_t_7);
4690 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4691 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 73, __pyx_L1_error)
4692 __Pyx_GIVEREF(__pyx_t_7);
4693 __Pyx_GOTREF(__pyx_v_self->weights);
4694 __Pyx_DECREF(((PyObject *)__pyx_v_self->weights));
4695 __pyx_v_self->weights = ((PyArrayObject *)__pyx_t_7);
4707 __pyx_t_8 = ((__pyx_v_self->mesh.U_KNOT != NULL) != 0);
4717 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 75, __pyx_L1_error)
4718 __Pyx_GOTREF(__pyx_t_4);
4719 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 75, __pyx_L1_error)
4720 __Pyx_GOTREF(__pyx_t_3);
4721 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4722 __pyx_t_9 = __pyx_v_self->mesh.U_KNOT;
4724 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4725 __PYX_ERR(1, 75, __pyx_L1_error)
4727 __pyx_t_2 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 75, __pyx_L1_error)
4728 __Pyx_GOTREF(__pyx_t_2);
4729 __pyx_t_4 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)((__pyx_v_self->mesh.nx + __pyx_v_self->mesh.px) + 1)));
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 75, __pyx_L1_error)
4730 __Pyx_GOTREF(__pyx_t_4);
4731 __pyx_t_6 = __pyx_array_new(__pyx_t_4,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_2), (
char *)
"c", (
char *) __pyx_t_9);
4732 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 75, __pyx_L1_error)
4733 __Pyx_GOTREF(__pyx_t_6);
4734 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4735 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4737 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
4738 __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3);
4739 if (likely(__pyx_t_2)) {
4740 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
4741 __Pyx_INCREF(__pyx_t_2);
4742 __Pyx_INCREF(
function);
4743 __Pyx_DECREF_SET(__pyx_t_3,
function);
4746 __pyx_t_7 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
4747 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
4748 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4749 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 75, __pyx_L1_error)
4750 __Pyx_GOTREF(__pyx_t_7);
4751 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4752 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 75, __pyx_L1_error)
4753 __Pyx_GIVEREF(__pyx_t_7);
4754 __Pyx_GOTREF(__pyx_v_self->U_KNOT);
4755 __Pyx_DECREF(((PyObject *)__pyx_v_self->U_KNOT));
4756 __pyx_v_self->U_KNOT = ((PyArrayObject *)__pyx_t_7);
4777 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 77, __pyx_L1_error)
4778 __Pyx_GOTREF(__pyx_t_3);
4779 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_empty);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 77, __pyx_L1_error)
4780 __Pyx_GOTREF(__pyx_t_2);
4781 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4783 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
4784 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
4785 if (likely(__pyx_t_3)) {
4786 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
4787 __Pyx_INCREF(__pyx_t_3);
4788 __Pyx_INCREF(
function);
4789 __Pyx_DECREF_SET(__pyx_t_2,
function);
4792 __pyx_t_7 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_int_0) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_int_0);
4793 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
4794 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 77, __pyx_L1_error)
4795 __Pyx_GOTREF(__pyx_t_7);
4796 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4797 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 77, __pyx_L1_error)
4798 __Pyx_GIVEREF(__pyx_t_7);
4799 __Pyx_GOTREF(__pyx_v_self->U_KNOT);
4800 __Pyx_DECREF(((PyObject *)__pyx_v_self->U_KNOT));
4801 __pyx_v_self->U_KNOT = ((PyArrayObject *)__pyx_t_7);
4813 __pyx_t_8 = ((__pyx_v_self->mesh.V_KNOT != NULL) != 0);
4823 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 79, __pyx_L1_error)
4824 __Pyx_GOTREF(__pyx_t_2);
4825 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 79, __pyx_L1_error)
4826 __Pyx_GOTREF(__pyx_t_3);
4827 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4828 __pyx_t_9 = __pyx_v_self->mesh.V_KNOT;
4830 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4831 __PYX_ERR(1, 79, __pyx_L1_error)
4833 __pyx_t_4 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 79, __pyx_L1_error)
4834 __Pyx_GOTREF(__pyx_t_4);
4835 __pyx_t_2 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)((__pyx_v_self->mesh.ny + __pyx_v_self->mesh.py) + 1)));
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 79, __pyx_L1_error)
4836 __Pyx_GOTREF(__pyx_t_2);
4837 __pyx_t_6 = __pyx_array_new(__pyx_t_2,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_4), (
char *)
"c", (
char *) __pyx_t_9);
4838 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 79, __pyx_L1_error)
4839 __Pyx_GOTREF(__pyx_t_6);
4840 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4841 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4843 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
4844 __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
4845 if (likely(__pyx_t_4)) {
4846 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
4847 __Pyx_INCREF(__pyx_t_4);
4848 __Pyx_INCREF(
function);
4849 __Pyx_DECREF_SET(__pyx_t_3,
function);
4852 __pyx_t_7 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
4853 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
4854 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4855 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 79, __pyx_L1_error)
4856 __Pyx_GOTREF(__pyx_t_7);
4857 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4858 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 79, __pyx_L1_error)
4859 __Pyx_GIVEREF(__pyx_t_7);
4860 __Pyx_GOTREF(__pyx_v_self->V_KNOT);
4861 __Pyx_DECREF(((PyObject *)__pyx_v_self->V_KNOT));
4862 __pyx_v_self->V_KNOT = ((PyArrayObject *)__pyx_t_7);
4883 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 81, __pyx_L1_error)
4884 __Pyx_GOTREF(__pyx_t_3);
4885 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_empty);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 81, __pyx_L1_error)
4886 __Pyx_GOTREF(__pyx_t_4);
4887 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4889 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
4890 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_4);
4891 if (likely(__pyx_t_3)) {
4892 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
4893 __Pyx_INCREF(__pyx_t_3);
4894 __Pyx_INCREF(
function);
4895 __Pyx_DECREF_SET(__pyx_t_4,
function);
4898 __pyx_t_7 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_3, __pyx_int_0) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_int_0);
4899 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
4900 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 81, __pyx_L1_error)
4901 __Pyx_GOTREF(__pyx_t_7);
4902 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4903 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 81, __pyx_L1_error)
4904 __Pyx_GIVEREF(__pyx_t_7);
4905 __Pyx_GOTREF(__pyx_v_self->V_KNOT);
4906 __Pyx_DECREF(((PyObject *)__pyx_v_self->V_KNOT));
4907 __pyx_v_self->V_KNOT = ((PyArrayObject *)__pyx_t_7);
4919 __pyx_t_8 = ((__pyx_v_self->mesh.W_KNOT != NULL) != 0);
4929 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 83, __pyx_L1_error)
4930 __Pyx_GOTREF(__pyx_t_4);
4931 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 83, __pyx_L1_error)
4932 __Pyx_GOTREF(__pyx_t_3);
4933 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4934 __pyx_t_9 = __pyx_v_self->mesh.W_KNOT;
4936 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
4937 __PYX_ERR(1, 83, __pyx_L1_error)
4939 __pyx_t_2 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 83, __pyx_L1_error)
4940 __Pyx_GOTREF(__pyx_t_2);
4941 __pyx_t_4 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)((__pyx_v_self->mesh.nz + __pyx_v_self->mesh.pz) + 1)));
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 83, __pyx_L1_error)
4942 __Pyx_GOTREF(__pyx_t_4);
4943 __pyx_t_6 = __pyx_array_new(__pyx_t_4,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_2), (
char *)
"c", (
char *) __pyx_t_9);
4944 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 83, __pyx_L1_error)
4945 __Pyx_GOTREF(__pyx_t_6);
4946 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
4947 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
4949 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
4950 __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3);
4951 if (likely(__pyx_t_2)) {
4952 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
4953 __Pyx_INCREF(__pyx_t_2);
4954 __Pyx_INCREF(
function);
4955 __Pyx_DECREF_SET(__pyx_t_3,
function);
4958 __pyx_t_7 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
4959 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
4960 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
4961 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 83, __pyx_L1_error)
4962 __Pyx_GOTREF(__pyx_t_7);
4963 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4964 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 83, __pyx_L1_error)
4965 __Pyx_GIVEREF(__pyx_t_7);
4966 __Pyx_GOTREF(__pyx_v_self->W_KNOT);
4967 __Pyx_DECREF(((PyObject *)__pyx_v_self->W_KNOT));
4968 __pyx_v_self->W_KNOT = ((PyArrayObject *)__pyx_t_7);
4989 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 85, __pyx_L1_error)
4990 __Pyx_GOTREF(__pyx_t_3);
4991 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_empty);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 85, __pyx_L1_error)
4992 __Pyx_GOTREF(__pyx_t_2);
4993 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
4995 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
4996 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
4997 if (likely(__pyx_t_3)) {
4998 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
4999 __Pyx_INCREF(__pyx_t_3);
5000 __Pyx_INCREF(
function);
5001 __Pyx_DECREF_SET(__pyx_t_2,
function);
5004 __pyx_t_7 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, __pyx_int_0) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_int_0);
5005 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
5006 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 85, __pyx_L1_error)
5007 __Pyx_GOTREF(__pyx_t_7);
5008 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5009 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 85, __pyx_L1_error)
5010 __Pyx_GIVEREF(__pyx_t_7);
5011 __Pyx_GOTREF(__pyx_v_self->W_KNOT);
5012 __Pyx_DECREF(((PyObject *)__pyx_v_self->W_KNOT));
5013 __pyx_v_self->W_KNOT = ((PyArrayObject *)__pyx_t_7);
5025 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 86, __pyx_L1_error)
5026 __Pyx_GOTREF(__pyx_t_2);
5027 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 86, __pyx_L1_error)
5028 __Pyx_GOTREF(__pyx_t_3);
5029 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5030 __pyx_t_9 = __pyx_v_self->mesh.elementDiametersArray;
5032 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
5033 __PYX_ERR(1, 86, __pyx_L1_error)
5035 __pyx_t_4 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 86, __pyx_L1_error)
5036 __Pyx_GOTREF(__pyx_t_4);
5037 __pyx_t_2 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElements_global));
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 86, __pyx_L1_error)
5038 __Pyx_GOTREF(__pyx_t_2);
5039 __pyx_t_6 = __pyx_array_new(__pyx_t_2,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_4), (
char *)
"c", (
char *) __pyx_t_9);
5040 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 86, __pyx_L1_error)
5041 __Pyx_GOTREF(__pyx_t_6);
5042 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5043 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5045 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
5046 __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
5047 if (likely(__pyx_t_4)) {
5048 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
5049 __Pyx_INCREF(__pyx_t_4);
5050 __Pyx_INCREF(
function);
5051 __Pyx_DECREF_SET(__pyx_t_3,
function);
5054 __pyx_t_7 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
5055 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
5056 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
5057 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 86, __pyx_L1_error)
5058 __Pyx_GOTREF(__pyx_t_7);
5059 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5060 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 86, __pyx_L1_error)
5061 __Pyx_GIVEREF(__pyx_t_7);
5062 __Pyx_GOTREF(__pyx_v_self->elementDiametersArray);
5063 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementDiametersArray));
5064 __pyx_v_self->elementDiametersArray = ((PyArrayObject *)__pyx_t_7);
5074 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 87, __pyx_L1_error)
5075 __Pyx_GOTREF(__pyx_t_3);
5076 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 87, __pyx_L1_error)
5077 __Pyx_GOTREF(__pyx_t_4);
5078 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5079 __pyx_t_9 = __pyx_v_self->mesh.elementInnerDiametersArray;
5081 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
5082 __PYX_ERR(1, 87, __pyx_L1_error)
5084 __pyx_t_2 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 87, __pyx_L1_error)
5085 __Pyx_GOTREF(__pyx_t_2);
5086 __pyx_t_3 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElements_global));
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 87, __pyx_L1_error)
5087 __Pyx_GOTREF(__pyx_t_3);
5088 __pyx_t_6 = __pyx_array_new(__pyx_t_3,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_2), (
char *)
"c", (
char *) __pyx_t_9);
5089 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 87, __pyx_L1_error)
5090 __Pyx_GOTREF(__pyx_t_6);
5091 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5092 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5094 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
5095 __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_4);
5096 if (likely(__pyx_t_2)) {
5097 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
5098 __Pyx_INCREF(__pyx_t_2);
5099 __Pyx_INCREF(
function);
5100 __Pyx_DECREF_SET(__pyx_t_4,
function);
5103 __pyx_t_7 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_2, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_4, ((PyObject *)__pyx_t_6));
5104 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
5105 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
5106 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 87, __pyx_L1_error)
5107 __Pyx_GOTREF(__pyx_t_7);
5108 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5109 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 87, __pyx_L1_error)
5110 __Pyx_GIVEREF(__pyx_t_7);
5111 __Pyx_GOTREF(__pyx_v_self->elementInnerDiametersArray);
5112 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementInnerDiametersArray));
5113 __pyx_v_self->elementInnerDiametersArray = ((PyArrayObject *)__pyx_t_7);
5123 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 88, __pyx_L1_error)
5124 __Pyx_GOTREF(__pyx_t_4);
5125 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 88, __pyx_L1_error)
5126 __Pyx_GOTREF(__pyx_t_2);
5127 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5128 __pyx_t_9 = __pyx_v_self->mesh.elementBoundaryDiametersArray;
5130 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
5131 __PYX_ERR(1, 88, __pyx_L1_error)
5133 __pyx_t_3 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 88, __pyx_L1_error)
5134 __Pyx_GOTREF(__pyx_t_3);
5135 __pyx_t_4 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElementBoundaries_global));
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 88, __pyx_L1_error)
5136 __Pyx_GOTREF(__pyx_t_4);
5137 __pyx_t_6 = __pyx_array_new(__pyx_t_4,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_3), (
char *)
"c", (
char *) __pyx_t_9);
5138 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 88, __pyx_L1_error)
5139 __Pyx_GOTREF(__pyx_t_6);
5140 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5141 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5143 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
5144 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
5145 if (likely(__pyx_t_3)) {
5146 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
5147 __Pyx_INCREF(__pyx_t_3);
5148 __Pyx_INCREF(
function);
5149 __Pyx_DECREF_SET(__pyx_t_2,
function);
5152 __pyx_t_7 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_t_6));
5153 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
5154 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
5155 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 88, __pyx_L1_error)
5156 __Pyx_GOTREF(__pyx_t_7);
5157 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5158 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 88, __pyx_L1_error)
5159 __Pyx_GIVEREF(__pyx_t_7);
5160 __Pyx_GOTREF(__pyx_v_self->elementBoundaryDiametersArray);
5161 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryDiametersArray));
5162 __pyx_v_self->elementBoundaryDiametersArray = ((PyArrayObject *)__pyx_t_7);
5172 __pyx_t_8 = (__pyx_v_self->mesh.elementBarycentersArray != 0);
5182 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 90, __pyx_L1_error)
5183 __Pyx_GOTREF(__pyx_t_2);
5184 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 90, __pyx_L1_error)
5185 __Pyx_GOTREF(__pyx_t_3);
5186 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5187 __pyx_t_9 = __pyx_v_self->mesh.elementBarycentersArray;
5189 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
5190 __PYX_ERR(1, 90, __pyx_L1_error)
5192 __pyx_t_4 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 90, __pyx_L1_error)
5193 __Pyx_GOTREF(__pyx_t_4);
5194 __pyx_t_2 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElements_global), ((Py_ssize_t)3));
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 90, __pyx_L1_error)
5195 __Pyx_GOTREF(__pyx_t_2);
5196 __pyx_t_6 = __pyx_array_new(__pyx_t_2,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_4), (
char *)
"c", (
char *) __pyx_t_9);
5197 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 90, __pyx_L1_error)
5198 __Pyx_GOTREF(__pyx_t_6);
5199 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5200 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5202 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
5203 __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
5204 if (likely(__pyx_t_4)) {
5205 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
5206 __Pyx_INCREF(__pyx_t_4);
5207 __Pyx_INCREF(
function);
5208 __Pyx_DECREF_SET(__pyx_t_3,
function);
5211 __pyx_t_7 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
5212 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
5213 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
5214 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 90, __pyx_L1_error)
5215 __Pyx_GOTREF(__pyx_t_7);
5216 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5217 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 90, __pyx_L1_error)
5218 __Pyx_GIVEREF(__pyx_t_7);
5219 __Pyx_GOTREF(__pyx_v_self->elementBarycentersArray);
5220 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBarycentersArray));
5221 __pyx_v_self->elementBarycentersArray = ((PyArrayObject *)__pyx_t_7);
5240 __pyx_t_8 = (__pyx_v_self->mesh.elementBoundaryBarycentersArray != 0);
5250 __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_np);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 92, __pyx_L1_error)
5251 __Pyx_GOTREF(__pyx_t_3);
5252 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_t_3, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 92, __pyx_L1_error)
5253 __Pyx_GOTREF(__pyx_t_4);
5254 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5255 __pyx_t_9 = __pyx_v_self->mesh.elementBoundaryBarycentersArray;
5257 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
5258 __PYX_ERR(1, 92, __pyx_L1_error)
5260 __pyx_t_2 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 92, __pyx_L1_error)
5261 __Pyx_GOTREF(__pyx_t_2);
5262 __pyx_t_3 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nElementBoundaries_global), ((Py_ssize_t)3));
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 92, __pyx_L1_error)
5263 __Pyx_GOTREF(__pyx_t_3);
5264 __pyx_t_6 = __pyx_array_new(__pyx_t_3,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_2), (
char *)
"c", (
char *) __pyx_t_9);
5265 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 92, __pyx_L1_error)
5266 __Pyx_GOTREF(__pyx_t_6);
5267 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5268 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5270 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
5271 __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_4);
5272 if (likely(__pyx_t_2)) {
5273 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
5274 __Pyx_INCREF(__pyx_t_2);
5275 __Pyx_INCREF(
function);
5276 __Pyx_DECREF_SET(__pyx_t_4,
function);
5279 __pyx_t_7 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_2, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_4, ((PyObject *)__pyx_t_6));
5280 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
5281 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
5282 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 92, __pyx_L1_error)
5283 __Pyx_GOTREF(__pyx_t_7);
5284 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5285 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 92, __pyx_L1_error)
5286 __Pyx_GIVEREF(__pyx_t_7);
5287 __Pyx_GOTREF(__pyx_v_self->elementBoundaryBarycentersArray);
5288 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryBarycentersArray));
5289 __pyx_v_self->elementBoundaryBarycentersArray = ((PyArrayObject *)__pyx_t_7);
5308 __pyx_t_8 = (__pyx_v_self->mesh.nodeDiametersArray != 0);
5318 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_np);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 94, __pyx_L1_error)
5319 __Pyx_GOTREF(__pyx_t_4);
5320 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_4, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 94, __pyx_L1_error)
5321 __Pyx_GOTREF(__pyx_t_2);
5322 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5323 __pyx_t_9 = __pyx_v_self->mesh.nodeDiametersArray;
5325 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
5326 __PYX_ERR(1, 94, __pyx_L1_error)
5328 __pyx_t_3 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 94, __pyx_L1_error)
5329 __Pyx_GOTREF(__pyx_t_3);
5330 __pyx_t_4 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nNodes_global));
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 94, __pyx_L1_error)
5331 __Pyx_GOTREF(__pyx_t_4);
5332 __pyx_t_6 = __pyx_array_new(__pyx_t_4,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_3), (
char *)
"c", (
char *) __pyx_t_9);
5333 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 94, __pyx_L1_error)
5334 __Pyx_GOTREF(__pyx_t_6);
5335 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5336 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5338 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
5339 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
5340 if (likely(__pyx_t_3)) {
5341 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
5342 __Pyx_INCREF(__pyx_t_3);
5343 __Pyx_INCREF(
function);
5344 __Pyx_DECREF_SET(__pyx_t_2,
function);
5347 __pyx_t_7 = (__pyx_t_3) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_3, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_2, ((PyObject *)__pyx_t_6));
5348 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
5349 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
5350 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 94, __pyx_L1_error)
5351 __Pyx_GOTREF(__pyx_t_7);
5352 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5353 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 94, __pyx_L1_error)
5354 __Pyx_GIVEREF(__pyx_t_7);
5355 __Pyx_GOTREF(__pyx_v_self->nodeDiametersArray);
5356 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeDiametersArray));
5357 __pyx_v_self->nodeDiametersArray = ((PyArrayObject *)__pyx_t_7);
5376 __pyx_t_8 = (__pyx_v_self->mesh.nodeSupportArray != 0);
5386 __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_np);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 96, __pyx_L1_error)
5387 __Pyx_GOTREF(__pyx_t_2);
5388 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 96, __pyx_L1_error)
5389 __Pyx_GOTREF(__pyx_t_3);
5390 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5391 __pyx_t_9 = __pyx_v_self->mesh.nodeSupportArray;
5393 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
5394 __PYX_ERR(1, 96, __pyx_L1_error)
5396 __pyx_t_4 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_double);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 96, __pyx_L1_error)
5397 __Pyx_GOTREF(__pyx_t_4);
5398 __pyx_t_2 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_self->mesh.nNodes_global));
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 96, __pyx_L1_error)
5399 __Pyx_GOTREF(__pyx_t_2);
5400 __pyx_t_6 = __pyx_array_new(__pyx_t_2,
sizeof(
double), PyBytes_AS_STRING(__pyx_t_4), (
char *)
"c", (
char *) __pyx_t_9);
5401 if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 96, __pyx_L1_error)
5402 __Pyx_GOTREF(__pyx_t_6);
5403 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
5404 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
5406 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
5407 __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
5408 if (likely(__pyx_t_4)) {
5409 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
5410 __Pyx_INCREF(__pyx_t_4);
5411 __Pyx_INCREF(
function);
5412 __Pyx_DECREF_SET(__pyx_t_3,
function);
5415 __pyx_t_7 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_t_6)) : __Pyx_PyObject_CallOneArg(__pyx_t_3, ((PyObject *)__pyx_t_6));
5416 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
5417 __Pyx_DECREF(((PyObject *)__pyx_t_6)); __pyx_t_6 = 0;
5418 if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 96, __pyx_L1_error)
5419 __Pyx_GOTREF(__pyx_t_7);
5420 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
5421 if (!(likely(((__pyx_t_7) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(1, 96, __pyx_L1_error)
5422 __Pyx_GIVEREF(__pyx_t_7);
5423 __Pyx_GOTREF(__pyx_v_self->nodeSupportArray);
5424 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeSupportArray));
5425 __pyx_v_self->nodeSupportArray = ((PyArrayObject *)__pyx_t_7);
5444 __pyx_t_10 = __pyx_v_self->mesh.h;
5445 __pyx_v_self->h = __pyx_t_10;
5454 __pyx_t_10 = __pyx_v_self->mesh.hMin;
5455 __pyx_v_self->hMin = __pyx_t_10;
5464 __pyx_t_10 = __pyx_v_self->mesh.sigmaMax;
5465 __pyx_v_self->sigmaMax = __pyx_t_10;
5474 __pyx_t_10 = __pyx_v_self->mesh.volume;
5475 __pyx_v_self->volume = __pyx_t_10;
5486 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
5489 __Pyx_XDECREF(__pyx_t_2);
5490 __Pyx_XDECREF(__pyx_t_3);
5491 __Pyx_XDECREF(__pyx_t_4);
5492 __Pyx_XDECREF(((PyObject *)__pyx_t_6));
5493 __Pyx_XDECREF(__pyx_t_7);
5494 __Pyx_AddTraceback(
"cmeshTools.CMesh.buildPythonMeshInterface", __pyx_clineno, __pyx_lineno, __pyx_filename);
5497 __Pyx_XGIVEREF(__pyx_r);
5498 __Pyx_RefNannyFinishContext();
5511 static PyObject *__pyx_pw_10cmeshTools_5CMesh_7buildPythonMeshInterfaceNoArrays(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
5512 static PyObject *__pyx_pw_10cmeshTools_5CMesh_7buildPythonMeshInterfaceNoArrays(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
5513 PyObject *__pyx_r = 0;
5514 __Pyx_RefNannyDeclarations
5515 __Pyx_RefNannySetupContext(
"buildPythonMeshInterfaceNoArrays (wrapper)", 0);
5516 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6buildPythonMeshInterfaceNoArrays(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
5519 __Pyx_RefNannyFinishContext();
5523 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6buildPythonMeshInterfaceNoArrays(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
5524 PyObject *__pyx_r = NULL;
5525 __Pyx_RefNannyDeclarations
5528 __Pyx_RefNannySetupContext(
"buildPythonMeshInterfaceNoArrays", 0);
5537 __pyx_t_1 = __pyx_v_self->mesh.nElements_global;
5538 __pyx_v_self->nElements_global = __pyx_t_1;
5547 __pyx_t_1 = __pyx_v_self->mesh.nNodes_global;
5548 __pyx_v_self->nNodes_global = __pyx_t_1;
5557 __pyx_t_1 = __pyx_v_self->mesh.nNodes_element;
5558 __pyx_v_self->nNodes_element = __pyx_t_1;
5567 __pyx_t_1 = __pyx_v_self->mesh.nNodes_elementBoundary;
5568 __pyx_v_self->nNodes_elementBoundary = __pyx_t_1;
5577 __pyx_t_1 = __pyx_v_self->mesh.nElementBoundaries_element;
5578 __pyx_v_self->nElementBoundaries_element = __pyx_t_1;
5587 __pyx_t_1 = __pyx_v_self->mesh.nElementBoundaries_global;
5588 __pyx_v_self->nElementBoundaries_global = __pyx_t_1;
5597 __pyx_t_1 = __pyx_v_self->mesh.nInteriorElementBoundaries_global;
5598 __pyx_v_self->nInteriorElementBoundaries_global = __pyx_t_1;
5607 __pyx_t_1 = __pyx_v_self->mesh.nExteriorElementBoundaries_global;
5608 __pyx_v_self->nExteriorElementBoundaries_global = __pyx_t_1;
5617 __pyx_t_1 = __pyx_v_self->mesh.max_nElements_node;
5618 __pyx_v_self->max_nElements_node = __pyx_t_1;
5627 __pyx_t_1 = __pyx_v_self->mesh.nEdges_global;
5628 __pyx_v_self->nEdges_global = __pyx_t_1;
5637 __pyx_t_1 = __pyx_v_self->mesh.max_nNodeNeighbors_node;
5638 __pyx_v_self->max_nNodeNeighbors_node = __pyx_t_1;
5647 __pyx_t_2 = __pyx_v_self->mesh.h;
5648 __pyx_v_self->h = __pyx_t_2;
5657 __pyx_t_2 = __pyx_v_self->mesh.hMin;
5658 __pyx_v_self->hMin = __pyx_t_2;
5667 __pyx_t_2 = __pyx_v_self->mesh.sigmaMax;
5668 __pyx_v_self->sigmaMax = __pyx_t_2;
5677 __pyx_t_2 = __pyx_v_self->mesh.volume;
5678 __pyx_v_self->volume = __pyx_t_2;
5689 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
5690 __Pyx_XGIVEREF(__pyx_r);
5691 __Pyx_RefNannyFinishContext();
5704 static PyObject *__pyx_pw_10cmeshTools_5CMesh_16nElements_global_1__get__(PyObject *__pyx_v_self);
5705 static PyObject *__pyx_pw_10cmeshTools_5CMesh_16nElements_global_1__get__(PyObject *__pyx_v_self) {
5706 PyObject *__pyx_r = 0;
5707 __Pyx_RefNannyDeclarations
5708 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
5709 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_16nElements_global___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
5712 __Pyx_RefNannyFinishContext();
5716 static PyObject *__pyx_pf_10cmeshTools_5CMesh_16nElements_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
5717 PyObject *__pyx_r = NULL;
5718 __Pyx_RefNannyDeclarations
5719 PyObject *__pyx_t_1 = NULL;
5720 int __pyx_lineno = 0;
5721 const char *__pyx_filename = NULL;
5722 int __pyx_clineno = 0;
5723 __Pyx_RefNannySetupContext(
"__get__", 0);
5724 __Pyx_XDECREF(__pyx_r);
5725 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nElements_global);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 8, __pyx_L1_error)
5726 __Pyx_GOTREF(__pyx_t_1);
5727 __pyx_r = __pyx_t_1;
5733 __Pyx_XDECREF(__pyx_t_1);
5734 __Pyx_AddTraceback(
"cmeshTools.CMesh.nElements_global.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
5737 __Pyx_XGIVEREF(__pyx_r);
5738 __Pyx_RefNannyFinishContext();
5743 static int __pyx_pw_10cmeshTools_5CMesh_16nElements_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
5744 static int __pyx_pw_10cmeshTools_5CMesh_16nElements_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
5746 __Pyx_RefNannyDeclarations
5747 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
5748 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_16nElements_global_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
5751 __Pyx_RefNannyFinishContext();
5755 static int __pyx_pf_10cmeshTools_5CMesh_16nElements_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
5757 __Pyx_RefNannyDeclarations
5759 int __pyx_lineno = 0;
5760 const char *__pyx_filename = NULL;
5761 int __pyx_clineno = 0;
5762 __Pyx_RefNannySetupContext(
"__set__", 0);
5763 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 8, __pyx_L1_error)
5764 __pyx_v_self->nElements_global = __pyx_t_1;
5770 __Pyx_AddTraceback(
"cmeshTools.CMesh.nElements_global.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
5773 __Pyx_RefNannyFinishContext();
5786 static PyObject *__pyx_pw_10cmeshTools_5CMesh_13nNodes_global_1__get__(PyObject *__pyx_v_self);
5787 static PyObject *__pyx_pw_10cmeshTools_5CMesh_13nNodes_global_1__get__(PyObject *__pyx_v_self) {
5788 PyObject *__pyx_r = 0;
5789 __Pyx_RefNannyDeclarations
5790 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
5791 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_13nNodes_global___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
5794 __Pyx_RefNannyFinishContext();
5798 static PyObject *__pyx_pf_10cmeshTools_5CMesh_13nNodes_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
5799 PyObject *__pyx_r = NULL;
5800 __Pyx_RefNannyDeclarations
5801 PyObject *__pyx_t_1 = NULL;
5802 int __pyx_lineno = 0;
5803 const char *__pyx_filename = NULL;
5804 int __pyx_clineno = 0;
5805 __Pyx_RefNannySetupContext(
"__get__", 0);
5806 __Pyx_XDECREF(__pyx_r);
5807 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nNodes_global);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 9, __pyx_L1_error)
5808 __Pyx_GOTREF(__pyx_t_1);
5809 __pyx_r = __pyx_t_1;
5815 __Pyx_XDECREF(__pyx_t_1);
5816 __Pyx_AddTraceback(
"cmeshTools.CMesh.nNodes_global.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
5819 __Pyx_XGIVEREF(__pyx_r);
5820 __Pyx_RefNannyFinishContext();
5825 static int __pyx_pw_10cmeshTools_5CMesh_13nNodes_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
5826 static int __pyx_pw_10cmeshTools_5CMesh_13nNodes_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
5828 __Pyx_RefNannyDeclarations
5829 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
5830 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_13nNodes_global_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
5833 __Pyx_RefNannyFinishContext();
5837 static int __pyx_pf_10cmeshTools_5CMesh_13nNodes_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
5839 __Pyx_RefNannyDeclarations
5841 int __pyx_lineno = 0;
5842 const char *__pyx_filename = NULL;
5843 int __pyx_clineno = 0;
5844 __Pyx_RefNannySetupContext(
"__set__", 0);
5845 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 9, __pyx_L1_error)
5846 __pyx_v_self->nNodes_global = __pyx_t_1;
5852 __Pyx_AddTraceback(
"cmeshTools.CMesh.nNodes_global.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
5855 __Pyx_RefNannyFinishContext();
5868 static PyObject *__pyx_pw_10cmeshTools_5CMesh_14nNodes_element_1__get__(PyObject *__pyx_v_self);
5869 static PyObject *__pyx_pw_10cmeshTools_5CMesh_14nNodes_element_1__get__(PyObject *__pyx_v_self) {
5870 PyObject *__pyx_r = 0;
5871 __Pyx_RefNannyDeclarations
5872 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
5873 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_14nNodes_element___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
5876 __Pyx_RefNannyFinishContext();
5880 static PyObject *__pyx_pf_10cmeshTools_5CMesh_14nNodes_element___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
5881 PyObject *__pyx_r = NULL;
5882 __Pyx_RefNannyDeclarations
5883 PyObject *__pyx_t_1 = NULL;
5884 int __pyx_lineno = 0;
5885 const char *__pyx_filename = NULL;
5886 int __pyx_clineno = 0;
5887 __Pyx_RefNannySetupContext(
"__get__", 0);
5888 __Pyx_XDECREF(__pyx_r);
5889 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nNodes_element);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 10, __pyx_L1_error)
5890 __Pyx_GOTREF(__pyx_t_1);
5891 __pyx_r = __pyx_t_1;
5897 __Pyx_XDECREF(__pyx_t_1);
5898 __Pyx_AddTraceback(
"cmeshTools.CMesh.nNodes_element.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
5901 __Pyx_XGIVEREF(__pyx_r);
5902 __Pyx_RefNannyFinishContext();
5907 static int __pyx_pw_10cmeshTools_5CMesh_14nNodes_element_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
5908 static int __pyx_pw_10cmeshTools_5CMesh_14nNodes_element_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
5910 __Pyx_RefNannyDeclarations
5911 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
5912 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_14nNodes_element_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
5915 __Pyx_RefNannyFinishContext();
5919 static int __pyx_pf_10cmeshTools_5CMesh_14nNodes_element_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
5921 __Pyx_RefNannyDeclarations
5923 int __pyx_lineno = 0;
5924 const char *__pyx_filename = NULL;
5925 int __pyx_clineno = 0;
5926 __Pyx_RefNannySetupContext(
"__set__", 0);
5927 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 10, __pyx_L1_error)
5928 __pyx_v_self->nNodes_element = __pyx_t_1;
5934 __Pyx_AddTraceback(
"cmeshTools.CMesh.nNodes_element.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
5937 __Pyx_RefNannyFinishContext();
5950 static PyObject *__pyx_pw_10cmeshTools_5CMesh_22nNodes_elementBoundary_1__get__(PyObject *__pyx_v_self);
5951 static PyObject *__pyx_pw_10cmeshTools_5CMesh_22nNodes_elementBoundary_1__get__(PyObject *__pyx_v_self) {
5952 PyObject *__pyx_r = 0;
5953 __Pyx_RefNannyDeclarations
5954 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
5955 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_22nNodes_elementBoundary___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
5958 __Pyx_RefNannyFinishContext();
5962 static PyObject *__pyx_pf_10cmeshTools_5CMesh_22nNodes_elementBoundary___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
5963 PyObject *__pyx_r = NULL;
5964 __Pyx_RefNannyDeclarations
5965 PyObject *__pyx_t_1 = NULL;
5966 int __pyx_lineno = 0;
5967 const char *__pyx_filename = NULL;
5968 int __pyx_clineno = 0;
5969 __Pyx_RefNannySetupContext(
"__get__", 0);
5970 __Pyx_XDECREF(__pyx_r);
5971 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nNodes_elementBoundary);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 11, __pyx_L1_error)
5972 __Pyx_GOTREF(__pyx_t_1);
5973 __pyx_r = __pyx_t_1;
5979 __Pyx_XDECREF(__pyx_t_1);
5980 __Pyx_AddTraceback(
"cmeshTools.CMesh.nNodes_elementBoundary.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
5983 __Pyx_XGIVEREF(__pyx_r);
5984 __Pyx_RefNannyFinishContext();
5989 static int __pyx_pw_10cmeshTools_5CMesh_22nNodes_elementBoundary_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
5990 static int __pyx_pw_10cmeshTools_5CMesh_22nNodes_elementBoundary_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
5992 __Pyx_RefNannyDeclarations
5993 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
5994 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_22nNodes_elementBoundary_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
5997 __Pyx_RefNannyFinishContext();
6001 static int __pyx_pf_10cmeshTools_5CMesh_22nNodes_elementBoundary_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6003 __Pyx_RefNannyDeclarations
6005 int __pyx_lineno = 0;
6006 const char *__pyx_filename = NULL;
6007 int __pyx_clineno = 0;
6008 __Pyx_RefNannySetupContext(
"__set__", 0);
6009 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 11, __pyx_L1_error)
6010 __pyx_v_self->nNodes_elementBoundary = __pyx_t_1;
6016 __Pyx_AddTraceback(
"cmeshTools.CMesh.nNodes_elementBoundary.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6019 __Pyx_RefNannyFinishContext();
6032 static PyObject *__pyx_pw_10cmeshTools_5CMesh_26nElementBoundaries_element_1__get__(PyObject *__pyx_v_self);
6033 static PyObject *__pyx_pw_10cmeshTools_5CMesh_26nElementBoundaries_element_1__get__(PyObject *__pyx_v_self) {
6034 PyObject *__pyx_r = 0;
6035 __Pyx_RefNannyDeclarations
6036 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6037 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_26nElementBoundaries_element___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6040 __Pyx_RefNannyFinishContext();
6044 static PyObject *__pyx_pf_10cmeshTools_5CMesh_26nElementBoundaries_element___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6045 PyObject *__pyx_r = NULL;
6046 __Pyx_RefNannyDeclarations
6047 PyObject *__pyx_t_1 = NULL;
6048 int __pyx_lineno = 0;
6049 const char *__pyx_filename = NULL;
6050 int __pyx_clineno = 0;
6051 __Pyx_RefNannySetupContext(
"__get__", 0);
6052 __Pyx_XDECREF(__pyx_r);
6053 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nElementBoundaries_element);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 12, __pyx_L1_error)
6054 __Pyx_GOTREF(__pyx_t_1);
6055 __pyx_r = __pyx_t_1;
6061 __Pyx_XDECREF(__pyx_t_1);
6062 __Pyx_AddTraceback(
"cmeshTools.CMesh.nElementBoundaries_element.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6065 __Pyx_XGIVEREF(__pyx_r);
6066 __Pyx_RefNannyFinishContext();
6071 static int __pyx_pw_10cmeshTools_5CMesh_26nElementBoundaries_element_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6072 static int __pyx_pw_10cmeshTools_5CMesh_26nElementBoundaries_element_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6074 __Pyx_RefNannyDeclarations
6075 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6076 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_26nElementBoundaries_element_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6079 __Pyx_RefNannyFinishContext();
6083 static int __pyx_pf_10cmeshTools_5CMesh_26nElementBoundaries_element_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6085 __Pyx_RefNannyDeclarations
6087 int __pyx_lineno = 0;
6088 const char *__pyx_filename = NULL;
6089 int __pyx_clineno = 0;
6090 __Pyx_RefNannySetupContext(
"__set__", 0);
6091 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 12, __pyx_L1_error)
6092 __pyx_v_self->nElementBoundaries_element = __pyx_t_1;
6098 __Pyx_AddTraceback(
"cmeshTools.CMesh.nElementBoundaries_element.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6101 __Pyx_RefNannyFinishContext();
6114 static PyObject *__pyx_pw_10cmeshTools_5CMesh_25nElementBoundaries_global_1__get__(PyObject *__pyx_v_self);
6115 static PyObject *__pyx_pw_10cmeshTools_5CMesh_25nElementBoundaries_global_1__get__(PyObject *__pyx_v_self) {
6116 PyObject *__pyx_r = 0;
6117 __Pyx_RefNannyDeclarations
6118 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6119 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_25nElementBoundaries_global___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6122 __Pyx_RefNannyFinishContext();
6126 static PyObject *__pyx_pf_10cmeshTools_5CMesh_25nElementBoundaries_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6127 PyObject *__pyx_r = NULL;
6128 __Pyx_RefNannyDeclarations
6129 PyObject *__pyx_t_1 = NULL;
6130 int __pyx_lineno = 0;
6131 const char *__pyx_filename = NULL;
6132 int __pyx_clineno = 0;
6133 __Pyx_RefNannySetupContext(
"__get__", 0);
6134 __Pyx_XDECREF(__pyx_r);
6135 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nElementBoundaries_global);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 13, __pyx_L1_error)
6136 __Pyx_GOTREF(__pyx_t_1);
6137 __pyx_r = __pyx_t_1;
6143 __Pyx_XDECREF(__pyx_t_1);
6144 __Pyx_AddTraceback(
"cmeshTools.CMesh.nElementBoundaries_global.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6147 __Pyx_XGIVEREF(__pyx_r);
6148 __Pyx_RefNannyFinishContext();
6153 static int __pyx_pw_10cmeshTools_5CMesh_25nElementBoundaries_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6154 static int __pyx_pw_10cmeshTools_5CMesh_25nElementBoundaries_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6156 __Pyx_RefNannyDeclarations
6157 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6158 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_25nElementBoundaries_global_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6161 __Pyx_RefNannyFinishContext();
6165 static int __pyx_pf_10cmeshTools_5CMesh_25nElementBoundaries_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6167 __Pyx_RefNannyDeclarations
6169 int __pyx_lineno = 0;
6170 const char *__pyx_filename = NULL;
6171 int __pyx_clineno = 0;
6172 __Pyx_RefNannySetupContext(
"__set__", 0);
6173 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 13, __pyx_L1_error)
6174 __pyx_v_self->nElementBoundaries_global = __pyx_t_1;
6180 __Pyx_AddTraceback(
"cmeshTools.CMesh.nElementBoundaries_global.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6183 __Pyx_RefNannyFinishContext();
6196 static PyObject *__pyx_pw_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global_1__get__(PyObject *__pyx_v_self);
6197 static PyObject *__pyx_pw_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global_1__get__(PyObject *__pyx_v_self) {
6198 PyObject *__pyx_r = 0;
6199 __Pyx_RefNannyDeclarations
6200 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6201 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6204 __Pyx_RefNannyFinishContext();
6208 static PyObject *__pyx_pf_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6209 PyObject *__pyx_r = NULL;
6210 __Pyx_RefNannyDeclarations
6211 PyObject *__pyx_t_1 = NULL;
6212 int __pyx_lineno = 0;
6213 const char *__pyx_filename = NULL;
6214 int __pyx_clineno = 0;
6215 __Pyx_RefNannySetupContext(
"__get__", 0);
6216 __Pyx_XDECREF(__pyx_r);
6217 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nInteriorElementBoundaries_global);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 14, __pyx_L1_error)
6218 __Pyx_GOTREF(__pyx_t_1);
6219 __pyx_r = __pyx_t_1;
6225 __Pyx_XDECREF(__pyx_t_1);
6226 __Pyx_AddTraceback(
"cmeshTools.CMesh.nInteriorElementBoundaries_global.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6229 __Pyx_XGIVEREF(__pyx_r);
6230 __Pyx_RefNannyFinishContext();
6235 static int __pyx_pw_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6236 static int __pyx_pw_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6238 __Pyx_RefNannyDeclarations
6239 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6240 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6243 __Pyx_RefNannyFinishContext();
6247 static int __pyx_pf_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6249 __Pyx_RefNannyDeclarations
6251 int __pyx_lineno = 0;
6252 const char *__pyx_filename = NULL;
6253 int __pyx_clineno = 0;
6254 __Pyx_RefNannySetupContext(
"__set__", 0);
6255 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 14, __pyx_L1_error)
6256 __pyx_v_self->nInteriorElementBoundaries_global = __pyx_t_1;
6262 __Pyx_AddTraceback(
"cmeshTools.CMesh.nInteriorElementBoundaries_global.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6265 __Pyx_RefNannyFinishContext();
6278 static PyObject *__pyx_pw_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global_1__get__(PyObject *__pyx_v_self);
6279 static PyObject *__pyx_pw_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global_1__get__(PyObject *__pyx_v_self) {
6280 PyObject *__pyx_r = 0;
6281 __Pyx_RefNannyDeclarations
6282 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6283 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6286 __Pyx_RefNannyFinishContext();
6290 static PyObject *__pyx_pf_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6291 PyObject *__pyx_r = NULL;
6292 __Pyx_RefNannyDeclarations
6293 PyObject *__pyx_t_1 = NULL;
6294 int __pyx_lineno = 0;
6295 const char *__pyx_filename = NULL;
6296 int __pyx_clineno = 0;
6297 __Pyx_RefNannySetupContext(
"__get__", 0);
6298 __Pyx_XDECREF(__pyx_r);
6299 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nExteriorElementBoundaries_global);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 15, __pyx_L1_error)
6300 __Pyx_GOTREF(__pyx_t_1);
6301 __pyx_r = __pyx_t_1;
6307 __Pyx_XDECREF(__pyx_t_1);
6308 __Pyx_AddTraceback(
"cmeshTools.CMesh.nExteriorElementBoundaries_global.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6311 __Pyx_XGIVEREF(__pyx_r);
6312 __Pyx_RefNannyFinishContext();
6317 static int __pyx_pw_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6318 static int __pyx_pw_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6320 __Pyx_RefNannyDeclarations
6321 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6322 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6325 __Pyx_RefNannyFinishContext();
6329 static int __pyx_pf_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6331 __Pyx_RefNannyDeclarations
6333 int __pyx_lineno = 0;
6334 const char *__pyx_filename = NULL;
6335 int __pyx_clineno = 0;
6336 __Pyx_RefNannySetupContext(
"__set__", 0);
6337 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 15, __pyx_L1_error)
6338 __pyx_v_self->nExteriorElementBoundaries_global = __pyx_t_1;
6344 __Pyx_AddTraceback(
"cmeshTools.CMesh.nExteriorElementBoundaries_global.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6347 __Pyx_RefNannyFinishContext();
6360 static PyObject *__pyx_pw_10cmeshTools_5CMesh_18max_nElements_node_1__get__(PyObject *__pyx_v_self);
6361 static PyObject *__pyx_pw_10cmeshTools_5CMesh_18max_nElements_node_1__get__(PyObject *__pyx_v_self) {
6362 PyObject *__pyx_r = 0;
6363 __Pyx_RefNannyDeclarations
6364 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6365 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_18max_nElements_node___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6368 __Pyx_RefNannyFinishContext();
6372 static PyObject *__pyx_pf_10cmeshTools_5CMesh_18max_nElements_node___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6373 PyObject *__pyx_r = NULL;
6374 __Pyx_RefNannyDeclarations
6375 PyObject *__pyx_t_1 = NULL;
6376 int __pyx_lineno = 0;
6377 const char *__pyx_filename = NULL;
6378 int __pyx_clineno = 0;
6379 __Pyx_RefNannySetupContext(
"__get__", 0);
6380 __Pyx_XDECREF(__pyx_r);
6381 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->max_nElements_node);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 16, __pyx_L1_error)
6382 __Pyx_GOTREF(__pyx_t_1);
6383 __pyx_r = __pyx_t_1;
6389 __Pyx_XDECREF(__pyx_t_1);
6390 __Pyx_AddTraceback(
"cmeshTools.CMesh.max_nElements_node.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6393 __Pyx_XGIVEREF(__pyx_r);
6394 __Pyx_RefNannyFinishContext();
6399 static int __pyx_pw_10cmeshTools_5CMesh_18max_nElements_node_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6400 static int __pyx_pw_10cmeshTools_5CMesh_18max_nElements_node_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6402 __Pyx_RefNannyDeclarations
6403 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6404 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_18max_nElements_node_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6407 __Pyx_RefNannyFinishContext();
6411 static int __pyx_pf_10cmeshTools_5CMesh_18max_nElements_node_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6413 __Pyx_RefNannyDeclarations
6415 int __pyx_lineno = 0;
6416 const char *__pyx_filename = NULL;
6417 int __pyx_clineno = 0;
6418 __Pyx_RefNannySetupContext(
"__set__", 0);
6419 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 16, __pyx_L1_error)
6420 __pyx_v_self->max_nElements_node = __pyx_t_1;
6426 __Pyx_AddTraceback(
"cmeshTools.CMesh.max_nElements_node.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6429 __Pyx_RefNannyFinishContext();
6442 static PyObject *__pyx_pw_10cmeshTools_5CMesh_13nEdges_global_1__get__(PyObject *__pyx_v_self);
6443 static PyObject *__pyx_pw_10cmeshTools_5CMesh_13nEdges_global_1__get__(PyObject *__pyx_v_self) {
6444 PyObject *__pyx_r = 0;
6445 __Pyx_RefNannyDeclarations
6446 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6447 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_13nEdges_global___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6450 __Pyx_RefNannyFinishContext();
6454 static PyObject *__pyx_pf_10cmeshTools_5CMesh_13nEdges_global___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6455 PyObject *__pyx_r = NULL;
6456 __Pyx_RefNannyDeclarations
6457 PyObject *__pyx_t_1 = NULL;
6458 int __pyx_lineno = 0;
6459 const char *__pyx_filename = NULL;
6460 int __pyx_clineno = 0;
6461 __Pyx_RefNannySetupContext(
"__get__", 0);
6462 __Pyx_XDECREF(__pyx_r);
6463 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nEdges_global);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 17, __pyx_L1_error)
6464 __Pyx_GOTREF(__pyx_t_1);
6465 __pyx_r = __pyx_t_1;
6471 __Pyx_XDECREF(__pyx_t_1);
6472 __Pyx_AddTraceback(
"cmeshTools.CMesh.nEdges_global.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6475 __Pyx_XGIVEREF(__pyx_r);
6476 __Pyx_RefNannyFinishContext();
6481 static int __pyx_pw_10cmeshTools_5CMesh_13nEdges_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6482 static int __pyx_pw_10cmeshTools_5CMesh_13nEdges_global_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6484 __Pyx_RefNannyDeclarations
6485 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6486 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_13nEdges_global_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6489 __Pyx_RefNannyFinishContext();
6493 static int __pyx_pf_10cmeshTools_5CMesh_13nEdges_global_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6495 __Pyx_RefNannyDeclarations
6497 int __pyx_lineno = 0;
6498 const char *__pyx_filename = NULL;
6499 int __pyx_clineno = 0;
6500 __Pyx_RefNannySetupContext(
"__set__", 0);
6501 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 17, __pyx_L1_error)
6502 __pyx_v_self->nEdges_global = __pyx_t_1;
6508 __Pyx_AddTraceback(
"cmeshTools.CMesh.nEdges_global.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6511 __Pyx_RefNannyFinishContext();
6524 static PyObject *__pyx_pw_10cmeshTools_5CMesh_23max_nNodeNeighbors_node_1__get__(PyObject *__pyx_v_self);
6525 static PyObject *__pyx_pw_10cmeshTools_5CMesh_23max_nNodeNeighbors_node_1__get__(PyObject *__pyx_v_self) {
6526 PyObject *__pyx_r = 0;
6527 __Pyx_RefNannyDeclarations
6528 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6529 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_23max_nNodeNeighbors_node___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6532 __Pyx_RefNannyFinishContext();
6536 static PyObject *__pyx_pf_10cmeshTools_5CMesh_23max_nNodeNeighbors_node___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6537 PyObject *__pyx_r = NULL;
6538 __Pyx_RefNannyDeclarations
6539 PyObject *__pyx_t_1 = NULL;
6540 int __pyx_lineno = 0;
6541 const char *__pyx_filename = NULL;
6542 int __pyx_clineno = 0;
6543 __Pyx_RefNannySetupContext(
"__get__", 0);
6544 __Pyx_XDECREF(__pyx_r);
6545 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->max_nNodeNeighbors_node);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 18, __pyx_L1_error)
6546 __Pyx_GOTREF(__pyx_t_1);
6547 __pyx_r = __pyx_t_1;
6553 __Pyx_XDECREF(__pyx_t_1);
6554 __Pyx_AddTraceback(
"cmeshTools.CMesh.max_nNodeNeighbors_node.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6557 __Pyx_XGIVEREF(__pyx_r);
6558 __Pyx_RefNannyFinishContext();
6563 static int __pyx_pw_10cmeshTools_5CMesh_23max_nNodeNeighbors_node_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6564 static int __pyx_pw_10cmeshTools_5CMesh_23max_nNodeNeighbors_node_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6566 __Pyx_RefNannyDeclarations
6567 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6568 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_23max_nNodeNeighbors_node_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6571 __Pyx_RefNannyFinishContext();
6575 static int __pyx_pf_10cmeshTools_5CMesh_23max_nNodeNeighbors_node_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6577 __Pyx_RefNannyDeclarations
6579 int __pyx_lineno = 0;
6580 const char *__pyx_filename = NULL;
6581 int __pyx_clineno = 0;
6582 __Pyx_RefNannySetupContext(
"__set__", 0);
6583 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 18, __pyx_L1_error)
6584 __pyx_v_self->max_nNodeNeighbors_node = __pyx_t_1;
6590 __Pyx_AddTraceback(
"cmeshTools.CMesh.max_nNodeNeighbors_node.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6593 __Pyx_RefNannyFinishContext();
6606 static PyObject *__pyx_pw_10cmeshTools_5CMesh_17elementNodesArray_1__get__(PyObject *__pyx_v_self);
6607 static PyObject *__pyx_pw_10cmeshTools_5CMesh_17elementNodesArray_1__get__(PyObject *__pyx_v_self) {
6608 PyObject *__pyx_r = 0;
6609 __Pyx_RefNannyDeclarations
6610 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6611 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_17elementNodesArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6614 __Pyx_RefNannyFinishContext();
6618 static PyObject *__pyx_pf_10cmeshTools_5CMesh_17elementNodesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6619 PyObject *__pyx_r = NULL;
6620 __Pyx_RefNannyDeclarations
6621 __Pyx_RefNannySetupContext(
"__get__", 0);
6622 __Pyx_XDECREF(__pyx_r);
6623 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementNodesArray));
6624 __pyx_r = ((PyObject *)__pyx_v_self->elementNodesArray);
6629 __Pyx_XGIVEREF(__pyx_r);
6630 __Pyx_RefNannyFinishContext();
6635 static int __pyx_pw_10cmeshTools_5CMesh_17elementNodesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6636 static int __pyx_pw_10cmeshTools_5CMesh_17elementNodesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6638 __Pyx_RefNannyDeclarations
6639 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6640 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_17elementNodesArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6643 __Pyx_RefNannyFinishContext();
6647 static int __pyx_pf_10cmeshTools_5CMesh_17elementNodesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6649 __Pyx_RefNannyDeclarations
6650 PyObject *__pyx_t_1 = NULL;
6651 int __pyx_lineno = 0;
6652 const char *__pyx_filename = NULL;
6653 int __pyx_clineno = 0;
6654 __Pyx_RefNannySetupContext(
"__set__", 0);
6655 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 37, __pyx_L1_error)
6656 __pyx_t_1 = __pyx_v_value;
6657 __Pyx_INCREF(__pyx_t_1);
6658 __Pyx_GIVEREF(__pyx_t_1);
6659 __Pyx_GOTREF(__pyx_v_self->elementNodesArray);
6660 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementNodesArray));
6661 __pyx_v_self->elementNodesArray = ((PyArrayObject *)__pyx_t_1);
6668 __Pyx_XDECREF(__pyx_t_1);
6669 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementNodesArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6672 __Pyx_RefNannyFinishContext();
6677 static int __pyx_pw_10cmeshTools_5CMesh_17elementNodesArray_5__del__(PyObject *__pyx_v_self);
6678 static int __pyx_pw_10cmeshTools_5CMesh_17elementNodesArray_5__del__(PyObject *__pyx_v_self) {
6680 __Pyx_RefNannyDeclarations
6681 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
6682 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_17elementNodesArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6685 __Pyx_RefNannyFinishContext();
6689 static int __pyx_pf_10cmeshTools_5CMesh_17elementNodesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6691 __Pyx_RefNannyDeclarations
6692 __Pyx_RefNannySetupContext(
"__del__", 0);
6693 __Pyx_INCREF(Py_None);
6694 __Pyx_GIVEREF(Py_None);
6695 __Pyx_GOTREF(__pyx_v_self->elementNodesArray);
6696 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementNodesArray));
6697 __pyx_v_self->elementNodesArray = ((PyArrayObject *)Py_None);
6701 __Pyx_RefNannyFinishContext();
6714 static PyObject *__pyx_pw_10cmeshTools_5CMesh_17nodeElementsArray_1__get__(PyObject *__pyx_v_self);
6715 static PyObject *__pyx_pw_10cmeshTools_5CMesh_17nodeElementsArray_1__get__(PyObject *__pyx_v_self) {
6716 PyObject *__pyx_r = 0;
6717 __Pyx_RefNannyDeclarations
6718 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6719 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_17nodeElementsArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6722 __Pyx_RefNannyFinishContext();
6726 static PyObject *__pyx_pf_10cmeshTools_5CMesh_17nodeElementsArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6727 PyObject *__pyx_r = NULL;
6728 __Pyx_RefNannyDeclarations
6729 __Pyx_RefNannySetupContext(
"__get__", 0);
6730 __Pyx_XDECREF(__pyx_r);
6731 __Pyx_INCREF(((PyObject *)__pyx_v_self->nodeElementsArray));
6732 __pyx_r = ((PyObject *)__pyx_v_self->nodeElementsArray);
6737 __Pyx_XGIVEREF(__pyx_r);
6738 __Pyx_RefNannyFinishContext();
6743 static int __pyx_pw_10cmeshTools_5CMesh_17nodeElementsArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6744 static int __pyx_pw_10cmeshTools_5CMesh_17nodeElementsArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6746 __Pyx_RefNannyDeclarations
6747 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6748 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_17nodeElementsArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6751 __Pyx_RefNannyFinishContext();
6755 static int __pyx_pf_10cmeshTools_5CMesh_17nodeElementsArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6757 __Pyx_RefNannyDeclarations
6758 PyObject *__pyx_t_1 = NULL;
6759 int __pyx_lineno = 0;
6760 const char *__pyx_filename = NULL;
6761 int __pyx_clineno = 0;
6762 __Pyx_RefNannySetupContext(
"__set__", 0);
6763 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 38, __pyx_L1_error)
6764 __pyx_t_1 = __pyx_v_value;
6765 __Pyx_INCREF(__pyx_t_1);
6766 __Pyx_GIVEREF(__pyx_t_1);
6767 __Pyx_GOTREF(__pyx_v_self->nodeElementsArray);
6768 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeElementsArray));
6769 __pyx_v_self->nodeElementsArray = ((PyArrayObject *)__pyx_t_1);
6776 __Pyx_XDECREF(__pyx_t_1);
6777 __Pyx_AddTraceback(
"cmeshTools.CMesh.nodeElementsArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6780 __Pyx_RefNannyFinishContext();
6785 static int __pyx_pw_10cmeshTools_5CMesh_17nodeElementsArray_5__del__(PyObject *__pyx_v_self);
6786 static int __pyx_pw_10cmeshTools_5CMesh_17nodeElementsArray_5__del__(PyObject *__pyx_v_self) {
6788 __Pyx_RefNannyDeclarations
6789 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
6790 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_17nodeElementsArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6793 __Pyx_RefNannyFinishContext();
6797 static int __pyx_pf_10cmeshTools_5CMesh_17nodeElementsArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6799 __Pyx_RefNannyDeclarations
6800 __Pyx_RefNannySetupContext(
"__del__", 0);
6801 __Pyx_INCREF(Py_None);
6802 __Pyx_GIVEREF(Py_None);
6803 __Pyx_GOTREF(__pyx_v_self->nodeElementsArray);
6804 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeElementsArray));
6805 __pyx_v_self->nodeElementsArray = ((PyArrayObject *)Py_None);
6809 __Pyx_RefNannyFinishContext();
6822 static PyObject *__pyx_pw_10cmeshTools_5CMesh_18nodeElementOffsets_1__get__(PyObject *__pyx_v_self);
6823 static PyObject *__pyx_pw_10cmeshTools_5CMesh_18nodeElementOffsets_1__get__(PyObject *__pyx_v_self) {
6824 PyObject *__pyx_r = 0;
6825 __Pyx_RefNannyDeclarations
6826 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6827 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_18nodeElementOffsets___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6830 __Pyx_RefNannyFinishContext();
6834 static PyObject *__pyx_pf_10cmeshTools_5CMesh_18nodeElementOffsets___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6835 PyObject *__pyx_r = NULL;
6836 __Pyx_RefNannyDeclarations
6837 __Pyx_RefNannySetupContext(
"__get__", 0);
6838 __Pyx_XDECREF(__pyx_r);
6839 __Pyx_INCREF(((PyObject *)__pyx_v_self->nodeElementOffsets));
6840 __pyx_r = ((PyObject *)__pyx_v_self->nodeElementOffsets);
6845 __Pyx_XGIVEREF(__pyx_r);
6846 __Pyx_RefNannyFinishContext();
6851 static int __pyx_pw_10cmeshTools_5CMesh_18nodeElementOffsets_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6852 static int __pyx_pw_10cmeshTools_5CMesh_18nodeElementOffsets_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6854 __Pyx_RefNannyDeclarations
6855 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6856 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_18nodeElementOffsets_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6859 __Pyx_RefNannyFinishContext();
6863 static int __pyx_pf_10cmeshTools_5CMesh_18nodeElementOffsets_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6865 __Pyx_RefNannyDeclarations
6866 PyObject *__pyx_t_1 = NULL;
6867 int __pyx_lineno = 0;
6868 const char *__pyx_filename = NULL;
6869 int __pyx_clineno = 0;
6870 __Pyx_RefNannySetupContext(
"__set__", 0);
6871 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 39, __pyx_L1_error)
6872 __pyx_t_1 = __pyx_v_value;
6873 __Pyx_INCREF(__pyx_t_1);
6874 __Pyx_GIVEREF(__pyx_t_1);
6875 __Pyx_GOTREF(__pyx_v_self->nodeElementOffsets);
6876 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeElementOffsets));
6877 __pyx_v_self->nodeElementOffsets = ((PyArrayObject *)__pyx_t_1);
6884 __Pyx_XDECREF(__pyx_t_1);
6885 __Pyx_AddTraceback(
"cmeshTools.CMesh.nodeElementOffsets.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6888 __Pyx_RefNannyFinishContext();
6893 static int __pyx_pw_10cmeshTools_5CMesh_18nodeElementOffsets_5__del__(PyObject *__pyx_v_self);
6894 static int __pyx_pw_10cmeshTools_5CMesh_18nodeElementOffsets_5__del__(PyObject *__pyx_v_self) {
6896 __Pyx_RefNannyDeclarations
6897 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
6898 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_18nodeElementOffsets_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6901 __Pyx_RefNannyFinishContext();
6905 static int __pyx_pf_10cmeshTools_5CMesh_18nodeElementOffsets_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6907 __Pyx_RefNannyDeclarations
6908 __Pyx_RefNannySetupContext(
"__del__", 0);
6909 __Pyx_INCREF(Py_None);
6910 __Pyx_GIVEREF(Py_None);
6911 __Pyx_GOTREF(__pyx_v_self->nodeElementOffsets);
6912 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeElementOffsets));
6913 __pyx_v_self->nodeElementOffsets = ((PyArrayObject *)Py_None);
6917 __Pyx_RefNannyFinishContext();
6930 static PyObject *__pyx_pw_10cmeshTools_5CMesh_21elementNeighborsArray_1__get__(PyObject *__pyx_v_self);
6931 static PyObject *__pyx_pw_10cmeshTools_5CMesh_21elementNeighborsArray_1__get__(PyObject *__pyx_v_self) {
6932 PyObject *__pyx_r = 0;
6933 __Pyx_RefNannyDeclarations
6934 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
6935 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_21elementNeighborsArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
6938 __Pyx_RefNannyFinishContext();
6942 static PyObject *__pyx_pf_10cmeshTools_5CMesh_21elementNeighborsArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
6943 PyObject *__pyx_r = NULL;
6944 __Pyx_RefNannyDeclarations
6945 __Pyx_RefNannySetupContext(
"__get__", 0);
6946 __Pyx_XDECREF(__pyx_r);
6947 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementNeighborsArray));
6948 __pyx_r = ((PyObject *)__pyx_v_self->elementNeighborsArray);
6953 __Pyx_XGIVEREF(__pyx_r);
6954 __Pyx_RefNannyFinishContext();
6959 static int __pyx_pw_10cmeshTools_5CMesh_21elementNeighborsArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
6960 static int __pyx_pw_10cmeshTools_5CMesh_21elementNeighborsArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
6962 __Pyx_RefNannyDeclarations
6963 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
6964 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_21elementNeighborsArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
6967 __Pyx_RefNannyFinishContext();
6971 static int __pyx_pf_10cmeshTools_5CMesh_21elementNeighborsArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
6973 __Pyx_RefNannyDeclarations
6974 PyObject *__pyx_t_1 = NULL;
6975 int __pyx_lineno = 0;
6976 const char *__pyx_filename = NULL;
6977 int __pyx_clineno = 0;
6978 __Pyx_RefNannySetupContext(
"__set__", 0);
6979 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 40, __pyx_L1_error)
6980 __pyx_t_1 = __pyx_v_value;
6981 __Pyx_INCREF(__pyx_t_1);
6982 __Pyx_GIVEREF(__pyx_t_1);
6983 __Pyx_GOTREF(__pyx_v_self->elementNeighborsArray);
6984 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementNeighborsArray));
6985 __pyx_v_self->elementNeighborsArray = ((PyArrayObject *)__pyx_t_1);
6992 __Pyx_XDECREF(__pyx_t_1);
6993 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementNeighborsArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
6996 __Pyx_RefNannyFinishContext();
7001 static int __pyx_pw_10cmeshTools_5CMesh_21elementNeighborsArray_5__del__(PyObject *__pyx_v_self);
7002 static int __pyx_pw_10cmeshTools_5CMesh_21elementNeighborsArray_5__del__(PyObject *__pyx_v_self) {
7004 __Pyx_RefNannyDeclarations
7005 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7006 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_21elementNeighborsArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7009 __Pyx_RefNannyFinishContext();
7013 static int __pyx_pf_10cmeshTools_5CMesh_21elementNeighborsArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7015 __Pyx_RefNannyDeclarations
7016 __Pyx_RefNannySetupContext(
"__del__", 0);
7017 __Pyx_INCREF(Py_None);
7018 __Pyx_GIVEREF(Py_None);
7019 __Pyx_GOTREF(__pyx_v_self->elementNeighborsArray);
7020 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementNeighborsArray));
7021 __pyx_v_self->elementNeighborsArray = ((PyArrayObject *)Py_None);
7025 __Pyx_RefNannyFinishContext();
7038 static PyObject *__pyx_pw_10cmeshTools_5CMesh_22elementBoundariesArray_1__get__(PyObject *__pyx_v_self);
7039 static PyObject *__pyx_pw_10cmeshTools_5CMesh_22elementBoundariesArray_1__get__(PyObject *__pyx_v_self) {
7040 PyObject *__pyx_r = 0;
7041 __Pyx_RefNannyDeclarations
7042 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
7043 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_22elementBoundariesArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7046 __Pyx_RefNannyFinishContext();
7050 static PyObject *__pyx_pf_10cmeshTools_5CMesh_22elementBoundariesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7051 PyObject *__pyx_r = NULL;
7052 __Pyx_RefNannyDeclarations
7053 __Pyx_RefNannySetupContext(
"__get__", 0);
7054 __Pyx_XDECREF(__pyx_r);
7055 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementBoundariesArray));
7056 __pyx_r = ((PyObject *)__pyx_v_self->elementBoundariesArray);
7061 __Pyx_XGIVEREF(__pyx_r);
7062 __Pyx_RefNannyFinishContext();
7067 static int __pyx_pw_10cmeshTools_5CMesh_22elementBoundariesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
7068 static int __pyx_pw_10cmeshTools_5CMesh_22elementBoundariesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
7070 __Pyx_RefNannyDeclarations
7071 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
7072 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_22elementBoundariesArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
7075 __Pyx_RefNannyFinishContext();
7079 static int __pyx_pf_10cmeshTools_5CMesh_22elementBoundariesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
7081 __Pyx_RefNannyDeclarations
7082 PyObject *__pyx_t_1 = NULL;
7083 int __pyx_lineno = 0;
7084 const char *__pyx_filename = NULL;
7085 int __pyx_clineno = 0;
7086 __Pyx_RefNannySetupContext(
"__set__", 0);
7087 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 41, __pyx_L1_error)
7088 __pyx_t_1 = __pyx_v_value;
7089 __Pyx_INCREF(__pyx_t_1);
7090 __Pyx_GIVEREF(__pyx_t_1);
7091 __Pyx_GOTREF(__pyx_v_self->elementBoundariesArray);
7092 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundariesArray));
7093 __pyx_v_self->elementBoundariesArray = ((PyArrayObject *)__pyx_t_1);
7100 __Pyx_XDECREF(__pyx_t_1);
7101 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementBoundariesArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7104 __Pyx_RefNannyFinishContext();
7109 static int __pyx_pw_10cmeshTools_5CMesh_22elementBoundariesArray_5__del__(PyObject *__pyx_v_self);
7110 static int __pyx_pw_10cmeshTools_5CMesh_22elementBoundariesArray_5__del__(PyObject *__pyx_v_self) {
7112 __Pyx_RefNannyDeclarations
7113 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7114 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_22elementBoundariesArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7117 __Pyx_RefNannyFinishContext();
7121 static int __pyx_pf_10cmeshTools_5CMesh_22elementBoundariesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7123 __Pyx_RefNannyDeclarations
7124 __Pyx_RefNannySetupContext(
"__del__", 0);
7125 __Pyx_INCREF(Py_None);
7126 __Pyx_GIVEREF(Py_None);
7127 __Pyx_GOTREF(__pyx_v_self->elementBoundariesArray);
7128 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundariesArray));
7129 __pyx_v_self->elementBoundariesArray = ((PyArrayObject *)Py_None);
7133 __Pyx_RefNannyFinishContext();
7146 static PyObject *__pyx_pw_10cmeshTools_5CMesh_25elementBoundaryNodesArray_1__get__(PyObject *__pyx_v_self);
7147 static PyObject *__pyx_pw_10cmeshTools_5CMesh_25elementBoundaryNodesArray_1__get__(PyObject *__pyx_v_self) {
7148 PyObject *__pyx_r = 0;
7149 __Pyx_RefNannyDeclarations
7150 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
7151 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_25elementBoundaryNodesArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7154 __Pyx_RefNannyFinishContext();
7158 static PyObject *__pyx_pf_10cmeshTools_5CMesh_25elementBoundaryNodesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7159 PyObject *__pyx_r = NULL;
7160 __Pyx_RefNannyDeclarations
7161 __Pyx_RefNannySetupContext(
"__get__", 0);
7162 __Pyx_XDECREF(__pyx_r);
7163 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementBoundaryNodesArray));
7164 __pyx_r = ((PyObject *)__pyx_v_self->elementBoundaryNodesArray);
7169 __Pyx_XGIVEREF(__pyx_r);
7170 __Pyx_RefNannyFinishContext();
7175 static int __pyx_pw_10cmeshTools_5CMesh_25elementBoundaryNodesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
7176 static int __pyx_pw_10cmeshTools_5CMesh_25elementBoundaryNodesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
7178 __Pyx_RefNannyDeclarations
7179 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
7180 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_25elementBoundaryNodesArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
7183 __Pyx_RefNannyFinishContext();
7187 static int __pyx_pf_10cmeshTools_5CMesh_25elementBoundaryNodesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
7189 __Pyx_RefNannyDeclarations
7190 PyObject *__pyx_t_1 = NULL;
7191 int __pyx_lineno = 0;
7192 const char *__pyx_filename = NULL;
7193 int __pyx_clineno = 0;
7194 __Pyx_RefNannySetupContext(
"__set__", 0);
7195 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 42, __pyx_L1_error)
7196 __pyx_t_1 = __pyx_v_value;
7197 __Pyx_INCREF(__pyx_t_1);
7198 __Pyx_GIVEREF(__pyx_t_1);
7199 __Pyx_GOTREF(__pyx_v_self->elementBoundaryNodesArray);
7200 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryNodesArray));
7201 __pyx_v_self->elementBoundaryNodesArray = ((PyArrayObject *)__pyx_t_1);
7208 __Pyx_XDECREF(__pyx_t_1);
7209 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementBoundaryNodesArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7212 __Pyx_RefNannyFinishContext();
7217 static int __pyx_pw_10cmeshTools_5CMesh_25elementBoundaryNodesArray_5__del__(PyObject *__pyx_v_self);
7218 static int __pyx_pw_10cmeshTools_5CMesh_25elementBoundaryNodesArray_5__del__(PyObject *__pyx_v_self) {
7220 __Pyx_RefNannyDeclarations
7221 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7222 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_25elementBoundaryNodesArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7225 __Pyx_RefNannyFinishContext();
7229 static int __pyx_pf_10cmeshTools_5CMesh_25elementBoundaryNodesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7231 __Pyx_RefNannyDeclarations
7232 __Pyx_RefNannySetupContext(
"__del__", 0);
7233 __Pyx_INCREF(Py_None);
7234 __Pyx_GIVEREF(Py_None);
7235 __Pyx_GOTREF(__pyx_v_self->elementBoundaryNodesArray);
7236 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryNodesArray));
7237 __pyx_v_self->elementBoundaryNodesArray = ((PyArrayObject *)Py_None);
7241 __Pyx_RefNannyFinishContext();
7254 static PyObject *__pyx_pw_10cmeshTools_5CMesh_28elementBoundaryElementsArray_1__get__(PyObject *__pyx_v_self);
7255 static PyObject *__pyx_pw_10cmeshTools_5CMesh_28elementBoundaryElementsArray_1__get__(PyObject *__pyx_v_self) {
7256 PyObject *__pyx_r = 0;
7257 __Pyx_RefNannyDeclarations
7258 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
7259 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryElementsArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7262 __Pyx_RefNannyFinishContext();
7266 static PyObject *__pyx_pf_10cmeshTools_5CMesh_28elementBoundaryElementsArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7267 PyObject *__pyx_r = NULL;
7268 __Pyx_RefNannyDeclarations
7269 __Pyx_RefNannySetupContext(
"__get__", 0);
7270 __Pyx_XDECREF(__pyx_r);
7271 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementBoundaryElementsArray));
7272 __pyx_r = ((PyObject *)__pyx_v_self->elementBoundaryElementsArray);
7277 __Pyx_XGIVEREF(__pyx_r);
7278 __Pyx_RefNannyFinishContext();
7283 static int __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryElementsArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
7284 static int __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryElementsArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
7286 __Pyx_RefNannyDeclarations
7287 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
7288 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryElementsArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
7291 __Pyx_RefNannyFinishContext();
7295 static int __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryElementsArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
7297 __Pyx_RefNannyDeclarations
7298 PyObject *__pyx_t_1 = NULL;
7299 int __pyx_lineno = 0;
7300 const char *__pyx_filename = NULL;
7301 int __pyx_clineno = 0;
7302 __Pyx_RefNannySetupContext(
"__set__", 0);
7303 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 43, __pyx_L1_error)
7304 __pyx_t_1 = __pyx_v_value;
7305 __Pyx_INCREF(__pyx_t_1);
7306 __Pyx_GIVEREF(__pyx_t_1);
7307 __Pyx_GOTREF(__pyx_v_self->elementBoundaryElementsArray);
7308 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryElementsArray));
7309 __pyx_v_self->elementBoundaryElementsArray = ((PyArrayObject *)__pyx_t_1);
7316 __Pyx_XDECREF(__pyx_t_1);
7317 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementBoundaryElementsArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7320 __Pyx_RefNannyFinishContext();
7325 static int __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryElementsArray_5__del__(PyObject *__pyx_v_self);
7326 static int __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryElementsArray_5__del__(PyObject *__pyx_v_self) {
7328 __Pyx_RefNannyDeclarations
7329 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7330 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryElementsArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7333 __Pyx_RefNannyFinishContext();
7337 static int __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryElementsArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7339 __Pyx_RefNannyDeclarations
7340 __Pyx_RefNannySetupContext(
"__del__", 0);
7341 __Pyx_INCREF(Py_None);
7342 __Pyx_GIVEREF(Py_None);
7343 __Pyx_GOTREF(__pyx_v_self->elementBoundaryElementsArray);
7344 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryElementsArray));
7345 __pyx_v_self->elementBoundaryElementsArray = ((PyArrayObject *)Py_None);
7349 __Pyx_RefNannyFinishContext();
7362 static PyObject *__pyx_pw_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_1__get__(PyObject *__pyx_v_self);
7363 static PyObject *__pyx_pw_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_1__get__(PyObject *__pyx_v_self) {
7364 PyObject *__pyx_r = 0;
7365 __Pyx_RefNannyDeclarations
7366 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
7367 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7370 __Pyx_RefNannyFinishContext();
7374 static PyObject *__pyx_pf_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7375 PyObject *__pyx_r = NULL;
7376 __Pyx_RefNannyDeclarations
7377 __Pyx_RefNannySetupContext(
"__get__", 0);
7378 __Pyx_XDECREF(__pyx_r);
7379 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementBoundaryLocalElementBoundariesArray));
7380 __pyx_r = ((PyObject *)__pyx_v_self->elementBoundaryLocalElementBoundariesArray);
7385 __Pyx_XGIVEREF(__pyx_r);
7386 __Pyx_RefNannyFinishContext();
7391 static int __pyx_pw_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
7392 static int __pyx_pw_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
7394 __Pyx_RefNannyDeclarations
7395 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
7396 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
7399 __Pyx_RefNannyFinishContext();
7403 static int __pyx_pf_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
7405 __Pyx_RefNannyDeclarations
7406 PyObject *__pyx_t_1 = NULL;
7407 int __pyx_lineno = 0;
7408 const char *__pyx_filename = NULL;
7409 int __pyx_clineno = 0;
7410 __Pyx_RefNannySetupContext(
"__set__", 0);
7411 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 44, __pyx_L1_error)
7412 __pyx_t_1 = __pyx_v_value;
7413 __Pyx_INCREF(__pyx_t_1);
7414 __Pyx_GIVEREF(__pyx_t_1);
7415 __Pyx_GOTREF(__pyx_v_self->elementBoundaryLocalElementBoundariesArray);
7416 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryLocalElementBoundariesArray));
7417 __pyx_v_self->elementBoundaryLocalElementBoundariesArray = ((PyArrayObject *)__pyx_t_1);
7424 __Pyx_XDECREF(__pyx_t_1);
7425 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementBoundaryLocalElementBoundariesArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7428 __Pyx_RefNannyFinishContext();
7433 static int __pyx_pw_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_5__del__(PyObject *__pyx_v_self);
7434 static int __pyx_pw_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_5__del__(PyObject *__pyx_v_self) {
7436 __Pyx_RefNannyDeclarations
7437 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7438 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7441 __Pyx_RefNannyFinishContext();
7445 static int __pyx_pf_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7447 __Pyx_RefNannyDeclarations
7448 __Pyx_RefNannySetupContext(
"__del__", 0);
7449 __Pyx_INCREF(Py_None);
7450 __Pyx_GIVEREF(Py_None);
7451 __Pyx_GOTREF(__pyx_v_self->elementBoundaryLocalElementBoundariesArray);
7452 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryLocalElementBoundariesArray));
7453 __pyx_v_self->elementBoundaryLocalElementBoundariesArray = ((PyArrayObject *)Py_None);
7457 __Pyx_RefNannyFinishContext();
7470 static PyObject *__pyx_pw_10cmeshTools_5CMesh_30interiorElementBoundariesArray_1__get__(PyObject *__pyx_v_self);
7471 static PyObject *__pyx_pw_10cmeshTools_5CMesh_30interiorElementBoundariesArray_1__get__(PyObject *__pyx_v_self) {
7472 PyObject *__pyx_r = 0;
7473 __Pyx_RefNannyDeclarations
7474 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
7475 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_30interiorElementBoundariesArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7478 __Pyx_RefNannyFinishContext();
7482 static PyObject *__pyx_pf_10cmeshTools_5CMesh_30interiorElementBoundariesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7483 PyObject *__pyx_r = NULL;
7484 __Pyx_RefNannyDeclarations
7485 __Pyx_RefNannySetupContext(
"__get__", 0);
7486 __Pyx_XDECREF(__pyx_r);
7487 __Pyx_INCREF(((PyObject *)__pyx_v_self->interiorElementBoundariesArray));
7488 __pyx_r = ((PyObject *)__pyx_v_self->interiorElementBoundariesArray);
7493 __Pyx_XGIVEREF(__pyx_r);
7494 __Pyx_RefNannyFinishContext();
7499 static int __pyx_pw_10cmeshTools_5CMesh_30interiorElementBoundariesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
7500 static int __pyx_pw_10cmeshTools_5CMesh_30interiorElementBoundariesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
7502 __Pyx_RefNannyDeclarations
7503 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
7504 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_30interiorElementBoundariesArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
7507 __Pyx_RefNannyFinishContext();
7511 static int __pyx_pf_10cmeshTools_5CMesh_30interiorElementBoundariesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
7513 __Pyx_RefNannyDeclarations
7514 PyObject *__pyx_t_1 = NULL;
7515 int __pyx_lineno = 0;
7516 const char *__pyx_filename = NULL;
7517 int __pyx_clineno = 0;
7518 __Pyx_RefNannySetupContext(
"__set__", 0);
7519 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 45, __pyx_L1_error)
7520 __pyx_t_1 = __pyx_v_value;
7521 __Pyx_INCREF(__pyx_t_1);
7522 __Pyx_GIVEREF(__pyx_t_1);
7523 __Pyx_GOTREF(__pyx_v_self->interiorElementBoundariesArray);
7524 __Pyx_DECREF(((PyObject *)__pyx_v_self->interiorElementBoundariesArray));
7525 __pyx_v_self->interiorElementBoundariesArray = ((PyArrayObject *)__pyx_t_1);
7532 __Pyx_XDECREF(__pyx_t_1);
7533 __Pyx_AddTraceback(
"cmeshTools.CMesh.interiorElementBoundariesArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7536 __Pyx_RefNannyFinishContext();
7541 static int __pyx_pw_10cmeshTools_5CMesh_30interiorElementBoundariesArray_5__del__(PyObject *__pyx_v_self);
7542 static int __pyx_pw_10cmeshTools_5CMesh_30interiorElementBoundariesArray_5__del__(PyObject *__pyx_v_self) {
7544 __Pyx_RefNannyDeclarations
7545 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7546 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_30interiorElementBoundariesArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7549 __Pyx_RefNannyFinishContext();
7553 static int __pyx_pf_10cmeshTools_5CMesh_30interiorElementBoundariesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7555 __Pyx_RefNannyDeclarations
7556 __Pyx_RefNannySetupContext(
"__del__", 0);
7557 __Pyx_INCREF(Py_None);
7558 __Pyx_GIVEREF(Py_None);
7559 __Pyx_GOTREF(__pyx_v_self->interiorElementBoundariesArray);
7560 __Pyx_DECREF(((PyObject *)__pyx_v_self->interiorElementBoundariesArray));
7561 __pyx_v_self->interiorElementBoundariesArray = ((PyArrayObject *)Py_None);
7565 __Pyx_RefNannyFinishContext();
7578 static PyObject *__pyx_pw_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_1__get__(PyObject *__pyx_v_self);
7579 static PyObject *__pyx_pw_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_1__get__(PyObject *__pyx_v_self) {
7580 PyObject *__pyx_r = 0;
7581 __Pyx_RefNannyDeclarations
7582 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
7583 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_30exteriorElementBoundariesArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7586 __Pyx_RefNannyFinishContext();
7590 static PyObject *__pyx_pf_10cmeshTools_5CMesh_30exteriorElementBoundariesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7591 PyObject *__pyx_r = NULL;
7592 __Pyx_RefNannyDeclarations
7593 __Pyx_RefNannySetupContext(
"__get__", 0);
7594 __Pyx_XDECREF(__pyx_r);
7595 __Pyx_INCREF(((PyObject *)__pyx_v_self->exteriorElementBoundariesArray));
7596 __pyx_r = ((PyObject *)__pyx_v_self->exteriorElementBoundariesArray);
7601 __Pyx_XGIVEREF(__pyx_r);
7602 __Pyx_RefNannyFinishContext();
7607 static int __pyx_pw_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
7608 static int __pyx_pw_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
7610 __Pyx_RefNannyDeclarations
7611 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
7612 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
7615 __Pyx_RefNannyFinishContext();
7619 static int __pyx_pf_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
7621 __Pyx_RefNannyDeclarations
7622 PyObject *__pyx_t_1 = NULL;
7623 int __pyx_lineno = 0;
7624 const char *__pyx_filename = NULL;
7625 int __pyx_clineno = 0;
7626 __Pyx_RefNannySetupContext(
"__set__", 0);
7627 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 46, __pyx_L1_error)
7628 __pyx_t_1 = __pyx_v_value;
7629 __Pyx_INCREF(__pyx_t_1);
7630 __Pyx_GIVEREF(__pyx_t_1);
7631 __Pyx_GOTREF(__pyx_v_self->exteriorElementBoundariesArray);
7632 __Pyx_DECREF(((PyObject *)__pyx_v_self->exteriorElementBoundariesArray));
7633 __pyx_v_self->exteriorElementBoundariesArray = ((PyArrayObject *)__pyx_t_1);
7640 __Pyx_XDECREF(__pyx_t_1);
7641 __Pyx_AddTraceback(
"cmeshTools.CMesh.exteriorElementBoundariesArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7644 __Pyx_RefNannyFinishContext();
7649 static int __pyx_pw_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_5__del__(PyObject *__pyx_v_self);
7650 static int __pyx_pw_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_5__del__(PyObject *__pyx_v_self) {
7652 __Pyx_RefNannyDeclarations
7653 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7654 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7657 __Pyx_RefNannyFinishContext();
7661 static int __pyx_pf_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7663 __Pyx_RefNannyDeclarations
7664 __Pyx_RefNannySetupContext(
"__del__", 0);
7665 __Pyx_INCREF(Py_None);
7666 __Pyx_GIVEREF(Py_None);
7667 __Pyx_GOTREF(__pyx_v_self->exteriorElementBoundariesArray);
7668 __Pyx_DECREF(((PyObject *)__pyx_v_self->exteriorElementBoundariesArray));
7669 __pyx_v_self->exteriorElementBoundariesArray = ((PyArrayObject *)Py_None);
7673 __Pyx_RefNannyFinishContext();
7686 static PyObject *__pyx_pw_10cmeshTools_5CMesh_14edgeNodesArray_1__get__(PyObject *__pyx_v_self);
7687 static PyObject *__pyx_pw_10cmeshTools_5CMesh_14edgeNodesArray_1__get__(PyObject *__pyx_v_self) {
7688 PyObject *__pyx_r = 0;
7689 __Pyx_RefNannyDeclarations
7690 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
7691 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_14edgeNodesArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7694 __Pyx_RefNannyFinishContext();
7698 static PyObject *__pyx_pf_10cmeshTools_5CMesh_14edgeNodesArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7699 PyObject *__pyx_r = NULL;
7700 __Pyx_RefNannyDeclarations
7701 __Pyx_RefNannySetupContext(
"__get__", 0);
7702 __Pyx_XDECREF(__pyx_r);
7703 __Pyx_INCREF(((PyObject *)__pyx_v_self->edgeNodesArray));
7704 __pyx_r = ((PyObject *)__pyx_v_self->edgeNodesArray);
7709 __Pyx_XGIVEREF(__pyx_r);
7710 __Pyx_RefNannyFinishContext();
7715 static int __pyx_pw_10cmeshTools_5CMesh_14edgeNodesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
7716 static int __pyx_pw_10cmeshTools_5CMesh_14edgeNodesArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
7718 __Pyx_RefNannyDeclarations
7719 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
7720 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_14edgeNodesArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
7723 __Pyx_RefNannyFinishContext();
7727 static int __pyx_pf_10cmeshTools_5CMesh_14edgeNodesArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
7729 __Pyx_RefNannyDeclarations
7730 PyObject *__pyx_t_1 = NULL;
7731 int __pyx_lineno = 0;
7732 const char *__pyx_filename = NULL;
7733 int __pyx_clineno = 0;
7734 __Pyx_RefNannySetupContext(
"__set__", 0);
7735 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 47, __pyx_L1_error)
7736 __pyx_t_1 = __pyx_v_value;
7737 __Pyx_INCREF(__pyx_t_1);
7738 __Pyx_GIVEREF(__pyx_t_1);
7739 __Pyx_GOTREF(__pyx_v_self->edgeNodesArray);
7740 __Pyx_DECREF(((PyObject *)__pyx_v_self->edgeNodesArray));
7741 __pyx_v_self->edgeNodesArray = ((PyArrayObject *)__pyx_t_1);
7748 __Pyx_XDECREF(__pyx_t_1);
7749 __Pyx_AddTraceback(
"cmeshTools.CMesh.edgeNodesArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7752 __Pyx_RefNannyFinishContext();
7757 static int __pyx_pw_10cmeshTools_5CMesh_14edgeNodesArray_5__del__(PyObject *__pyx_v_self);
7758 static int __pyx_pw_10cmeshTools_5CMesh_14edgeNodesArray_5__del__(PyObject *__pyx_v_self) {
7760 __Pyx_RefNannyDeclarations
7761 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7762 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_14edgeNodesArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7765 __Pyx_RefNannyFinishContext();
7769 static int __pyx_pf_10cmeshTools_5CMesh_14edgeNodesArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7771 __Pyx_RefNannyDeclarations
7772 __Pyx_RefNannySetupContext(
"__del__", 0);
7773 __Pyx_INCREF(Py_None);
7774 __Pyx_GIVEREF(Py_None);
7775 __Pyx_GOTREF(__pyx_v_self->edgeNodesArray);
7776 __Pyx_DECREF(((PyObject *)__pyx_v_self->edgeNodesArray));
7777 __pyx_v_self->edgeNodesArray = ((PyArrayObject *)Py_None);
7781 __Pyx_RefNannyFinishContext();
7794 static PyObject *__pyx_pw_10cmeshTools_5CMesh_13nodeStarArray_1__get__(PyObject *__pyx_v_self);
7795 static PyObject *__pyx_pw_10cmeshTools_5CMesh_13nodeStarArray_1__get__(PyObject *__pyx_v_self) {
7796 PyObject *__pyx_r = 0;
7797 __Pyx_RefNannyDeclarations
7798 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
7799 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_13nodeStarArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7802 __Pyx_RefNannyFinishContext();
7806 static PyObject *__pyx_pf_10cmeshTools_5CMesh_13nodeStarArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7807 PyObject *__pyx_r = NULL;
7808 __Pyx_RefNannyDeclarations
7809 __Pyx_RefNannySetupContext(
"__get__", 0);
7810 __Pyx_XDECREF(__pyx_r);
7811 __Pyx_INCREF(((PyObject *)__pyx_v_self->nodeStarArray));
7812 __pyx_r = ((PyObject *)__pyx_v_self->nodeStarArray);
7817 __Pyx_XGIVEREF(__pyx_r);
7818 __Pyx_RefNannyFinishContext();
7823 static int __pyx_pw_10cmeshTools_5CMesh_13nodeStarArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
7824 static int __pyx_pw_10cmeshTools_5CMesh_13nodeStarArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
7826 __Pyx_RefNannyDeclarations
7827 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
7828 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_13nodeStarArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
7831 __Pyx_RefNannyFinishContext();
7835 static int __pyx_pf_10cmeshTools_5CMesh_13nodeStarArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
7837 __Pyx_RefNannyDeclarations
7838 PyObject *__pyx_t_1 = NULL;
7839 int __pyx_lineno = 0;
7840 const char *__pyx_filename = NULL;
7841 int __pyx_clineno = 0;
7842 __Pyx_RefNannySetupContext(
"__set__", 0);
7843 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 48, __pyx_L1_error)
7844 __pyx_t_1 = __pyx_v_value;
7845 __Pyx_INCREF(__pyx_t_1);
7846 __Pyx_GIVEREF(__pyx_t_1);
7847 __Pyx_GOTREF(__pyx_v_self->nodeStarArray);
7848 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeStarArray));
7849 __pyx_v_self->nodeStarArray = ((PyArrayObject *)__pyx_t_1);
7856 __Pyx_XDECREF(__pyx_t_1);
7857 __Pyx_AddTraceback(
"cmeshTools.CMesh.nodeStarArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7860 __Pyx_RefNannyFinishContext();
7865 static int __pyx_pw_10cmeshTools_5CMesh_13nodeStarArray_5__del__(PyObject *__pyx_v_self);
7866 static int __pyx_pw_10cmeshTools_5CMesh_13nodeStarArray_5__del__(PyObject *__pyx_v_self) {
7868 __Pyx_RefNannyDeclarations
7869 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7870 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_13nodeStarArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7873 __Pyx_RefNannyFinishContext();
7877 static int __pyx_pf_10cmeshTools_5CMesh_13nodeStarArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7879 __Pyx_RefNannyDeclarations
7880 __Pyx_RefNannySetupContext(
"__del__", 0);
7881 __Pyx_INCREF(Py_None);
7882 __Pyx_GIVEREF(Py_None);
7883 __Pyx_GOTREF(__pyx_v_self->nodeStarArray);
7884 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeStarArray));
7885 __pyx_v_self->nodeStarArray = ((PyArrayObject *)Py_None);
7889 __Pyx_RefNannyFinishContext();
7902 static PyObject *__pyx_pw_10cmeshTools_5CMesh_15nodeStarOffsets_1__get__(PyObject *__pyx_v_self);
7903 static PyObject *__pyx_pw_10cmeshTools_5CMesh_15nodeStarOffsets_1__get__(PyObject *__pyx_v_self) {
7904 PyObject *__pyx_r = 0;
7905 __Pyx_RefNannyDeclarations
7906 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
7907 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_15nodeStarOffsets___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7910 __Pyx_RefNannyFinishContext();
7914 static PyObject *__pyx_pf_10cmeshTools_5CMesh_15nodeStarOffsets___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7915 PyObject *__pyx_r = NULL;
7916 __Pyx_RefNannyDeclarations
7917 __Pyx_RefNannySetupContext(
"__get__", 0);
7918 __Pyx_XDECREF(__pyx_r);
7919 __Pyx_INCREF(((PyObject *)__pyx_v_self->nodeStarOffsets));
7920 __pyx_r = ((PyObject *)__pyx_v_self->nodeStarOffsets);
7925 __Pyx_XGIVEREF(__pyx_r);
7926 __Pyx_RefNannyFinishContext();
7931 static int __pyx_pw_10cmeshTools_5CMesh_15nodeStarOffsets_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
7932 static int __pyx_pw_10cmeshTools_5CMesh_15nodeStarOffsets_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
7934 __Pyx_RefNannyDeclarations
7935 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
7936 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_15nodeStarOffsets_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
7939 __Pyx_RefNannyFinishContext();
7943 static int __pyx_pf_10cmeshTools_5CMesh_15nodeStarOffsets_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
7945 __Pyx_RefNannyDeclarations
7946 PyObject *__pyx_t_1 = NULL;
7947 int __pyx_lineno = 0;
7948 const char *__pyx_filename = NULL;
7949 int __pyx_clineno = 0;
7950 __Pyx_RefNannySetupContext(
"__set__", 0);
7951 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 49, __pyx_L1_error)
7952 __pyx_t_1 = __pyx_v_value;
7953 __Pyx_INCREF(__pyx_t_1);
7954 __Pyx_GIVEREF(__pyx_t_1);
7955 __Pyx_GOTREF(__pyx_v_self->nodeStarOffsets);
7956 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeStarOffsets));
7957 __pyx_v_self->nodeStarOffsets = ((PyArrayObject *)__pyx_t_1);
7964 __Pyx_XDECREF(__pyx_t_1);
7965 __Pyx_AddTraceback(
"cmeshTools.CMesh.nodeStarOffsets.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
7968 __Pyx_RefNannyFinishContext();
7973 static int __pyx_pw_10cmeshTools_5CMesh_15nodeStarOffsets_5__del__(PyObject *__pyx_v_self);
7974 static int __pyx_pw_10cmeshTools_5CMesh_15nodeStarOffsets_5__del__(PyObject *__pyx_v_self) {
7976 __Pyx_RefNannyDeclarations
7977 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
7978 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_15nodeStarOffsets_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
7981 __Pyx_RefNannyFinishContext();
7985 static int __pyx_pf_10cmeshTools_5CMesh_15nodeStarOffsets_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
7987 __Pyx_RefNannyDeclarations
7988 __Pyx_RefNannySetupContext(
"__del__", 0);
7989 __Pyx_INCREF(Py_None);
7990 __Pyx_GIVEREF(Py_None);
7991 __Pyx_GOTREF(__pyx_v_self->nodeStarOffsets);
7992 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeStarOffsets));
7993 __pyx_v_self->nodeStarOffsets = ((PyArrayObject *)Py_None);
7997 __Pyx_RefNannyFinishContext();
8010 static PyObject *__pyx_pw_10cmeshTools_5CMesh_20elementMaterialTypes_1__get__(PyObject *__pyx_v_self);
8011 static PyObject *__pyx_pw_10cmeshTools_5CMesh_20elementMaterialTypes_1__get__(PyObject *__pyx_v_self) {
8012 PyObject *__pyx_r = 0;
8013 __Pyx_RefNannyDeclarations
8014 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8015 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_20elementMaterialTypes___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8018 __Pyx_RefNannyFinishContext();
8022 static PyObject *__pyx_pf_10cmeshTools_5CMesh_20elementMaterialTypes___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8023 PyObject *__pyx_r = NULL;
8024 __Pyx_RefNannyDeclarations
8025 __Pyx_RefNannySetupContext(
"__get__", 0);
8026 __Pyx_XDECREF(__pyx_r);
8027 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementMaterialTypes));
8028 __pyx_r = ((PyObject *)__pyx_v_self->elementMaterialTypes);
8033 __Pyx_XGIVEREF(__pyx_r);
8034 __Pyx_RefNannyFinishContext();
8039 static int __pyx_pw_10cmeshTools_5CMesh_20elementMaterialTypes_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8040 static int __pyx_pw_10cmeshTools_5CMesh_20elementMaterialTypes_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8042 __Pyx_RefNannyDeclarations
8043 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8044 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_20elementMaterialTypes_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8047 __Pyx_RefNannyFinishContext();
8051 static int __pyx_pf_10cmeshTools_5CMesh_20elementMaterialTypes_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8053 __Pyx_RefNannyDeclarations
8054 PyObject *__pyx_t_1 = NULL;
8055 int __pyx_lineno = 0;
8056 const char *__pyx_filename = NULL;
8057 int __pyx_clineno = 0;
8058 __Pyx_RefNannySetupContext(
"__set__", 0);
8059 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 50, __pyx_L1_error)
8060 __pyx_t_1 = __pyx_v_value;
8061 __Pyx_INCREF(__pyx_t_1);
8062 __Pyx_GIVEREF(__pyx_t_1);
8063 __Pyx_GOTREF(__pyx_v_self->elementMaterialTypes);
8064 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementMaterialTypes));
8065 __pyx_v_self->elementMaterialTypes = ((PyArrayObject *)__pyx_t_1);
8072 __Pyx_XDECREF(__pyx_t_1);
8073 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementMaterialTypes.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8076 __Pyx_RefNannyFinishContext();
8081 static int __pyx_pw_10cmeshTools_5CMesh_20elementMaterialTypes_5__del__(PyObject *__pyx_v_self);
8082 static int __pyx_pw_10cmeshTools_5CMesh_20elementMaterialTypes_5__del__(PyObject *__pyx_v_self) {
8084 __Pyx_RefNannyDeclarations
8085 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
8086 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_20elementMaterialTypes_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8089 __Pyx_RefNannyFinishContext();
8093 static int __pyx_pf_10cmeshTools_5CMesh_20elementMaterialTypes_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8095 __Pyx_RefNannyDeclarations
8096 __Pyx_RefNannySetupContext(
"__del__", 0);
8097 __Pyx_INCREF(Py_None);
8098 __Pyx_GIVEREF(Py_None);
8099 __Pyx_GOTREF(__pyx_v_self->elementMaterialTypes);
8100 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementMaterialTypes));
8101 __pyx_v_self->elementMaterialTypes = ((PyArrayObject *)Py_None);
8105 __Pyx_RefNannyFinishContext();
8118 static PyObject *__pyx_pw_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_1__get__(PyObject *__pyx_v_self);
8119 static PyObject *__pyx_pw_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_1__get__(PyObject *__pyx_v_self) {
8120 PyObject *__pyx_r = 0;
8121 __Pyx_RefNannyDeclarations
8122 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8123 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8126 __Pyx_RefNannyFinishContext();
8130 static PyObject *__pyx_pf_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8131 PyObject *__pyx_r = NULL;
8132 __Pyx_RefNannyDeclarations
8133 __Pyx_RefNannySetupContext(
"__get__", 0);
8134 __Pyx_XDECREF(__pyx_r);
8135 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementBoundaryMaterialTypes));
8136 __pyx_r = ((PyObject *)__pyx_v_self->elementBoundaryMaterialTypes);
8141 __Pyx_XGIVEREF(__pyx_r);
8142 __Pyx_RefNannyFinishContext();
8147 static int __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8148 static int __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8150 __Pyx_RefNannyDeclarations
8151 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8152 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8155 __Pyx_RefNannyFinishContext();
8159 static int __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8161 __Pyx_RefNannyDeclarations
8162 PyObject *__pyx_t_1 = NULL;
8163 int __pyx_lineno = 0;
8164 const char *__pyx_filename = NULL;
8165 int __pyx_clineno = 0;
8166 __Pyx_RefNannySetupContext(
"__set__", 0);
8167 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 51, __pyx_L1_error)
8168 __pyx_t_1 = __pyx_v_value;
8169 __Pyx_INCREF(__pyx_t_1);
8170 __Pyx_GIVEREF(__pyx_t_1);
8171 __Pyx_GOTREF(__pyx_v_self->elementBoundaryMaterialTypes);
8172 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryMaterialTypes));
8173 __pyx_v_self->elementBoundaryMaterialTypes = ((PyArrayObject *)__pyx_t_1);
8180 __Pyx_XDECREF(__pyx_t_1);
8181 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementBoundaryMaterialTypes.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8184 __Pyx_RefNannyFinishContext();
8189 static int __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_5__del__(PyObject *__pyx_v_self);
8190 static int __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_5__del__(PyObject *__pyx_v_self) {
8192 __Pyx_RefNannyDeclarations
8193 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
8194 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8197 __Pyx_RefNannyFinishContext();
8201 static int __pyx_pf_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8203 __Pyx_RefNannyDeclarations
8204 __Pyx_RefNannySetupContext(
"__del__", 0);
8205 __Pyx_INCREF(Py_None);
8206 __Pyx_GIVEREF(Py_None);
8207 __Pyx_GOTREF(__pyx_v_self->elementBoundaryMaterialTypes);
8208 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryMaterialTypes));
8209 __pyx_v_self->elementBoundaryMaterialTypes = ((PyArrayObject *)Py_None);
8213 __Pyx_RefNannyFinishContext();
8226 static PyObject *__pyx_pw_10cmeshTools_5CMesh_17nodeMaterialTypes_1__get__(PyObject *__pyx_v_self);
8227 static PyObject *__pyx_pw_10cmeshTools_5CMesh_17nodeMaterialTypes_1__get__(PyObject *__pyx_v_self) {
8228 PyObject *__pyx_r = 0;
8229 __Pyx_RefNannyDeclarations
8230 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8231 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_17nodeMaterialTypes___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8234 __Pyx_RefNannyFinishContext();
8238 static PyObject *__pyx_pf_10cmeshTools_5CMesh_17nodeMaterialTypes___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8239 PyObject *__pyx_r = NULL;
8240 __Pyx_RefNannyDeclarations
8241 __Pyx_RefNannySetupContext(
"__get__", 0);
8242 __Pyx_XDECREF(__pyx_r);
8243 __Pyx_INCREF(((PyObject *)__pyx_v_self->nodeMaterialTypes));
8244 __pyx_r = ((PyObject *)__pyx_v_self->nodeMaterialTypes);
8249 __Pyx_XGIVEREF(__pyx_r);
8250 __Pyx_RefNannyFinishContext();
8255 static int __pyx_pw_10cmeshTools_5CMesh_17nodeMaterialTypes_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8256 static int __pyx_pw_10cmeshTools_5CMesh_17nodeMaterialTypes_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8258 __Pyx_RefNannyDeclarations
8259 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8260 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_17nodeMaterialTypes_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8263 __Pyx_RefNannyFinishContext();
8267 static int __pyx_pf_10cmeshTools_5CMesh_17nodeMaterialTypes_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8269 __Pyx_RefNannyDeclarations
8270 PyObject *__pyx_t_1 = NULL;
8271 int __pyx_lineno = 0;
8272 const char *__pyx_filename = NULL;
8273 int __pyx_clineno = 0;
8274 __Pyx_RefNannySetupContext(
"__set__", 0);
8275 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 52, __pyx_L1_error)
8276 __pyx_t_1 = __pyx_v_value;
8277 __Pyx_INCREF(__pyx_t_1);
8278 __Pyx_GIVEREF(__pyx_t_1);
8279 __Pyx_GOTREF(__pyx_v_self->nodeMaterialTypes);
8280 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeMaterialTypes));
8281 __pyx_v_self->nodeMaterialTypes = ((PyArrayObject *)__pyx_t_1);
8288 __Pyx_XDECREF(__pyx_t_1);
8289 __Pyx_AddTraceback(
"cmeshTools.CMesh.nodeMaterialTypes.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8292 __Pyx_RefNannyFinishContext();
8297 static int __pyx_pw_10cmeshTools_5CMesh_17nodeMaterialTypes_5__del__(PyObject *__pyx_v_self);
8298 static int __pyx_pw_10cmeshTools_5CMesh_17nodeMaterialTypes_5__del__(PyObject *__pyx_v_self) {
8300 __Pyx_RefNannyDeclarations
8301 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
8302 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_17nodeMaterialTypes_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8305 __Pyx_RefNannyFinishContext();
8309 static int __pyx_pf_10cmeshTools_5CMesh_17nodeMaterialTypes_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8311 __Pyx_RefNannyDeclarations
8312 __Pyx_RefNannySetupContext(
"__del__", 0);
8313 __Pyx_INCREF(Py_None);
8314 __Pyx_GIVEREF(Py_None);
8315 __Pyx_GOTREF(__pyx_v_self->nodeMaterialTypes);
8316 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeMaterialTypes));
8317 __pyx_v_self->nodeMaterialTypes = ((PyArrayObject *)Py_None);
8321 __Pyx_RefNannyFinishContext();
8334 static PyObject *__pyx_pw_10cmeshTools_5CMesh_9nodeArray_1__get__(PyObject *__pyx_v_self);
8335 static PyObject *__pyx_pw_10cmeshTools_5CMesh_9nodeArray_1__get__(PyObject *__pyx_v_self) {
8336 PyObject *__pyx_r = 0;
8337 __Pyx_RefNannyDeclarations
8338 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8339 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_9nodeArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8342 __Pyx_RefNannyFinishContext();
8346 static PyObject *__pyx_pf_10cmeshTools_5CMesh_9nodeArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8347 PyObject *__pyx_r = NULL;
8348 __Pyx_RefNannyDeclarations
8349 __Pyx_RefNannySetupContext(
"__get__", 0);
8350 __Pyx_XDECREF(__pyx_r);
8351 __Pyx_INCREF(((PyObject *)__pyx_v_self->nodeArray));
8352 __pyx_r = ((PyObject *)__pyx_v_self->nodeArray);
8357 __Pyx_XGIVEREF(__pyx_r);
8358 __Pyx_RefNannyFinishContext();
8363 static int __pyx_pw_10cmeshTools_5CMesh_9nodeArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8364 static int __pyx_pw_10cmeshTools_5CMesh_9nodeArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8366 __Pyx_RefNannyDeclarations
8367 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8368 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_9nodeArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8371 __Pyx_RefNannyFinishContext();
8375 static int __pyx_pf_10cmeshTools_5CMesh_9nodeArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8377 __Pyx_RefNannyDeclarations
8378 PyObject *__pyx_t_1 = NULL;
8379 int __pyx_lineno = 0;
8380 const char *__pyx_filename = NULL;
8381 int __pyx_clineno = 0;
8382 __Pyx_RefNannySetupContext(
"__set__", 0);
8383 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 53, __pyx_L1_error)
8384 __pyx_t_1 = __pyx_v_value;
8385 __Pyx_INCREF(__pyx_t_1);
8386 __Pyx_GIVEREF(__pyx_t_1);
8387 __Pyx_GOTREF(__pyx_v_self->nodeArray);
8388 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeArray));
8389 __pyx_v_self->nodeArray = ((PyArrayObject *)__pyx_t_1);
8396 __Pyx_XDECREF(__pyx_t_1);
8397 __Pyx_AddTraceback(
"cmeshTools.CMesh.nodeArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8400 __Pyx_RefNannyFinishContext();
8405 static int __pyx_pw_10cmeshTools_5CMesh_9nodeArray_5__del__(PyObject *__pyx_v_self);
8406 static int __pyx_pw_10cmeshTools_5CMesh_9nodeArray_5__del__(PyObject *__pyx_v_self) {
8408 __Pyx_RefNannyDeclarations
8409 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
8410 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_9nodeArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8413 __Pyx_RefNannyFinishContext();
8417 static int __pyx_pf_10cmeshTools_5CMesh_9nodeArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8419 __Pyx_RefNannyDeclarations
8420 __Pyx_RefNannySetupContext(
"__del__", 0);
8421 __Pyx_INCREF(Py_None);
8422 __Pyx_GIVEREF(Py_None);
8423 __Pyx_GOTREF(__pyx_v_self->nodeArray);
8424 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeArray));
8425 __pyx_v_self->nodeArray = ((PyArrayObject *)Py_None);
8429 __Pyx_RefNannyFinishContext();
8442 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2nx_1__get__(PyObject *__pyx_v_self);
8443 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2nx_1__get__(PyObject *__pyx_v_self) {
8444 PyObject *__pyx_r = 0;
8445 __Pyx_RefNannyDeclarations
8446 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8447 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2nx___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8450 __Pyx_RefNannyFinishContext();
8454 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2nx___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8455 PyObject *__pyx_r = NULL;
8456 __Pyx_RefNannyDeclarations
8457 PyObject *__pyx_t_1 = NULL;
8458 int __pyx_lineno = 0;
8459 const char *__pyx_filename = NULL;
8460 int __pyx_clineno = 0;
8461 __Pyx_RefNannySetupContext(
"__get__", 0);
8462 __Pyx_XDECREF(__pyx_r);
8463 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nx);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 55, __pyx_L1_error)
8464 __Pyx_GOTREF(__pyx_t_1);
8465 __pyx_r = __pyx_t_1;
8471 __Pyx_XDECREF(__pyx_t_1);
8472 __Pyx_AddTraceback(
"cmeshTools.CMesh.nx.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8475 __Pyx_XGIVEREF(__pyx_r);
8476 __Pyx_RefNannyFinishContext();
8481 static int __pyx_pw_10cmeshTools_5CMesh_2nx_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8482 static int __pyx_pw_10cmeshTools_5CMesh_2nx_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8484 __Pyx_RefNannyDeclarations
8485 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8486 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2nx_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8489 __Pyx_RefNannyFinishContext();
8493 static int __pyx_pf_10cmeshTools_5CMesh_2nx_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8495 __Pyx_RefNannyDeclarations
8497 int __pyx_lineno = 0;
8498 const char *__pyx_filename = NULL;
8499 int __pyx_clineno = 0;
8500 __Pyx_RefNannySetupContext(
"__set__", 0);
8501 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 55, __pyx_L1_error)
8502 __pyx_v_self->nx = __pyx_t_1;
8508 __Pyx_AddTraceback(
"cmeshTools.CMesh.nx.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8511 __Pyx_RefNannyFinishContext();
8524 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2ny_1__get__(PyObject *__pyx_v_self);
8525 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2ny_1__get__(PyObject *__pyx_v_self) {
8526 PyObject *__pyx_r = 0;
8527 __Pyx_RefNannyDeclarations
8528 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8529 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2ny___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8532 __Pyx_RefNannyFinishContext();
8536 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2ny___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8537 PyObject *__pyx_r = NULL;
8538 __Pyx_RefNannyDeclarations
8539 PyObject *__pyx_t_1 = NULL;
8540 int __pyx_lineno = 0;
8541 const char *__pyx_filename = NULL;
8542 int __pyx_clineno = 0;
8543 __Pyx_RefNannySetupContext(
"__get__", 0);
8544 __Pyx_XDECREF(__pyx_r);
8545 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->ny);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 56, __pyx_L1_error)
8546 __Pyx_GOTREF(__pyx_t_1);
8547 __pyx_r = __pyx_t_1;
8553 __Pyx_XDECREF(__pyx_t_1);
8554 __Pyx_AddTraceback(
"cmeshTools.CMesh.ny.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8557 __Pyx_XGIVEREF(__pyx_r);
8558 __Pyx_RefNannyFinishContext();
8563 static int __pyx_pw_10cmeshTools_5CMesh_2ny_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8564 static int __pyx_pw_10cmeshTools_5CMesh_2ny_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8566 __Pyx_RefNannyDeclarations
8567 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8568 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2ny_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8571 __Pyx_RefNannyFinishContext();
8575 static int __pyx_pf_10cmeshTools_5CMesh_2ny_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8577 __Pyx_RefNannyDeclarations
8579 int __pyx_lineno = 0;
8580 const char *__pyx_filename = NULL;
8581 int __pyx_clineno = 0;
8582 __Pyx_RefNannySetupContext(
"__set__", 0);
8583 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 56, __pyx_L1_error)
8584 __pyx_v_self->ny = __pyx_t_1;
8590 __Pyx_AddTraceback(
"cmeshTools.CMesh.ny.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8593 __Pyx_RefNannyFinishContext();
8606 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2nz_1__get__(PyObject *__pyx_v_self);
8607 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2nz_1__get__(PyObject *__pyx_v_self) {
8608 PyObject *__pyx_r = 0;
8609 __Pyx_RefNannyDeclarations
8610 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8611 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2nz___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8614 __Pyx_RefNannyFinishContext();
8618 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2nz___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8619 PyObject *__pyx_r = NULL;
8620 __Pyx_RefNannyDeclarations
8621 PyObject *__pyx_t_1 = NULL;
8622 int __pyx_lineno = 0;
8623 const char *__pyx_filename = NULL;
8624 int __pyx_clineno = 0;
8625 __Pyx_RefNannySetupContext(
"__get__", 0);
8626 __Pyx_XDECREF(__pyx_r);
8627 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nz);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 57, __pyx_L1_error)
8628 __Pyx_GOTREF(__pyx_t_1);
8629 __pyx_r = __pyx_t_1;
8635 __Pyx_XDECREF(__pyx_t_1);
8636 __Pyx_AddTraceback(
"cmeshTools.CMesh.nz.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8639 __Pyx_XGIVEREF(__pyx_r);
8640 __Pyx_RefNannyFinishContext();
8645 static int __pyx_pw_10cmeshTools_5CMesh_2nz_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8646 static int __pyx_pw_10cmeshTools_5CMesh_2nz_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8648 __Pyx_RefNannyDeclarations
8649 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8650 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2nz_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8653 __Pyx_RefNannyFinishContext();
8657 static int __pyx_pf_10cmeshTools_5CMesh_2nz_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8659 __Pyx_RefNannyDeclarations
8661 int __pyx_lineno = 0;
8662 const char *__pyx_filename = NULL;
8663 int __pyx_clineno = 0;
8664 __Pyx_RefNannySetupContext(
"__set__", 0);
8665 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 57, __pyx_L1_error)
8666 __pyx_v_self->nz = __pyx_t_1;
8672 __Pyx_AddTraceback(
"cmeshTools.CMesh.nz.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8675 __Pyx_RefNannyFinishContext();
8688 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2px_1__get__(PyObject *__pyx_v_self);
8689 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2px_1__get__(PyObject *__pyx_v_self) {
8690 PyObject *__pyx_r = 0;
8691 __Pyx_RefNannyDeclarations
8692 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8693 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2px___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8696 __Pyx_RefNannyFinishContext();
8700 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2px___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8701 PyObject *__pyx_r = NULL;
8702 __Pyx_RefNannyDeclarations
8703 PyObject *__pyx_t_1 = NULL;
8704 int __pyx_lineno = 0;
8705 const char *__pyx_filename = NULL;
8706 int __pyx_clineno = 0;
8707 __Pyx_RefNannySetupContext(
"__get__", 0);
8708 __Pyx_XDECREF(__pyx_r);
8709 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->px);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 58, __pyx_L1_error)
8710 __Pyx_GOTREF(__pyx_t_1);
8711 __pyx_r = __pyx_t_1;
8717 __Pyx_XDECREF(__pyx_t_1);
8718 __Pyx_AddTraceback(
"cmeshTools.CMesh.px.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8721 __Pyx_XGIVEREF(__pyx_r);
8722 __Pyx_RefNannyFinishContext();
8727 static int __pyx_pw_10cmeshTools_5CMesh_2px_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8728 static int __pyx_pw_10cmeshTools_5CMesh_2px_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8730 __Pyx_RefNannyDeclarations
8731 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8732 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2px_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8735 __Pyx_RefNannyFinishContext();
8739 static int __pyx_pf_10cmeshTools_5CMesh_2px_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8741 __Pyx_RefNannyDeclarations
8743 int __pyx_lineno = 0;
8744 const char *__pyx_filename = NULL;
8745 int __pyx_clineno = 0;
8746 __Pyx_RefNannySetupContext(
"__set__", 0);
8747 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 58, __pyx_L1_error)
8748 __pyx_v_self->px = __pyx_t_1;
8754 __Pyx_AddTraceback(
"cmeshTools.CMesh.px.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8757 __Pyx_RefNannyFinishContext();
8770 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2py_1__get__(PyObject *__pyx_v_self);
8771 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2py_1__get__(PyObject *__pyx_v_self) {
8772 PyObject *__pyx_r = 0;
8773 __Pyx_RefNannyDeclarations
8774 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8775 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2py___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8778 __Pyx_RefNannyFinishContext();
8782 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2py___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8783 PyObject *__pyx_r = NULL;
8784 __Pyx_RefNannyDeclarations
8785 PyObject *__pyx_t_1 = NULL;
8786 int __pyx_lineno = 0;
8787 const char *__pyx_filename = NULL;
8788 int __pyx_clineno = 0;
8789 __Pyx_RefNannySetupContext(
"__get__", 0);
8790 __Pyx_XDECREF(__pyx_r);
8791 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->py);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 59, __pyx_L1_error)
8792 __Pyx_GOTREF(__pyx_t_1);
8793 __pyx_r = __pyx_t_1;
8799 __Pyx_XDECREF(__pyx_t_1);
8800 __Pyx_AddTraceback(
"cmeshTools.CMesh.py.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8803 __Pyx_XGIVEREF(__pyx_r);
8804 __Pyx_RefNannyFinishContext();
8809 static int __pyx_pw_10cmeshTools_5CMesh_2py_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8810 static int __pyx_pw_10cmeshTools_5CMesh_2py_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8812 __Pyx_RefNannyDeclarations
8813 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8814 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2py_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8817 __Pyx_RefNannyFinishContext();
8821 static int __pyx_pf_10cmeshTools_5CMesh_2py_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8823 __Pyx_RefNannyDeclarations
8825 int __pyx_lineno = 0;
8826 const char *__pyx_filename = NULL;
8827 int __pyx_clineno = 0;
8828 __Pyx_RefNannySetupContext(
"__set__", 0);
8829 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 59, __pyx_L1_error)
8830 __pyx_v_self->py = __pyx_t_1;
8836 __Pyx_AddTraceback(
"cmeshTools.CMesh.py.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8839 __Pyx_RefNannyFinishContext();
8852 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2pz_1__get__(PyObject *__pyx_v_self);
8853 static PyObject *__pyx_pw_10cmeshTools_5CMesh_2pz_1__get__(PyObject *__pyx_v_self) {
8854 PyObject *__pyx_r = 0;
8855 __Pyx_RefNannyDeclarations
8856 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8857 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2pz___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8860 __Pyx_RefNannyFinishContext();
8864 static PyObject *__pyx_pf_10cmeshTools_5CMesh_2pz___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8865 PyObject *__pyx_r = NULL;
8866 __Pyx_RefNannyDeclarations
8867 PyObject *__pyx_t_1 = NULL;
8868 int __pyx_lineno = 0;
8869 const char *__pyx_filename = NULL;
8870 int __pyx_clineno = 0;
8871 __Pyx_RefNannySetupContext(
"__get__", 0);
8872 __Pyx_XDECREF(__pyx_r);
8873 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->pz);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 60, __pyx_L1_error)
8874 __Pyx_GOTREF(__pyx_t_1);
8875 __pyx_r = __pyx_t_1;
8881 __Pyx_XDECREF(__pyx_t_1);
8882 __Pyx_AddTraceback(
"cmeshTools.CMesh.pz.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8885 __Pyx_XGIVEREF(__pyx_r);
8886 __Pyx_RefNannyFinishContext();
8891 static int __pyx_pw_10cmeshTools_5CMesh_2pz_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8892 static int __pyx_pw_10cmeshTools_5CMesh_2pz_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8894 __Pyx_RefNannyDeclarations
8895 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8896 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_2pz_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8899 __Pyx_RefNannyFinishContext();
8903 static int __pyx_pf_10cmeshTools_5CMesh_2pz_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8905 __Pyx_RefNannyDeclarations
8907 int __pyx_lineno = 0;
8908 const char *__pyx_filename = NULL;
8909 int __pyx_clineno = 0;
8910 __Pyx_RefNannySetupContext(
"__set__", 0);
8911 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(2, 60, __pyx_L1_error)
8912 __pyx_v_self->pz = __pyx_t_1;
8918 __Pyx_AddTraceback(
"cmeshTools.CMesh.pz.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
8921 __Pyx_RefNannyFinishContext();
8934 static PyObject *__pyx_pw_10cmeshTools_5CMesh_10elementIJK_1__get__(PyObject *__pyx_v_self);
8935 static PyObject *__pyx_pw_10cmeshTools_5CMesh_10elementIJK_1__get__(PyObject *__pyx_v_self) {
8936 PyObject *__pyx_r = 0;
8937 __Pyx_RefNannyDeclarations
8938 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
8939 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_10elementIJK___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
8942 __Pyx_RefNannyFinishContext();
8946 static PyObject *__pyx_pf_10cmeshTools_5CMesh_10elementIJK___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
8947 PyObject *__pyx_r = NULL;
8948 __Pyx_RefNannyDeclarations
8949 __Pyx_RefNannySetupContext(
"__get__", 0);
8950 __Pyx_XDECREF(__pyx_r);
8951 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementIJK));
8952 __pyx_r = ((PyObject *)__pyx_v_self->elementIJK);
8957 __Pyx_XGIVEREF(__pyx_r);
8958 __Pyx_RefNannyFinishContext();
8963 static int __pyx_pw_10cmeshTools_5CMesh_10elementIJK_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
8964 static int __pyx_pw_10cmeshTools_5CMesh_10elementIJK_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
8966 __Pyx_RefNannyDeclarations
8967 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
8968 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_10elementIJK_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
8971 __Pyx_RefNannyFinishContext();
8975 static int __pyx_pf_10cmeshTools_5CMesh_10elementIJK_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
8977 __Pyx_RefNannyDeclarations
8978 PyObject *__pyx_t_1 = NULL;
8979 int __pyx_lineno = 0;
8980 const char *__pyx_filename = NULL;
8981 int __pyx_clineno = 0;
8982 __Pyx_RefNannySetupContext(
"__set__", 0);
8983 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 74, __pyx_L1_error)
8984 __pyx_t_1 = __pyx_v_value;
8985 __Pyx_INCREF(__pyx_t_1);
8986 __Pyx_GIVEREF(__pyx_t_1);
8987 __Pyx_GOTREF(__pyx_v_self->elementIJK);
8988 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementIJK));
8989 __pyx_v_self->elementIJK = ((PyArrayObject *)__pyx_t_1);
8996 __Pyx_XDECREF(__pyx_t_1);
8997 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementIJK.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9000 __Pyx_RefNannyFinishContext();
9005 static int __pyx_pw_10cmeshTools_5CMesh_10elementIJK_5__del__(PyObject *__pyx_v_self);
9006 static int __pyx_pw_10cmeshTools_5CMesh_10elementIJK_5__del__(PyObject *__pyx_v_self) {
9008 __Pyx_RefNannyDeclarations
9009 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9010 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_10elementIJK_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9013 __Pyx_RefNannyFinishContext();
9017 static int __pyx_pf_10cmeshTools_5CMesh_10elementIJK_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9019 __Pyx_RefNannyDeclarations
9020 __Pyx_RefNannySetupContext(
"__del__", 0);
9021 __Pyx_INCREF(Py_None);
9022 __Pyx_GIVEREF(Py_None);
9023 __Pyx_GOTREF(__pyx_v_self->elementIJK);
9024 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementIJK));
9025 __pyx_v_self->elementIJK = ((PyArrayObject *)Py_None);
9029 __Pyx_RefNannyFinishContext();
9042 static PyObject *__pyx_pw_10cmeshTools_5CMesh_7weights_1__get__(PyObject *__pyx_v_self);
9043 static PyObject *__pyx_pw_10cmeshTools_5CMesh_7weights_1__get__(PyObject *__pyx_v_self) {
9044 PyObject *__pyx_r = 0;
9045 __Pyx_RefNannyDeclarations
9046 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
9047 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_7weights___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9050 __Pyx_RefNannyFinishContext();
9054 static PyObject *__pyx_pf_10cmeshTools_5CMesh_7weights___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9055 PyObject *__pyx_r = NULL;
9056 __Pyx_RefNannyDeclarations
9057 __Pyx_RefNannySetupContext(
"__get__", 0);
9058 __Pyx_XDECREF(__pyx_r);
9059 __Pyx_INCREF(((PyObject *)__pyx_v_self->weights));
9060 __pyx_r = ((PyObject *)__pyx_v_self->weights);
9065 __Pyx_XGIVEREF(__pyx_r);
9066 __Pyx_RefNannyFinishContext();
9071 static int __pyx_pw_10cmeshTools_5CMesh_7weights_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
9072 static int __pyx_pw_10cmeshTools_5CMesh_7weights_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
9074 __Pyx_RefNannyDeclarations
9075 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
9076 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_7weights_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
9079 __Pyx_RefNannyFinishContext();
9083 static int __pyx_pf_10cmeshTools_5CMesh_7weights_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
9085 __Pyx_RefNannyDeclarations
9086 PyObject *__pyx_t_1 = NULL;
9087 int __pyx_lineno = 0;
9088 const char *__pyx_filename = NULL;
9089 int __pyx_clineno = 0;
9090 __Pyx_RefNannySetupContext(
"__set__", 0);
9091 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 75, __pyx_L1_error)
9092 __pyx_t_1 = __pyx_v_value;
9093 __Pyx_INCREF(__pyx_t_1);
9094 __Pyx_GIVEREF(__pyx_t_1);
9095 __Pyx_GOTREF(__pyx_v_self->weights);
9096 __Pyx_DECREF(((PyObject *)__pyx_v_self->weights));
9097 __pyx_v_self->weights = ((PyArrayObject *)__pyx_t_1);
9104 __Pyx_XDECREF(__pyx_t_1);
9105 __Pyx_AddTraceback(
"cmeshTools.CMesh.weights.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9108 __Pyx_RefNannyFinishContext();
9113 static int __pyx_pw_10cmeshTools_5CMesh_7weights_5__del__(PyObject *__pyx_v_self);
9114 static int __pyx_pw_10cmeshTools_5CMesh_7weights_5__del__(PyObject *__pyx_v_self) {
9116 __Pyx_RefNannyDeclarations
9117 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9118 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_7weights_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9121 __Pyx_RefNannyFinishContext();
9125 static int __pyx_pf_10cmeshTools_5CMesh_7weights_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9127 __Pyx_RefNannyDeclarations
9128 __Pyx_RefNannySetupContext(
"__del__", 0);
9129 __Pyx_INCREF(Py_None);
9130 __Pyx_GIVEREF(Py_None);
9131 __Pyx_GOTREF(__pyx_v_self->weights);
9132 __Pyx_DECREF(((PyObject *)__pyx_v_self->weights));
9133 __pyx_v_self->weights = ((PyArrayObject *)Py_None);
9137 __Pyx_RefNannyFinishContext();
9150 static PyObject *__pyx_pw_10cmeshTools_5CMesh_6U_KNOT_1__get__(PyObject *__pyx_v_self);
9151 static PyObject *__pyx_pw_10cmeshTools_5CMesh_6U_KNOT_1__get__(PyObject *__pyx_v_self) {
9152 PyObject *__pyx_r = 0;
9153 __Pyx_RefNannyDeclarations
9154 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
9155 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6U_KNOT___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9158 __Pyx_RefNannyFinishContext();
9162 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6U_KNOT___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9163 PyObject *__pyx_r = NULL;
9164 __Pyx_RefNannyDeclarations
9165 __Pyx_RefNannySetupContext(
"__get__", 0);
9166 __Pyx_XDECREF(__pyx_r);
9167 __Pyx_INCREF(((PyObject *)__pyx_v_self->U_KNOT));
9168 __pyx_r = ((PyObject *)__pyx_v_self->U_KNOT);
9173 __Pyx_XGIVEREF(__pyx_r);
9174 __Pyx_RefNannyFinishContext();
9179 static int __pyx_pw_10cmeshTools_5CMesh_6U_KNOT_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
9180 static int __pyx_pw_10cmeshTools_5CMesh_6U_KNOT_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
9182 __Pyx_RefNannyDeclarations
9183 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
9184 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6U_KNOT_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
9187 __Pyx_RefNannyFinishContext();
9191 static int __pyx_pf_10cmeshTools_5CMesh_6U_KNOT_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
9193 __Pyx_RefNannyDeclarations
9194 PyObject *__pyx_t_1 = NULL;
9195 int __pyx_lineno = 0;
9196 const char *__pyx_filename = NULL;
9197 int __pyx_clineno = 0;
9198 __Pyx_RefNannySetupContext(
"__set__", 0);
9199 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 76, __pyx_L1_error)
9200 __pyx_t_1 = __pyx_v_value;
9201 __Pyx_INCREF(__pyx_t_1);
9202 __Pyx_GIVEREF(__pyx_t_1);
9203 __Pyx_GOTREF(__pyx_v_self->U_KNOT);
9204 __Pyx_DECREF(((PyObject *)__pyx_v_self->U_KNOT));
9205 __pyx_v_self->U_KNOT = ((PyArrayObject *)__pyx_t_1);
9212 __Pyx_XDECREF(__pyx_t_1);
9213 __Pyx_AddTraceback(
"cmeshTools.CMesh.U_KNOT.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9216 __Pyx_RefNannyFinishContext();
9221 static int __pyx_pw_10cmeshTools_5CMesh_6U_KNOT_5__del__(PyObject *__pyx_v_self);
9222 static int __pyx_pw_10cmeshTools_5CMesh_6U_KNOT_5__del__(PyObject *__pyx_v_self) {
9224 __Pyx_RefNannyDeclarations
9225 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9226 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6U_KNOT_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9229 __Pyx_RefNannyFinishContext();
9233 static int __pyx_pf_10cmeshTools_5CMesh_6U_KNOT_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9235 __Pyx_RefNannyDeclarations
9236 __Pyx_RefNannySetupContext(
"__del__", 0);
9237 __Pyx_INCREF(Py_None);
9238 __Pyx_GIVEREF(Py_None);
9239 __Pyx_GOTREF(__pyx_v_self->U_KNOT);
9240 __Pyx_DECREF(((PyObject *)__pyx_v_self->U_KNOT));
9241 __pyx_v_self->U_KNOT = ((PyArrayObject *)Py_None);
9245 __Pyx_RefNannyFinishContext();
9258 static PyObject *__pyx_pw_10cmeshTools_5CMesh_6V_KNOT_1__get__(PyObject *__pyx_v_self);
9259 static PyObject *__pyx_pw_10cmeshTools_5CMesh_6V_KNOT_1__get__(PyObject *__pyx_v_self) {
9260 PyObject *__pyx_r = 0;
9261 __Pyx_RefNannyDeclarations
9262 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
9263 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6V_KNOT___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9266 __Pyx_RefNannyFinishContext();
9270 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6V_KNOT___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9271 PyObject *__pyx_r = NULL;
9272 __Pyx_RefNannyDeclarations
9273 __Pyx_RefNannySetupContext(
"__get__", 0);
9274 __Pyx_XDECREF(__pyx_r);
9275 __Pyx_INCREF(((PyObject *)__pyx_v_self->V_KNOT));
9276 __pyx_r = ((PyObject *)__pyx_v_self->V_KNOT);
9281 __Pyx_XGIVEREF(__pyx_r);
9282 __Pyx_RefNannyFinishContext();
9287 static int __pyx_pw_10cmeshTools_5CMesh_6V_KNOT_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
9288 static int __pyx_pw_10cmeshTools_5CMesh_6V_KNOT_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
9290 __Pyx_RefNannyDeclarations
9291 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
9292 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6V_KNOT_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
9295 __Pyx_RefNannyFinishContext();
9299 static int __pyx_pf_10cmeshTools_5CMesh_6V_KNOT_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
9301 __Pyx_RefNannyDeclarations
9302 PyObject *__pyx_t_1 = NULL;
9303 int __pyx_lineno = 0;
9304 const char *__pyx_filename = NULL;
9305 int __pyx_clineno = 0;
9306 __Pyx_RefNannySetupContext(
"__set__", 0);
9307 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 77, __pyx_L1_error)
9308 __pyx_t_1 = __pyx_v_value;
9309 __Pyx_INCREF(__pyx_t_1);
9310 __Pyx_GIVEREF(__pyx_t_1);
9311 __Pyx_GOTREF(__pyx_v_self->V_KNOT);
9312 __Pyx_DECREF(((PyObject *)__pyx_v_self->V_KNOT));
9313 __pyx_v_self->V_KNOT = ((PyArrayObject *)__pyx_t_1);
9320 __Pyx_XDECREF(__pyx_t_1);
9321 __Pyx_AddTraceback(
"cmeshTools.CMesh.V_KNOT.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9324 __Pyx_RefNannyFinishContext();
9329 static int __pyx_pw_10cmeshTools_5CMesh_6V_KNOT_5__del__(PyObject *__pyx_v_self);
9330 static int __pyx_pw_10cmeshTools_5CMesh_6V_KNOT_5__del__(PyObject *__pyx_v_self) {
9332 __Pyx_RefNannyDeclarations
9333 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9334 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6V_KNOT_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9337 __Pyx_RefNannyFinishContext();
9341 static int __pyx_pf_10cmeshTools_5CMesh_6V_KNOT_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9343 __Pyx_RefNannyDeclarations
9344 __Pyx_RefNannySetupContext(
"__del__", 0);
9345 __Pyx_INCREF(Py_None);
9346 __Pyx_GIVEREF(Py_None);
9347 __Pyx_GOTREF(__pyx_v_self->V_KNOT);
9348 __Pyx_DECREF(((PyObject *)__pyx_v_self->V_KNOT));
9349 __pyx_v_self->V_KNOT = ((PyArrayObject *)Py_None);
9353 __Pyx_RefNannyFinishContext();
9366 static PyObject *__pyx_pw_10cmeshTools_5CMesh_6W_KNOT_1__get__(PyObject *__pyx_v_self);
9367 static PyObject *__pyx_pw_10cmeshTools_5CMesh_6W_KNOT_1__get__(PyObject *__pyx_v_self) {
9368 PyObject *__pyx_r = 0;
9369 __Pyx_RefNannyDeclarations
9370 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
9371 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6W_KNOT___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9374 __Pyx_RefNannyFinishContext();
9378 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6W_KNOT___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9379 PyObject *__pyx_r = NULL;
9380 __Pyx_RefNannyDeclarations
9381 __Pyx_RefNannySetupContext(
"__get__", 0);
9382 __Pyx_XDECREF(__pyx_r);
9383 __Pyx_INCREF(((PyObject *)__pyx_v_self->W_KNOT));
9384 __pyx_r = ((PyObject *)__pyx_v_self->W_KNOT);
9389 __Pyx_XGIVEREF(__pyx_r);
9390 __Pyx_RefNannyFinishContext();
9395 static int __pyx_pw_10cmeshTools_5CMesh_6W_KNOT_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
9396 static int __pyx_pw_10cmeshTools_5CMesh_6W_KNOT_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
9398 __Pyx_RefNannyDeclarations
9399 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
9400 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6W_KNOT_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
9403 __Pyx_RefNannyFinishContext();
9407 static int __pyx_pf_10cmeshTools_5CMesh_6W_KNOT_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
9409 __Pyx_RefNannyDeclarations
9410 PyObject *__pyx_t_1 = NULL;
9411 int __pyx_lineno = 0;
9412 const char *__pyx_filename = NULL;
9413 int __pyx_clineno = 0;
9414 __Pyx_RefNannySetupContext(
"__set__", 0);
9415 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 78, __pyx_L1_error)
9416 __pyx_t_1 = __pyx_v_value;
9417 __Pyx_INCREF(__pyx_t_1);
9418 __Pyx_GIVEREF(__pyx_t_1);
9419 __Pyx_GOTREF(__pyx_v_self->W_KNOT);
9420 __Pyx_DECREF(((PyObject *)__pyx_v_self->W_KNOT));
9421 __pyx_v_self->W_KNOT = ((PyArrayObject *)__pyx_t_1);
9428 __Pyx_XDECREF(__pyx_t_1);
9429 __Pyx_AddTraceback(
"cmeshTools.CMesh.W_KNOT.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9432 __Pyx_RefNannyFinishContext();
9437 static int __pyx_pw_10cmeshTools_5CMesh_6W_KNOT_5__del__(PyObject *__pyx_v_self);
9438 static int __pyx_pw_10cmeshTools_5CMesh_6W_KNOT_5__del__(PyObject *__pyx_v_self) {
9440 __Pyx_RefNannyDeclarations
9441 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9442 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6W_KNOT_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9445 __Pyx_RefNannyFinishContext();
9449 static int __pyx_pf_10cmeshTools_5CMesh_6W_KNOT_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9451 __Pyx_RefNannyDeclarations
9452 __Pyx_RefNannySetupContext(
"__del__", 0);
9453 __Pyx_INCREF(Py_None);
9454 __Pyx_GIVEREF(Py_None);
9455 __Pyx_GOTREF(__pyx_v_self->W_KNOT);
9456 __Pyx_DECREF(((PyObject *)__pyx_v_self->W_KNOT));
9457 __pyx_v_self->W_KNOT = ((PyArrayObject *)Py_None);
9461 __Pyx_RefNannyFinishContext();
9474 static PyObject *__pyx_pw_10cmeshTools_5CMesh_21elementDiametersArray_1__get__(PyObject *__pyx_v_self);
9475 static PyObject *__pyx_pw_10cmeshTools_5CMesh_21elementDiametersArray_1__get__(PyObject *__pyx_v_self) {
9476 PyObject *__pyx_r = 0;
9477 __Pyx_RefNannyDeclarations
9478 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
9479 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_21elementDiametersArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9482 __Pyx_RefNannyFinishContext();
9486 static PyObject *__pyx_pf_10cmeshTools_5CMesh_21elementDiametersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9487 PyObject *__pyx_r = NULL;
9488 __Pyx_RefNannyDeclarations
9489 __Pyx_RefNannySetupContext(
"__get__", 0);
9490 __Pyx_XDECREF(__pyx_r);
9491 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementDiametersArray));
9492 __pyx_r = ((PyObject *)__pyx_v_self->elementDiametersArray);
9497 __Pyx_XGIVEREF(__pyx_r);
9498 __Pyx_RefNannyFinishContext();
9503 static int __pyx_pw_10cmeshTools_5CMesh_21elementDiametersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
9504 static int __pyx_pw_10cmeshTools_5CMesh_21elementDiametersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
9506 __Pyx_RefNannyDeclarations
9507 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
9508 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_21elementDiametersArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
9511 __Pyx_RefNannyFinishContext();
9515 static int __pyx_pf_10cmeshTools_5CMesh_21elementDiametersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
9517 __Pyx_RefNannyDeclarations
9518 PyObject *__pyx_t_1 = NULL;
9519 int __pyx_lineno = 0;
9520 const char *__pyx_filename = NULL;
9521 int __pyx_clineno = 0;
9522 __Pyx_RefNannySetupContext(
"__set__", 0);
9523 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 79, __pyx_L1_error)
9524 __pyx_t_1 = __pyx_v_value;
9525 __Pyx_INCREF(__pyx_t_1);
9526 __Pyx_GIVEREF(__pyx_t_1);
9527 __Pyx_GOTREF(__pyx_v_self->elementDiametersArray);
9528 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementDiametersArray));
9529 __pyx_v_self->elementDiametersArray = ((PyArrayObject *)__pyx_t_1);
9536 __Pyx_XDECREF(__pyx_t_1);
9537 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementDiametersArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9540 __Pyx_RefNannyFinishContext();
9545 static int __pyx_pw_10cmeshTools_5CMesh_21elementDiametersArray_5__del__(PyObject *__pyx_v_self);
9546 static int __pyx_pw_10cmeshTools_5CMesh_21elementDiametersArray_5__del__(PyObject *__pyx_v_self) {
9548 __Pyx_RefNannyDeclarations
9549 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9550 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_21elementDiametersArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9553 __Pyx_RefNannyFinishContext();
9557 static int __pyx_pf_10cmeshTools_5CMesh_21elementDiametersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9559 __Pyx_RefNannyDeclarations
9560 __Pyx_RefNannySetupContext(
"__del__", 0);
9561 __Pyx_INCREF(Py_None);
9562 __Pyx_GIVEREF(Py_None);
9563 __Pyx_GOTREF(__pyx_v_self->elementDiametersArray);
9564 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementDiametersArray));
9565 __pyx_v_self->elementDiametersArray = ((PyArrayObject *)Py_None);
9569 __Pyx_RefNannyFinishContext();
9582 static PyObject *__pyx_pw_10cmeshTools_5CMesh_26elementInnerDiametersArray_1__get__(PyObject *__pyx_v_self);
9583 static PyObject *__pyx_pw_10cmeshTools_5CMesh_26elementInnerDiametersArray_1__get__(PyObject *__pyx_v_self) {
9584 PyObject *__pyx_r = 0;
9585 __Pyx_RefNannyDeclarations
9586 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
9587 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_26elementInnerDiametersArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9590 __Pyx_RefNannyFinishContext();
9594 static PyObject *__pyx_pf_10cmeshTools_5CMesh_26elementInnerDiametersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9595 PyObject *__pyx_r = NULL;
9596 __Pyx_RefNannyDeclarations
9597 __Pyx_RefNannySetupContext(
"__get__", 0);
9598 __Pyx_XDECREF(__pyx_r);
9599 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementInnerDiametersArray));
9600 __pyx_r = ((PyObject *)__pyx_v_self->elementInnerDiametersArray);
9605 __Pyx_XGIVEREF(__pyx_r);
9606 __Pyx_RefNannyFinishContext();
9611 static int __pyx_pw_10cmeshTools_5CMesh_26elementInnerDiametersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
9612 static int __pyx_pw_10cmeshTools_5CMesh_26elementInnerDiametersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
9614 __Pyx_RefNannyDeclarations
9615 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
9616 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_26elementInnerDiametersArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
9619 __Pyx_RefNannyFinishContext();
9623 static int __pyx_pf_10cmeshTools_5CMesh_26elementInnerDiametersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
9625 __Pyx_RefNannyDeclarations
9626 PyObject *__pyx_t_1 = NULL;
9627 int __pyx_lineno = 0;
9628 const char *__pyx_filename = NULL;
9629 int __pyx_clineno = 0;
9630 __Pyx_RefNannySetupContext(
"__set__", 0);
9631 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 80, __pyx_L1_error)
9632 __pyx_t_1 = __pyx_v_value;
9633 __Pyx_INCREF(__pyx_t_1);
9634 __Pyx_GIVEREF(__pyx_t_1);
9635 __Pyx_GOTREF(__pyx_v_self->elementInnerDiametersArray);
9636 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementInnerDiametersArray));
9637 __pyx_v_self->elementInnerDiametersArray = ((PyArrayObject *)__pyx_t_1);
9644 __Pyx_XDECREF(__pyx_t_1);
9645 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementInnerDiametersArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9648 __Pyx_RefNannyFinishContext();
9653 static int __pyx_pw_10cmeshTools_5CMesh_26elementInnerDiametersArray_5__del__(PyObject *__pyx_v_self);
9654 static int __pyx_pw_10cmeshTools_5CMesh_26elementInnerDiametersArray_5__del__(PyObject *__pyx_v_self) {
9656 __Pyx_RefNannyDeclarations
9657 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9658 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_26elementInnerDiametersArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9661 __Pyx_RefNannyFinishContext();
9665 static int __pyx_pf_10cmeshTools_5CMesh_26elementInnerDiametersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9667 __Pyx_RefNannyDeclarations
9668 __Pyx_RefNannySetupContext(
"__del__", 0);
9669 __Pyx_INCREF(Py_None);
9670 __Pyx_GIVEREF(Py_None);
9671 __Pyx_GOTREF(__pyx_v_self->elementInnerDiametersArray);
9672 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementInnerDiametersArray));
9673 __pyx_v_self->elementInnerDiametersArray = ((PyArrayObject *)Py_None);
9677 __Pyx_RefNannyFinishContext();
9690 static PyObject *__pyx_pw_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_1__get__(PyObject *__pyx_v_self);
9691 static PyObject *__pyx_pw_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_1__get__(PyObject *__pyx_v_self) {
9692 PyObject *__pyx_r = 0;
9693 __Pyx_RefNannyDeclarations
9694 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
9695 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_29elementBoundaryDiametersArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9698 __Pyx_RefNannyFinishContext();
9702 static PyObject *__pyx_pf_10cmeshTools_5CMesh_29elementBoundaryDiametersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9703 PyObject *__pyx_r = NULL;
9704 __Pyx_RefNannyDeclarations
9705 __Pyx_RefNannySetupContext(
"__get__", 0);
9706 __Pyx_XDECREF(__pyx_r);
9707 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementBoundaryDiametersArray));
9708 __pyx_r = ((PyObject *)__pyx_v_self->elementBoundaryDiametersArray);
9713 __Pyx_XGIVEREF(__pyx_r);
9714 __Pyx_RefNannyFinishContext();
9719 static int __pyx_pw_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
9720 static int __pyx_pw_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
9722 __Pyx_RefNannyDeclarations
9723 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
9724 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
9727 __Pyx_RefNannyFinishContext();
9731 static int __pyx_pf_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
9733 __Pyx_RefNannyDeclarations
9734 PyObject *__pyx_t_1 = NULL;
9735 int __pyx_lineno = 0;
9736 const char *__pyx_filename = NULL;
9737 int __pyx_clineno = 0;
9738 __Pyx_RefNannySetupContext(
"__set__", 0);
9739 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 81, __pyx_L1_error)
9740 __pyx_t_1 = __pyx_v_value;
9741 __Pyx_INCREF(__pyx_t_1);
9742 __Pyx_GIVEREF(__pyx_t_1);
9743 __Pyx_GOTREF(__pyx_v_self->elementBoundaryDiametersArray);
9744 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryDiametersArray));
9745 __pyx_v_self->elementBoundaryDiametersArray = ((PyArrayObject *)__pyx_t_1);
9752 __Pyx_XDECREF(__pyx_t_1);
9753 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementBoundaryDiametersArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9756 __Pyx_RefNannyFinishContext();
9761 static int __pyx_pw_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_5__del__(PyObject *__pyx_v_self);
9762 static int __pyx_pw_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_5__del__(PyObject *__pyx_v_self) {
9764 __Pyx_RefNannyDeclarations
9765 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9766 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9769 __Pyx_RefNannyFinishContext();
9773 static int __pyx_pf_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9775 __Pyx_RefNannyDeclarations
9776 __Pyx_RefNannySetupContext(
"__del__", 0);
9777 __Pyx_INCREF(Py_None);
9778 __Pyx_GIVEREF(Py_None);
9779 __Pyx_GOTREF(__pyx_v_self->elementBoundaryDiametersArray);
9780 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryDiametersArray));
9781 __pyx_v_self->elementBoundaryDiametersArray = ((PyArrayObject *)Py_None);
9785 __Pyx_RefNannyFinishContext();
9798 static PyObject *__pyx_pw_10cmeshTools_5CMesh_23elementBarycentersArray_1__get__(PyObject *__pyx_v_self);
9799 static PyObject *__pyx_pw_10cmeshTools_5CMesh_23elementBarycentersArray_1__get__(PyObject *__pyx_v_self) {
9800 PyObject *__pyx_r = 0;
9801 __Pyx_RefNannyDeclarations
9802 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
9803 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_23elementBarycentersArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9806 __Pyx_RefNannyFinishContext();
9810 static PyObject *__pyx_pf_10cmeshTools_5CMesh_23elementBarycentersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9811 PyObject *__pyx_r = NULL;
9812 __Pyx_RefNannyDeclarations
9813 __Pyx_RefNannySetupContext(
"__get__", 0);
9814 __Pyx_XDECREF(__pyx_r);
9815 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementBarycentersArray));
9816 __pyx_r = ((PyObject *)__pyx_v_self->elementBarycentersArray);
9821 __Pyx_XGIVEREF(__pyx_r);
9822 __Pyx_RefNannyFinishContext();
9827 static int __pyx_pw_10cmeshTools_5CMesh_23elementBarycentersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
9828 static int __pyx_pw_10cmeshTools_5CMesh_23elementBarycentersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
9830 __Pyx_RefNannyDeclarations
9831 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
9832 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_23elementBarycentersArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
9835 __Pyx_RefNannyFinishContext();
9839 static int __pyx_pf_10cmeshTools_5CMesh_23elementBarycentersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
9841 __Pyx_RefNannyDeclarations
9842 PyObject *__pyx_t_1 = NULL;
9843 int __pyx_lineno = 0;
9844 const char *__pyx_filename = NULL;
9845 int __pyx_clineno = 0;
9846 __Pyx_RefNannySetupContext(
"__set__", 0);
9847 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 82, __pyx_L1_error)
9848 __pyx_t_1 = __pyx_v_value;
9849 __Pyx_INCREF(__pyx_t_1);
9850 __Pyx_GIVEREF(__pyx_t_1);
9851 __Pyx_GOTREF(__pyx_v_self->elementBarycentersArray);
9852 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBarycentersArray));
9853 __pyx_v_self->elementBarycentersArray = ((PyArrayObject *)__pyx_t_1);
9860 __Pyx_XDECREF(__pyx_t_1);
9861 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementBarycentersArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9864 __Pyx_RefNannyFinishContext();
9869 static int __pyx_pw_10cmeshTools_5CMesh_23elementBarycentersArray_5__del__(PyObject *__pyx_v_self);
9870 static int __pyx_pw_10cmeshTools_5CMesh_23elementBarycentersArray_5__del__(PyObject *__pyx_v_self) {
9872 __Pyx_RefNannyDeclarations
9873 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9874 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_23elementBarycentersArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9877 __Pyx_RefNannyFinishContext();
9881 static int __pyx_pf_10cmeshTools_5CMesh_23elementBarycentersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9883 __Pyx_RefNannyDeclarations
9884 __Pyx_RefNannySetupContext(
"__del__", 0);
9885 __Pyx_INCREF(Py_None);
9886 __Pyx_GIVEREF(Py_None);
9887 __Pyx_GOTREF(__pyx_v_self->elementBarycentersArray);
9888 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBarycentersArray));
9889 __pyx_v_self->elementBarycentersArray = ((PyArrayObject *)Py_None);
9893 __Pyx_RefNannyFinishContext();
9906 static PyObject *__pyx_pw_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_1__get__(PyObject *__pyx_v_self);
9907 static PyObject *__pyx_pw_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_1__get__(PyObject *__pyx_v_self) {
9908 PyObject *__pyx_r = 0;
9909 __Pyx_RefNannyDeclarations
9910 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
9911 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9914 __Pyx_RefNannyFinishContext();
9918 static PyObject *__pyx_pf_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9919 PyObject *__pyx_r = NULL;
9920 __Pyx_RefNannyDeclarations
9921 __Pyx_RefNannySetupContext(
"__get__", 0);
9922 __Pyx_XDECREF(__pyx_r);
9923 __Pyx_INCREF(((PyObject *)__pyx_v_self->elementBoundaryBarycentersArray));
9924 __pyx_r = ((PyObject *)__pyx_v_self->elementBoundaryBarycentersArray);
9929 __Pyx_XGIVEREF(__pyx_r);
9930 __Pyx_RefNannyFinishContext();
9935 static int __pyx_pw_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
9936 static int __pyx_pw_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
9938 __Pyx_RefNannyDeclarations
9939 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
9940 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
9943 __Pyx_RefNannyFinishContext();
9947 static int __pyx_pf_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
9949 __Pyx_RefNannyDeclarations
9950 PyObject *__pyx_t_1 = NULL;
9951 int __pyx_lineno = 0;
9952 const char *__pyx_filename = NULL;
9953 int __pyx_clineno = 0;
9954 __Pyx_RefNannySetupContext(
"__set__", 0);
9955 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 83, __pyx_L1_error)
9956 __pyx_t_1 = __pyx_v_value;
9957 __Pyx_INCREF(__pyx_t_1);
9958 __Pyx_GIVEREF(__pyx_t_1);
9959 __Pyx_GOTREF(__pyx_v_self->elementBoundaryBarycentersArray);
9960 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryBarycentersArray));
9961 __pyx_v_self->elementBoundaryBarycentersArray = ((PyArrayObject *)__pyx_t_1);
9968 __Pyx_XDECREF(__pyx_t_1);
9969 __Pyx_AddTraceback(
"cmeshTools.CMesh.elementBoundaryBarycentersArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
9972 __Pyx_RefNannyFinishContext();
9977 static int __pyx_pw_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_5__del__(PyObject *__pyx_v_self);
9978 static int __pyx_pw_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_5__del__(PyObject *__pyx_v_self) {
9980 __Pyx_RefNannyDeclarations
9981 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
9982 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
9985 __Pyx_RefNannyFinishContext();
9989 static int __pyx_pf_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
9991 __Pyx_RefNannyDeclarations
9992 __Pyx_RefNannySetupContext(
"__del__", 0);
9993 __Pyx_INCREF(Py_None);
9994 __Pyx_GIVEREF(Py_None);
9995 __Pyx_GOTREF(__pyx_v_self->elementBoundaryBarycentersArray);
9996 __Pyx_DECREF(((PyObject *)__pyx_v_self->elementBoundaryBarycentersArray));
9997 __pyx_v_self->elementBoundaryBarycentersArray = ((PyArrayObject *)Py_None);
10001 __Pyx_RefNannyFinishContext();
10014 static PyObject *__pyx_pw_10cmeshTools_5CMesh_18nodeDiametersArray_1__get__(PyObject *__pyx_v_self);
10015 static PyObject *__pyx_pw_10cmeshTools_5CMesh_18nodeDiametersArray_1__get__(PyObject *__pyx_v_self) {
10016 PyObject *__pyx_r = 0;
10017 __Pyx_RefNannyDeclarations
10018 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
10019 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_18nodeDiametersArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
10022 __Pyx_RefNannyFinishContext();
10026 static PyObject *__pyx_pf_10cmeshTools_5CMesh_18nodeDiametersArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
10027 PyObject *__pyx_r = NULL;
10028 __Pyx_RefNannyDeclarations
10029 __Pyx_RefNannySetupContext(
"__get__", 0);
10030 __Pyx_XDECREF(__pyx_r);
10031 __Pyx_INCREF(((PyObject *)__pyx_v_self->nodeDiametersArray));
10032 __pyx_r = ((PyObject *)__pyx_v_self->nodeDiametersArray);
10037 __Pyx_XGIVEREF(__pyx_r);
10038 __Pyx_RefNannyFinishContext();
10043 static int __pyx_pw_10cmeshTools_5CMesh_18nodeDiametersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
10044 static int __pyx_pw_10cmeshTools_5CMesh_18nodeDiametersArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
10046 __Pyx_RefNannyDeclarations
10047 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
10048 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_18nodeDiametersArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
10051 __Pyx_RefNannyFinishContext();
10055 static int __pyx_pf_10cmeshTools_5CMesh_18nodeDiametersArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
10057 __Pyx_RefNannyDeclarations
10058 PyObject *__pyx_t_1 = NULL;
10059 int __pyx_lineno = 0;
10060 const char *__pyx_filename = NULL;
10061 int __pyx_clineno = 0;
10062 __Pyx_RefNannySetupContext(
"__set__", 0);
10063 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 84, __pyx_L1_error)
10064 __pyx_t_1 = __pyx_v_value;
10065 __Pyx_INCREF(__pyx_t_1);
10066 __Pyx_GIVEREF(__pyx_t_1);
10067 __Pyx_GOTREF(__pyx_v_self->nodeDiametersArray);
10068 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeDiametersArray));
10069 __pyx_v_self->nodeDiametersArray = ((PyArrayObject *)__pyx_t_1);
10076 __Pyx_XDECREF(__pyx_t_1);
10077 __Pyx_AddTraceback(
"cmeshTools.CMesh.nodeDiametersArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10080 __Pyx_RefNannyFinishContext();
10085 static int __pyx_pw_10cmeshTools_5CMesh_18nodeDiametersArray_5__del__(PyObject *__pyx_v_self);
10086 static int __pyx_pw_10cmeshTools_5CMesh_18nodeDiametersArray_5__del__(PyObject *__pyx_v_self) {
10088 __Pyx_RefNannyDeclarations
10089 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
10090 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_18nodeDiametersArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
10093 __Pyx_RefNannyFinishContext();
10097 static int __pyx_pf_10cmeshTools_5CMesh_18nodeDiametersArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
10099 __Pyx_RefNannyDeclarations
10100 __Pyx_RefNannySetupContext(
"__del__", 0);
10101 __Pyx_INCREF(Py_None);
10102 __Pyx_GIVEREF(Py_None);
10103 __Pyx_GOTREF(__pyx_v_self->nodeDiametersArray);
10104 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeDiametersArray));
10105 __pyx_v_self->nodeDiametersArray = ((PyArrayObject *)Py_None);
10109 __Pyx_RefNannyFinishContext();
10122 static PyObject *__pyx_pw_10cmeshTools_5CMesh_16nodeSupportArray_1__get__(PyObject *__pyx_v_self);
10123 static PyObject *__pyx_pw_10cmeshTools_5CMesh_16nodeSupportArray_1__get__(PyObject *__pyx_v_self) {
10124 PyObject *__pyx_r = 0;
10125 __Pyx_RefNannyDeclarations
10126 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
10127 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_16nodeSupportArray___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
10130 __Pyx_RefNannyFinishContext();
10134 static PyObject *__pyx_pf_10cmeshTools_5CMesh_16nodeSupportArray___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
10135 PyObject *__pyx_r = NULL;
10136 __Pyx_RefNannyDeclarations
10137 __Pyx_RefNannySetupContext(
"__get__", 0);
10138 __Pyx_XDECREF(__pyx_r);
10139 __Pyx_INCREF(((PyObject *)__pyx_v_self->nodeSupportArray));
10140 __pyx_r = ((PyObject *)__pyx_v_self->nodeSupportArray);
10145 __Pyx_XGIVEREF(__pyx_r);
10146 __Pyx_RefNannyFinishContext();
10151 static int __pyx_pw_10cmeshTools_5CMesh_16nodeSupportArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
10152 static int __pyx_pw_10cmeshTools_5CMesh_16nodeSupportArray_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
10154 __Pyx_RefNannyDeclarations
10155 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
10156 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_16nodeSupportArray_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
10159 __Pyx_RefNannyFinishContext();
10163 static int __pyx_pf_10cmeshTools_5CMesh_16nodeSupportArray_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
10165 __Pyx_RefNannyDeclarations
10166 PyObject *__pyx_t_1 = NULL;
10167 int __pyx_lineno = 0;
10168 const char *__pyx_filename = NULL;
10169 int __pyx_clineno = 0;
10170 __Pyx_RefNannySetupContext(
"__set__", 0);
10171 if (!(likely(((__pyx_v_value) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_value, __pyx_ptype_5numpy_ndarray))))) __PYX_ERR(2, 85, __pyx_L1_error)
10172 __pyx_t_1 = __pyx_v_value;
10173 __Pyx_INCREF(__pyx_t_1);
10174 __Pyx_GIVEREF(__pyx_t_1);
10175 __Pyx_GOTREF(__pyx_v_self->nodeSupportArray);
10176 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeSupportArray));
10177 __pyx_v_self->nodeSupportArray = ((PyArrayObject *)__pyx_t_1);
10184 __Pyx_XDECREF(__pyx_t_1);
10185 __Pyx_AddTraceback(
"cmeshTools.CMesh.nodeSupportArray.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10188 __Pyx_RefNannyFinishContext();
10193 static int __pyx_pw_10cmeshTools_5CMesh_16nodeSupportArray_5__del__(PyObject *__pyx_v_self);
10194 static int __pyx_pw_10cmeshTools_5CMesh_16nodeSupportArray_5__del__(PyObject *__pyx_v_self) {
10196 __Pyx_RefNannyDeclarations
10197 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
10198 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_16nodeSupportArray_4__del__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
10201 __Pyx_RefNannyFinishContext();
10205 static int __pyx_pf_10cmeshTools_5CMesh_16nodeSupportArray_4__del__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
10207 __Pyx_RefNannyDeclarations
10208 __Pyx_RefNannySetupContext(
"__del__", 0);
10209 __Pyx_INCREF(Py_None);
10210 __Pyx_GIVEREF(Py_None);
10211 __Pyx_GOTREF(__pyx_v_self->nodeSupportArray);
10212 __Pyx_DECREF(((PyObject *)__pyx_v_self->nodeSupportArray));
10213 __pyx_v_self->nodeSupportArray = ((PyArrayObject *)Py_None);
10217 __Pyx_RefNannyFinishContext();
10230 static PyObject *__pyx_pw_10cmeshTools_5CMesh_1h_1__get__(PyObject *__pyx_v_self);
10231 static PyObject *__pyx_pw_10cmeshTools_5CMesh_1h_1__get__(PyObject *__pyx_v_self) {
10232 PyObject *__pyx_r = 0;
10233 __Pyx_RefNannyDeclarations
10234 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
10235 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_1h___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
10238 __Pyx_RefNannyFinishContext();
10242 static PyObject *__pyx_pf_10cmeshTools_5CMesh_1h___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
10243 PyObject *__pyx_r = NULL;
10244 __Pyx_RefNannyDeclarations
10245 PyObject *__pyx_t_1 = NULL;
10246 int __pyx_lineno = 0;
10247 const char *__pyx_filename = NULL;
10248 int __pyx_clineno = 0;
10249 __Pyx_RefNannySetupContext(
"__get__", 0);
10250 __Pyx_XDECREF(__pyx_r);
10251 __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->h);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 87, __pyx_L1_error)
10252 __Pyx_GOTREF(__pyx_t_1);
10253 __pyx_r = __pyx_t_1;
10259 __Pyx_XDECREF(__pyx_t_1);
10260 __Pyx_AddTraceback(
"cmeshTools.CMesh.h.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10263 __Pyx_XGIVEREF(__pyx_r);
10264 __Pyx_RefNannyFinishContext();
10269 static int __pyx_pw_10cmeshTools_5CMesh_1h_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
10270 static int __pyx_pw_10cmeshTools_5CMesh_1h_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
10272 __Pyx_RefNannyDeclarations
10273 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
10274 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_1h_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
10277 __Pyx_RefNannyFinishContext();
10281 static int __pyx_pf_10cmeshTools_5CMesh_1h_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
10283 __Pyx_RefNannyDeclarations
10285 int __pyx_lineno = 0;
10286 const char *__pyx_filename = NULL;
10287 int __pyx_clineno = 0;
10288 __Pyx_RefNannySetupContext(
"__set__", 0);
10289 __pyx_t_1 = __pyx_PyFloat_AsDouble(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
double)-1) && PyErr_Occurred())) __PYX_ERR(2, 87, __pyx_L1_error)
10290 __pyx_v_self->h = __pyx_t_1;
10296 __Pyx_AddTraceback(
"cmeshTools.CMesh.h.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10299 __Pyx_RefNannyFinishContext();
10312 static PyObject *__pyx_pw_10cmeshTools_5CMesh_4hMin_1__get__(PyObject *__pyx_v_self);
10313 static PyObject *__pyx_pw_10cmeshTools_5CMesh_4hMin_1__get__(PyObject *__pyx_v_self) {
10314 PyObject *__pyx_r = 0;
10315 __Pyx_RefNannyDeclarations
10316 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
10317 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_4hMin___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
10320 __Pyx_RefNannyFinishContext();
10324 static PyObject *__pyx_pf_10cmeshTools_5CMesh_4hMin___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
10325 PyObject *__pyx_r = NULL;
10326 __Pyx_RefNannyDeclarations
10327 PyObject *__pyx_t_1 = NULL;
10328 int __pyx_lineno = 0;
10329 const char *__pyx_filename = NULL;
10330 int __pyx_clineno = 0;
10331 __Pyx_RefNannySetupContext(
"__get__", 0);
10332 __Pyx_XDECREF(__pyx_r);
10333 __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->hMin);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 88, __pyx_L1_error)
10334 __Pyx_GOTREF(__pyx_t_1);
10335 __pyx_r = __pyx_t_1;
10341 __Pyx_XDECREF(__pyx_t_1);
10342 __Pyx_AddTraceback(
"cmeshTools.CMesh.hMin.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10345 __Pyx_XGIVEREF(__pyx_r);
10346 __Pyx_RefNannyFinishContext();
10351 static int __pyx_pw_10cmeshTools_5CMesh_4hMin_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
10352 static int __pyx_pw_10cmeshTools_5CMesh_4hMin_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
10354 __Pyx_RefNannyDeclarations
10355 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
10356 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_4hMin_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
10359 __Pyx_RefNannyFinishContext();
10363 static int __pyx_pf_10cmeshTools_5CMesh_4hMin_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
10365 __Pyx_RefNannyDeclarations
10367 int __pyx_lineno = 0;
10368 const char *__pyx_filename = NULL;
10369 int __pyx_clineno = 0;
10370 __Pyx_RefNannySetupContext(
"__set__", 0);
10371 __pyx_t_1 = __pyx_PyFloat_AsDouble(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
double)-1) && PyErr_Occurred())) __PYX_ERR(2, 88, __pyx_L1_error)
10372 __pyx_v_self->hMin = __pyx_t_1;
10378 __Pyx_AddTraceback(
"cmeshTools.CMesh.hMin.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10381 __Pyx_RefNannyFinishContext();
10393 static PyObject *__pyx_pw_10cmeshTools_5CMesh_8sigmaMax_1__get__(PyObject *__pyx_v_self);
10394 static PyObject *__pyx_pw_10cmeshTools_5CMesh_8sigmaMax_1__get__(PyObject *__pyx_v_self) {
10395 PyObject *__pyx_r = 0;
10396 __Pyx_RefNannyDeclarations
10397 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
10398 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_8sigmaMax___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
10401 __Pyx_RefNannyFinishContext();
10405 static PyObject *__pyx_pf_10cmeshTools_5CMesh_8sigmaMax___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
10406 PyObject *__pyx_r = NULL;
10407 __Pyx_RefNannyDeclarations
10408 PyObject *__pyx_t_1 = NULL;
10409 int __pyx_lineno = 0;
10410 const char *__pyx_filename = NULL;
10411 int __pyx_clineno = 0;
10412 __Pyx_RefNannySetupContext(
"__get__", 0);
10413 __Pyx_XDECREF(__pyx_r);
10414 __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->sigmaMax);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 89, __pyx_L1_error)
10415 __Pyx_GOTREF(__pyx_t_1);
10416 __pyx_r = __pyx_t_1;
10422 __Pyx_XDECREF(__pyx_t_1);
10423 __Pyx_AddTraceback(
"cmeshTools.CMesh.sigmaMax.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10426 __Pyx_XGIVEREF(__pyx_r);
10427 __Pyx_RefNannyFinishContext();
10432 static int __pyx_pw_10cmeshTools_5CMesh_8sigmaMax_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
10433 static int __pyx_pw_10cmeshTools_5CMesh_8sigmaMax_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
10435 __Pyx_RefNannyDeclarations
10436 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
10437 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_8sigmaMax_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
10440 __Pyx_RefNannyFinishContext();
10444 static int __pyx_pf_10cmeshTools_5CMesh_8sigmaMax_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
10446 __Pyx_RefNannyDeclarations
10448 int __pyx_lineno = 0;
10449 const char *__pyx_filename = NULL;
10450 int __pyx_clineno = 0;
10451 __Pyx_RefNannySetupContext(
"__set__", 0);
10452 __pyx_t_1 = __pyx_PyFloat_AsDouble(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
double)-1) && PyErr_Occurred())) __PYX_ERR(2, 89, __pyx_L1_error)
10453 __pyx_v_self->sigmaMax = __pyx_t_1;
10459 __Pyx_AddTraceback(
"cmeshTools.CMesh.sigmaMax.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10462 __Pyx_RefNannyFinishContext();
10473 static PyObject *__pyx_pw_10cmeshTools_5CMesh_6volume_1__get__(PyObject *__pyx_v_self);
10474 static PyObject *__pyx_pw_10cmeshTools_5CMesh_6volume_1__get__(PyObject *__pyx_v_self) {
10475 PyObject *__pyx_r = 0;
10476 __Pyx_RefNannyDeclarations
10477 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
10478 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6volume___get__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
10481 __Pyx_RefNannyFinishContext();
10485 static PyObject *__pyx_pf_10cmeshTools_5CMesh_6volume___get__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
10486 PyObject *__pyx_r = NULL;
10487 __Pyx_RefNannyDeclarations
10488 PyObject *__pyx_t_1 = NULL;
10489 int __pyx_lineno = 0;
10490 const char *__pyx_filename = NULL;
10491 int __pyx_clineno = 0;
10492 __Pyx_RefNannySetupContext(
"__get__", 0);
10493 __Pyx_XDECREF(__pyx_r);
10494 __pyx_t_1 = PyFloat_FromDouble(__pyx_v_self->volume);
if (unlikely(!__pyx_t_1)) __PYX_ERR(2, 90, __pyx_L1_error)
10495 __Pyx_GOTREF(__pyx_t_1);
10496 __pyx_r = __pyx_t_1;
10502 __Pyx_XDECREF(__pyx_t_1);
10503 __Pyx_AddTraceback(
"cmeshTools.CMesh.volume.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10506 __Pyx_XGIVEREF(__pyx_r);
10507 __Pyx_RefNannyFinishContext();
10512 static int __pyx_pw_10cmeshTools_5CMesh_6volume_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
10513 static int __pyx_pw_10cmeshTools_5CMesh_6volume_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
10515 __Pyx_RefNannyDeclarations
10516 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
10517 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_6volume_2__set__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
10520 __Pyx_RefNannyFinishContext();
10524 static int __pyx_pf_10cmeshTools_5CMesh_6volume_2__set__(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, PyObject *__pyx_v_value) {
10526 __Pyx_RefNannyDeclarations
10528 int __pyx_lineno = 0;
10529 const char *__pyx_filename = NULL;
10530 int __pyx_clineno = 0;
10531 __Pyx_RefNannySetupContext(
"__set__", 0);
10532 __pyx_t_1 = __pyx_PyFloat_AsDouble(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
double)-1) && PyErr_Occurred())) __PYX_ERR(2, 90, __pyx_L1_error)
10533 __pyx_v_self->volume = __pyx_t_1;
10539 __Pyx_AddTraceback(
"cmeshTools.CMesh.volume.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10542 __Pyx_RefNannyFinishContext();
10553 static PyObject *__pyx_pw_10cmeshTools_5CMesh_9__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
10554 static PyObject *__pyx_pw_10cmeshTools_5CMesh_9__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
10555 PyObject *__pyx_r = 0;
10556 __Pyx_RefNannyDeclarations
10557 __Pyx_RefNannySetupContext(
"__reduce_cython__ (wrapper)", 0);
10558 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_8__reduce_cython__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self));
10561 __Pyx_RefNannyFinishContext();
10565 static PyObject *__pyx_pf_10cmeshTools_5CMesh_8__reduce_cython__(CYTHON_UNUSED
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self) {
10566 PyObject *__pyx_r = NULL;
10567 __Pyx_RefNannyDeclarations
10568 PyObject *__pyx_t_1 = NULL;
10569 int __pyx_lineno = 0;
10570 const char *__pyx_filename = NULL;
10571 int __pyx_clineno = 0;
10572 __Pyx_RefNannySetupContext(
"__reduce_cython__", 0);
10580 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__2, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 2, __pyx_L1_error)
10581 __Pyx_GOTREF(__pyx_t_1);
10582 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
10583 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
10584 __PYX_ERR(0, 2, __pyx_L1_error)
10594 __Pyx_XDECREF(__pyx_t_1);
10595 __Pyx_AddTraceback(
"cmeshTools.CMesh.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10597 __Pyx_XGIVEREF(__pyx_r);
10598 __Pyx_RefNannyFinishContext();
10610 static PyObject *__pyx_pw_10cmeshTools_5CMesh_11__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state);
10611 static PyObject *__pyx_pw_10cmeshTools_5CMesh_11__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
10612 PyObject *__pyx_r = 0;
10613 __Pyx_RefNannyDeclarations
10614 __Pyx_RefNannySetupContext(
"__setstate_cython__ (wrapper)", 0);
10615 __pyx_r = __pyx_pf_10cmeshTools_5CMesh_10__setstate_cython__(((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
10618 __Pyx_RefNannyFinishContext();
10622 static PyObject *__pyx_pf_10cmeshTools_5CMesh_10__setstate_cython__(CYTHON_UNUSED
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
10623 PyObject *__pyx_r = NULL;
10624 __Pyx_RefNannyDeclarations
10625 PyObject *__pyx_t_1 = NULL;
10626 int __pyx_lineno = 0;
10627 const char *__pyx_filename = NULL;
10628 int __pyx_clineno = 0;
10629 __Pyx_RefNannySetupContext(
"__setstate_cython__", 0);
10636 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__3, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 4, __pyx_L1_error)
10637 __Pyx_GOTREF(__pyx_t_1);
10638 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
10639 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
10640 __PYX_ERR(0, 4, __pyx_L1_error)
10651 __Pyx_XDECREF(__pyx_t_1);
10652 __Pyx_AddTraceback(
"cmeshTools.CMesh.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
10654 __Pyx_XGIVEREF(__pyx_r);
10655 __Pyx_RefNannyFinishContext();
10668 static PyObject *__pyx_pw_10cmeshTools_1buildPythonMeshInterface(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
10669 static char __pyx_doc_10cmeshTools_buildPythonMeshInterface[] =
"\n function to be conform to old module, and to calls from MeshTools\n ";
10670 static PyMethodDef __pyx_mdef_10cmeshTools_1buildPythonMeshInterface = {
"buildPythonMeshInterface", (PyCFunction)__pyx_pw_10cmeshTools_1buildPythonMeshInterface, METH_O, __pyx_doc_10cmeshTools_buildPythonMeshInterface};
10671 static PyObject *__pyx_pw_10cmeshTools_1buildPythonMeshInterface(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
10672 PyObject *__pyx_r = 0;
10673 __Pyx_RefNannyDeclarations
10674 __Pyx_RefNannySetupContext(
"buildPythonMeshInterface (wrapper)", 0);
10675 __pyx_r = __pyx_pf_10cmeshTools_buildPythonMeshInterface(__pyx_self, ((PyObject *)__pyx_v_cmesh));
10678 __Pyx_RefNannyFinishContext();
10682 static PyObject *__pyx_pf_10cmeshTools_buildPythonMeshInterface(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
10683 PyObject *__pyx_r = NULL;
10684 __Pyx_RefNannyDeclarations
10685 PyObject *__pyx_t_1 = NULL;
10686 PyObject *__pyx_t_2 = NULL;
10687 PyObject *__pyx_t_3 = NULL;
10688 PyObject *__pyx_t_4 = NULL;
10689 PyObject *__pyx_t_5 = NULL;
10690 PyObject *__pyx_t_6 = NULL;
10691 PyObject *__pyx_t_7 = NULL;
10692 PyObject *__pyx_t_8 = NULL;
10693 PyObject *__pyx_t_9 = NULL;
10694 PyObject *__pyx_t_10 = NULL;
10695 PyObject *__pyx_t_11 = NULL;
10696 PyObject *__pyx_t_12 = NULL;
10697 PyObject *__pyx_t_13 = NULL;
10698 PyObject *__pyx_t_14 = NULL;
10699 PyObject *__pyx_t_15 = NULL;
10700 PyObject *__pyx_t_16 = NULL;
10701 PyObject *__pyx_t_17 = NULL;
10702 PyObject *__pyx_t_18 = NULL;
10703 PyObject *__pyx_t_19 = NULL;
10704 PyObject *__pyx_t_20 = NULL;
10705 PyObject *__pyx_t_21 = NULL;
10706 PyObject *__pyx_t_22 = NULL;
10707 PyObject *__pyx_t_23 = NULL;
10708 PyObject *__pyx_t_24 = NULL;
10709 PyObject *__pyx_t_25 = NULL;
10710 PyObject *__pyx_t_26 = NULL;
10711 PyObject *__pyx_t_27 = NULL;
10712 PyObject *__pyx_t_28 = NULL;
10713 PyObject *__pyx_t_29 = NULL;
10714 PyObject *__pyx_t_30 = NULL;
10715 PyObject *__pyx_t_31 = NULL;
10716 PyObject *__pyx_t_32 = NULL;
10717 PyObject *__pyx_t_33 = NULL;
10718 PyObject *__pyx_t_34 = NULL;
10719 PyObject *__pyx_t_35 = NULL;
10720 PyObject *__pyx_t_36 = NULL;
10721 PyObject *__pyx_t_37 = NULL;
10722 PyObject *__pyx_t_38 = NULL;
10723 PyObject *__pyx_t_39 = NULL;
10724 PyObject *__pyx_t_40 = NULL;
10725 PyObject *__pyx_t_41 = NULL;
10726 PyObject *__pyx_t_42 = NULL;
10727 PyObject *__pyx_t_43 = NULL;
10728 PyObject *__pyx_t_44 = NULL;
10729 PyObject *__pyx_t_45 = NULL;
10730 PyObject *__pyx_t_46 = NULL;
10731 PyObject *__pyx_t_47 = NULL;
10732 PyObject *__pyx_t_48 = NULL;
10733 PyObject *__pyx_t_49 = NULL;
10734 PyObject *__pyx_t_50 = NULL;
10735 PyObject *__pyx_t_51 = NULL;
10736 int __pyx_lineno = 0;
10737 const char *__pyx_filename = NULL;
10738 int __pyx_clineno = 0;
10739 __Pyx_RefNannySetupContext(
"buildPythonMeshInterface", 0);
10748 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_buildPythonMeshInterface);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 124, __pyx_L1_error)
10749 __Pyx_GOTREF(__pyx_t_2);
10751 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
10752 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
10753 if (likely(__pyx_t_3)) {
10754 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
10755 __Pyx_INCREF(__pyx_t_3);
10756 __Pyx_INCREF(
function);
10757 __Pyx_DECREF_SET(__pyx_t_2,
function);
10760 __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2);
10761 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
10762 if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 124, __pyx_L1_error)
10763 __Pyx_GOTREF(__pyx_t_1);
10764 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
10765 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
10774 __Pyx_XDECREF(__pyx_r);
10775 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nElements_global);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 125, __pyx_L1_error)
10776 __Pyx_GOTREF(__pyx_t_1);
10785 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nNodes_global);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 126, __pyx_L1_error)
10786 __Pyx_GOTREF(__pyx_t_2);
10795 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nNodes_element);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 127, __pyx_L1_error)
10796 __Pyx_GOTREF(__pyx_t_3);
10805 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nNodes_elementBoundary);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 128, __pyx_L1_error)
10806 __Pyx_GOTREF(__pyx_t_4);
10815 __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nElementBoundaries_element);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 129, __pyx_L1_error)
10816 __Pyx_GOTREF(__pyx_t_5);
10825 __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nElementBoundaries_global);
if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 130, __pyx_L1_error)
10826 __Pyx_GOTREF(__pyx_t_6);
10835 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nInteriorElementBoundaries_globa);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 131, __pyx_L1_error)
10836 __Pyx_GOTREF(__pyx_t_7);
10845 __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nExteriorElementBoundaries_globa);
if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 132, __pyx_L1_error)
10846 __Pyx_GOTREF(__pyx_t_8);
10855 __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_max_nElements_node);
if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 133, __pyx_L1_error)
10856 __Pyx_GOTREF(__pyx_t_9);
10865 __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nEdges_global);
if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 134, __pyx_L1_error)
10866 __Pyx_GOTREF(__pyx_t_10);
10875 __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_max_nNodeNeighbors_node);
if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 135, __pyx_L1_error)
10876 __Pyx_GOTREF(__pyx_t_11);
10885 __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementNodesArray);
if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 136, __pyx_L1_error)
10886 __Pyx_GOTREF(__pyx_t_12);
10895 __pyx_t_13 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nodeElementsArray);
if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 137, __pyx_L1_error)
10896 __Pyx_GOTREF(__pyx_t_13);
10905 __pyx_t_14 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nodeElementOffsets);
if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 138, __pyx_L1_error)
10906 __Pyx_GOTREF(__pyx_t_14);
10915 __pyx_t_15 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementNeighborsArray);
if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 139, __pyx_L1_error)
10916 __Pyx_GOTREF(__pyx_t_15);
10925 __pyx_t_16 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementBoundariesArray);
if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 140, __pyx_L1_error)
10926 __Pyx_GOTREF(__pyx_t_16);
10935 __pyx_t_17 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementBoundaryNodesArray);
if (unlikely(!__pyx_t_17)) __PYX_ERR(1, 141, __pyx_L1_error)
10936 __Pyx_GOTREF(__pyx_t_17);
10945 __pyx_t_18 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementBoundaryElementsArray);
if (unlikely(!__pyx_t_18)) __PYX_ERR(1, 142, __pyx_L1_error)
10946 __Pyx_GOTREF(__pyx_t_18);
10955 __pyx_t_19 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementBoundaryLocalElementBound);
if (unlikely(!__pyx_t_19)) __PYX_ERR(1, 143, __pyx_L1_error)
10956 __Pyx_GOTREF(__pyx_t_19);
10965 __pyx_t_20 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_interiorElementBoundariesArray);
if (unlikely(!__pyx_t_20)) __PYX_ERR(1, 144, __pyx_L1_error)
10966 __Pyx_GOTREF(__pyx_t_20);
10975 __pyx_t_21 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_exteriorElementBoundariesArray);
if (unlikely(!__pyx_t_21)) __PYX_ERR(1, 145, __pyx_L1_error)
10976 __Pyx_GOTREF(__pyx_t_21);
10985 __pyx_t_22 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_edgeNodesArray);
if (unlikely(!__pyx_t_22)) __PYX_ERR(1, 146, __pyx_L1_error)
10986 __Pyx_GOTREF(__pyx_t_22);
10995 __pyx_t_23 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nodeStarArray);
if (unlikely(!__pyx_t_23)) __PYX_ERR(1, 147, __pyx_L1_error)
10996 __Pyx_GOTREF(__pyx_t_23);
11005 __pyx_t_24 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nodeStarOffsets);
if (unlikely(!__pyx_t_24)) __PYX_ERR(1, 148, __pyx_L1_error)
11006 __Pyx_GOTREF(__pyx_t_24);
11015 __pyx_t_25 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementMaterialTypes);
if (unlikely(!__pyx_t_25)) __PYX_ERR(1, 149, __pyx_L1_error)
11016 __Pyx_GOTREF(__pyx_t_25);
11025 __pyx_t_26 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementBoundaryMaterialTypes);
if (unlikely(!__pyx_t_26)) __PYX_ERR(1, 150, __pyx_L1_error)
11026 __Pyx_GOTREF(__pyx_t_26);
11035 __pyx_t_27 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nodeMaterialTypes);
if (unlikely(!__pyx_t_27)) __PYX_ERR(1, 151, __pyx_L1_error)
11036 __Pyx_GOTREF(__pyx_t_27);
11045 __pyx_t_28 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nodeArray);
if (unlikely(!__pyx_t_28)) __PYX_ERR(1, 152, __pyx_L1_error)
11046 __Pyx_GOTREF(__pyx_t_28);
11055 __pyx_t_29 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nx);
if (unlikely(!__pyx_t_29)) __PYX_ERR(1, 153, __pyx_L1_error)
11056 __Pyx_GOTREF(__pyx_t_29);
11065 __pyx_t_30 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_ny);
if (unlikely(!__pyx_t_30)) __PYX_ERR(1, 154, __pyx_L1_error)
11066 __Pyx_GOTREF(__pyx_t_30);
11075 __pyx_t_31 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nz);
if (unlikely(!__pyx_t_31)) __PYX_ERR(1, 155, __pyx_L1_error)
11076 __Pyx_GOTREF(__pyx_t_31);
11085 __pyx_t_32 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_px);
if (unlikely(!__pyx_t_32)) __PYX_ERR(1, 156, __pyx_L1_error)
11086 __Pyx_GOTREF(__pyx_t_32);
11095 __pyx_t_33 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_py);
if (unlikely(!__pyx_t_33)) __PYX_ERR(1, 157, __pyx_L1_error)
11096 __Pyx_GOTREF(__pyx_t_33);
11105 __pyx_t_34 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_pz);
if (unlikely(!__pyx_t_34)) __PYX_ERR(1, 158, __pyx_L1_error)
11106 __Pyx_GOTREF(__pyx_t_34);
11115 __pyx_t_35 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementIJK);
if (unlikely(!__pyx_t_35)) __PYX_ERR(1, 159, __pyx_L1_error)
11116 __Pyx_GOTREF(__pyx_t_35);
11125 __pyx_t_36 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_weights);
if (unlikely(!__pyx_t_36)) __PYX_ERR(1, 160, __pyx_L1_error)
11126 __Pyx_GOTREF(__pyx_t_36);
11135 __pyx_t_37 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_U_KNOT);
if (unlikely(!__pyx_t_37)) __PYX_ERR(1, 161, __pyx_L1_error)
11136 __Pyx_GOTREF(__pyx_t_37);
11145 __pyx_t_38 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_V_KNOT);
if (unlikely(!__pyx_t_38)) __PYX_ERR(1, 162, __pyx_L1_error)
11146 __Pyx_GOTREF(__pyx_t_38);
11155 __pyx_t_39 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_W_KNOT);
if (unlikely(!__pyx_t_39)) __PYX_ERR(1, 163, __pyx_L1_error)
11156 __Pyx_GOTREF(__pyx_t_39);
11165 __pyx_t_40 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementDiametersArray);
if (unlikely(!__pyx_t_40)) __PYX_ERR(1, 164, __pyx_L1_error)
11166 __Pyx_GOTREF(__pyx_t_40);
11175 __pyx_t_41 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementInnerDiametersArray);
if (unlikely(!__pyx_t_41)) __PYX_ERR(1, 165, __pyx_L1_error)
11176 __Pyx_GOTREF(__pyx_t_41);
11185 __pyx_t_42 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementBoundaryDiametersArray);
if (unlikely(!__pyx_t_42)) __PYX_ERR(1, 166, __pyx_L1_error)
11186 __Pyx_GOTREF(__pyx_t_42);
11195 __pyx_t_43 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementBarycentersArray);
if (unlikely(!__pyx_t_43)) __PYX_ERR(1, 167, __pyx_L1_error)
11196 __Pyx_GOTREF(__pyx_t_43);
11205 __pyx_t_44 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_elementBoundaryBarycentersArray);
if (unlikely(!__pyx_t_44)) __PYX_ERR(1, 168, __pyx_L1_error)
11206 __Pyx_GOTREF(__pyx_t_44);
11215 __pyx_t_45 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nodeDiametersArray);
if (unlikely(!__pyx_t_45)) __PYX_ERR(1, 169, __pyx_L1_error)
11216 __Pyx_GOTREF(__pyx_t_45);
11225 __pyx_t_46 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nodeSupportArray);
if (unlikely(!__pyx_t_46)) __PYX_ERR(1, 170, __pyx_L1_error)
11226 __Pyx_GOTREF(__pyx_t_46);
11235 __pyx_t_47 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_h);
if (unlikely(!__pyx_t_47)) __PYX_ERR(1, 171, __pyx_L1_error)
11236 __Pyx_GOTREF(__pyx_t_47);
11245 __pyx_t_48 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_hMin);
if (unlikely(!__pyx_t_48)) __PYX_ERR(1, 172, __pyx_L1_error)
11246 __Pyx_GOTREF(__pyx_t_48);
11255 __pyx_t_49 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_sigmaMax);
if (unlikely(!__pyx_t_49)) __PYX_ERR(1, 173, __pyx_L1_error)
11256 __Pyx_GOTREF(__pyx_t_49);
11265 __pyx_t_50 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_volume);
if (unlikely(!__pyx_t_50)) __PYX_ERR(1, 174, __pyx_L1_error)
11266 __Pyx_GOTREF(__pyx_t_50);
11275 __pyx_t_51 = PyTuple_New(50);
if (unlikely(!__pyx_t_51)) __PYX_ERR(1, 125, __pyx_L1_error)
11276 __Pyx_GOTREF(__pyx_t_51);
11277 __Pyx_GIVEREF(__pyx_t_1);
11278 PyTuple_SET_ITEM(__pyx_t_51, 0, __pyx_t_1);
11279 __Pyx_GIVEREF(__pyx_t_2);
11280 PyTuple_SET_ITEM(__pyx_t_51, 1, __pyx_t_2);
11281 __Pyx_GIVEREF(__pyx_t_3);
11282 PyTuple_SET_ITEM(__pyx_t_51, 2, __pyx_t_3);
11283 __Pyx_GIVEREF(__pyx_t_4);
11284 PyTuple_SET_ITEM(__pyx_t_51, 3, __pyx_t_4);
11285 __Pyx_GIVEREF(__pyx_t_5);
11286 PyTuple_SET_ITEM(__pyx_t_51, 4, __pyx_t_5);
11287 __Pyx_GIVEREF(__pyx_t_6);
11288 PyTuple_SET_ITEM(__pyx_t_51, 5, __pyx_t_6);
11289 __Pyx_GIVEREF(__pyx_t_7);
11290 PyTuple_SET_ITEM(__pyx_t_51, 6, __pyx_t_7);
11291 __Pyx_GIVEREF(__pyx_t_8);
11292 PyTuple_SET_ITEM(__pyx_t_51, 7, __pyx_t_8);
11293 __Pyx_GIVEREF(__pyx_t_9);
11294 PyTuple_SET_ITEM(__pyx_t_51, 8, __pyx_t_9);
11295 __Pyx_GIVEREF(__pyx_t_10);
11296 PyTuple_SET_ITEM(__pyx_t_51, 9, __pyx_t_10);
11297 __Pyx_GIVEREF(__pyx_t_11);
11298 PyTuple_SET_ITEM(__pyx_t_51, 10, __pyx_t_11);
11299 __Pyx_GIVEREF(__pyx_t_12);
11300 PyTuple_SET_ITEM(__pyx_t_51, 11, __pyx_t_12);
11301 __Pyx_GIVEREF(__pyx_t_13);
11302 PyTuple_SET_ITEM(__pyx_t_51, 12, __pyx_t_13);
11303 __Pyx_GIVEREF(__pyx_t_14);
11304 PyTuple_SET_ITEM(__pyx_t_51, 13, __pyx_t_14);
11305 __Pyx_GIVEREF(__pyx_t_15);
11306 PyTuple_SET_ITEM(__pyx_t_51, 14, __pyx_t_15);
11307 __Pyx_GIVEREF(__pyx_t_16);
11308 PyTuple_SET_ITEM(__pyx_t_51, 15, __pyx_t_16);
11309 __Pyx_GIVEREF(__pyx_t_17);
11310 PyTuple_SET_ITEM(__pyx_t_51, 16, __pyx_t_17);
11311 __Pyx_GIVEREF(__pyx_t_18);
11312 PyTuple_SET_ITEM(__pyx_t_51, 17, __pyx_t_18);
11313 __Pyx_GIVEREF(__pyx_t_19);
11314 PyTuple_SET_ITEM(__pyx_t_51, 18, __pyx_t_19);
11315 __Pyx_GIVEREF(__pyx_t_20);
11316 PyTuple_SET_ITEM(__pyx_t_51, 19, __pyx_t_20);
11317 __Pyx_GIVEREF(__pyx_t_21);
11318 PyTuple_SET_ITEM(__pyx_t_51, 20, __pyx_t_21);
11319 __Pyx_GIVEREF(__pyx_t_22);
11320 PyTuple_SET_ITEM(__pyx_t_51, 21, __pyx_t_22);
11321 __Pyx_GIVEREF(__pyx_t_23);
11322 PyTuple_SET_ITEM(__pyx_t_51, 22, __pyx_t_23);
11323 __Pyx_GIVEREF(__pyx_t_24);
11324 PyTuple_SET_ITEM(__pyx_t_51, 23, __pyx_t_24);
11325 __Pyx_GIVEREF(__pyx_t_25);
11326 PyTuple_SET_ITEM(__pyx_t_51, 24, __pyx_t_25);
11327 __Pyx_GIVEREF(__pyx_t_26);
11328 PyTuple_SET_ITEM(__pyx_t_51, 25, __pyx_t_26);
11329 __Pyx_GIVEREF(__pyx_t_27);
11330 PyTuple_SET_ITEM(__pyx_t_51, 26, __pyx_t_27);
11331 __Pyx_GIVEREF(__pyx_t_28);
11332 PyTuple_SET_ITEM(__pyx_t_51, 27, __pyx_t_28);
11333 __Pyx_GIVEREF(__pyx_t_29);
11334 PyTuple_SET_ITEM(__pyx_t_51, 28, __pyx_t_29);
11335 __Pyx_GIVEREF(__pyx_t_30);
11336 PyTuple_SET_ITEM(__pyx_t_51, 29, __pyx_t_30);
11337 __Pyx_GIVEREF(__pyx_t_31);
11338 PyTuple_SET_ITEM(__pyx_t_51, 30, __pyx_t_31);
11339 __Pyx_GIVEREF(__pyx_t_32);
11340 PyTuple_SET_ITEM(__pyx_t_51, 31, __pyx_t_32);
11341 __Pyx_GIVEREF(__pyx_t_33);
11342 PyTuple_SET_ITEM(__pyx_t_51, 32, __pyx_t_33);
11343 __Pyx_GIVEREF(__pyx_t_34);
11344 PyTuple_SET_ITEM(__pyx_t_51, 33, __pyx_t_34);
11345 __Pyx_GIVEREF(__pyx_t_35);
11346 PyTuple_SET_ITEM(__pyx_t_51, 34, __pyx_t_35);
11347 __Pyx_GIVEREF(__pyx_t_36);
11348 PyTuple_SET_ITEM(__pyx_t_51, 35, __pyx_t_36);
11349 __Pyx_GIVEREF(__pyx_t_37);
11350 PyTuple_SET_ITEM(__pyx_t_51, 36, __pyx_t_37);
11351 __Pyx_GIVEREF(__pyx_t_38);
11352 PyTuple_SET_ITEM(__pyx_t_51, 37, __pyx_t_38);
11353 __Pyx_GIVEREF(__pyx_t_39);
11354 PyTuple_SET_ITEM(__pyx_t_51, 38, __pyx_t_39);
11355 __Pyx_GIVEREF(__pyx_t_40);
11356 PyTuple_SET_ITEM(__pyx_t_51, 39, __pyx_t_40);
11357 __Pyx_GIVEREF(__pyx_t_41);
11358 PyTuple_SET_ITEM(__pyx_t_51, 40, __pyx_t_41);
11359 __Pyx_GIVEREF(__pyx_t_42);
11360 PyTuple_SET_ITEM(__pyx_t_51, 41, __pyx_t_42);
11361 __Pyx_GIVEREF(__pyx_t_43);
11362 PyTuple_SET_ITEM(__pyx_t_51, 42, __pyx_t_43);
11363 __Pyx_GIVEREF(__pyx_t_44);
11364 PyTuple_SET_ITEM(__pyx_t_51, 43, __pyx_t_44);
11365 __Pyx_GIVEREF(__pyx_t_45);
11366 PyTuple_SET_ITEM(__pyx_t_51, 44, __pyx_t_45);
11367 __Pyx_GIVEREF(__pyx_t_46);
11368 PyTuple_SET_ITEM(__pyx_t_51, 45, __pyx_t_46);
11369 __Pyx_GIVEREF(__pyx_t_47);
11370 PyTuple_SET_ITEM(__pyx_t_51, 46, __pyx_t_47);
11371 __Pyx_GIVEREF(__pyx_t_48);
11372 PyTuple_SET_ITEM(__pyx_t_51, 47, __pyx_t_48);
11373 __Pyx_GIVEREF(__pyx_t_49);
11374 PyTuple_SET_ITEM(__pyx_t_51, 48, __pyx_t_49);
11375 __Pyx_GIVEREF(__pyx_t_50);
11376 PyTuple_SET_ITEM(__pyx_t_51, 49, __pyx_t_50);
11427 __pyx_r = __pyx_t_51;
11441 __Pyx_XDECREF(__pyx_t_1);
11442 __Pyx_XDECREF(__pyx_t_2);
11443 __Pyx_XDECREF(__pyx_t_3);
11444 __Pyx_XDECREF(__pyx_t_4);
11445 __Pyx_XDECREF(__pyx_t_5);
11446 __Pyx_XDECREF(__pyx_t_6);
11447 __Pyx_XDECREF(__pyx_t_7);
11448 __Pyx_XDECREF(__pyx_t_8);
11449 __Pyx_XDECREF(__pyx_t_9);
11450 __Pyx_XDECREF(__pyx_t_10);
11451 __Pyx_XDECREF(__pyx_t_11);
11452 __Pyx_XDECREF(__pyx_t_12);
11453 __Pyx_XDECREF(__pyx_t_13);
11454 __Pyx_XDECREF(__pyx_t_14);
11455 __Pyx_XDECREF(__pyx_t_15);
11456 __Pyx_XDECREF(__pyx_t_16);
11457 __Pyx_XDECREF(__pyx_t_17);
11458 __Pyx_XDECREF(__pyx_t_18);
11459 __Pyx_XDECREF(__pyx_t_19);
11460 __Pyx_XDECREF(__pyx_t_20);
11461 __Pyx_XDECREF(__pyx_t_21);
11462 __Pyx_XDECREF(__pyx_t_22);
11463 __Pyx_XDECREF(__pyx_t_23);
11464 __Pyx_XDECREF(__pyx_t_24);
11465 __Pyx_XDECREF(__pyx_t_25);
11466 __Pyx_XDECREF(__pyx_t_26);
11467 __Pyx_XDECREF(__pyx_t_27);
11468 __Pyx_XDECREF(__pyx_t_28);
11469 __Pyx_XDECREF(__pyx_t_29);
11470 __Pyx_XDECREF(__pyx_t_30);
11471 __Pyx_XDECREF(__pyx_t_31);
11472 __Pyx_XDECREF(__pyx_t_32);
11473 __Pyx_XDECREF(__pyx_t_33);
11474 __Pyx_XDECREF(__pyx_t_34);
11475 __Pyx_XDECREF(__pyx_t_35);
11476 __Pyx_XDECREF(__pyx_t_36);
11477 __Pyx_XDECREF(__pyx_t_37);
11478 __Pyx_XDECREF(__pyx_t_38);
11479 __Pyx_XDECREF(__pyx_t_39);
11480 __Pyx_XDECREF(__pyx_t_40);
11481 __Pyx_XDECREF(__pyx_t_41);
11482 __Pyx_XDECREF(__pyx_t_42);
11483 __Pyx_XDECREF(__pyx_t_43);
11484 __Pyx_XDECREF(__pyx_t_44);
11485 __Pyx_XDECREF(__pyx_t_45);
11486 __Pyx_XDECREF(__pyx_t_46);
11487 __Pyx_XDECREF(__pyx_t_47);
11488 __Pyx_XDECREF(__pyx_t_48);
11489 __Pyx_XDECREF(__pyx_t_49);
11490 __Pyx_XDECREF(__pyx_t_50);
11491 __Pyx_XDECREF(__pyx_t_51);
11492 __Pyx_AddTraceback(
"cmeshTools.buildPythonMeshInterface", __pyx_clineno, __pyx_lineno, __pyx_filename);
11495 __Pyx_XGIVEREF(__pyx_r);
11496 __Pyx_RefNannyFinishContext();
11509 static PyObject *__pyx_pw_10cmeshTools_3buildPythonMeshInterfaceNoArrays(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
11510 static char __pyx_doc_10cmeshTools_2buildPythonMeshInterfaceNoArrays[] =
"\n function to be conform to old module, and to calls from MeshTools\n ";
11511 static PyMethodDef __pyx_mdef_10cmeshTools_3buildPythonMeshInterfaceNoArrays = {
"buildPythonMeshInterfaceNoArrays", (PyCFunction)__pyx_pw_10cmeshTools_3buildPythonMeshInterfaceNoArrays, METH_O, __pyx_doc_10cmeshTools_2buildPythonMeshInterfaceNoArrays};
11512 static PyObject *__pyx_pw_10cmeshTools_3buildPythonMeshInterfaceNoArrays(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
11513 PyObject *__pyx_r = 0;
11514 __Pyx_RefNannyDeclarations
11515 __Pyx_RefNannySetupContext(
"buildPythonMeshInterfaceNoArrays (wrapper)", 0);
11516 __pyx_r = __pyx_pf_10cmeshTools_2buildPythonMeshInterfaceNoArrays(__pyx_self, ((PyObject *)__pyx_v_cmesh));
11519 __Pyx_RefNannyFinishContext();
11523 static PyObject *__pyx_pf_10cmeshTools_2buildPythonMeshInterfaceNoArrays(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
11524 PyObject *__pyx_r = NULL;
11525 __Pyx_RefNannyDeclarations
11526 PyObject *__pyx_t_1 = NULL;
11527 PyObject *__pyx_t_2 = NULL;
11528 PyObject *__pyx_t_3 = NULL;
11529 PyObject *__pyx_t_4 = NULL;
11530 PyObject *__pyx_t_5 = NULL;
11531 PyObject *__pyx_t_6 = NULL;
11532 PyObject *__pyx_t_7 = NULL;
11533 PyObject *__pyx_t_8 = NULL;
11534 PyObject *__pyx_t_9 = NULL;
11535 PyObject *__pyx_t_10 = NULL;
11536 PyObject *__pyx_t_11 = NULL;
11537 PyObject *__pyx_t_12 = NULL;
11538 PyObject *__pyx_t_13 = NULL;
11539 PyObject *__pyx_t_14 = NULL;
11540 PyObject *__pyx_t_15 = NULL;
11541 PyObject *__pyx_t_16 = NULL;
11542 int __pyx_lineno = 0;
11543 const char *__pyx_filename = NULL;
11544 int __pyx_clineno = 0;
11545 __Pyx_RefNannySetupContext(
"buildPythonMeshInterfaceNoArrays", 0);
11554 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_buildPythonMeshInterfaceNoArrays);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 180, __pyx_L1_error)
11555 __Pyx_GOTREF(__pyx_t_2);
11557 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
11558 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
11559 if (likely(__pyx_t_3)) {
11560 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
11561 __Pyx_INCREF(__pyx_t_3);
11562 __Pyx_INCREF(
function);
11563 __Pyx_DECREF_SET(__pyx_t_2,
function);
11566 __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2);
11567 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
11568 if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 180, __pyx_L1_error)
11569 __Pyx_GOTREF(__pyx_t_1);
11570 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
11571 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
11580 __Pyx_XDECREF(__pyx_r);
11581 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nElements_global);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 181, __pyx_L1_error)
11582 __Pyx_GOTREF(__pyx_t_1);
11591 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nNodes_global);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 182, __pyx_L1_error)
11592 __Pyx_GOTREF(__pyx_t_2);
11601 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nNodes_element);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 183, __pyx_L1_error)
11602 __Pyx_GOTREF(__pyx_t_3);
11611 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nNodes_elementBoundary);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 184, __pyx_L1_error)
11612 __Pyx_GOTREF(__pyx_t_4);
11621 __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nElementBoundaries_element);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 185, __pyx_L1_error)
11622 __Pyx_GOTREF(__pyx_t_5);
11631 __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nElementBoundaries_global);
if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 186, __pyx_L1_error)
11632 __Pyx_GOTREF(__pyx_t_6);
11641 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nInteriorElementBoundaries_globa);
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 187, __pyx_L1_error)
11642 __Pyx_GOTREF(__pyx_t_7);
11651 __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nExteriorElementBoundaries_globa);
if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 188, __pyx_L1_error)
11652 __Pyx_GOTREF(__pyx_t_8);
11661 __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_max_nElements_node);
if (unlikely(!__pyx_t_9)) __PYX_ERR(1, 189, __pyx_L1_error)
11662 __Pyx_GOTREF(__pyx_t_9);
11671 __pyx_t_10 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_nEdges_global);
if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 190, __pyx_L1_error)
11672 __Pyx_GOTREF(__pyx_t_10);
11681 __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_max_nNodeNeighbors_node);
if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 191, __pyx_L1_error)
11682 __Pyx_GOTREF(__pyx_t_11);
11691 __pyx_t_12 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_h);
if (unlikely(!__pyx_t_12)) __PYX_ERR(1, 192, __pyx_L1_error)
11692 __Pyx_GOTREF(__pyx_t_12);
11701 __pyx_t_13 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_hMin);
if (unlikely(!__pyx_t_13)) __PYX_ERR(1, 193, __pyx_L1_error)
11702 __Pyx_GOTREF(__pyx_t_13);
11711 __pyx_t_14 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_sigmaMax);
if (unlikely(!__pyx_t_14)) __PYX_ERR(1, 194, __pyx_L1_error)
11712 __Pyx_GOTREF(__pyx_t_14);
11721 __pyx_t_15 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmesh, __pyx_n_s_volume);
if (unlikely(!__pyx_t_15)) __PYX_ERR(1, 195, __pyx_L1_error)
11722 __Pyx_GOTREF(__pyx_t_15);
11731 __pyx_t_16 = PyTuple_New(15);
if (unlikely(!__pyx_t_16)) __PYX_ERR(1, 181, __pyx_L1_error)
11732 __Pyx_GOTREF(__pyx_t_16);
11733 __Pyx_GIVEREF(__pyx_t_1);
11734 PyTuple_SET_ITEM(__pyx_t_16, 0, __pyx_t_1);
11735 __Pyx_GIVEREF(__pyx_t_2);
11736 PyTuple_SET_ITEM(__pyx_t_16, 1, __pyx_t_2);
11737 __Pyx_GIVEREF(__pyx_t_3);
11738 PyTuple_SET_ITEM(__pyx_t_16, 2, __pyx_t_3);
11739 __Pyx_GIVEREF(__pyx_t_4);
11740 PyTuple_SET_ITEM(__pyx_t_16, 3, __pyx_t_4);
11741 __Pyx_GIVEREF(__pyx_t_5);
11742 PyTuple_SET_ITEM(__pyx_t_16, 4, __pyx_t_5);
11743 __Pyx_GIVEREF(__pyx_t_6);
11744 PyTuple_SET_ITEM(__pyx_t_16, 5, __pyx_t_6);
11745 __Pyx_GIVEREF(__pyx_t_7);
11746 PyTuple_SET_ITEM(__pyx_t_16, 6, __pyx_t_7);
11747 __Pyx_GIVEREF(__pyx_t_8);
11748 PyTuple_SET_ITEM(__pyx_t_16, 7, __pyx_t_8);
11749 __Pyx_GIVEREF(__pyx_t_9);
11750 PyTuple_SET_ITEM(__pyx_t_16, 8, __pyx_t_9);
11751 __Pyx_GIVEREF(__pyx_t_10);
11752 PyTuple_SET_ITEM(__pyx_t_16, 9, __pyx_t_10);
11753 __Pyx_GIVEREF(__pyx_t_11);
11754 PyTuple_SET_ITEM(__pyx_t_16, 10, __pyx_t_11);
11755 __Pyx_GIVEREF(__pyx_t_12);
11756 PyTuple_SET_ITEM(__pyx_t_16, 11, __pyx_t_12);
11757 __Pyx_GIVEREF(__pyx_t_13);
11758 PyTuple_SET_ITEM(__pyx_t_16, 12, __pyx_t_13);
11759 __Pyx_GIVEREF(__pyx_t_14);
11760 PyTuple_SET_ITEM(__pyx_t_16, 13, __pyx_t_14);
11761 __Pyx_GIVEREF(__pyx_t_15);
11762 PyTuple_SET_ITEM(__pyx_t_16, 14, __pyx_t_15);
11778 __pyx_r = __pyx_t_16;
11792 __Pyx_XDECREF(__pyx_t_1);
11793 __Pyx_XDECREF(__pyx_t_2);
11794 __Pyx_XDECREF(__pyx_t_3);
11795 __Pyx_XDECREF(__pyx_t_4);
11796 __Pyx_XDECREF(__pyx_t_5);
11797 __Pyx_XDECREF(__pyx_t_6);
11798 __Pyx_XDECREF(__pyx_t_7);
11799 __Pyx_XDECREF(__pyx_t_8);
11800 __Pyx_XDECREF(__pyx_t_9);
11801 __Pyx_XDECREF(__pyx_t_10);
11802 __Pyx_XDECREF(__pyx_t_11);
11803 __Pyx_XDECREF(__pyx_t_12);
11804 __Pyx_XDECREF(__pyx_t_13);
11805 __Pyx_XDECREF(__pyx_t_14);
11806 __Pyx_XDECREF(__pyx_t_15);
11807 __Pyx_XDECREF(__pyx_t_16);
11808 __Pyx_AddTraceback(
"cmeshTools.buildPythonMeshInterfaceNoArrays", __pyx_clineno, __pyx_lineno, __pyx_filename);
11811 __Pyx_XGIVEREF(__pyx_r);
11812 __Pyx_RefNannyFinishContext();
11824 static struct __pyx_obj_10cmeshTools_CMesh *__pyx_f_10cmeshTools_CMesh_FromMesh(
struct Mesh __pyx_v_mesh) {
11825 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_CMeshnew = NULL;
11826 struct __pyx_obj_10cmeshTools_CMesh *__pyx_r = NULL;
11827 __Pyx_RefNannyDeclarations
11828 PyObject *__pyx_t_1 = NULL;
11829 int __pyx_lineno = 0;
11830 const char *__pyx_filename = NULL;
11831 int __pyx_clineno = 0;
11832 __Pyx_RefNannySetupContext(
"CMesh_FromMesh", 0);
11841 __pyx_t_1 = __Pyx_PyObject_CallNoArg(((PyObject *)__pyx_ptype_10cmeshTools_CMesh));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 198, __pyx_L1_error)
11842 __Pyx_GOTREF(__pyx_t_1);
11843 __pyx_v_CMeshnew = ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_t_1);
11853 __pyx_v_CMeshnew->mesh = __pyx_v_mesh;
11862 __Pyx_XDECREF(((PyObject *)__pyx_r));
11863 __Pyx_INCREF(((PyObject *)__pyx_v_CMeshnew));
11864 __pyx_r = __pyx_v_CMeshnew;
11877 __Pyx_XDECREF(__pyx_t_1);
11878 __Pyx_AddTraceback(
"cmeshTools.CMesh_FromMesh", __pyx_clineno, __pyx_lineno, __pyx_filename);
11881 __Pyx_XDECREF((PyObject *)__pyx_v_CMeshnew);
11882 __Pyx_XGIVEREF((PyObject *)__pyx_r);
11883 __Pyx_RefNannyFinishContext();
11896 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
11897 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
11898 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
11899 PyObject *__pyx_v_nLevels = 0;
11900 int __pyx_lineno = 0;
11901 const char *__pyx_filename = NULL;
11902 int __pyx_clineno = 0;
11904 __Pyx_RefNannyDeclarations
11905 __Pyx_RefNannySetupContext(
"__init__ (wrapper)", 0);
11907 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_nLevels,0};
11908 PyObject* values[2] = {0,0};
11909 if (unlikely(__pyx_kwds)) {
11910 Py_ssize_t kw_args;
11911 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
11912 switch (pos_args) {
11913 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11914 CYTHON_FALLTHROUGH;
11915 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11916 CYTHON_FALLTHROUGH;
11918 default:
goto __pyx_L5_argtuple_error;
11920 kw_args = PyDict_Size(__pyx_kwds);
11921 switch (pos_args) {
11923 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
11924 else goto __pyx_L5_argtuple_error;
11925 CYTHON_FALLTHROUGH;
11927 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nLevels)) != 0)) kw_args--;
11929 __Pyx_RaiseArgtupleInvalid(
"__init__", 1, 2, 2, 1); __PYX_ERR(1, 210, __pyx_L3_error)
11932 if (unlikely(kw_args > 0)) {
11933 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"__init__") < 0)) __PYX_ERR(1, 210, __pyx_L3_error)
11935 }
else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
11936 goto __pyx_L5_argtuple_error;
11938 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
11939 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
11941 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
11942 __pyx_v_nLevels = values[1];
11944 goto __pyx_L4_argument_unpacking_done;
11945 __pyx_L5_argtuple_error:;
11946 __Pyx_RaiseArgtupleInvalid(
"__init__", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 210, __pyx_L3_error)
11948 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
11949 __Pyx_RefNannyFinishContext();
11951 __pyx_L4_argument_unpacking_done:;
11952 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 210, __pyx_L1_error)
11953 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh___init__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self), __pyx_v_cmesh, __pyx_v_nLevels);
11960 __Pyx_RefNannyFinishContext();
11964 static int __pyx_pf_10cmeshTools_15CMultilevelMesh___init__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_nLevels) {
11965 PyObject *__pyx_v_i = NULL;
11967 __Pyx_RefNannyDeclarations
11971 PyObject *__pyx_t_4 = NULL;
11972 PyObject *__pyx_t_5 = NULL;
11973 Py_ssize_t __pyx_t_6;
11974 PyObject *(*__pyx_t_7)(PyObject *);
11975 Py_ssize_t __pyx_t_8;
11976 Py_ssize_t __pyx_t_9;
11977 Py_ssize_t __pyx_t_10;
11979 int __pyx_lineno = 0;
11980 const char *__pyx_filename = NULL;
11981 int __pyx_clineno = 0;
11982 __Pyx_RefNannySetupContext(
"__init__", 0);
11991 __pyx_v_self->multilevelMesh = __pyx_t_1;
12000 __pyx_t_2 = ((__pyx_v_cmesh->mesh.nNodes_element == 2) != 0);
12010 __pyx_t_3 = __Pyx_PyInt_As_int(__pyx_v_nLevels);
if (unlikely((__pyx_t_3 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 213, __pyx_L1_error)
12028 __pyx_t_4 = PyTuple_New(2);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 217, __pyx_L1_error)
12029 __Pyx_GOTREF(__pyx_t_4);
12030 __Pyx_INCREF(__pyx_int_1);
12031 __Pyx_GIVEREF(__pyx_int_1);
12032 PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_int_1);
12033 __Pyx_INCREF(__pyx_v_nLevels);
12034 __Pyx_GIVEREF(__pyx_v_nLevels);
12035 PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_nLevels);
12036 __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_range, __pyx_t_4, NULL);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 217, __pyx_L1_error)
12037 __Pyx_GOTREF(__pyx_t_5);
12038 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12039 if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) {
12040 __pyx_t_4 = __pyx_t_5; __Pyx_INCREF(__pyx_t_4); __pyx_t_6 = 0;
12043 __pyx_t_6 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_t_5);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 217, __pyx_L1_error)
12044 __Pyx_GOTREF(__pyx_t_4);
12045 __pyx_t_7 = Py_TYPE(__pyx_t_4)->tp_iternext;
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 217, __pyx_L1_error)
12047 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12049 if (likely(!__pyx_t_7)) {
12050 if (likely(PyList_CheckExact(__pyx_t_4))) {
12051 if (__pyx_t_6 >= PyList_GET_SIZE(__pyx_t_4))
break;
12052 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12053 __pyx_t_5 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 217, __pyx_L1_error)
12055 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 217, __pyx_L1_error)
12056 __Pyx_GOTREF(__pyx_t_5);
12059 if (__pyx_t_6 >= PyTuple_GET_SIZE(__pyx_t_4))
break;
12060 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12061 __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 217, __pyx_L1_error)
12063 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 217, __pyx_L1_error)
12064 __Pyx_GOTREF(__pyx_t_5);
12068 __pyx_t_5 = __pyx_t_7(__pyx_t_4);
12069 if (unlikely(!__pyx_t_5)) {
12070 PyObject* exc_type = PyErr_Occurred();
12072 if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
12073 else __PYX_ERR(1, 217, __pyx_L1_error)
12077 __Pyx_GOTREF(__pyx_t_5);
12079 __Pyx_XDECREF_SET(__pyx_v_i, __pyx_t_5);
12089 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 218, __pyx_L1_error)
12099 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 219, __pyx_L1_error)
12109 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 220, __pyx_L1_error)
12119 __pyx_t_5 = __Pyx_PyInt_SubtractObjC(__pyx_v_i, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 221, __pyx_L1_error)
12120 __Pyx_GOTREF(__pyx_t_5);
12121 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_t_5);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 221, __pyx_L1_error)
12122 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12131 __pyx_t_9 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_9 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 222, __pyx_L1_error)
12140 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 223, __pyx_L1_error)
12149 (void)(
assignElementBoundaryMaterialTypesFromParent((__pyx_v_self->multilevelMesh.meshArray[__pyx_t_8]), (__pyx_v_self->multilevelMesh.meshArray[__pyx_t_9]), (__pyx_v_self->multilevelMesh.elementParentsArray[__pyx_t_10]), 1));
12159 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12178 __pyx_t_2 = ((__pyx_v_cmesh->mesh.nNodes_element == 3) != 0);
12188 __pyx_t_3 = __Pyx_PyInt_As_int(__pyx_v_nLevels);
if (unlikely((__pyx_t_3 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 226, __pyx_L1_error)
12206 __pyx_t_4 = PyTuple_New(2);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 230, __pyx_L1_error)
12207 __Pyx_GOTREF(__pyx_t_4);
12208 __Pyx_INCREF(__pyx_int_1);
12209 __Pyx_GIVEREF(__pyx_int_1);
12210 PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_int_1);
12211 __Pyx_INCREF(__pyx_v_nLevels);
12212 __Pyx_GIVEREF(__pyx_v_nLevels);
12213 PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_nLevels);
12214 __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_range, __pyx_t_4, NULL);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 230, __pyx_L1_error)
12215 __Pyx_GOTREF(__pyx_t_5);
12216 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12217 if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) {
12218 __pyx_t_4 = __pyx_t_5; __Pyx_INCREF(__pyx_t_4); __pyx_t_6 = 0;
12221 __pyx_t_6 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_t_5);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 230, __pyx_L1_error)
12222 __Pyx_GOTREF(__pyx_t_4);
12223 __pyx_t_7 = Py_TYPE(__pyx_t_4)->tp_iternext;
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 230, __pyx_L1_error)
12225 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12227 if (likely(!__pyx_t_7)) {
12228 if (likely(PyList_CheckExact(__pyx_t_4))) {
12229 if (__pyx_t_6 >= PyList_GET_SIZE(__pyx_t_4))
break;
12230 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12231 __pyx_t_5 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 230, __pyx_L1_error)
12233 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 230, __pyx_L1_error)
12234 __Pyx_GOTREF(__pyx_t_5);
12237 if (__pyx_t_6 >= PyTuple_GET_SIZE(__pyx_t_4))
break;
12238 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12239 __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 230, __pyx_L1_error)
12241 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 230, __pyx_L1_error)
12242 __Pyx_GOTREF(__pyx_t_5);
12246 __pyx_t_5 = __pyx_t_7(__pyx_t_4);
12247 if (unlikely(!__pyx_t_5)) {
12248 PyObject* exc_type = PyErr_Occurred();
12250 if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
12251 else __PYX_ERR(1, 230, __pyx_L1_error)
12255 __Pyx_GOTREF(__pyx_t_5);
12257 __Pyx_XDECREF_SET(__pyx_v_i, __pyx_t_5);
12267 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 231, __pyx_L1_error)
12277 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 232, __pyx_L1_error)
12287 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 233, __pyx_L1_error)
12297 __pyx_t_5 = __Pyx_PyInt_SubtractObjC(__pyx_v_i, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 234, __pyx_L1_error)
12298 __Pyx_GOTREF(__pyx_t_5);
12299 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_t_5);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 234, __pyx_L1_error)
12300 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12309 __pyx_t_9 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_9 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 235, __pyx_L1_error)
12318 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 236, __pyx_L1_error)
12327 (void)(
assignElementBoundaryMaterialTypesFromParent((__pyx_v_self->multilevelMesh.meshArray[__pyx_t_10]), (__pyx_v_self->multilevelMesh.meshArray[__pyx_t_9]), (__pyx_v_self->multilevelMesh.elementParentsArray[__pyx_t_8]), 2));
12337 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12356 __pyx_t_11 = ((__pyx_v_cmesh->mesh.nNodes_element == 4) != 0);
12359 __pyx_t_2 = __pyx_t_11;
12360 goto __pyx_L8_bool_binop_done;
12362 __pyx_t_11 = ((__pyx_v_cmesh->mesh.nNodes_elementBoundary == 2) != 0);
12363 __pyx_t_2 = __pyx_t_11;
12364 __pyx_L8_bool_binop_done:;
12374 __pyx_t_3 = __Pyx_PyInt_As_int(__pyx_v_nLevels);
if (unlikely((__pyx_t_3 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 239, __pyx_L1_error)
12392 __pyx_t_4 = PyTuple_New(2);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 243, __pyx_L1_error)
12393 __Pyx_GOTREF(__pyx_t_4);
12394 __Pyx_INCREF(__pyx_int_1);
12395 __Pyx_GIVEREF(__pyx_int_1);
12396 PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_int_1);
12397 __Pyx_INCREF(__pyx_v_nLevels);
12398 __Pyx_GIVEREF(__pyx_v_nLevels);
12399 PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_nLevels);
12400 __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_range, __pyx_t_4, NULL);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 243, __pyx_L1_error)
12401 __Pyx_GOTREF(__pyx_t_5);
12402 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12403 if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) {
12404 __pyx_t_4 = __pyx_t_5; __Pyx_INCREF(__pyx_t_4); __pyx_t_6 = 0;
12407 __pyx_t_6 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_t_5);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 243, __pyx_L1_error)
12408 __Pyx_GOTREF(__pyx_t_4);
12409 __pyx_t_7 = Py_TYPE(__pyx_t_4)->tp_iternext;
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 243, __pyx_L1_error)
12411 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12413 if (likely(!__pyx_t_7)) {
12414 if (likely(PyList_CheckExact(__pyx_t_4))) {
12415 if (__pyx_t_6 >= PyList_GET_SIZE(__pyx_t_4))
break;
12416 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12417 __pyx_t_5 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 243, __pyx_L1_error)
12419 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 243, __pyx_L1_error)
12420 __Pyx_GOTREF(__pyx_t_5);
12423 if (__pyx_t_6 >= PyTuple_GET_SIZE(__pyx_t_4))
break;
12424 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12425 __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 243, __pyx_L1_error)
12427 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 243, __pyx_L1_error)
12428 __Pyx_GOTREF(__pyx_t_5);
12432 __pyx_t_5 = __pyx_t_7(__pyx_t_4);
12433 if (unlikely(!__pyx_t_5)) {
12434 PyObject* exc_type = PyErr_Occurred();
12436 if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
12437 else __PYX_ERR(1, 243, __pyx_L1_error)
12441 __Pyx_GOTREF(__pyx_t_5);
12443 __Pyx_XDECREF_SET(__pyx_v_i, __pyx_t_5);
12453 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 244, __pyx_L1_error)
12463 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 245, __pyx_L1_error)
12473 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 246, __pyx_L1_error)
12483 __pyx_t_5 = __Pyx_PyInt_SubtractObjC(__pyx_v_i, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 247, __pyx_L1_error)
12484 __Pyx_GOTREF(__pyx_t_5);
12485 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_t_5);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 247, __pyx_L1_error)
12486 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12495 __pyx_t_9 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_9 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 248, __pyx_L1_error)
12504 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 249, __pyx_L1_error)
12513 (void)(
assignElementBoundaryMaterialTypesFromParent((__pyx_v_self->multilevelMesh.meshArray[__pyx_t_8]), (__pyx_v_self->multilevelMesh.meshArray[__pyx_t_9]), (__pyx_v_self->multilevelMesh.elementParentsArray[__pyx_t_10]), 2));
12523 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12542 __pyx_t_11 = ((__pyx_v_cmesh->mesh.nNodes_element == 4) != 0);
12545 __pyx_t_2 = __pyx_t_11;
12546 goto __pyx_L12_bool_binop_done;
12548 __pyx_t_11 = ((__pyx_v_cmesh->mesh.nNodes_elementBoundary == 3) != 0);
12549 __pyx_t_2 = __pyx_t_11;
12550 __pyx_L12_bool_binop_done:;
12560 __pyx_t_3 = __Pyx_PyInt_As_int(__pyx_v_nLevels);
if (unlikely((__pyx_t_3 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 252, __pyx_L1_error)
12578 __pyx_t_4 = PyTuple_New(2);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 256, __pyx_L1_error)
12579 __Pyx_GOTREF(__pyx_t_4);
12580 __Pyx_INCREF(__pyx_int_1);
12581 __Pyx_GIVEREF(__pyx_int_1);
12582 PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_int_1);
12583 __Pyx_INCREF(__pyx_v_nLevels);
12584 __Pyx_GIVEREF(__pyx_v_nLevels);
12585 PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_nLevels);
12586 __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_range, __pyx_t_4, NULL);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 256, __pyx_L1_error)
12587 __Pyx_GOTREF(__pyx_t_5);
12588 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12589 if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) {
12590 __pyx_t_4 = __pyx_t_5; __Pyx_INCREF(__pyx_t_4); __pyx_t_6 = 0;
12593 __pyx_t_6 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_t_5);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 256, __pyx_L1_error)
12594 __Pyx_GOTREF(__pyx_t_4);
12595 __pyx_t_7 = Py_TYPE(__pyx_t_4)->tp_iternext;
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 256, __pyx_L1_error)
12597 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12599 if (likely(!__pyx_t_7)) {
12600 if (likely(PyList_CheckExact(__pyx_t_4))) {
12601 if (__pyx_t_6 >= PyList_GET_SIZE(__pyx_t_4))
break;
12602 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12603 __pyx_t_5 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 256, __pyx_L1_error)
12605 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 256, __pyx_L1_error)
12606 __Pyx_GOTREF(__pyx_t_5);
12609 if (__pyx_t_6 >= PyTuple_GET_SIZE(__pyx_t_4))
break;
12610 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12611 __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 256, __pyx_L1_error)
12613 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 256, __pyx_L1_error)
12614 __Pyx_GOTREF(__pyx_t_5);
12618 __pyx_t_5 = __pyx_t_7(__pyx_t_4);
12619 if (unlikely(!__pyx_t_5)) {
12620 PyObject* exc_type = PyErr_Occurred();
12622 if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
12623 else __PYX_ERR(1, 256, __pyx_L1_error)
12627 __Pyx_GOTREF(__pyx_t_5);
12629 __Pyx_XDECREF_SET(__pyx_v_i, __pyx_t_5);
12639 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 257, __pyx_L1_error)
12649 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 258, __pyx_L1_error)
12659 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 259, __pyx_L1_error)
12669 __pyx_t_5 = __Pyx_PyInt_SubtractObjC(__pyx_v_i, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 260, __pyx_L1_error)
12670 __Pyx_GOTREF(__pyx_t_5);
12671 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_t_5);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 260, __pyx_L1_error)
12672 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12681 __pyx_t_9 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_9 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 261, __pyx_L1_error)
12690 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 262, __pyx_L1_error)
12699 (void)(
assignElementBoundaryMaterialTypesFromParent((__pyx_v_self->multilevelMesh.meshArray[__pyx_t_10]), (__pyx_v_self->multilevelMesh.meshArray[__pyx_t_9]), (__pyx_v_self->multilevelMesh.elementParentsArray[__pyx_t_8]), 3));
12709 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12728 __pyx_t_11 = ((__pyx_v_cmesh->mesh.nNodes_element == 8) != 0);
12731 __pyx_t_2 = __pyx_t_11;
12732 goto __pyx_L16_bool_binop_done;
12734 __pyx_t_11 = ((__pyx_v_cmesh->mesh.nNodes_elementBoundary == 4) != 0);
12735 __pyx_t_2 = __pyx_t_11;
12736 __pyx_L16_bool_binop_done:;
12746 __pyx_t_3 = __Pyx_PyInt_As_int(__pyx_v_nLevels);
if (unlikely((__pyx_t_3 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 265, __pyx_L1_error)
12764 __pyx_t_4 = PyTuple_New(2);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 269, __pyx_L1_error)
12765 __Pyx_GOTREF(__pyx_t_4);
12766 __Pyx_INCREF(__pyx_int_1);
12767 __Pyx_GIVEREF(__pyx_int_1);
12768 PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_int_1);
12769 __Pyx_INCREF(__pyx_v_nLevels);
12770 __Pyx_GIVEREF(__pyx_v_nLevels);
12771 PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_nLevels);
12772 __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_range, __pyx_t_4, NULL);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 269, __pyx_L1_error)
12773 __Pyx_GOTREF(__pyx_t_5);
12774 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12775 if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) {
12776 __pyx_t_4 = __pyx_t_5; __Pyx_INCREF(__pyx_t_4); __pyx_t_6 = 0;
12779 __pyx_t_6 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_t_5);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 269, __pyx_L1_error)
12780 __Pyx_GOTREF(__pyx_t_4);
12781 __pyx_t_7 = Py_TYPE(__pyx_t_4)->tp_iternext;
if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 269, __pyx_L1_error)
12783 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12785 if (likely(!__pyx_t_7)) {
12786 if (likely(PyList_CheckExact(__pyx_t_4))) {
12787 if (__pyx_t_6 >= PyList_GET_SIZE(__pyx_t_4))
break;
12788 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12789 __pyx_t_5 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 269, __pyx_L1_error)
12791 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 269, __pyx_L1_error)
12792 __Pyx_GOTREF(__pyx_t_5);
12795 if (__pyx_t_6 >= PyTuple_GET_SIZE(__pyx_t_4))
break;
12796 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
12797 __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_5); __pyx_t_6++;
if (unlikely(0 < 0)) __PYX_ERR(1, 269, __pyx_L1_error)
12799 __pyx_t_5 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 269, __pyx_L1_error)
12800 __Pyx_GOTREF(__pyx_t_5);
12804 __pyx_t_5 = __pyx_t_7(__pyx_t_4);
12805 if (unlikely(!__pyx_t_5)) {
12806 PyObject* exc_type = PyErr_Occurred();
12808 if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
12809 else __PYX_ERR(1, 269, __pyx_L1_error)
12813 __Pyx_GOTREF(__pyx_t_5);
12815 __Pyx_XDECREF_SET(__pyx_v_i, __pyx_t_5);
12825 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 271, __pyx_L1_error)
12843 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 272, __pyx_L1_error)
12853 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 273, __pyx_L1_error)
12863 __pyx_t_5 = __Pyx_PyInt_SubtractObjC(__pyx_v_i, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 274, __pyx_L1_error)
12864 __Pyx_GOTREF(__pyx_t_5);
12865 __pyx_t_8 = __Pyx_PyIndex_AsSsize_t(__pyx_t_5);
if (unlikely((__pyx_t_8 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 274, __pyx_L1_error)
12866 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
12875 __pyx_t_9 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_9 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 275, __pyx_L1_error)
12884 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 276, __pyx_L1_error)
12893 (void)(
assignElementBoundaryMaterialTypesFromParent((__pyx_v_self->multilevelMesh.meshArray[__pyx_t_8]), (__pyx_v_self->multilevelMesh.meshArray[__pyx_t_9]), (__pyx_v_self->multilevelMesh.elementParentsArray[__pyx_t_10]), 4));
12903 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12923 #ifndef CYTHON_WITHOUT_ASSERTIONS
12924 if (unlikely(!Py_OptimizeFlag)) {
12925 __pyx_t_4 = __Pyx_PyInt_EqObjC(__pyx_v_nLevels, __pyx_int_1, 1, 0);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 279, __pyx_L1_error)
12926 __Pyx_GOTREF(__pyx_t_4);
12927 __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_4);
if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(1, 279, __pyx_L1_error)
12928 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
12929 if (unlikely(!__pyx_t_2)) {
12930 PyErr_SetObject(PyExc_AssertionError, __pyx_kp_s_wrong_nLevels);
12931 __PYX_ERR(1, 279, __pyx_L1_error)
12943 __pyx_t_3 = __Pyx_PyInt_As_int(__pyx_v_nLevels);
if (unlikely((__pyx_t_3 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 280, __pyx_L1_error)
12968 __Pyx_XDECREF(__pyx_t_4);
12969 __Pyx_XDECREF(__pyx_t_5);
12970 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
12973 __Pyx_XDECREF(__pyx_v_i);
12974 __Pyx_RefNannyFinishContext();
12987 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_3buildPythonMultilevelMeshInterface(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
12988 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_3buildPythonMultilevelMeshInterface(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
12989 PyObject *__pyx_r = 0;
12990 __Pyx_RefNannyDeclarations
12991 __Pyx_RefNannySetupContext(
"buildPythonMultilevelMeshInterface (wrapper)", 0);
12992 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_2buildPythonMultilevelMeshInterface(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
12995 __Pyx_RefNannyFinishContext();
12999 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_2buildPythonMultilevelMeshInterface(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13000 CYTHON_UNUSED
int __pyx_v_dim;
13001 PyObject *__pyx_v_n = NULL;
13002 PyObject *__pyx_r = NULL;
13003 __Pyx_RefNannyDeclarations
13004 PyObject *__pyx_t_1 = NULL;
13005 PyObject *__pyx_t_2 = NULL;
13006 PyObject *__pyx_t_3 = NULL;
13007 Py_ssize_t __pyx_t_4;
13008 PyObject *(*__pyx_t_5)(PyObject *);
13009 Py_ssize_t __pyx_t_6;
13011 PyObject *__pyx_t_8 = NULL;
13013 struct __pyx_array_obj *__pyx_t_10 = NULL;
13014 PyObject *__pyx_t_11 = NULL;
13015 Py_ssize_t __pyx_t_12;
13016 int __pyx_lineno = 0;
13017 const char *__pyx_filename = NULL;
13018 int __pyx_clineno = 0;
13019 __Pyx_RefNannySetupContext(
"buildPythonMultilevelMeshInterface", 0);
13028 __pyx_t_1 = ((PyObject *)__pyx_f_10cmeshTools_CMesh_FromMesh((__pyx_v_self->multilevelMesh.meshArray[0])));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 287, __pyx_L1_error)
13029 __Pyx_GOTREF(__pyx_t_1);
13030 __pyx_t_2 = PyList_New(1);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 287, __pyx_L1_error)
13031 __Pyx_GOTREF(__pyx_t_2);
13032 __Pyx_GIVEREF(__pyx_t_1);
13033 PyList_SET_ITEM(__pyx_t_2, 0, __pyx_t_1);
13035 __Pyx_GIVEREF(__pyx_t_2);
13036 __Pyx_GOTREF(__pyx_v_self->cmeshList);
13037 __Pyx_DECREF(__pyx_v_self->cmeshList);
13038 __pyx_v_self->cmeshList = ((PyObject*)__pyx_t_2);
13048 __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_np);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 288, __pyx_L1_error)
13049 __Pyx_GOTREF(__pyx_t_1);
13050 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_zeros);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 288, __pyx_L1_error)
13051 __Pyx_GOTREF(__pyx_t_3);
13052 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
13054 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
13055 __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_3);
13056 if (likely(__pyx_t_1)) {
13057 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
13058 __Pyx_INCREF(__pyx_t_1);
13059 __Pyx_INCREF(
function);
13060 __Pyx_DECREF_SET(__pyx_t_3,
function);
13063 __pyx_t_2 = (__pyx_t_1) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_1, __pyx_int_0) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_int_0);
13064 __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
13065 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 288, __pyx_L1_error)
13066 __Pyx_GOTREF(__pyx_t_2);
13067 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13068 __pyx_t_3 = PyList_New(1);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 288, __pyx_L1_error)
13069 __Pyx_GOTREF(__pyx_t_3);
13070 __Pyx_GIVEREF(__pyx_t_2);
13071 PyList_SET_ITEM(__pyx_t_3, 0, __pyx_t_2);
13073 __Pyx_GIVEREF(__pyx_t_3);
13074 __Pyx_GOTREF(__pyx_v_self->elementParentsArrayList);
13075 __Pyx_DECREF(__pyx_v_self->elementParentsArrayList);
13076 __pyx_v_self->elementParentsArrayList = ((PyObject*)__pyx_t_3);
13086 __pyx_t_3 = PyList_New(0);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 289, __pyx_L1_error)
13087 __Pyx_GOTREF(__pyx_t_3);
13088 __Pyx_GIVEREF(__pyx_t_3);
13089 __Pyx_GOTREF(__pyx_v_self->elementChildrenArrayList);
13090 __Pyx_DECREF(__pyx_v_self->elementChildrenArrayList);
13091 __pyx_v_self->elementChildrenArrayList = ((PyObject*)__pyx_t_3);
13101 __pyx_t_3 = PyList_New(0);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 290, __pyx_L1_error)
13102 __Pyx_GOTREF(__pyx_t_3);
13103 __Pyx_GIVEREF(__pyx_t_3);
13104 __Pyx_GOTREF(__pyx_v_self->elementChildrenOffsetsList);
13105 __Pyx_DECREF(__pyx_v_self->elementChildrenOffsetsList);
13106 __pyx_v_self->elementChildrenOffsetsList = ((PyObject*)__pyx_t_3);
13116 __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->multilevelMesh.nLevels);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 291, __pyx_L1_error)
13117 __Pyx_GOTREF(__pyx_t_3);
13118 __pyx_t_2 = PyTuple_New(2);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 291, __pyx_L1_error)
13119 __Pyx_GOTREF(__pyx_t_2);
13120 __Pyx_INCREF(__pyx_int_1);
13121 __Pyx_GIVEREF(__pyx_int_1);
13122 PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_int_1);
13123 __Pyx_GIVEREF(__pyx_t_3);
13124 PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3);
13126 __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_range, __pyx_t_2, NULL);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 291, __pyx_L1_error)
13127 __Pyx_GOTREF(__pyx_t_3);
13128 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
13129 if (likely(PyList_CheckExact(__pyx_t_3)) || PyTuple_CheckExact(__pyx_t_3)) {
13130 __pyx_t_2 = __pyx_t_3; __Pyx_INCREF(__pyx_t_2); __pyx_t_4 = 0;
13133 __pyx_t_4 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_3);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 291, __pyx_L1_error)
13134 __Pyx_GOTREF(__pyx_t_2);
13135 __pyx_t_5 = Py_TYPE(__pyx_t_2)->tp_iternext;
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 291, __pyx_L1_error)
13137 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13139 if (likely(!__pyx_t_5)) {
13140 if (likely(PyList_CheckExact(__pyx_t_2))) {
13141 if (__pyx_t_4 >= PyList_GET_SIZE(__pyx_t_2))
break;
13142 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
13143 __pyx_t_3 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_3); __pyx_t_4++;
if (unlikely(0 < 0)) __PYX_ERR(1, 291, __pyx_L1_error)
13145 __pyx_t_3 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++;
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 291, __pyx_L1_error)
13146 __Pyx_GOTREF(__pyx_t_3);
13149 if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_2))
break;
13150 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
13151 __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_4); __Pyx_INCREF(__pyx_t_3); __pyx_t_4++;
if (unlikely(0 < 0)) __PYX_ERR(1, 291, __pyx_L1_error)
13153 __pyx_t_3 = PySequence_ITEM(__pyx_t_2, __pyx_t_4); __pyx_t_4++;
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 291, __pyx_L1_error)
13154 __Pyx_GOTREF(__pyx_t_3);
13158 __pyx_t_3 = __pyx_t_5(__pyx_t_2);
13159 if (unlikely(!__pyx_t_3)) {
13160 PyObject* exc_type = PyErr_Occurred();
13162 if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
13163 else __PYX_ERR(1, 291, __pyx_L1_error)
13167 __Pyx_GOTREF(__pyx_t_3);
13169 __Pyx_XDECREF_SET(__pyx_v_n, __pyx_t_3);
13179 __pyx_t_6 = __Pyx_PyIndex_AsSsize_t(__pyx_v_n);
if (unlikely((__pyx_t_6 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 292, __pyx_L1_error)
13180 __pyx_t_3 = ((PyObject *)__pyx_f_10cmeshTools_CMesh_FromMesh((__pyx_v_self->multilevelMesh.meshArray[__pyx_t_6])));
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 292, __pyx_L1_error)
13181 __Pyx_GOTREF(__pyx_t_3);
13182 __pyx_t_1 = PyList_New(1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 292, __pyx_L1_error)
13183 __Pyx_GOTREF(__pyx_t_1);
13184 __Pyx_GIVEREF(__pyx_t_3);
13185 PyList_SET_ITEM(__pyx_t_1, 0, __pyx_t_3);
13187 __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_self->cmeshList, __pyx_t_1);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 292, __pyx_L1_error)
13188 __Pyx_GOTREF(__pyx_t_3);
13189 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
13190 __Pyx_GIVEREF(__pyx_t_3);
13191 __Pyx_GOTREF(__pyx_v_self->cmeshList);
13192 __Pyx_DECREF(__pyx_v_self->cmeshList);
13193 __pyx_v_self->cmeshList = ((PyObject*)__pyx_t_3);
13203 __pyx_t_6 = __Pyx_PyIndex_AsSsize_t(__pyx_v_n);
if (unlikely((__pyx_t_6 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 293, __pyx_L1_error)
13204 __pyx_t_7 = (__pyx_v_self->multilevelMesh.meshArray[__pyx_t_6]).nElements_global;
13205 __pyx_v_dim = __pyx_t_7;
13214 __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_np);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 294, __pyx_L1_error)
13215 __Pyx_GOTREF(__pyx_t_1);
13216 __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 294, __pyx_L1_error)
13217 __Pyx_GOTREF(__pyx_t_8);
13218 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
13219 __pyx_t_6 = __Pyx_PyIndex_AsSsize_t(__pyx_v_n);
if (unlikely((__pyx_t_6 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 294, __pyx_L1_error)
13220 __pyx_t_9 = (__pyx_v_self->multilevelMesh.elementParentsArray[__pyx_t_6]);
13222 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
13223 __PYX_ERR(1, 294, __pyx_L1_error)
13225 __pyx_t_11 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 294, __pyx_L1_error)
13226 __Pyx_GOTREF(__pyx_t_11);
13227 __pyx_t_1 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_dim));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 294, __pyx_L1_error)
13228 __Pyx_GOTREF(__pyx_t_1);
13229 __pyx_t_10 = __pyx_array_new(__pyx_t_1,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_11), (
char *)
"c", (
char *) __pyx_t_9);
13230 if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 294, __pyx_L1_error)
13231 __Pyx_GOTREF(__pyx_t_10);
13232 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
13233 __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
13235 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_8))) {
13236 __pyx_t_11 = PyMethod_GET_SELF(__pyx_t_8);
13237 if (likely(__pyx_t_11)) {
13238 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_8);
13239 __Pyx_INCREF(__pyx_t_11);
13240 __Pyx_INCREF(
function);
13241 __Pyx_DECREF_SET(__pyx_t_8,
function);
13244 __pyx_t_3 = (__pyx_t_11) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_11, ((PyObject *)__pyx_t_10)) : __Pyx_PyObject_CallOneArg(__pyx_t_8, ((PyObject *)__pyx_t_10));
13245 __Pyx_XDECREF(__pyx_t_11); __pyx_t_11 = 0;
13246 __Pyx_DECREF(((PyObject *)__pyx_t_10)); __pyx_t_10 = 0;
13247 if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 294, __pyx_L1_error)
13248 __Pyx_GOTREF(__pyx_t_3);
13249 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
13250 __pyx_t_8 = PyList_New(1);
if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 294, __pyx_L1_error)
13251 __Pyx_GOTREF(__pyx_t_8);
13252 __Pyx_GIVEREF(__pyx_t_3);
13253 PyList_SET_ITEM(__pyx_t_8, 0, __pyx_t_3);
13255 __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_self->elementParentsArrayList, __pyx_t_8);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 294, __pyx_L1_error)
13256 __Pyx_GOTREF(__pyx_t_3);
13257 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
13258 __Pyx_GIVEREF(__pyx_t_3);
13259 __Pyx_GOTREF(__pyx_v_self->elementParentsArrayList);
13260 __Pyx_DECREF(__pyx_v_self->elementParentsArrayList);
13261 __pyx_v_self->elementParentsArrayList = ((PyObject*)__pyx_t_3);
13271 __pyx_t_3 = __Pyx_PyInt_SubtractObjC(__pyx_v_n, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 295, __pyx_L1_error)
13272 __Pyx_GOTREF(__pyx_t_3);
13273 __pyx_t_6 = __Pyx_PyIndex_AsSsize_t(__pyx_t_3);
if (unlikely((__pyx_t_6 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 295, __pyx_L1_error)
13274 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13275 __pyx_t_3 = __Pyx_PyInt_SubtractObjC(__pyx_v_n, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 295, __pyx_L1_error)
13276 __Pyx_GOTREF(__pyx_t_3);
13277 __pyx_t_12 = __Pyx_PyIndex_AsSsize_t(__pyx_t_3);
if (unlikely((__pyx_t_12 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 295, __pyx_L1_error)
13278 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13279 __pyx_v_dim = ((__pyx_v_self->multilevelMesh.elementChildrenOffsets[__pyx_t_6])[(__pyx_v_self->multilevelMesh.meshArray[__pyx_t_12]).nElements_global]);
13288 __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_np);
if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 296, __pyx_L1_error)
13289 __Pyx_GOTREF(__pyx_t_8);
13290 __pyx_t_11 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 296, __pyx_L1_error)
13291 __Pyx_GOTREF(__pyx_t_11);
13292 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
13293 __pyx_t_8 = __Pyx_PyInt_SubtractObjC(__pyx_v_n, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 296, __pyx_L1_error)
13294 __Pyx_GOTREF(__pyx_t_8);
13295 __pyx_t_12 = __Pyx_PyIndex_AsSsize_t(__pyx_t_8);
if (unlikely((__pyx_t_12 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 296, __pyx_L1_error)
13296 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
13297 __pyx_t_9 = (__pyx_v_self->multilevelMesh.elementChildrenArray[__pyx_t_12]);
13299 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
13300 __PYX_ERR(1, 296, __pyx_L1_error)
13302 __pyx_t_1 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 296, __pyx_L1_error)
13303 __Pyx_GOTREF(__pyx_t_1);
13304 __pyx_t_8 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_dim));
if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 296, __pyx_L1_error)
13305 __Pyx_GOTREF(__pyx_t_8);
13306 __pyx_t_10 = __pyx_array_new(__pyx_t_8,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_1), (
char *)
"c", (
char *) __pyx_t_9);
13307 if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 296, __pyx_L1_error)
13308 __Pyx_GOTREF(__pyx_t_10);
13309 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
13310 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
13312 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_11))) {
13313 __pyx_t_1 = PyMethod_GET_SELF(__pyx_t_11);
13314 if (likely(__pyx_t_1)) {
13315 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_11);
13316 __Pyx_INCREF(__pyx_t_1);
13317 __Pyx_INCREF(
function);
13318 __Pyx_DECREF_SET(__pyx_t_11,
function);
13321 __pyx_t_3 = (__pyx_t_1) ? __Pyx_PyObject_Call2Args(__pyx_t_11, __pyx_t_1, ((PyObject *)__pyx_t_10)) : __Pyx_PyObject_CallOneArg(__pyx_t_11, ((PyObject *)__pyx_t_10));
13322 __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
13323 __Pyx_DECREF(((PyObject *)__pyx_t_10)); __pyx_t_10 = 0;
13324 if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 296, __pyx_L1_error)
13325 __Pyx_GOTREF(__pyx_t_3);
13326 __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
13327 __pyx_t_11 = PyList_New(1);
if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 296, __pyx_L1_error)
13328 __Pyx_GOTREF(__pyx_t_11);
13329 __Pyx_GIVEREF(__pyx_t_3);
13330 PyList_SET_ITEM(__pyx_t_11, 0, __pyx_t_3);
13332 __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_self->elementChildrenArrayList, __pyx_t_11);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 296, __pyx_L1_error)
13333 __Pyx_GOTREF(__pyx_t_3);
13334 __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
13335 __Pyx_GIVEREF(__pyx_t_3);
13336 __Pyx_GOTREF(__pyx_v_self->elementChildrenArrayList);
13337 __Pyx_DECREF(__pyx_v_self->elementChildrenArrayList);
13338 __pyx_v_self->elementChildrenArrayList = ((PyObject*)__pyx_t_3);
13348 __pyx_t_3 = __Pyx_PyInt_SubtractObjC(__pyx_v_n, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 297, __pyx_L1_error)
13349 __Pyx_GOTREF(__pyx_t_3);
13350 __pyx_t_12 = __Pyx_PyIndex_AsSsize_t(__pyx_t_3);
if (unlikely((__pyx_t_12 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 297, __pyx_L1_error)
13351 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
13352 __pyx_v_dim = ((__pyx_v_self->multilevelMesh.meshArray[__pyx_t_12]).nElements_global + 1);
13361 __Pyx_GetModuleGlobalName(__pyx_t_11, __pyx_n_s_np);
if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 298, __pyx_L1_error)
13362 __Pyx_GOTREF(__pyx_t_11);
13363 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_11, __pyx_n_s_asarray);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 298, __pyx_L1_error)
13364 __Pyx_GOTREF(__pyx_t_1);
13365 __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
13366 __pyx_t_11 = __Pyx_PyInt_SubtractObjC(__pyx_v_n, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 298, __pyx_L1_error)
13367 __Pyx_GOTREF(__pyx_t_11);
13368 __pyx_t_12 = __Pyx_PyIndex_AsSsize_t(__pyx_t_11);
if (unlikely((__pyx_t_12 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 298, __pyx_L1_error)
13369 __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
13370 __pyx_t_9 = (__pyx_v_self->multilevelMesh.elementChildrenOffsets[__pyx_t_12]);
13372 PyErr_SetString(PyExc_ValueError,
"Cannot create cython.array from NULL pointer");
13373 __PYX_ERR(1, 298, __pyx_L1_error)
13375 __pyx_t_8 = __pyx_format_from_typeinfo(&__Pyx_TypeInfo_int);
if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 298, __pyx_L1_error)
13376 __Pyx_GOTREF(__pyx_t_8);
13377 __pyx_t_11 = Py_BuildValue((
char*)
"(" __PYX_BUILD_PY_SSIZE_T
")", ((Py_ssize_t)__pyx_v_dim));
if (unlikely(!__pyx_t_11)) __PYX_ERR(1, 298, __pyx_L1_error)
13378 __Pyx_GOTREF(__pyx_t_11);
13379 __pyx_t_10 = __pyx_array_new(__pyx_t_11,
sizeof(
int), PyBytes_AS_STRING(__pyx_t_8), (
char *)
"c", (
char *) __pyx_t_9);
13380 if (unlikely(!__pyx_t_10)) __PYX_ERR(1, 298, __pyx_L1_error)
13381 __Pyx_GOTREF(__pyx_t_10);
13382 __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
13383 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
13385 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
13386 __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_1);
13387 if (likely(__pyx_t_8)) {
13388 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_1);
13389 __Pyx_INCREF(__pyx_t_8);
13390 __Pyx_INCREF(
function);
13391 __Pyx_DECREF_SET(__pyx_t_1,
function);
13394 __pyx_t_3 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_8, ((PyObject *)__pyx_t_10)) : __Pyx_PyObject_CallOneArg(__pyx_t_1, ((PyObject *)__pyx_t_10));
13395 __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
13396 __Pyx_DECREF(((PyObject *)__pyx_t_10)); __pyx_t_10 = 0;
13397 if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 298, __pyx_L1_error)
13398 __Pyx_GOTREF(__pyx_t_3);
13399 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
13400 __pyx_t_1 = PyList_New(1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 298, __pyx_L1_error)
13401 __Pyx_GOTREF(__pyx_t_1);
13402 __Pyx_GIVEREF(__pyx_t_3);
13403 PyList_SET_ITEM(__pyx_t_1, 0, __pyx_t_3);
13405 __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_self->elementChildrenOffsetsList, __pyx_t_1);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 298, __pyx_L1_error)
13406 __Pyx_GOTREF(__pyx_t_3);
13407 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
13408 __Pyx_GIVEREF(__pyx_t_3);
13409 __Pyx_GOTREF(__pyx_v_self->elementChildrenOffsetsList);
13410 __Pyx_DECREF(__pyx_v_self->elementChildrenOffsetsList);
13411 __pyx_v_self->elementChildrenOffsetsList = ((PyObject*)__pyx_t_3);
13422 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
13433 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
13436 __Pyx_XDECREF(__pyx_t_1);
13437 __Pyx_XDECREF(__pyx_t_2);
13438 __Pyx_XDECREF(__pyx_t_3);
13439 __Pyx_XDECREF(__pyx_t_8);
13440 __Pyx_XDECREF(((PyObject *)__pyx_t_10));
13441 __Pyx_XDECREF(__pyx_t_11);
13442 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.buildPythonMultilevelMeshInterface", __pyx_clineno, __pyx_lineno, __pyx_filename);
13445 __Pyx_XDECREF(__pyx_v_n);
13446 __Pyx_XGIVEREF(__pyx_r);
13447 __Pyx_RefNannyFinishContext();
13460 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_7nLevels_1__get__(PyObject *__pyx_v_self);
13461 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_7nLevels_1__get__(PyObject *__pyx_v_self) {
13462 PyObject *__pyx_r = 0;
13463 __Pyx_RefNannyDeclarations
13464 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
13465 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_7nLevels___get__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13468 __Pyx_RefNannyFinishContext();
13472 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_7nLevels___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13473 PyObject *__pyx_r = NULL;
13474 __Pyx_RefNannyDeclarations
13475 PyObject *__pyx_t_1 = NULL;
13476 int __pyx_lineno = 0;
13477 const char *__pyx_filename = NULL;
13478 int __pyx_clineno = 0;
13479 __Pyx_RefNannySetupContext(
"__get__", 0);
13480 __Pyx_XDECREF(__pyx_r);
13481 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->nLevels);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 205, __pyx_L1_error)
13482 __Pyx_GOTREF(__pyx_t_1);
13483 __pyx_r = __pyx_t_1;
13489 __Pyx_XDECREF(__pyx_t_1);
13490 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.nLevels.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
13493 __Pyx_XGIVEREF(__pyx_r);
13494 __Pyx_RefNannyFinishContext();
13499 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_7nLevels_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
13500 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_7nLevels_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
13502 __Pyx_RefNannyDeclarations
13503 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
13504 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_7nLevels_2__set__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
13507 __Pyx_RefNannyFinishContext();
13511 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_7nLevels_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value) {
13513 __Pyx_RefNannyDeclarations
13515 int __pyx_lineno = 0;
13516 const char *__pyx_filename = NULL;
13517 int __pyx_clineno = 0;
13518 __Pyx_RefNannySetupContext(
"__set__", 0);
13519 __pyx_t_1 = __Pyx_PyInt_As_int(__pyx_v_value);
if (unlikely((__pyx_t_1 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 205, __pyx_L1_error)
13520 __pyx_v_self->nLevels = __pyx_t_1;
13526 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.nLevels.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
13529 __Pyx_RefNannyFinishContext();
13542 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_9cmeshList_1__get__(PyObject *__pyx_v_self);
13543 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_9cmeshList_1__get__(PyObject *__pyx_v_self) {
13544 PyObject *__pyx_r = 0;
13545 __Pyx_RefNannyDeclarations
13546 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
13547 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_9cmeshList___get__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13550 __Pyx_RefNannyFinishContext();
13554 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_9cmeshList___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13555 PyObject *__pyx_r = NULL;
13556 __Pyx_RefNannyDeclarations
13557 __Pyx_RefNannySetupContext(
"__get__", 0);
13558 __Pyx_XDECREF(__pyx_r);
13559 __Pyx_INCREF(__pyx_v_self->cmeshList);
13560 __pyx_r = __pyx_v_self->cmeshList;
13565 __Pyx_XGIVEREF(__pyx_r);
13566 __Pyx_RefNannyFinishContext();
13571 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_9cmeshList_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
13572 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_9cmeshList_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
13574 __Pyx_RefNannyDeclarations
13575 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
13576 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_9cmeshList_2__set__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
13579 __Pyx_RefNannyFinishContext();
13583 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_9cmeshList_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value) {
13585 __Pyx_RefNannyDeclarations
13586 PyObject *__pyx_t_1 = NULL;
13587 int __pyx_lineno = 0;
13588 const char *__pyx_filename = NULL;
13589 int __pyx_clineno = 0;
13590 __Pyx_RefNannySetupContext(
"__set__", 0);
13591 if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(1, 206, __pyx_L1_error)
13592 __pyx_t_1 = __pyx_v_value;
13593 __Pyx_INCREF(__pyx_t_1);
13594 __Pyx_GIVEREF(__pyx_t_1);
13595 __Pyx_GOTREF(__pyx_v_self->cmeshList);
13596 __Pyx_DECREF(__pyx_v_self->cmeshList);
13597 __pyx_v_self->cmeshList = ((PyObject*)__pyx_t_1);
13604 __Pyx_XDECREF(__pyx_t_1);
13605 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.cmeshList.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
13608 __Pyx_RefNannyFinishContext();
13613 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_9cmeshList_5__del__(PyObject *__pyx_v_self);
13614 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_9cmeshList_5__del__(PyObject *__pyx_v_self) {
13616 __Pyx_RefNannyDeclarations
13617 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
13618 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_9cmeshList_4__del__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13621 __Pyx_RefNannyFinishContext();
13625 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_9cmeshList_4__del__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13627 __Pyx_RefNannyDeclarations
13628 __Pyx_RefNannySetupContext(
"__del__", 0);
13629 __Pyx_INCREF(Py_None);
13630 __Pyx_GIVEREF(Py_None);
13631 __Pyx_GOTREF(__pyx_v_self->cmeshList);
13632 __Pyx_DECREF(__pyx_v_self->cmeshList);
13633 __pyx_v_self->cmeshList = ((PyObject*)Py_None);
13637 __Pyx_RefNannyFinishContext();
13650 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_1__get__(PyObject *__pyx_v_self);
13651 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_1__get__(PyObject *__pyx_v_self) {
13652 PyObject *__pyx_r = 0;
13653 __Pyx_RefNannyDeclarations
13654 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
13655 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList___get__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13658 __Pyx_RefNannyFinishContext();
13662 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13663 PyObject *__pyx_r = NULL;
13664 __Pyx_RefNannyDeclarations
13665 __Pyx_RefNannySetupContext(
"__get__", 0);
13666 __Pyx_XDECREF(__pyx_r);
13667 __Pyx_INCREF(__pyx_v_self->elementParentsArrayList);
13668 __pyx_r = __pyx_v_self->elementParentsArrayList;
13673 __Pyx_XGIVEREF(__pyx_r);
13674 __Pyx_RefNannyFinishContext();
13679 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
13680 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
13682 __Pyx_RefNannyDeclarations
13683 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
13684 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_2__set__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
13687 __Pyx_RefNannyFinishContext();
13691 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value) {
13693 __Pyx_RefNannyDeclarations
13694 PyObject *__pyx_t_1 = NULL;
13695 int __pyx_lineno = 0;
13696 const char *__pyx_filename = NULL;
13697 int __pyx_clineno = 0;
13698 __Pyx_RefNannySetupContext(
"__set__", 0);
13699 if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(1, 207, __pyx_L1_error)
13700 __pyx_t_1 = __pyx_v_value;
13701 __Pyx_INCREF(__pyx_t_1);
13702 __Pyx_GIVEREF(__pyx_t_1);
13703 __Pyx_GOTREF(__pyx_v_self->elementParentsArrayList);
13704 __Pyx_DECREF(__pyx_v_self->elementParentsArrayList);
13705 __pyx_v_self->elementParentsArrayList = ((PyObject*)__pyx_t_1);
13712 __Pyx_XDECREF(__pyx_t_1);
13713 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.elementParentsArrayList.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
13716 __Pyx_RefNannyFinishContext();
13721 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_5__del__(PyObject *__pyx_v_self);
13722 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_5__del__(PyObject *__pyx_v_self) {
13724 __Pyx_RefNannyDeclarations
13725 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
13726 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_4__del__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13729 __Pyx_RefNannyFinishContext();
13733 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_4__del__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13735 __Pyx_RefNannyDeclarations
13736 __Pyx_RefNannySetupContext(
"__del__", 0);
13737 __Pyx_INCREF(Py_None);
13738 __Pyx_GIVEREF(Py_None);
13739 __Pyx_GOTREF(__pyx_v_self->elementParentsArrayList);
13740 __Pyx_DECREF(__pyx_v_self->elementParentsArrayList);
13741 __pyx_v_self->elementParentsArrayList = ((PyObject*)Py_None);
13745 __Pyx_RefNannyFinishContext();
13758 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_1__get__(PyObject *__pyx_v_self);
13759 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_1__get__(PyObject *__pyx_v_self) {
13760 PyObject *__pyx_r = 0;
13761 __Pyx_RefNannyDeclarations
13762 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
13763 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList___get__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13766 __Pyx_RefNannyFinishContext();
13770 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13771 PyObject *__pyx_r = NULL;
13772 __Pyx_RefNannyDeclarations
13773 __Pyx_RefNannySetupContext(
"__get__", 0);
13774 __Pyx_XDECREF(__pyx_r);
13775 __Pyx_INCREF(__pyx_v_self->elementChildrenArrayList);
13776 __pyx_r = __pyx_v_self->elementChildrenArrayList;
13781 __Pyx_XGIVEREF(__pyx_r);
13782 __Pyx_RefNannyFinishContext();
13787 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
13788 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
13790 __Pyx_RefNannyDeclarations
13791 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
13792 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_2__set__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
13795 __Pyx_RefNannyFinishContext();
13799 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value) {
13801 __Pyx_RefNannyDeclarations
13802 PyObject *__pyx_t_1 = NULL;
13803 int __pyx_lineno = 0;
13804 const char *__pyx_filename = NULL;
13805 int __pyx_clineno = 0;
13806 __Pyx_RefNannySetupContext(
"__set__", 0);
13807 if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(1, 208, __pyx_L1_error)
13808 __pyx_t_1 = __pyx_v_value;
13809 __Pyx_INCREF(__pyx_t_1);
13810 __Pyx_GIVEREF(__pyx_t_1);
13811 __Pyx_GOTREF(__pyx_v_self->elementChildrenArrayList);
13812 __Pyx_DECREF(__pyx_v_self->elementChildrenArrayList);
13813 __pyx_v_self->elementChildrenArrayList = ((PyObject*)__pyx_t_1);
13820 __Pyx_XDECREF(__pyx_t_1);
13821 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.elementChildrenArrayList.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
13824 __Pyx_RefNannyFinishContext();
13829 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_5__del__(PyObject *__pyx_v_self);
13830 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_5__del__(PyObject *__pyx_v_self) {
13832 __Pyx_RefNannyDeclarations
13833 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
13834 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_4__del__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13837 __Pyx_RefNannyFinishContext();
13841 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_4__del__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13843 __Pyx_RefNannyDeclarations
13844 __Pyx_RefNannySetupContext(
"__del__", 0);
13845 __Pyx_INCREF(Py_None);
13846 __Pyx_GIVEREF(Py_None);
13847 __Pyx_GOTREF(__pyx_v_self->elementChildrenArrayList);
13848 __Pyx_DECREF(__pyx_v_self->elementChildrenArrayList);
13849 __pyx_v_self->elementChildrenArrayList = ((PyObject*)Py_None);
13853 __Pyx_RefNannyFinishContext();
13866 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_1__get__(PyObject *__pyx_v_self);
13867 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_1__get__(PyObject *__pyx_v_self) {
13868 PyObject *__pyx_r = 0;
13869 __Pyx_RefNannyDeclarations
13870 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
13871 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList___get__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13874 __Pyx_RefNannyFinishContext();
13878 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList___get__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13879 PyObject *__pyx_r = NULL;
13880 __Pyx_RefNannyDeclarations
13881 __Pyx_RefNannySetupContext(
"__get__", 0);
13882 __Pyx_XDECREF(__pyx_r);
13883 __Pyx_INCREF(__pyx_v_self->elementChildrenOffsetsList);
13884 __pyx_r = __pyx_v_self->elementChildrenOffsetsList;
13889 __Pyx_XGIVEREF(__pyx_r);
13890 __Pyx_RefNannyFinishContext();
13895 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value);
13896 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_3__set__(PyObject *__pyx_v_self, PyObject *__pyx_v_value) {
13898 __Pyx_RefNannyDeclarations
13899 __Pyx_RefNannySetupContext(
"__set__ (wrapper)", 0);
13900 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_2__set__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self), ((PyObject *)__pyx_v_value));
13903 __Pyx_RefNannyFinishContext();
13907 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_2__set__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, PyObject *__pyx_v_value) {
13909 __Pyx_RefNannyDeclarations
13910 PyObject *__pyx_t_1 = NULL;
13911 int __pyx_lineno = 0;
13912 const char *__pyx_filename = NULL;
13913 int __pyx_clineno = 0;
13914 __Pyx_RefNannySetupContext(
"__set__", 0);
13915 if (!(likely(PyList_CheckExact(__pyx_v_value))||((__pyx_v_value) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"list", Py_TYPE(__pyx_v_value)->tp_name), 0))) __PYX_ERR(1, 209, __pyx_L1_error)
13916 __pyx_t_1 = __pyx_v_value;
13917 __Pyx_INCREF(__pyx_t_1);
13918 __Pyx_GIVEREF(__pyx_t_1);
13919 __Pyx_GOTREF(__pyx_v_self->elementChildrenOffsetsList);
13920 __Pyx_DECREF(__pyx_v_self->elementChildrenOffsetsList);
13921 __pyx_v_self->elementChildrenOffsetsList = ((PyObject*)__pyx_t_1);
13928 __Pyx_XDECREF(__pyx_t_1);
13929 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.elementChildrenOffsetsList.__set__", __pyx_clineno, __pyx_lineno, __pyx_filename);
13932 __Pyx_RefNannyFinishContext();
13937 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_5__del__(PyObject *__pyx_v_self);
13938 static int __pyx_pw_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_5__del__(PyObject *__pyx_v_self) {
13940 __Pyx_RefNannyDeclarations
13941 __Pyx_RefNannySetupContext(
"__del__ (wrapper)", 0);
13942 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_4__del__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13945 __Pyx_RefNannyFinishContext();
13949 static int __pyx_pf_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_4__del__(
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13951 __Pyx_RefNannyDeclarations
13952 __Pyx_RefNannySetupContext(
"__del__", 0);
13953 __Pyx_INCREF(Py_None);
13954 __Pyx_GIVEREF(Py_None);
13955 __Pyx_GOTREF(__pyx_v_self->elementChildrenOffsetsList);
13956 __Pyx_DECREF(__pyx_v_self->elementChildrenOffsetsList);
13957 __pyx_v_self->elementChildrenOffsetsList = ((PyObject*)Py_None);
13961 __Pyx_RefNannyFinishContext();
13972 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_5__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
13973 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_5__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
13974 PyObject *__pyx_r = 0;
13975 __Pyx_RefNannyDeclarations
13976 __Pyx_RefNannySetupContext(
"__reduce_cython__ (wrapper)", 0);
13977 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_4__reduce_cython__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self));
13980 __Pyx_RefNannyFinishContext();
13984 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_4__reduce_cython__(CYTHON_UNUSED
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self) {
13985 PyObject *__pyx_r = NULL;
13986 __Pyx_RefNannyDeclarations
13987 PyObject *__pyx_t_1 = NULL;
13988 int __pyx_lineno = 0;
13989 const char *__pyx_filename = NULL;
13990 int __pyx_clineno = 0;
13991 __Pyx_RefNannySetupContext(
"__reduce_cython__", 0);
13999 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__4, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 2, __pyx_L1_error)
14000 __Pyx_GOTREF(__pyx_t_1);
14001 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
14002 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
14003 __PYX_ERR(0, 2, __pyx_L1_error)
14013 __Pyx_XDECREF(__pyx_t_1);
14014 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
14016 __Pyx_XGIVEREF(__pyx_r);
14017 __Pyx_RefNannyFinishContext();
14029 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_7__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state);
14030 static PyObject *__pyx_pw_10cmeshTools_15CMultilevelMesh_7__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
14031 PyObject *__pyx_r = 0;
14032 __Pyx_RefNannyDeclarations
14033 __Pyx_RefNannySetupContext(
"__setstate_cython__ (wrapper)", 0);
14034 __pyx_r = __pyx_pf_10cmeshTools_15CMultilevelMesh_6__setstate_cython__(((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
14037 __Pyx_RefNannyFinishContext();
14041 static PyObject *__pyx_pf_10cmeshTools_15CMultilevelMesh_6__setstate_cython__(CYTHON_UNUSED
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
14042 PyObject *__pyx_r = NULL;
14043 __Pyx_RefNannyDeclarations
14044 PyObject *__pyx_t_1 = NULL;
14045 int __pyx_lineno = 0;
14046 const char *__pyx_filename = NULL;
14047 int __pyx_clineno = 0;
14048 __Pyx_RefNannySetupContext(
"__setstate_cython__", 0);
14055 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__5, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 4, __pyx_L1_error)
14056 __Pyx_GOTREF(__pyx_t_1);
14057 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
14058 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
14059 __PYX_ERR(0, 4, __pyx_L1_error)
14070 __Pyx_XDECREF(__pyx_t_1);
14071 __Pyx_AddTraceback(
"cmeshTools.CMultilevelMesh.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
14073 __Pyx_XGIVEREF(__pyx_r);
14074 __Pyx_RefNannyFinishContext();
14087 static PyObject *__pyx_pw_10cmeshTools_5buildPythonMultilevelMeshInterface(PyObject *__pyx_self, PyObject *__pyx_v_cmultilevelMesh);
14088 static PyMethodDef __pyx_mdef_10cmeshTools_5buildPythonMultilevelMeshInterface = {
"buildPythonMultilevelMeshInterface", (PyCFunction)__pyx_pw_10cmeshTools_5buildPythonMultilevelMeshInterface, METH_O, 0};
14089 static PyObject *__pyx_pw_10cmeshTools_5buildPythonMultilevelMeshInterface(PyObject *__pyx_self, PyObject *__pyx_v_cmultilevelMesh) {
14090 PyObject *__pyx_r = 0;
14091 __Pyx_RefNannyDeclarations
14092 __Pyx_RefNannySetupContext(
"buildPythonMultilevelMeshInterface (wrapper)", 0);
14093 __pyx_r = __pyx_pf_10cmeshTools_4buildPythonMultilevelMeshInterface(__pyx_self, ((PyObject *)__pyx_v_cmultilevelMesh));
14096 __Pyx_RefNannyFinishContext();
14100 static PyObject *__pyx_pf_10cmeshTools_4buildPythonMultilevelMeshInterface(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v_cmultilevelMesh) {
14101 PyObject *__pyx_r = NULL;
14102 __Pyx_RefNannyDeclarations
14103 PyObject *__pyx_t_1 = NULL;
14104 PyObject *__pyx_t_2 = NULL;
14105 PyObject *__pyx_t_3 = NULL;
14106 PyObject *__pyx_t_4 = NULL;
14107 PyObject *__pyx_t_5 = NULL;
14108 PyObject *__pyx_t_6 = NULL;
14109 int __pyx_lineno = 0;
14110 const char *__pyx_filename = NULL;
14111 int __pyx_clineno = 0;
14112 __Pyx_RefNannySetupContext(
"buildPythonMultilevelMeshInterface", 0);
14121 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmultilevelMesh, __pyx_n_s_buildPythonMultilevelMeshInterfa);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 301, __pyx_L1_error)
14122 __Pyx_GOTREF(__pyx_t_2);
14124 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
14125 __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_2);
14126 if (likely(__pyx_t_3)) {
14127 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_2);
14128 __Pyx_INCREF(__pyx_t_3);
14129 __Pyx_INCREF(
function);
14130 __Pyx_DECREF_SET(__pyx_t_2,
function);
14133 __pyx_t_1 = (__pyx_t_3) ? __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_3) : __Pyx_PyObject_CallNoArg(__pyx_t_2);
14134 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
14135 if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 301, __pyx_L1_error)
14136 __Pyx_GOTREF(__pyx_t_1);
14137 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
14138 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
14147 __Pyx_XDECREF(__pyx_r);
14148 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmultilevelMesh, __pyx_n_s_nLevels);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 302, __pyx_L1_error)
14149 __Pyx_GOTREF(__pyx_t_1);
14158 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmultilevelMesh, __pyx_n_s_cmeshList);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 303, __pyx_L1_error)
14159 __Pyx_GOTREF(__pyx_t_2);
14168 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmultilevelMesh, __pyx_n_s_elementParentsArrayList);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 304, __pyx_L1_error)
14169 __Pyx_GOTREF(__pyx_t_3);
14178 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmultilevelMesh, __pyx_n_s_elementChildrenArrayList);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 305, __pyx_L1_error)
14179 __Pyx_GOTREF(__pyx_t_4);
14188 __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_cmultilevelMesh, __pyx_n_s_elementChildrenOffsetsList);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 306, __pyx_L1_error)
14189 __Pyx_GOTREF(__pyx_t_5);
14198 __pyx_t_6 = PyTuple_New(5);
if (unlikely(!__pyx_t_6)) __PYX_ERR(1, 302, __pyx_L1_error)
14199 __Pyx_GOTREF(__pyx_t_6);
14200 __Pyx_GIVEREF(__pyx_t_1);
14201 PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_1);
14202 __Pyx_GIVEREF(__pyx_t_2);
14203 PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_2);
14204 __Pyx_GIVEREF(__pyx_t_3);
14205 PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_t_3);
14206 __Pyx_GIVEREF(__pyx_t_4);
14207 PyTuple_SET_ITEM(__pyx_t_6, 3, __pyx_t_4);
14208 __Pyx_GIVEREF(__pyx_t_5);
14209 PyTuple_SET_ITEM(__pyx_t_6, 4, __pyx_t_5);
14215 __pyx_r = __pyx_t_6;
14229 __Pyx_XDECREF(__pyx_t_1);
14230 __Pyx_XDECREF(__pyx_t_2);
14231 __Pyx_XDECREF(__pyx_t_3);
14232 __Pyx_XDECREF(__pyx_t_4);
14233 __Pyx_XDECREF(__pyx_t_5);
14234 __Pyx_XDECREF(__pyx_t_6);
14235 __Pyx_AddTraceback(
"cmeshTools.buildPythonMultilevelMeshInterface", __pyx_clineno, __pyx_lineno, __pyx_filename);
14238 __Pyx_XGIVEREF(__pyx_r);
14239 __Pyx_RefNannyFinishContext();
14251 static PyObject *__pyx_pw_10cmeshTools_7generateTetrahedralMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
14252 static void __pyx_f_10cmeshTools_generateTetrahedralMeshFromRectangularGrid(
int __pyx_v_nx,
int __pyx_v_ny,
int __pyx_v_nz,
double __pyx_v_Lx,
double __pyx_v_Ly,
double __pyx_v_Lz,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
14253 __Pyx_RefNannyDeclarations
14254 __Pyx_RefNannySetupContext(
"generateTetrahedralMeshFromRectangularGrid", 0);
14301 __Pyx_RefNannyFinishContext();
14305 static PyObject *__pyx_pw_10cmeshTools_7generateTetrahedralMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
14306 static PyObject *__pyx_pw_10cmeshTools_7generateTetrahedralMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
14313 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
14314 int __pyx_lineno = 0;
14315 const char *__pyx_filename = NULL;
14316 int __pyx_clineno = 0;
14317 PyObject *__pyx_r = 0;
14318 __Pyx_RefNannyDeclarations
14319 __Pyx_RefNannySetupContext(
"generateTetrahedralMeshFromRectangularGrid (wrapper)", 0);
14321 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nx,&__pyx_n_s_ny,&__pyx_n_s_nz,&__pyx_n_s_Lx,&__pyx_n_s_Ly,&__pyx_n_s_Lz,&__pyx_n_s_cmesh,0};
14322 PyObject* values[7] = {0,0,0,0,0,0,0};
14323 if (unlikely(__pyx_kwds)) {
14324 Py_ssize_t kw_args;
14325 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
14326 switch (pos_args) {
14327 case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
14328 CYTHON_FALLTHROUGH;
14329 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
14330 CYTHON_FALLTHROUGH;
14331 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
14332 CYTHON_FALLTHROUGH;
14333 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
14334 CYTHON_FALLTHROUGH;
14335 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
14336 CYTHON_FALLTHROUGH;
14337 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14338 CYTHON_FALLTHROUGH;
14339 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14340 CYTHON_FALLTHROUGH;
14342 default:
goto __pyx_L5_argtuple_error;
14344 kw_args = PyDict_Size(__pyx_kwds);
14345 switch (pos_args) {
14347 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nx)) != 0)) kw_args--;
14348 else goto __pyx_L5_argtuple_error;
14349 CYTHON_FALLTHROUGH;
14351 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ny)) != 0)) kw_args--;
14353 __Pyx_RaiseArgtupleInvalid(
"generateTetrahedralMeshFromRectangularGrid", 1, 7, 7, 1); __PYX_ERR(1, 308, __pyx_L3_error)
14355 CYTHON_FALLTHROUGH;
14357 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nz)) != 0)) kw_args--;
14359 __Pyx_RaiseArgtupleInvalid(
"generateTetrahedralMeshFromRectangularGrid", 1, 7, 7, 2); __PYX_ERR(1, 308, __pyx_L3_error)
14361 CYTHON_FALLTHROUGH;
14363 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Lx)) != 0)) kw_args--;
14365 __Pyx_RaiseArgtupleInvalid(
"generateTetrahedralMeshFromRectangularGrid", 1, 7, 7, 3); __PYX_ERR(1, 308, __pyx_L3_error)
14367 CYTHON_FALLTHROUGH;
14369 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Ly)) != 0)) kw_args--;
14371 __Pyx_RaiseArgtupleInvalid(
"generateTetrahedralMeshFromRectangularGrid", 1, 7, 7, 4); __PYX_ERR(1, 308, __pyx_L3_error)
14373 CYTHON_FALLTHROUGH;
14375 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Lz)) != 0)) kw_args--;
14377 __Pyx_RaiseArgtupleInvalid(
"generateTetrahedralMeshFromRectangularGrid", 1, 7, 7, 5); __PYX_ERR(1, 308, __pyx_L3_error)
14379 CYTHON_FALLTHROUGH;
14381 if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
14383 __Pyx_RaiseArgtupleInvalid(
"generateTetrahedralMeshFromRectangularGrid", 1, 7, 7, 6); __PYX_ERR(1, 308, __pyx_L3_error)
14386 if (unlikely(kw_args > 0)) {
14387 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateTetrahedralMeshFromRectangularGrid") < 0)) __PYX_ERR(1, 308, __pyx_L3_error)
14389 }
else if (PyTuple_GET_SIZE(__pyx_args) != 7) {
14390 goto __pyx_L5_argtuple_error;
14392 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14393 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14394 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
14395 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
14396 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
14397 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
14398 values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
14400 __pyx_v_nx = __Pyx_PyInt_As_int(values[0]);
if (unlikely((__pyx_v_nx == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 308, __pyx_L3_error)
14401 __pyx_v_ny = __Pyx_PyInt_As_int(values[1]);
if (unlikely((__pyx_v_ny == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 309, __pyx_L3_error)
14402 __pyx_v_nz = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_nz == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 310, __pyx_L3_error)
14403 __pyx_v_Lx = __pyx_PyFloat_AsDouble(values[3]);
if (unlikely((__pyx_v_Lx == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 311, __pyx_L3_error)
14404 __pyx_v_Ly = __pyx_PyFloat_AsDouble(values[4]);
if (unlikely((__pyx_v_Ly == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 312, __pyx_L3_error)
14405 __pyx_v_Lz = __pyx_PyFloat_AsDouble(values[5]);
if (unlikely((__pyx_v_Lz == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 313, __pyx_L3_error)
14406 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[6]);
14408 goto __pyx_L4_argument_unpacking_done;
14409 __pyx_L5_argtuple_error:;
14410 __Pyx_RaiseArgtupleInvalid(
"generateTetrahedralMeshFromRectangularGrid", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 308, __pyx_L3_error)
14412 __Pyx_AddTraceback(
"cmeshTools.generateTetrahedralMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
14413 __Pyx_RefNannyFinishContext();
14415 __pyx_L4_argument_unpacking_done:;
14416 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 314, __pyx_L1_error)
14417 __pyx_r = __pyx_pf_10cmeshTools_6generateTetrahedralMeshFromRectangularGrid(__pyx_self, __pyx_v_nx, __pyx_v_ny, __pyx_v_nz, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_Lz, __pyx_v_cmesh);
14424 __Pyx_RefNannyFinishContext();
14428 static PyObject *__pyx_pf_10cmeshTools_6generateTetrahedralMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
int __pyx_v_ny,
int __pyx_v_nz,
double __pyx_v_Lx,
double __pyx_v_Ly,
double __pyx_v_Lz,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
14429 PyObject *__pyx_r = NULL;
14430 __Pyx_RefNannyDeclarations
14431 PyObject *__pyx_t_1 = NULL;
14432 int __pyx_lineno = 0;
14433 const char *__pyx_filename = NULL;
14434 int __pyx_clineno = 0;
14435 __Pyx_RefNannySetupContext(
"generateTetrahedralMeshFromRectangularGrid", 0);
14436 __Pyx_XDECREF(__pyx_r);
14437 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateTetrahedralMeshFromRectangularGrid(__pyx_v_nx, __pyx_v_ny, __pyx_v_nz, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_Lz, __pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 308, __pyx_L1_error)
14438 __Pyx_GOTREF(__pyx_t_1);
14439 __pyx_r = __pyx_t_1;
14445 __Pyx_XDECREF(__pyx_t_1);
14446 __Pyx_AddTraceback(
"cmeshTools.generateTetrahedralMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
14449 __Pyx_XGIVEREF(__pyx_r);
14450 __Pyx_RefNannyFinishContext();
14462 static PyObject *__pyx_pw_10cmeshTools_9cmeshToolsComputeGeometricInfo_tetrahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
14463 static void __pyx_f_10cmeshTools_cmeshToolsComputeGeometricInfo_tetrahedron(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
14464 __Pyx_RefNannyDeclarations
14465 __Pyx_RefNannySetupContext(
"cmeshToolsComputeGeometricInfo_tetrahedron", 0);
14485 __Pyx_RefNannyFinishContext();
14489 static PyObject *__pyx_pw_10cmeshTools_9cmeshToolsComputeGeometricInfo_tetrahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
14490 static PyObject *__pyx_pw_10cmeshTools_9cmeshToolsComputeGeometricInfo_tetrahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
14491 int __pyx_lineno = 0;
14492 const char *__pyx_filename = NULL;
14493 int __pyx_clineno = 0;
14494 PyObject *__pyx_r = 0;
14495 __Pyx_RefNannyDeclarations
14496 __Pyx_RefNannySetupContext(
"cmeshToolsComputeGeometricInfo_tetrahedron (wrapper)", 0);
14497 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 320, __pyx_L1_error)
14498 __pyx_r = __pyx_pf_10cmeshTools_8cmeshToolsComputeGeometricInfo_tetrahedron(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
14505 __Pyx_RefNannyFinishContext();
14509 static PyObject *__pyx_pf_10cmeshTools_8cmeshToolsComputeGeometricInfo_tetrahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
14510 PyObject *__pyx_r = NULL;
14511 __Pyx_RefNannyDeclarations
14512 PyObject *__pyx_t_1 = NULL;
14513 int __pyx_lineno = 0;
14514 const char *__pyx_filename = NULL;
14515 int __pyx_clineno = 0;
14516 __Pyx_RefNannySetupContext(
"cmeshToolsComputeGeometricInfo_tetrahedron", 0);
14517 __Pyx_XDECREF(__pyx_r);
14518 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_cmeshToolsComputeGeometricInfo_tetrahedron(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 320, __pyx_L1_error)
14519 __Pyx_GOTREF(__pyx_t_1);
14520 __pyx_r = __pyx_t_1;
14526 __Pyx_XDECREF(__pyx_t_1);
14527 __Pyx_AddTraceback(
"cmeshTools.cmeshToolsComputeGeometricInfo_tetrahedron", __pyx_clineno, __pyx_lineno, __pyx_filename);
14530 __Pyx_XGIVEREF(__pyx_r);
14531 __Pyx_RefNannyFinishContext();
14543 static PyObject *__pyx_pw_10cmeshTools_11generateFromTriangleFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
14544 static void __pyx_f_10cmeshTools_generateFromTriangleFiles(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
14545 CYTHON_UNUSED
int __pyx_v_failed;
14546 __Pyx_RefNannyDeclarations
14547 PyObject *__pyx_t_1 = NULL;
14548 char const *__pyx_t_2;
14549 char const *__pyx_t_3;
14550 int __pyx_lineno = 0;
14551 const char *__pyx_filename = NULL;
14552 int __pyx_clineno = 0;
14553 __Pyx_RefNannySetupContext(
"generateFromTriangleFiles", 0);
14562 if (unlikely(__pyx_v_filebase == Py_None)) {
14563 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
14564 __PYX_ERR(1, 331, __pyx_L1_error)
14566 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 331, __pyx_L1_error)
14567 __Pyx_GOTREF(__pyx_t_1);
14568 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 331, __pyx_L1_error)
14569 __pyx_v_failed =
readTriangleMesh(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
14570 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
14588 if (unlikely(__pyx_v_filebase == Py_None)) {
14589 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
14590 __PYX_ERR(1, 333, __pyx_L1_error)
14592 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 333, __pyx_L1_error)
14593 __Pyx_GOTREF(__pyx_t_1);
14594 __pyx_t_3 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_3) && PyErr_Occurred())) __PYX_ERR(1, 333, __pyx_L1_error)
14596 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
14609 __Pyx_XDECREF(__pyx_t_1);
14610 __Pyx_WriteUnraisable(
"cmeshTools.generateFromTriangleFiles", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
14612 __Pyx_RefNannyFinishContext();
14616 static PyObject *__pyx_pw_10cmeshTools_11generateFromTriangleFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
14617 static PyObject *__pyx_pw_10cmeshTools_11generateFromTriangleFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
14618 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
14619 PyObject *__pyx_v_filebase = 0;
14621 int __pyx_lineno = 0;
14622 const char *__pyx_filename = NULL;
14623 int __pyx_clineno = 0;
14624 PyObject *__pyx_r = 0;
14625 __Pyx_RefNannyDeclarations
14626 __Pyx_RefNannySetupContext(
"generateFromTriangleFiles (wrapper)", 0);
14628 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
14629 PyObject* values[3] = {0,0,0};
14630 if (unlikely(__pyx_kwds)) {
14631 Py_ssize_t kw_args;
14632 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
14633 switch (pos_args) {
14634 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
14635 CYTHON_FALLTHROUGH;
14636 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14637 CYTHON_FALLTHROUGH;
14638 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14639 CYTHON_FALLTHROUGH;
14641 default:
goto __pyx_L5_argtuple_error;
14643 kw_args = PyDict_Size(__pyx_kwds);
14644 switch (pos_args) {
14646 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
14647 else goto __pyx_L5_argtuple_error;
14648 CYTHON_FALLTHROUGH;
14650 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
14652 __Pyx_RaiseArgtupleInvalid(
"generateFromTriangleFiles", 1, 3, 3, 1); __PYX_ERR(1, 326, __pyx_L3_error)
14654 CYTHON_FALLTHROUGH;
14656 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
14658 __Pyx_RaiseArgtupleInvalid(
"generateFromTriangleFiles", 1, 3, 3, 2); __PYX_ERR(1, 326, __pyx_L3_error)
14661 if (unlikely(kw_args > 0)) {
14662 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateFromTriangleFiles") < 0)) __PYX_ERR(1, 326, __pyx_L3_error)
14664 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
14665 goto __pyx_L5_argtuple_error;
14667 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14668 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14669 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
14671 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
14672 __pyx_v_filebase = ((PyObject*)values[1]);
14673 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 328, __pyx_L3_error)
14675 goto __pyx_L4_argument_unpacking_done;
14676 __pyx_L5_argtuple_error:;
14677 __Pyx_RaiseArgtupleInvalid(
"generateFromTriangleFiles", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 326, __pyx_L3_error)
14679 __Pyx_AddTraceback(
"cmeshTools.generateFromTriangleFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
14680 __Pyx_RefNannyFinishContext();
14682 __pyx_L4_argument_unpacking_done:;
14683 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 326, __pyx_L1_error)
14684 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 327, __pyx_L1_error)
14685 __pyx_r = __pyx_pf_10cmeshTools_10generateFromTriangleFiles(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
14692 __Pyx_RefNannyFinishContext();
14696 static PyObject *__pyx_pf_10cmeshTools_10generateFromTriangleFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
14697 PyObject *__pyx_r = NULL;
14698 __Pyx_RefNannyDeclarations
14699 PyObject *__pyx_t_1 = NULL;
14700 int __pyx_lineno = 0;
14701 const char *__pyx_filename = NULL;
14702 int __pyx_clineno = 0;
14703 __Pyx_RefNannySetupContext(
"generateFromTriangleFiles", 0);
14704 __Pyx_XDECREF(__pyx_r);
14705 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateFromTriangleFiles(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 326, __pyx_L1_error)
14706 __Pyx_GOTREF(__pyx_t_1);
14707 __pyx_r = __pyx_t_1;
14713 __Pyx_XDECREF(__pyx_t_1);
14714 __Pyx_AddTraceback(
"cmeshTools.generateFromTriangleFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
14717 __Pyx_XGIVEREF(__pyx_r);
14718 __Pyx_RefNannyFinishContext();
14730 static PyObject *__pyx_pw_10cmeshTools_13writeTriangleFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
14731 static void __pyx_f_10cmeshTools_writeTriangleFiles(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
14732 CYTHON_UNUSED
int __pyx_v_failed;
14733 __Pyx_RefNannyDeclarations
14734 PyObject *__pyx_t_1 = NULL;
14735 char const *__pyx_t_2;
14736 int __pyx_lineno = 0;
14737 const char *__pyx_filename = NULL;
14738 int __pyx_clineno = 0;
14739 __Pyx_RefNannySetupContext(
"writeTriangleFiles", 0);
14748 if (unlikely(__pyx_v_filebase == Py_None)) {
14749 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
14750 __PYX_ERR(1, 339, __pyx_L1_error)
14752 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 339, __pyx_L1_error)
14753 __Pyx_GOTREF(__pyx_t_1);
14754 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 339, __pyx_L1_error)
14755 __pyx_v_failed =
writeTriangleMesh(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
14756 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
14769 __Pyx_XDECREF(__pyx_t_1);
14770 __Pyx_WriteUnraisable(
"cmeshTools.writeTriangleFiles", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
14772 __Pyx_RefNannyFinishContext();
14776 static PyObject *__pyx_pw_10cmeshTools_13writeTriangleFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
14777 static PyObject *__pyx_pw_10cmeshTools_13writeTriangleFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
14778 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
14779 PyObject *__pyx_v_filebase = 0;
14781 int __pyx_lineno = 0;
14782 const char *__pyx_filename = NULL;
14783 int __pyx_clineno = 0;
14784 PyObject *__pyx_r = 0;
14785 __Pyx_RefNannyDeclarations
14786 __Pyx_RefNannySetupContext(
"writeTriangleFiles (wrapper)", 0);
14788 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
14789 PyObject* values[3] = {0,0,0};
14790 if (unlikely(__pyx_kwds)) {
14791 Py_ssize_t kw_args;
14792 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
14793 switch (pos_args) {
14794 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
14795 CYTHON_FALLTHROUGH;
14796 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14797 CYTHON_FALLTHROUGH;
14798 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14799 CYTHON_FALLTHROUGH;
14801 default:
goto __pyx_L5_argtuple_error;
14803 kw_args = PyDict_Size(__pyx_kwds);
14804 switch (pos_args) {
14806 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
14807 else goto __pyx_L5_argtuple_error;
14808 CYTHON_FALLTHROUGH;
14810 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
14812 __Pyx_RaiseArgtupleInvalid(
"writeTriangleFiles", 1, 3, 3, 1); __PYX_ERR(1, 335, __pyx_L3_error)
14814 CYTHON_FALLTHROUGH;
14816 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
14818 __Pyx_RaiseArgtupleInvalid(
"writeTriangleFiles", 1, 3, 3, 2); __PYX_ERR(1, 335, __pyx_L3_error)
14821 if (unlikely(kw_args > 0)) {
14822 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"writeTriangleFiles") < 0)) __PYX_ERR(1, 335, __pyx_L3_error)
14824 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
14825 goto __pyx_L5_argtuple_error;
14827 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14828 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14829 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
14831 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
14832 __pyx_v_filebase = ((PyObject*)values[1]);
14833 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 337, __pyx_L3_error)
14835 goto __pyx_L4_argument_unpacking_done;
14836 __pyx_L5_argtuple_error:;
14837 __Pyx_RaiseArgtupleInvalid(
"writeTriangleFiles", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 335, __pyx_L3_error)
14839 __Pyx_AddTraceback(
"cmeshTools.writeTriangleFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
14840 __Pyx_RefNannyFinishContext();
14842 __pyx_L4_argument_unpacking_done:;
14843 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 335, __pyx_L1_error)
14844 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 336, __pyx_L1_error)
14845 __pyx_r = __pyx_pf_10cmeshTools_12writeTriangleFiles(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
14852 __Pyx_RefNannyFinishContext();
14856 static PyObject *__pyx_pf_10cmeshTools_12writeTriangleFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
14857 PyObject *__pyx_r = NULL;
14858 __Pyx_RefNannyDeclarations
14859 PyObject *__pyx_t_1 = NULL;
14860 int __pyx_lineno = 0;
14861 const char *__pyx_filename = NULL;
14862 int __pyx_clineno = 0;
14863 __Pyx_RefNannySetupContext(
"writeTriangleFiles", 0);
14864 __Pyx_XDECREF(__pyx_r);
14865 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_writeTriangleFiles(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 335, __pyx_L1_error)
14866 __Pyx_GOTREF(__pyx_t_1);
14867 __pyx_r = __pyx_t_1;
14873 __Pyx_XDECREF(__pyx_t_1);
14874 __Pyx_AddTraceback(
"cmeshTools.writeTriangleFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
14877 __Pyx_XGIVEREF(__pyx_r);
14878 __Pyx_RefNannyFinishContext();
14890 static PyObject *__pyx_pw_10cmeshTools_15generateFromTetgenFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
14891 static void __pyx_f_10cmeshTools_generateFromTetgenFiles(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
14892 CYTHON_UNUSED
int __pyx_v_failed;
14893 __Pyx_RefNannyDeclarations
14894 PyObject *__pyx_t_1 = NULL;
14895 char const *__pyx_t_2;
14896 char const *__pyx_t_3;
14897 int __pyx_lineno = 0;
14898 const char *__pyx_filename = NULL;
14899 int __pyx_clineno = 0;
14900 __Pyx_RefNannySetupContext(
"generateFromTetgenFiles", 0);
14909 if (unlikely(__pyx_v_filebase == Py_None)) {
14910 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
14911 __PYX_ERR(1, 345, __pyx_L1_error)
14913 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 345, __pyx_L1_error)
14914 __Pyx_GOTREF(__pyx_t_1);
14915 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 345, __pyx_L1_error)
14916 __pyx_v_failed =
readTetgenMesh(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
14917 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
14935 if (unlikely(__pyx_v_filebase == Py_None)) {
14936 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
14937 __PYX_ERR(1, 347, __pyx_L1_error)
14939 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 347, __pyx_L1_error)
14940 __Pyx_GOTREF(__pyx_t_1);
14941 __pyx_t_3 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_3) && PyErr_Occurred())) __PYX_ERR(1, 347, __pyx_L1_error)
14943 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
14956 __Pyx_XDECREF(__pyx_t_1);
14957 __Pyx_WriteUnraisable(
"cmeshTools.generateFromTetgenFiles", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
14959 __Pyx_RefNannyFinishContext();
14963 static PyObject *__pyx_pw_10cmeshTools_15generateFromTetgenFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
14964 static PyObject *__pyx_pw_10cmeshTools_15generateFromTetgenFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
14965 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
14966 PyObject *__pyx_v_filebase = 0;
14968 int __pyx_lineno = 0;
14969 const char *__pyx_filename = NULL;
14970 int __pyx_clineno = 0;
14971 PyObject *__pyx_r = 0;
14972 __Pyx_RefNannyDeclarations
14973 __Pyx_RefNannySetupContext(
"generateFromTetgenFiles (wrapper)", 0);
14975 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
14976 PyObject* values[3] = {0,0,0};
14977 if (unlikely(__pyx_kwds)) {
14978 Py_ssize_t kw_args;
14979 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
14980 switch (pos_args) {
14981 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
14982 CYTHON_FALLTHROUGH;
14983 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
14984 CYTHON_FALLTHROUGH;
14985 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
14986 CYTHON_FALLTHROUGH;
14988 default:
goto __pyx_L5_argtuple_error;
14990 kw_args = PyDict_Size(__pyx_kwds);
14991 switch (pos_args) {
14993 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
14994 else goto __pyx_L5_argtuple_error;
14995 CYTHON_FALLTHROUGH;
14997 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
14999 __Pyx_RaiseArgtupleInvalid(
"generateFromTetgenFiles", 1, 3, 3, 1); __PYX_ERR(1, 341, __pyx_L3_error)
15001 CYTHON_FALLTHROUGH;
15003 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
15005 __Pyx_RaiseArgtupleInvalid(
"generateFromTetgenFiles", 1, 3, 3, 2); __PYX_ERR(1, 341, __pyx_L3_error)
15008 if (unlikely(kw_args > 0)) {
15009 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateFromTetgenFiles") < 0)) __PYX_ERR(1, 341, __pyx_L3_error)
15011 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
15012 goto __pyx_L5_argtuple_error;
15014 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15015 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15016 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15018 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
15019 __pyx_v_filebase = ((PyObject*)values[1]);
15020 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 343, __pyx_L3_error)
15022 goto __pyx_L4_argument_unpacking_done;
15023 __pyx_L5_argtuple_error:;
15024 __Pyx_RaiseArgtupleInvalid(
"generateFromTetgenFiles", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 341, __pyx_L3_error)
15026 __Pyx_AddTraceback(
"cmeshTools.generateFromTetgenFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
15027 __Pyx_RefNannyFinishContext();
15029 __pyx_L4_argument_unpacking_done:;
15030 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 341, __pyx_L1_error)
15031 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 342, __pyx_L1_error)
15032 __pyx_r = __pyx_pf_10cmeshTools_14generateFromTetgenFiles(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
15039 __Pyx_RefNannyFinishContext();
15043 static PyObject *__pyx_pf_10cmeshTools_14generateFromTetgenFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
15044 PyObject *__pyx_r = NULL;
15045 __Pyx_RefNannyDeclarations
15046 PyObject *__pyx_t_1 = NULL;
15047 int __pyx_lineno = 0;
15048 const char *__pyx_filename = NULL;
15049 int __pyx_clineno = 0;
15050 __Pyx_RefNannySetupContext(
"generateFromTetgenFiles", 0);
15051 __Pyx_XDECREF(__pyx_r);
15052 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateFromTetgenFiles(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 341, __pyx_L1_error)
15053 __Pyx_GOTREF(__pyx_t_1);
15054 __pyx_r = __pyx_t_1;
15060 __Pyx_XDECREF(__pyx_t_1);
15061 __Pyx_AddTraceback(
"cmeshTools.generateFromTetgenFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
15064 __Pyx_XGIVEREF(__pyx_r);
15065 __Pyx_RefNannyFinishContext();
15077 static PyObject *__pyx_pw_10cmeshTools_17generateFromTetgenFilesParallel(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15078 static void __pyx_f_10cmeshTools_generateFromTetgenFilesParallel(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
15079 CYTHON_UNUSED
int __pyx_v_failed;
15080 __Pyx_RefNannyDeclarations
15081 PyObject *__pyx_t_1 = NULL;
15082 char const *__pyx_t_2;
15083 char const *__pyx_t_3;
15084 int __pyx_lineno = 0;
15085 const char *__pyx_filename = NULL;
15086 int __pyx_clineno = 0;
15087 __Pyx_RefNannySetupContext(
"generateFromTetgenFilesParallel", 0);
15096 if (unlikely(__pyx_v_filebase == Py_None)) {
15097 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
15098 __PYX_ERR(1, 353, __pyx_L1_error)
15100 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 353, __pyx_L1_error)
15101 __Pyx_GOTREF(__pyx_t_1);
15102 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 353, __pyx_L1_error)
15103 __pyx_v_failed =
readTetgenMesh(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
15104 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15122 if (unlikely(__pyx_v_filebase == Py_None)) {
15123 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
15124 __PYX_ERR(1, 355, __pyx_L1_error)
15126 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 355, __pyx_L1_error)
15127 __Pyx_GOTREF(__pyx_t_1);
15128 __pyx_t_3 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_3) && PyErr_Occurred())) __PYX_ERR(1, 355, __pyx_L1_error)
15130 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15143 __Pyx_XDECREF(__pyx_t_1);
15144 __Pyx_WriteUnraisable(
"cmeshTools.generateFromTetgenFilesParallel", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
15146 __Pyx_RefNannyFinishContext();
15150 static PyObject *__pyx_pw_10cmeshTools_17generateFromTetgenFilesParallel(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15151 static PyObject *__pyx_pw_10cmeshTools_17generateFromTetgenFilesParallel(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
15152 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
15153 PyObject *__pyx_v_filebase = 0;
15155 int __pyx_lineno = 0;
15156 const char *__pyx_filename = NULL;
15157 int __pyx_clineno = 0;
15158 PyObject *__pyx_r = 0;
15159 __Pyx_RefNannyDeclarations
15160 __Pyx_RefNannySetupContext(
"generateFromTetgenFilesParallel (wrapper)", 0);
15162 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
15163 PyObject* values[3] = {0,0,0};
15164 if (unlikely(__pyx_kwds)) {
15165 Py_ssize_t kw_args;
15166 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
15167 switch (pos_args) {
15168 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15169 CYTHON_FALLTHROUGH;
15170 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15171 CYTHON_FALLTHROUGH;
15172 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15173 CYTHON_FALLTHROUGH;
15175 default:
goto __pyx_L5_argtuple_error;
15177 kw_args = PyDict_Size(__pyx_kwds);
15178 switch (pos_args) {
15180 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
15181 else goto __pyx_L5_argtuple_error;
15182 CYTHON_FALLTHROUGH;
15184 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
15186 __Pyx_RaiseArgtupleInvalid(
"generateFromTetgenFilesParallel", 1, 3, 3, 1); __PYX_ERR(1, 349, __pyx_L3_error)
15188 CYTHON_FALLTHROUGH;
15190 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
15192 __Pyx_RaiseArgtupleInvalid(
"generateFromTetgenFilesParallel", 1, 3, 3, 2); __PYX_ERR(1, 349, __pyx_L3_error)
15195 if (unlikely(kw_args > 0)) {
15196 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateFromTetgenFilesParallel") < 0)) __PYX_ERR(1, 349, __pyx_L3_error)
15198 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
15199 goto __pyx_L5_argtuple_error;
15201 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15202 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15203 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15205 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
15206 __pyx_v_filebase = ((PyObject*)values[1]);
15207 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 351, __pyx_L3_error)
15209 goto __pyx_L4_argument_unpacking_done;
15210 __pyx_L5_argtuple_error:;
15211 __Pyx_RaiseArgtupleInvalid(
"generateFromTetgenFilesParallel", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 349, __pyx_L3_error)
15213 __Pyx_AddTraceback(
"cmeshTools.generateFromTetgenFilesParallel", __pyx_clineno, __pyx_lineno, __pyx_filename);
15214 __Pyx_RefNannyFinishContext();
15216 __pyx_L4_argument_unpacking_done:;
15217 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 349, __pyx_L1_error)
15218 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 350, __pyx_L1_error)
15219 __pyx_r = __pyx_pf_10cmeshTools_16generateFromTetgenFilesParallel(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
15226 __Pyx_RefNannyFinishContext();
15230 static PyObject *__pyx_pf_10cmeshTools_16generateFromTetgenFilesParallel(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
15231 PyObject *__pyx_r = NULL;
15232 __Pyx_RefNannyDeclarations
15233 PyObject *__pyx_t_1 = NULL;
15234 int __pyx_lineno = 0;
15235 const char *__pyx_filename = NULL;
15236 int __pyx_clineno = 0;
15237 __Pyx_RefNannySetupContext(
"generateFromTetgenFilesParallel", 0);
15238 __Pyx_XDECREF(__pyx_r);
15239 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateFromTetgenFilesParallel(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 349, __pyx_L1_error)
15240 __Pyx_GOTREF(__pyx_t_1);
15241 __pyx_r = __pyx_t_1;
15247 __Pyx_XDECREF(__pyx_t_1);
15248 __Pyx_AddTraceback(
"cmeshTools.generateFromTetgenFilesParallel", __pyx_clineno, __pyx_lineno, __pyx_filename);
15251 __Pyx_XGIVEREF(__pyx_r);
15252 __Pyx_RefNannyFinishContext();
15264 static PyObject *__pyx_pw_10cmeshTools_19writeTetgenFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15265 static void __pyx_f_10cmeshTools_writeTetgenFiles(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
15266 CYTHON_UNUSED
int __pyx_v_failed;
15267 __Pyx_RefNannyDeclarations
15268 PyObject *__pyx_t_1 = NULL;
15269 char const *__pyx_t_2;
15270 int __pyx_lineno = 0;
15271 const char *__pyx_filename = NULL;
15272 int __pyx_clineno = 0;
15273 __Pyx_RefNannySetupContext(
"writeTetgenFiles", 0);
15291 if (unlikely(__pyx_v_filebase == Py_None)) {
15292 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
15293 __PYX_ERR(1, 362, __pyx_L1_error)
15295 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 362, __pyx_L1_error)
15296 __Pyx_GOTREF(__pyx_t_1);
15297 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 362, __pyx_L1_error)
15298 __pyx_v_failed =
writeTetgenMesh(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
15299 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15312 __Pyx_XDECREF(__pyx_t_1);
15313 __Pyx_WriteUnraisable(
"cmeshTools.writeTetgenFiles", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
15315 __Pyx_RefNannyFinishContext();
15319 static PyObject *__pyx_pw_10cmeshTools_19writeTetgenFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15320 static PyObject *__pyx_pw_10cmeshTools_19writeTetgenFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
15321 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
15322 PyObject *__pyx_v_filebase = 0;
15324 int __pyx_lineno = 0;
15325 const char *__pyx_filename = NULL;
15326 int __pyx_clineno = 0;
15327 PyObject *__pyx_r = 0;
15328 __Pyx_RefNannyDeclarations
15329 __Pyx_RefNannySetupContext(
"writeTetgenFiles (wrapper)", 0);
15331 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
15332 PyObject* values[3] = {0,0,0};
15333 if (unlikely(__pyx_kwds)) {
15334 Py_ssize_t kw_args;
15335 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
15336 switch (pos_args) {
15337 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15338 CYTHON_FALLTHROUGH;
15339 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15340 CYTHON_FALLTHROUGH;
15341 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15342 CYTHON_FALLTHROUGH;
15344 default:
goto __pyx_L5_argtuple_error;
15346 kw_args = PyDict_Size(__pyx_kwds);
15347 switch (pos_args) {
15349 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
15350 else goto __pyx_L5_argtuple_error;
15351 CYTHON_FALLTHROUGH;
15353 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
15355 __Pyx_RaiseArgtupleInvalid(
"writeTetgenFiles", 1, 3, 3, 1); __PYX_ERR(1, 357, __pyx_L3_error)
15357 CYTHON_FALLTHROUGH;
15359 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
15361 __Pyx_RaiseArgtupleInvalid(
"writeTetgenFiles", 1, 3, 3, 2); __PYX_ERR(1, 357, __pyx_L3_error)
15364 if (unlikely(kw_args > 0)) {
15365 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"writeTetgenFiles") < 0)) __PYX_ERR(1, 357, __pyx_L3_error)
15367 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
15368 goto __pyx_L5_argtuple_error;
15370 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15371 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15372 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15374 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
15375 __pyx_v_filebase = ((PyObject*)values[1]);
15376 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 359, __pyx_L3_error)
15378 goto __pyx_L4_argument_unpacking_done;
15379 __pyx_L5_argtuple_error:;
15380 __Pyx_RaiseArgtupleInvalid(
"writeTetgenFiles", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 357, __pyx_L3_error)
15382 __Pyx_AddTraceback(
"cmeshTools.writeTetgenFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
15383 __Pyx_RefNannyFinishContext();
15385 __pyx_L4_argument_unpacking_done:;
15386 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 357, __pyx_L1_error)
15387 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 358, __pyx_L1_error)
15388 __pyx_r = __pyx_pf_10cmeshTools_18writeTetgenFiles(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
15395 __Pyx_RefNannyFinishContext();
15399 static PyObject *__pyx_pf_10cmeshTools_18writeTetgenFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
15400 PyObject *__pyx_r = NULL;
15401 __Pyx_RefNannyDeclarations
15402 PyObject *__pyx_t_1 = NULL;
15403 int __pyx_lineno = 0;
15404 const char *__pyx_filename = NULL;
15405 int __pyx_clineno = 0;
15406 __Pyx_RefNannySetupContext(
"writeTetgenFiles", 0);
15407 __Pyx_XDECREF(__pyx_r);
15408 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_writeTetgenFiles(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 357, __pyx_L1_error)
15409 __Pyx_GOTREF(__pyx_t_1);
15410 __pyx_r = __pyx_t_1;
15416 __Pyx_XDECREF(__pyx_t_1);
15417 __Pyx_AddTraceback(
"cmeshTools.writeTetgenFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
15420 __Pyx_XGIVEREF(__pyx_r);
15421 __Pyx_RefNannyFinishContext();
15433 static PyObject *__pyx_pw_10cmeshTools_21write3dmFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15434 static void __pyx_f_10cmeshTools_write3dmFiles(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
15435 CYTHON_UNUSED
int __pyx_v_failed;
15436 __Pyx_RefNannyDeclarations
15437 PyObject *__pyx_t_1 = NULL;
15438 char const *__pyx_t_2;
15439 int __pyx_lineno = 0;
15440 const char *__pyx_filename = NULL;
15441 int __pyx_clineno = 0;
15442 __Pyx_RefNannySetupContext(
"write3dmFiles", 0);
15451 if (unlikely(__pyx_v_filebase == Py_None)) {
15452 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
15453 __PYX_ERR(1, 368, __pyx_L1_error)
15455 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 368, __pyx_L1_error)
15456 __Pyx_GOTREF(__pyx_t_1);
15457 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 368, __pyx_L1_error)
15458 __pyx_v_failed =
write3dmMesh(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
15459 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15472 __Pyx_XDECREF(__pyx_t_1);
15473 __Pyx_WriteUnraisable(
"cmeshTools.write3dmFiles", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
15475 __Pyx_RefNannyFinishContext();
15479 static PyObject *__pyx_pw_10cmeshTools_21write3dmFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15480 static PyObject *__pyx_pw_10cmeshTools_21write3dmFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
15481 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
15482 PyObject *__pyx_v_filebase = 0;
15484 int __pyx_lineno = 0;
15485 const char *__pyx_filename = NULL;
15486 int __pyx_clineno = 0;
15487 PyObject *__pyx_r = 0;
15488 __Pyx_RefNannyDeclarations
15489 __Pyx_RefNannySetupContext(
"write3dmFiles (wrapper)", 0);
15491 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
15492 PyObject* values[3] = {0,0,0};
15493 if (unlikely(__pyx_kwds)) {
15494 Py_ssize_t kw_args;
15495 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
15496 switch (pos_args) {
15497 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15498 CYTHON_FALLTHROUGH;
15499 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15500 CYTHON_FALLTHROUGH;
15501 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15502 CYTHON_FALLTHROUGH;
15504 default:
goto __pyx_L5_argtuple_error;
15506 kw_args = PyDict_Size(__pyx_kwds);
15507 switch (pos_args) {
15509 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
15510 else goto __pyx_L5_argtuple_error;
15511 CYTHON_FALLTHROUGH;
15513 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
15515 __Pyx_RaiseArgtupleInvalid(
"write3dmFiles", 1, 3, 3, 1); __PYX_ERR(1, 364, __pyx_L3_error)
15517 CYTHON_FALLTHROUGH;
15519 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
15521 __Pyx_RaiseArgtupleInvalid(
"write3dmFiles", 1, 3, 3, 2); __PYX_ERR(1, 364, __pyx_L3_error)
15524 if (unlikely(kw_args > 0)) {
15525 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"write3dmFiles") < 0)) __PYX_ERR(1, 364, __pyx_L3_error)
15527 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
15528 goto __pyx_L5_argtuple_error;
15530 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15531 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15532 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15534 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
15535 __pyx_v_filebase = ((PyObject*)values[1]);
15536 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 366, __pyx_L3_error)
15538 goto __pyx_L4_argument_unpacking_done;
15539 __pyx_L5_argtuple_error:;
15540 __Pyx_RaiseArgtupleInvalid(
"write3dmFiles", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 364, __pyx_L3_error)
15542 __Pyx_AddTraceback(
"cmeshTools.write3dmFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
15543 __Pyx_RefNannyFinishContext();
15545 __pyx_L4_argument_unpacking_done:;
15546 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 364, __pyx_L1_error)
15547 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 365, __pyx_L1_error)
15548 __pyx_r = __pyx_pf_10cmeshTools_20write3dmFiles(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
15555 __Pyx_RefNannyFinishContext();
15559 static PyObject *__pyx_pf_10cmeshTools_20write3dmFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
15560 PyObject *__pyx_r = NULL;
15561 __Pyx_RefNannyDeclarations
15562 PyObject *__pyx_t_1 = NULL;
15563 int __pyx_lineno = 0;
15564 const char *__pyx_filename = NULL;
15565 int __pyx_clineno = 0;
15566 __Pyx_RefNannySetupContext(
"write3dmFiles", 0);
15567 __Pyx_XDECREF(__pyx_r);
15568 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_write3dmFiles(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 364, __pyx_L1_error)
15569 __Pyx_GOTREF(__pyx_t_1);
15570 __pyx_r = __pyx_t_1;
15576 __Pyx_XDECREF(__pyx_t_1);
15577 __Pyx_AddTraceback(
"cmeshTools.write3dmFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
15580 __Pyx_XGIVEREF(__pyx_r);
15581 __Pyx_RefNannyFinishContext();
15593 static PyObject *__pyx_pw_10cmeshTools_23write2dmFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15594 static void __pyx_f_10cmeshTools_write2dmFiles(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
15595 CYTHON_UNUSED
int __pyx_v_failed;
15596 __Pyx_RefNannyDeclarations
15597 PyObject *__pyx_t_1 = NULL;
15598 char const *__pyx_t_2;
15599 int __pyx_lineno = 0;
15600 const char *__pyx_filename = NULL;
15601 int __pyx_clineno = 0;
15602 __Pyx_RefNannySetupContext(
"write2dmFiles", 0);
15611 if (unlikely(__pyx_v_filebase == Py_None)) {
15612 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
15613 __PYX_ERR(1, 374, __pyx_L1_error)
15615 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 374, __pyx_L1_error)
15616 __Pyx_GOTREF(__pyx_t_1);
15617 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 374, __pyx_L1_error)
15618 __pyx_v_failed =
write2dmMesh(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
15619 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15632 __Pyx_XDECREF(__pyx_t_1);
15633 __Pyx_WriteUnraisable(
"cmeshTools.write2dmFiles", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
15635 __Pyx_RefNannyFinishContext();
15639 static PyObject *__pyx_pw_10cmeshTools_23write2dmFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15640 static PyObject *__pyx_pw_10cmeshTools_23write2dmFiles(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
15641 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
15642 PyObject *__pyx_v_filebase = 0;
15644 int __pyx_lineno = 0;
15645 const char *__pyx_filename = NULL;
15646 int __pyx_clineno = 0;
15647 PyObject *__pyx_r = 0;
15648 __Pyx_RefNannyDeclarations
15649 __Pyx_RefNannySetupContext(
"write2dmFiles (wrapper)", 0);
15651 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
15652 PyObject* values[3] = {0,0,0};
15653 if (unlikely(__pyx_kwds)) {
15654 Py_ssize_t kw_args;
15655 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
15656 switch (pos_args) {
15657 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15658 CYTHON_FALLTHROUGH;
15659 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15660 CYTHON_FALLTHROUGH;
15661 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15662 CYTHON_FALLTHROUGH;
15664 default:
goto __pyx_L5_argtuple_error;
15666 kw_args = PyDict_Size(__pyx_kwds);
15667 switch (pos_args) {
15669 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
15670 else goto __pyx_L5_argtuple_error;
15671 CYTHON_FALLTHROUGH;
15673 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
15675 __Pyx_RaiseArgtupleInvalid(
"write2dmFiles", 1, 3, 3, 1); __PYX_ERR(1, 370, __pyx_L3_error)
15677 CYTHON_FALLTHROUGH;
15679 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
15681 __Pyx_RaiseArgtupleInvalid(
"write2dmFiles", 1, 3, 3, 2); __PYX_ERR(1, 370, __pyx_L3_error)
15684 if (unlikely(kw_args > 0)) {
15685 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"write2dmFiles") < 0)) __PYX_ERR(1, 370, __pyx_L3_error)
15687 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
15688 goto __pyx_L5_argtuple_error;
15690 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15691 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15692 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15694 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
15695 __pyx_v_filebase = ((PyObject*)values[1]);
15696 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 372, __pyx_L3_error)
15698 goto __pyx_L4_argument_unpacking_done;
15699 __pyx_L5_argtuple_error:;
15700 __Pyx_RaiseArgtupleInvalid(
"write2dmFiles", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 370, __pyx_L3_error)
15702 __Pyx_AddTraceback(
"cmeshTools.write2dmFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
15703 __Pyx_RefNannyFinishContext();
15705 __pyx_L4_argument_unpacking_done:;
15706 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 370, __pyx_L1_error)
15707 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 371, __pyx_L1_error)
15708 __pyx_r = __pyx_pf_10cmeshTools_22write2dmFiles(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
15715 __Pyx_RefNannyFinishContext();
15719 static PyObject *__pyx_pf_10cmeshTools_22write2dmFiles(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
15720 PyObject *__pyx_r = NULL;
15721 __Pyx_RefNannyDeclarations
15722 PyObject *__pyx_t_1 = NULL;
15723 int __pyx_lineno = 0;
15724 const char *__pyx_filename = NULL;
15725 int __pyx_clineno = 0;
15726 __Pyx_RefNannySetupContext(
"write2dmFiles", 0);
15727 __Pyx_XDECREF(__pyx_r);
15728 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_write2dmFiles(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 370, __pyx_L1_error)
15729 __Pyx_GOTREF(__pyx_t_1);
15730 __pyx_r = __pyx_t_1;
15736 __Pyx_XDECREF(__pyx_t_1);
15737 __Pyx_AddTraceback(
"cmeshTools.write2dmFiles", __pyx_clineno, __pyx_lineno, __pyx_filename);
15740 __Pyx_XGIVEREF(__pyx_r);
15741 __Pyx_RefNannyFinishContext();
15753 static PyObject *__pyx_pw_10cmeshTools_25generateFromHexFile(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15754 static void __pyx_f_10cmeshTools_generateFromHexFile(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
15755 CYTHON_UNUSED
int __pyx_v_failed;
15756 __Pyx_RefNannyDeclarations
15757 PyObject *__pyx_t_1 = NULL;
15758 char const *__pyx_t_2;
15759 int __pyx_lineno = 0;
15760 const char *__pyx_filename = NULL;
15761 int __pyx_clineno = 0;
15762 __Pyx_RefNannySetupContext(
"generateFromHexFile", 0);
15771 if (unlikely(__pyx_v_filebase == Py_None)) {
15772 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
15773 __PYX_ERR(1, 380, __pyx_L1_error)
15775 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 380, __pyx_L1_error)
15776 __Pyx_GOTREF(__pyx_t_1);
15777 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 380, __pyx_L1_error)
15778 __pyx_v_failed =
readHex(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
15779 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15801 __Pyx_XDECREF(__pyx_t_1);
15802 __Pyx_WriteUnraisable(
"cmeshTools.generateFromHexFile", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
15804 __Pyx_RefNannyFinishContext();
15808 static PyObject *__pyx_pw_10cmeshTools_25generateFromHexFile(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15809 static PyObject *__pyx_pw_10cmeshTools_25generateFromHexFile(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
15810 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
15811 PyObject *__pyx_v_filebase = 0;
15813 int __pyx_lineno = 0;
15814 const char *__pyx_filename = NULL;
15815 int __pyx_clineno = 0;
15816 PyObject *__pyx_r = 0;
15817 __Pyx_RefNannyDeclarations
15818 __Pyx_RefNannySetupContext(
"generateFromHexFile (wrapper)", 0);
15820 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
15821 PyObject* values[3] = {0,0,0};
15822 if (unlikely(__pyx_kwds)) {
15823 Py_ssize_t kw_args;
15824 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
15825 switch (pos_args) {
15826 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15827 CYTHON_FALLTHROUGH;
15828 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15829 CYTHON_FALLTHROUGH;
15830 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15831 CYTHON_FALLTHROUGH;
15833 default:
goto __pyx_L5_argtuple_error;
15835 kw_args = PyDict_Size(__pyx_kwds);
15836 switch (pos_args) {
15838 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
15839 else goto __pyx_L5_argtuple_error;
15840 CYTHON_FALLTHROUGH;
15842 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
15844 __Pyx_RaiseArgtupleInvalid(
"generateFromHexFile", 1, 3, 3, 1); __PYX_ERR(1, 376, __pyx_L3_error)
15846 CYTHON_FALLTHROUGH;
15848 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
15850 __Pyx_RaiseArgtupleInvalid(
"generateFromHexFile", 1, 3, 3, 2); __PYX_ERR(1, 376, __pyx_L3_error)
15853 if (unlikely(kw_args > 0)) {
15854 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateFromHexFile") < 0)) __PYX_ERR(1, 376, __pyx_L3_error)
15856 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
15857 goto __pyx_L5_argtuple_error;
15859 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
15860 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
15861 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
15863 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
15864 __pyx_v_filebase = ((PyObject*)values[1]);
15865 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 378, __pyx_L3_error)
15867 goto __pyx_L4_argument_unpacking_done;
15868 __pyx_L5_argtuple_error:;
15869 __Pyx_RaiseArgtupleInvalid(
"generateFromHexFile", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 376, __pyx_L3_error)
15871 __Pyx_AddTraceback(
"cmeshTools.generateFromHexFile", __pyx_clineno, __pyx_lineno, __pyx_filename);
15872 __Pyx_RefNannyFinishContext();
15874 __pyx_L4_argument_unpacking_done:;
15875 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 376, __pyx_L1_error)
15876 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 377, __pyx_L1_error)
15877 __pyx_r = __pyx_pf_10cmeshTools_24generateFromHexFile(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
15884 __Pyx_RefNannyFinishContext();
15888 static PyObject *__pyx_pf_10cmeshTools_24generateFromHexFile(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
15889 PyObject *__pyx_r = NULL;
15890 __Pyx_RefNannyDeclarations
15891 PyObject *__pyx_t_1 = NULL;
15892 int __pyx_lineno = 0;
15893 const char *__pyx_filename = NULL;
15894 int __pyx_clineno = 0;
15895 __Pyx_RefNannySetupContext(
"generateFromHexFile", 0);
15896 __Pyx_XDECREF(__pyx_r);
15897 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateFromHexFile(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 376, __pyx_L1_error)
15898 __Pyx_GOTREF(__pyx_t_1);
15899 __pyx_r = __pyx_t_1;
15905 __Pyx_XDECREF(__pyx_t_1);
15906 __Pyx_AddTraceback(
"cmeshTools.generateFromHexFile", __pyx_clineno, __pyx_lineno, __pyx_filename);
15909 __Pyx_XGIVEREF(__pyx_r);
15910 __Pyx_RefNannyFinishContext();
15922 static PyObject *__pyx_pw_10cmeshTools_27generateFrom3DMFile(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15923 static void __pyx_f_10cmeshTools_generateFrom3DMFile(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
15924 CYTHON_UNUSED
int __pyx_v_failed;
15925 __Pyx_RefNannyDeclarations
15926 PyObject *__pyx_t_1 = NULL;
15927 char const *__pyx_t_2;
15928 char const *__pyx_t_3;
15929 int __pyx_lineno = 0;
15930 const char *__pyx_filename = NULL;
15931 int __pyx_clineno = 0;
15932 __Pyx_RefNannySetupContext(
"generateFrom3DMFile", 0);
15941 if (unlikely(__pyx_v_filebase == Py_None)) {
15942 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
15943 __PYX_ERR(1, 387, __pyx_L1_error)
15945 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 387, __pyx_L1_error)
15946 __Pyx_GOTREF(__pyx_t_1);
15947 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 387, __pyx_L1_error)
15948 __pyx_v_failed =
read3DM(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
15949 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15967 if (unlikely(__pyx_v_filebase == Py_None)) {
15968 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
15969 __PYX_ERR(1, 389, __pyx_L1_error)
15971 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 389, __pyx_L1_error)
15972 __Pyx_GOTREF(__pyx_t_1);
15973 __pyx_t_3 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_3) && PyErr_Occurred())) __PYX_ERR(1, 389, __pyx_L1_error)
15974 __pyx_v_failed =
readBC(__pyx_v_cmesh->mesh, __pyx_t_3, __pyx_v_base);
15975 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
15988 __Pyx_XDECREF(__pyx_t_1);
15989 __Pyx_WriteUnraisable(
"cmeshTools.generateFrom3DMFile", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
15991 __Pyx_RefNannyFinishContext();
15995 static PyObject *__pyx_pw_10cmeshTools_27generateFrom3DMFile(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
15996 static PyObject *__pyx_pw_10cmeshTools_27generateFrom3DMFile(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
15997 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
15998 PyObject *__pyx_v_filebase = 0;
16000 int __pyx_lineno = 0;
16001 const char *__pyx_filename = NULL;
16002 int __pyx_clineno = 0;
16003 PyObject *__pyx_r = 0;
16004 __Pyx_RefNannyDeclarations
16005 __Pyx_RefNannySetupContext(
"generateFrom3DMFile (wrapper)", 0);
16007 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
16008 PyObject* values[3] = {0,0,0};
16009 if (unlikely(__pyx_kwds)) {
16010 Py_ssize_t kw_args;
16011 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
16012 switch (pos_args) {
16013 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
16014 CYTHON_FALLTHROUGH;
16015 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16016 CYTHON_FALLTHROUGH;
16017 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16018 CYTHON_FALLTHROUGH;
16020 default:
goto __pyx_L5_argtuple_error;
16022 kw_args = PyDict_Size(__pyx_kwds);
16023 switch (pos_args) {
16025 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
16026 else goto __pyx_L5_argtuple_error;
16027 CYTHON_FALLTHROUGH;
16029 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
16031 __Pyx_RaiseArgtupleInvalid(
"generateFrom3DMFile", 1, 3, 3, 1); __PYX_ERR(1, 383, __pyx_L3_error)
16033 CYTHON_FALLTHROUGH;
16035 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
16037 __Pyx_RaiseArgtupleInvalid(
"generateFrom3DMFile", 1, 3, 3, 2); __PYX_ERR(1, 383, __pyx_L3_error)
16040 if (unlikely(kw_args > 0)) {
16041 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateFrom3DMFile") < 0)) __PYX_ERR(1, 383, __pyx_L3_error)
16043 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
16044 goto __pyx_L5_argtuple_error;
16046 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16047 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16048 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
16050 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
16051 __pyx_v_filebase = ((PyObject*)values[1]);
16052 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 385, __pyx_L3_error)
16054 goto __pyx_L4_argument_unpacking_done;
16055 __pyx_L5_argtuple_error:;
16056 __Pyx_RaiseArgtupleInvalid(
"generateFrom3DMFile", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 383, __pyx_L3_error)
16058 __Pyx_AddTraceback(
"cmeshTools.generateFrom3DMFile", __pyx_clineno, __pyx_lineno, __pyx_filename);
16059 __Pyx_RefNannyFinishContext();
16061 __pyx_L4_argument_unpacking_done:;
16062 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 383, __pyx_L1_error)
16063 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 384, __pyx_L1_error)
16064 __pyx_r = __pyx_pf_10cmeshTools_26generateFrom3DMFile(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
16071 __Pyx_RefNannyFinishContext();
16075 static PyObject *__pyx_pf_10cmeshTools_26generateFrom3DMFile(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
16076 PyObject *__pyx_r = NULL;
16077 __Pyx_RefNannyDeclarations
16078 PyObject *__pyx_t_1 = NULL;
16079 int __pyx_lineno = 0;
16080 const char *__pyx_filename = NULL;
16081 int __pyx_clineno = 0;
16082 __Pyx_RefNannySetupContext(
"generateFrom3DMFile", 0);
16083 __Pyx_XDECREF(__pyx_r);
16084 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateFrom3DMFile(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 383, __pyx_L1_error)
16085 __Pyx_GOTREF(__pyx_t_1);
16086 __pyx_r = __pyx_t_1;
16092 __Pyx_XDECREF(__pyx_t_1);
16093 __Pyx_AddTraceback(
"cmeshTools.generateFrom3DMFile", __pyx_clineno, __pyx_lineno, __pyx_filename);
16096 __Pyx_XGIVEREF(__pyx_r);
16097 __Pyx_RefNannyFinishContext();
16109 static PyObject *__pyx_pw_10cmeshTools_29generateFrom2DMFile(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
16110 static void __pyx_f_10cmeshTools_generateFrom2DMFile(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base, CYTHON_UNUSED
int __pyx_skip_dispatch) {
16111 CYTHON_UNUSED
int __pyx_v_failed;
16112 __Pyx_RefNannyDeclarations
16113 PyObject *__pyx_t_1 = NULL;
16114 char const *__pyx_t_2;
16115 char const *__pyx_t_3;
16116 int __pyx_lineno = 0;
16117 const char *__pyx_filename = NULL;
16118 int __pyx_clineno = 0;
16119 __Pyx_RefNannySetupContext(
"generateFrom2DMFile", 0);
16128 if (unlikely(__pyx_v_filebase == Py_None)) {
16129 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
16130 __PYX_ERR(1, 395, __pyx_L1_error)
16132 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 395, __pyx_L1_error)
16133 __Pyx_GOTREF(__pyx_t_1);
16134 __pyx_t_2 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_2) && PyErr_Occurred())) __PYX_ERR(1, 395, __pyx_L1_error)
16135 __pyx_v_failed =
read2DM(__pyx_v_cmesh->mesh, __pyx_t_2, __pyx_v_base);
16136 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16154 if (unlikely(__pyx_v_filebase == Py_None)) {
16155 PyErr_Format(PyExc_AttributeError,
"'NoneType' object has no attribute '%.30s'",
"encode");
16156 __PYX_ERR(1, 397, __pyx_L1_error)
16158 __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_filebase);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 397, __pyx_L1_error)
16159 __Pyx_GOTREF(__pyx_t_1);
16160 __pyx_t_3 = __Pyx_PyBytes_AsString(__pyx_t_1);
if (unlikely((!__pyx_t_3) && PyErr_Occurred())) __PYX_ERR(1, 397, __pyx_L1_error)
16161 __pyx_v_failed =
readBC(__pyx_v_cmesh->mesh, __pyx_t_3, __pyx_v_base);
16162 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
16175 __Pyx_XDECREF(__pyx_t_1);
16176 __Pyx_WriteUnraisable(
"cmeshTools.generateFrom2DMFile", __pyx_clineno, __pyx_lineno, __pyx_filename, 1, 0);
16178 __Pyx_RefNannyFinishContext();
16182 static PyObject *__pyx_pw_10cmeshTools_29generateFrom2DMFile(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
16183 static PyObject *__pyx_pw_10cmeshTools_29generateFrom2DMFile(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
16184 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
16185 PyObject *__pyx_v_filebase = 0;
16187 int __pyx_lineno = 0;
16188 const char *__pyx_filename = NULL;
16189 int __pyx_clineno = 0;
16190 PyObject *__pyx_r = 0;
16191 __Pyx_RefNannyDeclarations
16192 __Pyx_RefNannySetupContext(
"generateFrom2DMFile (wrapper)", 0);
16194 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_filebase,&__pyx_n_s_base,0};
16195 PyObject* values[3] = {0,0,0};
16196 if (unlikely(__pyx_kwds)) {
16197 Py_ssize_t kw_args;
16198 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
16199 switch (pos_args) {
16200 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
16201 CYTHON_FALLTHROUGH;
16202 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16203 CYTHON_FALLTHROUGH;
16204 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16205 CYTHON_FALLTHROUGH;
16207 default:
goto __pyx_L5_argtuple_error;
16209 kw_args = PyDict_Size(__pyx_kwds);
16210 switch (pos_args) {
16212 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
16213 else goto __pyx_L5_argtuple_error;
16214 CYTHON_FALLTHROUGH;
16216 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_filebase)) != 0)) kw_args--;
16218 __Pyx_RaiseArgtupleInvalid(
"generateFrom2DMFile", 1, 3, 3, 1); __PYX_ERR(1, 391, __pyx_L3_error)
16220 CYTHON_FALLTHROUGH;
16222 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_base)) != 0)) kw_args--;
16224 __Pyx_RaiseArgtupleInvalid(
"generateFrom2DMFile", 1, 3, 3, 2); __PYX_ERR(1, 391, __pyx_L3_error)
16227 if (unlikely(kw_args > 0)) {
16228 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateFrom2DMFile") < 0)) __PYX_ERR(1, 391, __pyx_L3_error)
16230 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
16231 goto __pyx_L5_argtuple_error;
16233 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16234 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16235 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
16237 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
16238 __pyx_v_filebase = ((PyObject*)values[1]);
16239 __pyx_v_base = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_base == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 393, __pyx_L3_error)
16241 goto __pyx_L4_argument_unpacking_done;
16242 __pyx_L5_argtuple_error:;
16243 __Pyx_RaiseArgtupleInvalid(
"generateFrom2DMFile", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 391, __pyx_L3_error)
16245 __Pyx_AddTraceback(
"cmeshTools.generateFrom2DMFile", __pyx_clineno, __pyx_lineno, __pyx_filename);
16246 __Pyx_RefNannyFinishContext();
16248 __pyx_L4_argument_unpacking_done:;
16249 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 391, __pyx_L1_error)
16250 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_filebase), (&PyUnicode_Type), 1,
"filebase", 1))) __PYX_ERR(1, 392, __pyx_L1_error)
16251 __pyx_r = __pyx_pf_10cmeshTools_28generateFrom2DMFile(__pyx_self, __pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base);
16258 __Pyx_RefNannyFinishContext();
16262 static PyObject *__pyx_pf_10cmeshTools_28generateFrom2DMFile(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, PyObject *__pyx_v_filebase,
int __pyx_v_base) {
16263 PyObject *__pyx_r = NULL;
16264 __Pyx_RefNannyDeclarations
16265 PyObject *__pyx_t_1 = NULL;
16266 int __pyx_lineno = 0;
16267 const char *__pyx_filename = NULL;
16268 int __pyx_clineno = 0;
16269 __Pyx_RefNannySetupContext(
"generateFrom2DMFile", 0);
16270 __Pyx_XDECREF(__pyx_r);
16271 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateFrom2DMFile(__pyx_v_cmesh, __pyx_v_filebase, __pyx_v_base, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 391, __pyx_L1_error)
16272 __Pyx_GOTREF(__pyx_t_1);
16273 __pyx_r = __pyx_t_1;
16279 __Pyx_XDECREF(__pyx_t_1);
16280 __Pyx_AddTraceback(
"cmeshTools.generateFrom2DMFile", __pyx_clineno, __pyx_lineno, __pyx_filename);
16283 __Pyx_XGIVEREF(__pyx_r);
16284 __Pyx_RefNannyFinishContext();
16296 static PyObject *__pyx_pw_10cmeshTools_31computeGeometricInfo_tetrahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
16297 static void __pyx_f_10cmeshTools_computeGeometricInfo_tetrahedron(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
16298 __Pyx_RefNannyDeclarations
16299 __Pyx_RefNannySetupContext(
"computeGeometricInfo_tetrahedron", 0);
16319 __Pyx_RefNannyFinishContext();
16323 static PyObject *__pyx_pw_10cmeshTools_31computeGeometricInfo_tetrahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
16324 static PyObject *__pyx_pw_10cmeshTools_31computeGeometricInfo_tetrahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
16325 int __pyx_lineno = 0;
16326 const char *__pyx_filename = NULL;
16327 int __pyx_clineno = 0;
16328 PyObject *__pyx_r = 0;
16329 __Pyx_RefNannyDeclarations
16330 __Pyx_RefNannySetupContext(
"computeGeometricInfo_tetrahedron (wrapper)", 0);
16331 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 399, __pyx_L1_error)
16332 __pyx_r = __pyx_pf_10cmeshTools_30computeGeometricInfo_tetrahedron(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
16339 __Pyx_RefNannyFinishContext();
16343 static PyObject *__pyx_pf_10cmeshTools_30computeGeometricInfo_tetrahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
16344 PyObject *__pyx_r = NULL;
16345 __Pyx_RefNannyDeclarations
16346 PyObject *__pyx_t_1 = NULL;
16347 int __pyx_lineno = 0;
16348 const char *__pyx_filename = NULL;
16349 int __pyx_clineno = 0;
16350 __Pyx_RefNannySetupContext(
"computeGeometricInfo_tetrahedron", 0);
16351 __Pyx_XDECREF(__pyx_r);
16352 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_computeGeometricInfo_tetrahedron(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 399, __pyx_L1_error)
16353 __Pyx_GOTREF(__pyx_t_1);
16354 __pyx_r = __pyx_t_1;
16360 __Pyx_XDECREF(__pyx_t_1);
16361 __Pyx_AddTraceback(
"cmeshTools.computeGeometricInfo_tetrahedron", __pyx_clineno, __pyx_lineno, __pyx_filename);
16364 __Pyx_XGIVEREF(__pyx_r);
16365 __Pyx_RefNannyFinishContext();
16377 static PyObject *__pyx_pw_10cmeshTools_33allocateGeometricInfo_tetrahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
16378 static void __pyx_f_10cmeshTools_allocateGeometricInfo_tetrahedron(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
16379 __Pyx_RefNannyDeclarations
16380 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_tetrahedron", 0);
16400 __Pyx_RefNannyFinishContext();
16404 static PyObject *__pyx_pw_10cmeshTools_33allocateGeometricInfo_tetrahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
16405 static PyObject *__pyx_pw_10cmeshTools_33allocateGeometricInfo_tetrahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
16406 int __pyx_lineno = 0;
16407 const char *__pyx_filename = NULL;
16408 int __pyx_clineno = 0;
16409 PyObject *__pyx_r = 0;
16410 __Pyx_RefNannyDeclarations
16411 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_tetrahedron (wrapper)", 0);
16412 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 402, __pyx_L1_error)
16413 __pyx_r = __pyx_pf_10cmeshTools_32allocateGeometricInfo_tetrahedron(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
16420 __Pyx_RefNannyFinishContext();
16424 static PyObject *__pyx_pf_10cmeshTools_32allocateGeometricInfo_tetrahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
16425 PyObject *__pyx_r = NULL;
16426 __Pyx_RefNannyDeclarations
16427 PyObject *__pyx_t_1 = NULL;
16428 int __pyx_lineno = 0;
16429 const char *__pyx_filename = NULL;
16430 int __pyx_clineno = 0;
16431 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_tetrahedron", 0);
16432 __Pyx_XDECREF(__pyx_r);
16433 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_allocateGeometricInfo_tetrahedron(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 402, __pyx_L1_error)
16434 __Pyx_GOTREF(__pyx_t_1);
16435 __pyx_r = __pyx_t_1;
16441 __Pyx_XDECREF(__pyx_t_1);
16442 __Pyx_AddTraceback(
"cmeshTools.allocateGeometricInfo_tetrahedron", __pyx_clineno, __pyx_lineno, __pyx_filename);
16445 __Pyx_XGIVEREF(__pyx_r);
16446 __Pyx_RefNannyFinishContext();
16458 static PyObject *__pyx_pw_10cmeshTools_35allocateNodeAndElementNodeDataStructures(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
16459 static void __pyx_f_10cmeshTools_allocateNodeAndElementNodeDataStructures(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh,
int __pyx_v_nElements_global,
int __pyx_v_nNodes_global,
int __pyx_v_nNodes_element, CYTHON_UNUSED
int __pyx_skip_dispatch) {
16460 __Pyx_RefNannyDeclarations
16461 __Pyx_RefNannySetupContext(
"allocateNodeAndElementNodeDataStructures", 0);
16481 __Pyx_RefNannyFinishContext();
16485 static PyObject *__pyx_pw_10cmeshTools_35allocateNodeAndElementNodeDataStructures(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
16486 static PyObject *__pyx_pw_10cmeshTools_35allocateNodeAndElementNodeDataStructures(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
16487 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
16488 int __pyx_v_nElements_global;
16489 int __pyx_v_nNodes_global;
16490 int __pyx_v_nNodes_element;
16491 int __pyx_lineno = 0;
16492 const char *__pyx_filename = NULL;
16493 int __pyx_clineno = 0;
16494 PyObject *__pyx_r = 0;
16495 __Pyx_RefNannyDeclarations
16496 __Pyx_RefNannySetupContext(
"allocateNodeAndElementNodeDataStructures (wrapper)", 0);
16498 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_cmesh,&__pyx_n_s_nElements_global,&__pyx_n_s_nNodes_global,&__pyx_n_s_nNodes_element,0};
16499 PyObject* values[4] = {0,0,0,0};
16500 if (unlikely(__pyx_kwds)) {
16501 Py_ssize_t kw_args;
16502 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
16503 switch (pos_args) {
16504 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
16505 CYTHON_FALLTHROUGH;
16506 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
16507 CYTHON_FALLTHROUGH;
16508 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16509 CYTHON_FALLTHROUGH;
16510 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16511 CYTHON_FALLTHROUGH;
16513 default:
goto __pyx_L5_argtuple_error;
16515 kw_args = PyDict_Size(__pyx_kwds);
16516 switch (pos_args) {
16518 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
16519 else goto __pyx_L5_argtuple_error;
16520 CYTHON_FALLTHROUGH;
16522 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nElements_global)) != 0)) kw_args--;
16524 __Pyx_RaiseArgtupleInvalid(
"allocateNodeAndElementNodeDataStructures", 1, 4, 4, 1); __PYX_ERR(1, 405, __pyx_L3_error)
16526 CYTHON_FALLTHROUGH;
16528 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nNodes_global)) != 0)) kw_args--;
16530 __Pyx_RaiseArgtupleInvalid(
"allocateNodeAndElementNodeDataStructures", 1, 4, 4, 2); __PYX_ERR(1, 405, __pyx_L3_error)
16532 CYTHON_FALLTHROUGH;
16534 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nNodes_element)) != 0)) kw_args--;
16536 __Pyx_RaiseArgtupleInvalid(
"allocateNodeAndElementNodeDataStructures", 1, 4, 4, 3); __PYX_ERR(1, 405, __pyx_L3_error)
16539 if (unlikely(kw_args > 0)) {
16540 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"allocateNodeAndElementNodeDataStructures") < 0)) __PYX_ERR(1, 405, __pyx_L3_error)
16542 }
else if (PyTuple_GET_SIZE(__pyx_args) != 4) {
16543 goto __pyx_L5_argtuple_error;
16545 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16546 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16547 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
16548 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
16550 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[0]);
16551 __pyx_v_nElements_global = __Pyx_PyInt_As_int(values[1]);
if (unlikely((__pyx_v_nElements_global == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 406, __pyx_L3_error)
16552 __pyx_v_nNodes_global = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_nNodes_global == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 407, __pyx_L3_error)
16553 __pyx_v_nNodes_element = __Pyx_PyInt_As_int(values[3]);
if (unlikely((__pyx_v_nNodes_element == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 408, __pyx_L3_error)
16555 goto __pyx_L4_argument_unpacking_done;
16556 __pyx_L5_argtuple_error:;
16557 __Pyx_RaiseArgtupleInvalid(
"allocateNodeAndElementNodeDataStructures", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 405, __pyx_L3_error)
16559 __Pyx_AddTraceback(
"cmeshTools.allocateNodeAndElementNodeDataStructures", __pyx_clineno, __pyx_lineno, __pyx_filename);
16560 __Pyx_RefNannyFinishContext();
16562 __pyx_L4_argument_unpacking_done:;
16563 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 405, __pyx_L1_error)
16564 __pyx_r = __pyx_pf_10cmeshTools_34allocateNodeAndElementNodeDataStructures(__pyx_self, __pyx_v_cmesh, __pyx_v_nElements_global, __pyx_v_nNodes_global, __pyx_v_nNodes_element);
16571 __Pyx_RefNannyFinishContext();
16575 static PyObject *__pyx_pf_10cmeshTools_34allocateNodeAndElementNodeDataStructures(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh,
int __pyx_v_nElements_global,
int __pyx_v_nNodes_global,
int __pyx_v_nNodes_element) {
16576 PyObject *__pyx_r = NULL;
16577 __Pyx_RefNannyDeclarations
16578 PyObject *__pyx_t_1 = NULL;
16579 int __pyx_lineno = 0;
16580 const char *__pyx_filename = NULL;
16581 int __pyx_clineno = 0;
16582 __Pyx_RefNannySetupContext(
"allocateNodeAndElementNodeDataStructures", 0);
16583 __Pyx_XDECREF(__pyx_r);
16584 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_allocateNodeAndElementNodeDataStructures(__pyx_v_cmesh, __pyx_v_nElements_global, __pyx_v_nNodes_global, __pyx_v_nNodes_element, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 405, __pyx_L1_error)
16585 __Pyx_GOTREF(__pyx_t_1);
16586 __pyx_r = __pyx_t_1;
16592 __Pyx_XDECREF(__pyx_t_1);
16593 __Pyx_AddTraceback(
"cmeshTools.allocateNodeAndElementNodeDataStructures", __pyx_clineno, __pyx_lineno, __pyx_filename);
16596 __Pyx_XGIVEREF(__pyx_r);
16597 __Pyx_RefNannyFinishContext();
16609 static PyObject *__pyx_pw_10cmeshTools_37constructElementBoundaryElementsArray(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
16610 static void __pyx_f_10cmeshTools_constructElementBoundaryElementsArray(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
16611 __Pyx_RefNannyDeclarations
16612 __Pyx_RefNannySetupContext(
"constructElementBoundaryElementsArray", 0);
16621 switch (__pyx_v_cmesh->mesh.nNodes_element) {
16682 __Pyx_RefNannyFinishContext();
16686 static PyObject *__pyx_pw_10cmeshTools_37constructElementBoundaryElementsArray(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
16687 static PyObject *__pyx_pw_10cmeshTools_37constructElementBoundaryElementsArray(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
16688 int __pyx_lineno = 0;
16689 const char *__pyx_filename = NULL;
16690 int __pyx_clineno = 0;
16691 PyObject *__pyx_r = 0;
16692 __Pyx_RefNannyDeclarations
16693 __Pyx_RefNannySetupContext(
"constructElementBoundaryElementsArray (wrapper)", 0);
16694 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 411, __pyx_L1_error)
16695 __pyx_r = __pyx_pf_10cmeshTools_36constructElementBoundaryElementsArray(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
16702 __Pyx_RefNannyFinishContext();
16706 static PyObject *__pyx_pf_10cmeshTools_36constructElementBoundaryElementsArray(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
16707 PyObject *__pyx_r = NULL;
16708 __Pyx_RefNannyDeclarations
16709 PyObject *__pyx_t_1 = NULL;
16710 int __pyx_lineno = 0;
16711 const char *__pyx_filename = NULL;
16712 int __pyx_clineno = 0;
16713 __Pyx_RefNannySetupContext(
"constructElementBoundaryElementsArray", 0);
16714 __Pyx_XDECREF(__pyx_r);
16715 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_constructElementBoundaryElementsArray(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 411, __pyx_L1_error)
16716 __Pyx_GOTREF(__pyx_t_1);
16717 __pyx_r = __pyx_t_1;
16723 __Pyx_XDECREF(__pyx_t_1);
16724 __Pyx_AddTraceback(
"cmeshTools.constructElementBoundaryElementsArray", __pyx_clineno, __pyx_lineno, __pyx_filename);
16727 __Pyx_XGIVEREF(__pyx_r);
16728 __Pyx_RefNannyFinishContext();
16740 static PyObject *__pyx_pw_10cmeshTools_39generateTriangularMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
16741 static void __pyx_f_10cmeshTools_generateTriangularMeshFromRectangularGrid(
int __pyx_v_nx,
int __pyx_v_ny,
double __pyx_v_Lx,
double __pyx_v_Ly,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh,
int __pyx_v_triangleFlag, CYTHON_UNUSED
int __pyx_skip_dispatch) {
16742 __Pyx_RefNannyDeclarations
16743 __Pyx_RefNannySetupContext(
"generateTriangularMeshFromRectangularGrid", 0);
16790 __Pyx_RefNannyFinishContext();
16794 static PyObject *__pyx_pw_10cmeshTools_39generateTriangularMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
16795 static PyObject *__pyx_pw_10cmeshTools_39generateTriangularMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
16800 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
16801 int __pyx_v_triangleFlag;
16802 int __pyx_lineno = 0;
16803 const char *__pyx_filename = NULL;
16804 int __pyx_clineno = 0;
16805 PyObject *__pyx_r = 0;
16806 __Pyx_RefNannyDeclarations
16807 __Pyx_RefNannySetupContext(
"generateTriangularMeshFromRectangularGrid (wrapper)", 0);
16809 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nx,&__pyx_n_s_ny,&__pyx_n_s_Lx,&__pyx_n_s_Ly,&__pyx_n_s_cmesh,&__pyx_n_s_triangleFlag,0};
16810 PyObject* values[6] = {0,0,0,0,0,0};
16811 if (unlikely(__pyx_kwds)) {
16812 Py_ssize_t kw_args;
16813 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
16814 switch (pos_args) {
16815 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
16816 CYTHON_FALLTHROUGH;
16817 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
16818 CYTHON_FALLTHROUGH;
16819 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
16820 CYTHON_FALLTHROUGH;
16821 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
16822 CYTHON_FALLTHROUGH;
16823 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16824 CYTHON_FALLTHROUGH;
16825 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16826 CYTHON_FALLTHROUGH;
16828 default:
goto __pyx_L5_argtuple_error;
16830 kw_args = PyDict_Size(__pyx_kwds);
16831 switch (pos_args) {
16833 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nx)) != 0)) kw_args--;
16834 else goto __pyx_L5_argtuple_error;
16835 CYTHON_FALLTHROUGH;
16837 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ny)) != 0)) kw_args--;
16839 __Pyx_RaiseArgtupleInvalid(
"generateTriangularMeshFromRectangularGrid", 1, 6, 6, 1); __PYX_ERR(1, 419, __pyx_L3_error)
16841 CYTHON_FALLTHROUGH;
16843 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Lx)) != 0)) kw_args--;
16845 __Pyx_RaiseArgtupleInvalid(
"generateTriangularMeshFromRectangularGrid", 1, 6, 6, 2); __PYX_ERR(1, 419, __pyx_L3_error)
16847 CYTHON_FALLTHROUGH;
16849 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Ly)) != 0)) kw_args--;
16851 __Pyx_RaiseArgtupleInvalid(
"generateTriangularMeshFromRectangularGrid", 1, 6, 6, 3); __PYX_ERR(1, 419, __pyx_L3_error)
16853 CYTHON_FALLTHROUGH;
16855 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
16857 __Pyx_RaiseArgtupleInvalid(
"generateTriangularMeshFromRectangularGrid", 1, 6, 6, 4); __PYX_ERR(1, 419, __pyx_L3_error)
16859 CYTHON_FALLTHROUGH;
16861 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_triangleFlag)) != 0)) kw_args--;
16863 __Pyx_RaiseArgtupleInvalid(
"generateTriangularMeshFromRectangularGrid", 1, 6, 6, 5); __PYX_ERR(1, 419, __pyx_L3_error)
16866 if (unlikely(kw_args > 0)) {
16867 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateTriangularMeshFromRectangularGrid") < 0)) __PYX_ERR(1, 419, __pyx_L3_error)
16869 }
else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
16870 goto __pyx_L5_argtuple_error;
16872 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
16873 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
16874 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
16875 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
16876 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
16877 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
16879 __pyx_v_nx = __Pyx_PyInt_As_int(values[0]);
if (unlikely((__pyx_v_nx == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 419, __pyx_L3_error)
16880 __pyx_v_ny = __Pyx_PyInt_As_int(values[1]);
if (unlikely((__pyx_v_ny == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 420, __pyx_L3_error)
16881 __pyx_v_Lx = __pyx_PyFloat_AsDouble(values[2]);
if (unlikely((__pyx_v_Lx == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 421, __pyx_L3_error)
16882 __pyx_v_Ly = __pyx_PyFloat_AsDouble(values[3]);
if (unlikely((__pyx_v_Ly == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 422, __pyx_L3_error)
16883 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[4]);
16884 __pyx_v_triangleFlag = __Pyx_PyInt_As_int(values[5]);
if (unlikely((__pyx_v_triangleFlag == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 424, __pyx_L3_error)
16886 goto __pyx_L4_argument_unpacking_done;
16887 __pyx_L5_argtuple_error:;
16888 __Pyx_RaiseArgtupleInvalid(
"generateTriangularMeshFromRectangularGrid", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 419, __pyx_L3_error)
16890 __Pyx_AddTraceback(
"cmeshTools.generateTriangularMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
16891 __Pyx_RefNannyFinishContext();
16893 __pyx_L4_argument_unpacking_done:;
16894 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 423, __pyx_L1_error)
16895 __pyx_r = __pyx_pf_10cmeshTools_38generateTriangularMeshFromRectangularGrid(__pyx_self, __pyx_v_nx, __pyx_v_ny, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_cmesh, __pyx_v_triangleFlag);
16902 __Pyx_RefNannyFinishContext();
16906 static PyObject *__pyx_pf_10cmeshTools_38generateTriangularMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
int __pyx_v_ny,
double __pyx_v_Lx,
double __pyx_v_Ly,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh,
int __pyx_v_triangleFlag) {
16907 PyObject *__pyx_r = NULL;
16908 __Pyx_RefNannyDeclarations
16909 PyObject *__pyx_t_1 = NULL;
16910 int __pyx_lineno = 0;
16911 const char *__pyx_filename = NULL;
16912 int __pyx_clineno = 0;
16913 __Pyx_RefNannySetupContext(
"generateTriangularMeshFromRectangularGrid", 0);
16914 __Pyx_XDECREF(__pyx_r);
16915 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateTriangularMeshFromRectangularGrid(__pyx_v_nx, __pyx_v_ny, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_cmesh, __pyx_v_triangleFlag, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 419, __pyx_L1_error)
16916 __Pyx_GOTREF(__pyx_t_1);
16917 __pyx_r = __pyx_t_1;
16923 __Pyx_XDECREF(__pyx_t_1);
16924 __Pyx_AddTraceback(
"cmeshTools.generateTriangularMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
16927 __Pyx_XGIVEREF(__pyx_r);
16928 __Pyx_RefNannyFinishContext();
16940 static PyObject *__pyx_pw_10cmeshTools_41generateHexahedralMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
16941 static void __pyx_f_10cmeshTools_generateHexahedralMeshFromRectangularGrid(
int __pyx_v_nx,
int __pyx_v_ny,
int __pyx_v_nz,
int __pyx_v_px,
int __pyx_v_py,
int __pyx_v_pz,
double __pyx_v_Lx,
double __pyx_v_Ly,
double __pyx_v_Lz,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
16942 __Pyx_RefNannyDeclarations
16943 __Pyx_RefNannySetupContext(
"generateHexahedralMeshFromRectangularGrid", 0);
16961 (void)(
regularMeshNodes(__pyx_v_nx, __pyx_v_ny, __pyx_v_nz, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_Lz, __pyx_v_cmesh->mesh));
16990 __Pyx_RefNannyFinishContext();
16994 static PyObject *__pyx_pw_10cmeshTools_41generateHexahedralMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
16995 static PyObject *__pyx_pw_10cmeshTools_41generateHexahedralMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
17005 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
17006 int __pyx_lineno = 0;
17007 const char *__pyx_filename = NULL;
17008 int __pyx_clineno = 0;
17009 PyObject *__pyx_r = 0;
17010 __Pyx_RefNannyDeclarations
17011 __Pyx_RefNannySetupContext(
"generateHexahedralMeshFromRectangularGrid (wrapper)", 0);
17013 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nx,&__pyx_n_s_ny,&__pyx_n_s_nz,&__pyx_n_s_px,&__pyx_n_s_py,&__pyx_n_s_pz,&__pyx_n_s_Lx,&__pyx_n_s_Ly,&__pyx_n_s_Lz,&__pyx_n_s_cmesh,0};
17014 PyObject* values[10] = {0,0,0,0,0,0,0,0,0,0};
17015 if (unlikely(__pyx_kwds)) {
17016 Py_ssize_t kw_args;
17017 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
17018 switch (pos_args) {
17019 case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
17020 CYTHON_FALLTHROUGH;
17021 case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
17022 CYTHON_FALLTHROUGH;
17023 case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
17024 CYTHON_FALLTHROUGH;
17025 case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
17026 CYTHON_FALLTHROUGH;
17027 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
17028 CYTHON_FALLTHROUGH;
17029 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
17030 CYTHON_FALLTHROUGH;
17031 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
17032 CYTHON_FALLTHROUGH;
17033 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
17034 CYTHON_FALLTHROUGH;
17035 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17036 CYTHON_FALLTHROUGH;
17037 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17038 CYTHON_FALLTHROUGH;
17040 default:
goto __pyx_L5_argtuple_error;
17042 kw_args = PyDict_Size(__pyx_kwds);
17043 switch (pos_args) {
17045 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nx)) != 0)) kw_args--;
17046 else goto __pyx_L5_argtuple_error;
17047 CYTHON_FALLTHROUGH;
17049 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ny)) != 0)) kw_args--;
17051 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, 1); __PYX_ERR(1, 430, __pyx_L3_error)
17053 CYTHON_FALLTHROUGH;
17055 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nz)) != 0)) kw_args--;
17057 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, 2); __PYX_ERR(1, 430, __pyx_L3_error)
17059 CYTHON_FALLTHROUGH;
17061 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_px)) != 0)) kw_args--;
17063 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, 3); __PYX_ERR(1, 430, __pyx_L3_error)
17065 CYTHON_FALLTHROUGH;
17067 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_py)) != 0)) kw_args--;
17069 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, 4); __PYX_ERR(1, 430, __pyx_L3_error)
17071 CYTHON_FALLTHROUGH;
17073 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pz)) != 0)) kw_args--;
17075 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, 5); __PYX_ERR(1, 430, __pyx_L3_error)
17077 CYTHON_FALLTHROUGH;
17079 if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Lx)) != 0)) kw_args--;
17081 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, 6); __PYX_ERR(1, 430, __pyx_L3_error)
17083 CYTHON_FALLTHROUGH;
17085 if (likely((values[7] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Ly)) != 0)) kw_args--;
17087 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, 7); __PYX_ERR(1, 430, __pyx_L3_error)
17089 CYTHON_FALLTHROUGH;
17091 if (likely((values[8] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Lz)) != 0)) kw_args--;
17093 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, 8); __PYX_ERR(1, 430, __pyx_L3_error)
17095 CYTHON_FALLTHROUGH;
17097 if (likely((values[9] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
17099 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, 9); __PYX_ERR(1, 430, __pyx_L3_error)
17102 if (unlikely(kw_args > 0)) {
17103 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateHexahedralMeshFromRectangularGrid") < 0)) __PYX_ERR(1, 430, __pyx_L3_error)
17105 }
else if (PyTuple_GET_SIZE(__pyx_args) != 10) {
17106 goto __pyx_L5_argtuple_error;
17108 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17109 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17110 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
17111 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
17112 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
17113 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
17114 values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
17115 values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
17116 values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
17117 values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
17119 __pyx_v_nx = __Pyx_PyInt_As_int(values[0]);
if (unlikely((__pyx_v_nx == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 430, __pyx_L3_error)
17120 __pyx_v_ny = __Pyx_PyInt_As_int(values[1]);
if (unlikely((__pyx_v_ny == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 431, __pyx_L3_error)
17121 __pyx_v_nz = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_nz == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 432, __pyx_L3_error)
17122 __pyx_v_px = __Pyx_PyInt_As_int(values[3]);
if (unlikely((__pyx_v_px == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 433, __pyx_L3_error)
17123 __pyx_v_py = __Pyx_PyInt_As_int(values[4]);
if (unlikely((__pyx_v_py == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 434, __pyx_L3_error)
17124 __pyx_v_pz = __Pyx_PyInt_As_int(values[5]);
if (unlikely((__pyx_v_pz == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 435, __pyx_L3_error)
17125 __pyx_v_Lx = __pyx_PyFloat_AsDouble(values[6]);
if (unlikely((__pyx_v_Lx == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 436, __pyx_L3_error)
17126 __pyx_v_Ly = __pyx_PyFloat_AsDouble(values[7]);
if (unlikely((__pyx_v_Ly == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 437, __pyx_L3_error)
17127 __pyx_v_Lz = __pyx_PyFloat_AsDouble(values[8]);
if (unlikely((__pyx_v_Lz == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 438, __pyx_L3_error)
17128 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[9]);
17130 goto __pyx_L4_argument_unpacking_done;
17131 __pyx_L5_argtuple_error:;
17132 __Pyx_RaiseArgtupleInvalid(
"generateHexahedralMeshFromRectangularGrid", 1, 10, 10, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 430, __pyx_L3_error)
17134 __Pyx_AddTraceback(
"cmeshTools.generateHexahedralMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
17135 __Pyx_RefNannyFinishContext();
17137 __pyx_L4_argument_unpacking_done:;
17138 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 439, __pyx_L1_error)
17139 __pyx_r = __pyx_pf_10cmeshTools_40generateHexahedralMeshFromRectangularGrid(__pyx_self, __pyx_v_nx, __pyx_v_ny, __pyx_v_nz, __pyx_v_px, __pyx_v_py, __pyx_v_pz, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_Lz, __pyx_v_cmesh);
17146 __Pyx_RefNannyFinishContext();
17150 static PyObject *__pyx_pf_10cmeshTools_40generateHexahedralMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
int __pyx_v_ny,
int __pyx_v_nz,
int __pyx_v_px,
int __pyx_v_py,
int __pyx_v_pz,
double __pyx_v_Lx,
double __pyx_v_Ly,
double __pyx_v_Lz,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
17151 PyObject *__pyx_r = NULL;
17152 __Pyx_RefNannyDeclarations
17153 PyObject *__pyx_t_1 = NULL;
17154 int __pyx_lineno = 0;
17155 const char *__pyx_filename = NULL;
17156 int __pyx_clineno = 0;
17157 __Pyx_RefNannySetupContext(
"generateHexahedralMeshFromRectangularGrid", 0);
17158 __Pyx_XDECREF(__pyx_r);
17159 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateHexahedralMeshFromRectangularGrid(__pyx_v_nx, __pyx_v_ny, __pyx_v_nz, __pyx_v_px, __pyx_v_py, __pyx_v_pz, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_Lz, __pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 430, __pyx_L1_error)
17160 __Pyx_GOTREF(__pyx_t_1);
17161 __pyx_r = __pyx_t_1;
17167 __Pyx_XDECREF(__pyx_t_1);
17168 __Pyx_AddTraceback(
"cmeshTools.generateHexahedralMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
17171 __Pyx_XGIVEREF(__pyx_r);
17172 __Pyx_RefNannyFinishContext();
17184 static PyObject *__pyx_pw_10cmeshTools_43generateQuadrilateralMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
17185 static void __pyx_f_10cmeshTools_generateQuadrilateralMeshFromRectangularGrid(
int __pyx_v_nx,
int __pyx_v_ny, CYTHON_UNUSED
int __pyx_v_px, CYTHON_UNUSED
int __pyx_v_py,
double __pyx_v_Lx,
double __pyx_v_Ly,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
17186 __Pyx_RefNannyDeclarations
17187 __Pyx_RefNannySetupContext(
"generateQuadrilateralMeshFromRectangularGrid", 0);
17205 (void)(
regularMeshNodes2D(__pyx_v_nx, __pyx_v_ny, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_cmesh->mesh));
17234 __Pyx_RefNannyFinishContext();
17238 static PyObject *__pyx_pw_10cmeshTools_43generateQuadrilateralMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
17239 static PyObject *__pyx_pw_10cmeshTools_43generateQuadrilateralMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
17246 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
17247 int __pyx_lineno = 0;
17248 const char *__pyx_filename = NULL;
17249 int __pyx_clineno = 0;
17250 PyObject *__pyx_r = 0;
17251 __Pyx_RefNannyDeclarations
17252 __Pyx_RefNannySetupContext(
"generateQuadrilateralMeshFromRectangularGrid (wrapper)", 0);
17254 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nx,&__pyx_n_s_ny,&__pyx_n_s_px,&__pyx_n_s_py,&__pyx_n_s_Lx,&__pyx_n_s_Ly,&__pyx_n_s_cmesh,0};
17255 PyObject* values[7] = {0,0,0,0,0,0,0};
17256 if (unlikely(__pyx_kwds)) {
17257 Py_ssize_t kw_args;
17258 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
17259 switch (pos_args) {
17260 case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
17261 CYTHON_FALLTHROUGH;
17262 case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
17263 CYTHON_FALLTHROUGH;
17264 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
17265 CYTHON_FALLTHROUGH;
17266 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
17267 CYTHON_FALLTHROUGH;
17268 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
17269 CYTHON_FALLTHROUGH;
17270 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17271 CYTHON_FALLTHROUGH;
17272 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17273 CYTHON_FALLTHROUGH;
17275 default:
goto __pyx_L5_argtuple_error;
17277 kw_args = PyDict_Size(__pyx_kwds);
17278 switch (pos_args) {
17280 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nx)) != 0)) kw_args--;
17281 else goto __pyx_L5_argtuple_error;
17282 CYTHON_FALLTHROUGH;
17284 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_ny)) != 0)) kw_args--;
17286 __Pyx_RaiseArgtupleInvalid(
"generateQuadrilateralMeshFromRectangularGrid", 1, 7, 7, 1); __PYX_ERR(1, 445, __pyx_L3_error)
17288 CYTHON_FALLTHROUGH;
17290 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_px)) != 0)) kw_args--;
17292 __Pyx_RaiseArgtupleInvalid(
"generateQuadrilateralMeshFromRectangularGrid", 1, 7, 7, 2); __PYX_ERR(1, 445, __pyx_L3_error)
17294 CYTHON_FALLTHROUGH;
17296 if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_py)) != 0)) kw_args--;
17298 __Pyx_RaiseArgtupleInvalid(
"generateQuadrilateralMeshFromRectangularGrid", 1, 7, 7, 3); __PYX_ERR(1, 445, __pyx_L3_error)
17300 CYTHON_FALLTHROUGH;
17302 if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Lx)) != 0)) kw_args--;
17304 __Pyx_RaiseArgtupleInvalid(
"generateQuadrilateralMeshFromRectangularGrid", 1, 7, 7, 4); __PYX_ERR(1, 445, __pyx_L3_error)
17306 CYTHON_FALLTHROUGH;
17308 if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Ly)) != 0)) kw_args--;
17310 __Pyx_RaiseArgtupleInvalid(
"generateQuadrilateralMeshFromRectangularGrid", 1, 7, 7, 5); __PYX_ERR(1, 445, __pyx_L3_error)
17312 CYTHON_FALLTHROUGH;
17314 if (likely((values[6] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
17316 __Pyx_RaiseArgtupleInvalid(
"generateQuadrilateralMeshFromRectangularGrid", 1, 7, 7, 6); __PYX_ERR(1, 445, __pyx_L3_error)
17319 if (unlikely(kw_args > 0)) {
17320 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateQuadrilateralMeshFromRectangularGrid") < 0)) __PYX_ERR(1, 445, __pyx_L3_error)
17322 }
else if (PyTuple_GET_SIZE(__pyx_args) != 7) {
17323 goto __pyx_L5_argtuple_error;
17325 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17326 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17327 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
17328 values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
17329 values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
17330 values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
17331 values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
17333 __pyx_v_nx = __Pyx_PyInt_As_int(values[0]);
if (unlikely((__pyx_v_nx == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 445, __pyx_L3_error)
17334 __pyx_v_ny = __Pyx_PyInt_As_int(values[1]);
if (unlikely((__pyx_v_ny == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 446, __pyx_L3_error)
17335 __pyx_v_px = __Pyx_PyInt_As_int(values[2]);
if (unlikely((__pyx_v_px == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 447, __pyx_L3_error)
17336 __pyx_v_py = __Pyx_PyInt_As_int(values[3]);
if (unlikely((__pyx_v_py == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 448, __pyx_L3_error)
17337 __pyx_v_Lx = __pyx_PyFloat_AsDouble(values[4]);
if (unlikely((__pyx_v_Lx == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 449, __pyx_L3_error)
17338 __pyx_v_Ly = __pyx_PyFloat_AsDouble(values[5]);
if (unlikely((__pyx_v_Ly == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 450, __pyx_L3_error)
17339 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[6]);
17341 goto __pyx_L4_argument_unpacking_done;
17342 __pyx_L5_argtuple_error:;
17343 __Pyx_RaiseArgtupleInvalid(
"generateQuadrilateralMeshFromRectangularGrid", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 445, __pyx_L3_error)
17345 __Pyx_AddTraceback(
"cmeshTools.generateQuadrilateralMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
17346 __Pyx_RefNannyFinishContext();
17348 __pyx_L4_argument_unpacking_done:;
17349 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 451, __pyx_L1_error)
17350 __pyx_r = __pyx_pf_10cmeshTools_42generateQuadrilateralMeshFromRectangularGrid(__pyx_self, __pyx_v_nx, __pyx_v_ny, __pyx_v_px, __pyx_v_py, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_cmesh);
17357 __Pyx_RefNannyFinishContext();
17361 static PyObject *__pyx_pf_10cmeshTools_42generateQuadrilateralMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
int __pyx_v_ny,
int __pyx_v_px,
int __pyx_v_py,
double __pyx_v_Lx,
double __pyx_v_Ly,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
17362 PyObject *__pyx_r = NULL;
17363 __Pyx_RefNannyDeclarations
17364 PyObject *__pyx_t_1 = NULL;
17365 int __pyx_lineno = 0;
17366 const char *__pyx_filename = NULL;
17367 int __pyx_clineno = 0;
17368 __Pyx_RefNannySetupContext(
"generateQuadrilateralMeshFromRectangularGrid", 0);
17369 __Pyx_XDECREF(__pyx_r);
17370 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateQuadrilateralMeshFromRectangularGrid(__pyx_v_nx, __pyx_v_ny, __pyx_v_px, __pyx_v_py, __pyx_v_Lx, __pyx_v_Ly, __pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 445, __pyx_L1_error)
17371 __Pyx_GOTREF(__pyx_t_1);
17372 __pyx_r = __pyx_t_1;
17378 __Pyx_XDECREF(__pyx_t_1);
17379 __Pyx_AddTraceback(
"cmeshTools.generateQuadrilateralMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
17382 __Pyx_XGIVEREF(__pyx_r);
17383 __Pyx_RefNannyFinishContext();
17395 static PyObject *__pyx_pw_10cmeshTools_45computeGeometricInfo_triangle(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17396 static void __pyx_f_10cmeshTools_computeGeometricInfo_triangle(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
17397 __Pyx_RefNannyDeclarations
17398 __Pyx_RefNannySetupContext(
"computeGeometricInfo_triangle", 0);
17418 __Pyx_RefNannyFinishContext();
17422 static PyObject *__pyx_pw_10cmeshTools_45computeGeometricInfo_triangle(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17423 static PyObject *__pyx_pw_10cmeshTools_45computeGeometricInfo_triangle(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
17424 int __pyx_lineno = 0;
17425 const char *__pyx_filename = NULL;
17426 int __pyx_clineno = 0;
17427 PyObject *__pyx_r = 0;
17428 __Pyx_RefNannyDeclarations
17429 __Pyx_RefNannySetupContext(
"computeGeometricInfo_triangle (wrapper)", 0);
17430 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 457, __pyx_L1_error)
17431 __pyx_r = __pyx_pf_10cmeshTools_44computeGeometricInfo_triangle(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
17438 __Pyx_RefNannyFinishContext();
17442 static PyObject *__pyx_pf_10cmeshTools_44computeGeometricInfo_triangle(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
17443 PyObject *__pyx_r = NULL;
17444 __Pyx_RefNannyDeclarations
17445 PyObject *__pyx_t_1 = NULL;
17446 int __pyx_lineno = 0;
17447 const char *__pyx_filename = NULL;
17448 int __pyx_clineno = 0;
17449 __Pyx_RefNannySetupContext(
"computeGeometricInfo_triangle", 0);
17450 __Pyx_XDECREF(__pyx_r);
17451 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_computeGeometricInfo_triangle(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 457, __pyx_L1_error)
17452 __Pyx_GOTREF(__pyx_t_1);
17453 __pyx_r = __pyx_t_1;
17459 __Pyx_XDECREF(__pyx_t_1);
17460 __Pyx_AddTraceback(
"cmeshTools.computeGeometricInfo_triangle", __pyx_clineno, __pyx_lineno, __pyx_filename);
17463 __Pyx_XGIVEREF(__pyx_r);
17464 __Pyx_RefNannyFinishContext();
17476 static PyObject *__pyx_pw_10cmeshTools_47allocateGeometricInfo_triangle(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17477 static void __pyx_f_10cmeshTools_allocateGeometricInfo_triangle(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
17478 __Pyx_RefNannyDeclarations
17479 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_triangle", 0);
17499 __Pyx_RefNannyFinishContext();
17503 static PyObject *__pyx_pw_10cmeshTools_47allocateGeometricInfo_triangle(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17504 static PyObject *__pyx_pw_10cmeshTools_47allocateGeometricInfo_triangle(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
17505 int __pyx_lineno = 0;
17506 const char *__pyx_filename = NULL;
17507 int __pyx_clineno = 0;
17508 PyObject *__pyx_r = 0;
17509 __Pyx_RefNannyDeclarations
17510 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_triangle (wrapper)", 0);
17511 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 460, __pyx_L1_error)
17512 __pyx_r = __pyx_pf_10cmeshTools_46allocateGeometricInfo_triangle(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
17519 __Pyx_RefNannyFinishContext();
17523 static PyObject *__pyx_pf_10cmeshTools_46allocateGeometricInfo_triangle(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
17524 PyObject *__pyx_r = NULL;
17525 __Pyx_RefNannyDeclarations
17526 PyObject *__pyx_t_1 = NULL;
17527 int __pyx_lineno = 0;
17528 const char *__pyx_filename = NULL;
17529 int __pyx_clineno = 0;
17530 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_triangle", 0);
17531 __Pyx_XDECREF(__pyx_r);
17532 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_allocateGeometricInfo_triangle(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 460, __pyx_L1_error)
17533 __Pyx_GOTREF(__pyx_t_1);
17534 __pyx_r = __pyx_t_1;
17540 __Pyx_XDECREF(__pyx_t_1);
17541 __Pyx_AddTraceback(
"cmeshTools.allocateGeometricInfo_triangle", __pyx_clineno, __pyx_lineno, __pyx_filename);
17544 __Pyx_XGIVEREF(__pyx_r);
17545 __Pyx_RefNannyFinishContext();
17557 static PyObject *__pyx_pw_10cmeshTools_49generateEdgeMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
17558 static void __pyx_f_10cmeshTools_generateEdgeMeshFromRectangularGrid(
int __pyx_v_nx,
double __pyx_v_Lx,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
17559 __Pyx_RefNannyDeclarations
17560 __Pyx_RefNannySetupContext(
"generateEdgeMeshFromRectangularGrid", 0);
17598 __Pyx_RefNannyFinishContext();
17602 static PyObject *__pyx_pw_10cmeshTools_49generateEdgeMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
17603 static PyObject *__pyx_pw_10cmeshTools_49generateEdgeMeshFromRectangularGrid(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
17606 struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh = 0;
17607 int __pyx_lineno = 0;
17608 const char *__pyx_filename = NULL;
17609 int __pyx_clineno = 0;
17610 PyObject *__pyx_r = 0;
17611 __Pyx_RefNannyDeclarations
17612 __Pyx_RefNannySetupContext(
"generateEdgeMeshFromRectangularGrid (wrapper)", 0);
17614 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nx,&__pyx_n_s_Lx,&__pyx_n_s_cmesh,0};
17615 PyObject* values[3] = {0,0,0};
17616 if (unlikely(__pyx_kwds)) {
17617 Py_ssize_t kw_args;
17618 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
17619 switch (pos_args) {
17620 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
17621 CYTHON_FALLTHROUGH;
17622 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17623 CYTHON_FALLTHROUGH;
17624 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17625 CYTHON_FALLTHROUGH;
17627 default:
goto __pyx_L5_argtuple_error;
17629 kw_args = PyDict_Size(__pyx_kwds);
17630 switch (pos_args) {
17632 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nx)) != 0)) kw_args--;
17633 else goto __pyx_L5_argtuple_error;
17634 CYTHON_FALLTHROUGH;
17636 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_Lx)) != 0)) kw_args--;
17638 __Pyx_RaiseArgtupleInvalid(
"generateEdgeMeshFromRectangularGrid", 1, 3, 3, 1); __PYX_ERR(1, 463, __pyx_L3_error)
17640 CYTHON_FALLTHROUGH;
17642 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmesh)) != 0)) kw_args--;
17644 __Pyx_RaiseArgtupleInvalid(
"generateEdgeMeshFromRectangularGrid", 1, 3, 3, 2); __PYX_ERR(1, 463, __pyx_L3_error)
17647 if (unlikely(kw_args > 0)) {
17648 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"generateEdgeMeshFromRectangularGrid") < 0)) __PYX_ERR(1, 463, __pyx_L3_error)
17650 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
17651 goto __pyx_L5_argtuple_error;
17653 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
17654 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
17655 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
17657 __pyx_v_nx = __Pyx_PyInt_As_int(values[0]);
if (unlikely((__pyx_v_nx == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 463, __pyx_L3_error)
17658 __pyx_v_Lx = __pyx_PyFloat_AsDouble(values[1]);
if (unlikely((__pyx_v_Lx == (
double)-1) && PyErr_Occurred())) __PYX_ERR(1, 464, __pyx_L3_error)
17659 __pyx_v_cmesh = ((
struct __pyx_obj_10cmeshTools_CMesh *)values[2]);
17661 goto __pyx_L4_argument_unpacking_done;
17662 __pyx_L5_argtuple_error:;
17663 __Pyx_RaiseArgtupleInvalid(
"generateEdgeMeshFromRectangularGrid", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 463, __pyx_L3_error)
17665 __Pyx_AddTraceback(
"cmeshTools.generateEdgeMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
17666 __Pyx_RefNannyFinishContext();
17668 __pyx_L4_argument_unpacking_done:;
17669 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 465, __pyx_L1_error)
17670 __pyx_r = __pyx_pf_10cmeshTools_48generateEdgeMeshFromRectangularGrid(__pyx_self, __pyx_v_nx, __pyx_v_Lx, __pyx_v_cmesh);
17677 __Pyx_RefNannyFinishContext();
17681 static PyObject *__pyx_pf_10cmeshTools_48generateEdgeMeshFromRectangularGrid(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nx,
double __pyx_v_Lx,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
17682 PyObject *__pyx_r = NULL;
17683 __Pyx_RefNannyDeclarations
17684 PyObject *__pyx_t_1 = NULL;
17685 int __pyx_lineno = 0;
17686 const char *__pyx_filename = NULL;
17687 int __pyx_clineno = 0;
17688 __Pyx_RefNannySetupContext(
"generateEdgeMeshFromRectangularGrid", 0);
17689 __Pyx_XDECREF(__pyx_r);
17690 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_generateEdgeMeshFromRectangularGrid(__pyx_v_nx, __pyx_v_Lx, __pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 463, __pyx_L1_error)
17691 __Pyx_GOTREF(__pyx_t_1);
17692 __pyx_r = __pyx_t_1;
17698 __Pyx_XDECREF(__pyx_t_1);
17699 __Pyx_AddTraceback(
"cmeshTools.generateEdgeMeshFromRectangularGrid", __pyx_clineno, __pyx_lineno, __pyx_filename);
17702 __Pyx_XGIVEREF(__pyx_r);
17703 __Pyx_RefNannyFinishContext();
17715 static PyObject *__pyx_pw_10cmeshTools_51computeGeometricInfo_edge(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17716 static void __pyx_f_10cmeshTools_computeGeometricInfo_edge(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
17717 __Pyx_RefNannyDeclarations
17718 __Pyx_RefNannySetupContext(
"computeGeometricInfo_edge", 0);
17738 __Pyx_RefNannyFinishContext();
17742 static PyObject *__pyx_pw_10cmeshTools_51computeGeometricInfo_edge(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17743 static PyObject *__pyx_pw_10cmeshTools_51computeGeometricInfo_edge(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
17744 int __pyx_lineno = 0;
17745 const char *__pyx_filename = NULL;
17746 int __pyx_clineno = 0;
17747 PyObject *__pyx_r = 0;
17748 __Pyx_RefNannyDeclarations
17749 __Pyx_RefNannySetupContext(
"computeGeometricInfo_edge (wrapper)", 0);
17750 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 470, __pyx_L1_error)
17751 __pyx_r = __pyx_pf_10cmeshTools_50computeGeometricInfo_edge(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
17758 __Pyx_RefNannyFinishContext();
17762 static PyObject *__pyx_pf_10cmeshTools_50computeGeometricInfo_edge(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
17763 PyObject *__pyx_r = NULL;
17764 __Pyx_RefNannyDeclarations
17765 PyObject *__pyx_t_1 = NULL;
17766 int __pyx_lineno = 0;
17767 const char *__pyx_filename = NULL;
17768 int __pyx_clineno = 0;
17769 __Pyx_RefNannySetupContext(
"computeGeometricInfo_edge", 0);
17770 __Pyx_XDECREF(__pyx_r);
17771 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_computeGeometricInfo_edge(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 470, __pyx_L1_error)
17772 __Pyx_GOTREF(__pyx_t_1);
17773 __pyx_r = __pyx_t_1;
17779 __Pyx_XDECREF(__pyx_t_1);
17780 __Pyx_AddTraceback(
"cmeshTools.computeGeometricInfo_edge", __pyx_clineno, __pyx_lineno, __pyx_filename);
17783 __Pyx_XGIVEREF(__pyx_r);
17784 __Pyx_RefNannyFinishContext();
17796 static PyObject *__pyx_pw_10cmeshTools_53allocateGeometricInfo_edge(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17797 static void __pyx_f_10cmeshTools_allocateGeometricInfo_edge(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
17798 __Pyx_RefNannyDeclarations
17799 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_edge", 0);
17819 __Pyx_RefNannyFinishContext();
17823 static PyObject *__pyx_pw_10cmeshTools_53allocateGeometricInfo_edge(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17824 static PyObject *__pyx_pw_10cmeshTools_53allocateGeometricInfo_edge(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
17825 int __pyx_lineno = 0;
17826 const char *__pyx_filename = NULL;
17827 int __pyx_clineno = 0;
17828 PyObject *__pyx_r = 0;
17829 __Pyx_RefNannyDeclarations
17830 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_edge (wrapper)", 0);
17831 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 473, __pyx_L1_error)
17832 __pyx_r = __pyx_pf_10cmeshTools_52allocateGeometricInfo_edge(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
17839 __Pyx_RefNannyFinishContext();
17843 static PyObject *__pyx_pf_10cmeshTools_52allocateGeometricInfo_edge(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
17844 PyObject *__pyx_r = NULL;
17845 __Pyx_RefNannyDeclarations
17846 PyObject *__pyx_t_1 = NULL;
17847 int __pyx_lineno = 0;
17848 const char *__pyx_filename = NULL;
17849 int __pyx_clineno = 0;
17850 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_edge", 0);
17851 __Pyx_XDECREF(__pyx_r);
17852 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_allocateGeometricInfo_edge(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 473, __pyx_L1_error)
17853 __Pyx_GOTREF(__pyx_t_1);
17854 __pyx_r = __pyx_t_1;
17860 __Pyx_XDECREF(__pyx_t_1);
17861 __Pyx_AddTraceback(
"cmeshTools.allocateGeometricInfo_edge", __pyx_clineno, __pyx_lineno, __pyx_filename);
17864 __Pyx_XGIVEREF(__pyx_r);
17865 __Pyx_RefNannyFinishContext();
17877 static PyObject *__pyx_pw_10cmeshTools_55computeGeometricInfo_hexahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17878 static void __pyx_f_10cmeshTools_computeGeometricInfo_hexahedron(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
17879 __Pyx_RefNannyDeclarations
17880 __Pyx_RefNannySetupContext(
"computeGeometricInfo_hexahedron", 0);
17900 __Pyx_RefNannyFinishContext();
17904 static PyObject *__pyx_pw_10cmeshTools_55computeGeometricInfo_hexahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17905 static PyObject *__pyx_pw_10cmeshTools_55computeGeometricInfo_hexahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
17906 int __pyx_lineno = 0;
17907 const char *__pyx_filename = NULL;
17908 int __pyx_clineno = 0;
17909 PyObject *__pyx_r = 0;
17910 __Pyx_RefNannyDeclarations
17911 __Pyx_RefNannySetupContext(
"computeGeometricInfo_hexahedron (wrapper)", 0);
17912 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 477, __pyx_L1_error)
17913 __pyx_r = __pyx_pf_10cmeshTools_54computeGeometricInfo_hexahedron(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
17920 __Pyx_RefNannyFinishContext();
17924 static PyObject *__pyx_pf_10cmeshTools_54computeGeometricInfo_hexahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
17925 PyObject *__pyx_r = NULL;
17926 __Pyx_RefNannyDeclarations
17927 PyObject *__pyx_t_1 = NULL;
17928 int __pyx_lineno = 0;
17929 const char *__pyx_filename = NULL;
17930 int __pyx_clineno = 0;
17931 __Pyx_RefNannySetupContext(
"computeGeometricInfo_hexahedron", 0);
17932 __Pyx_XDECREF(__pyx_r);
17933 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_computeGeometricInfo_hexahedron(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 477, __pyx_L1_error)
17934 __Pyx_GOTREF(__pyx_t_1);
17935 __pyx_r = __pyx_t_1;
17941 __Pyx_XDECREF(__pyx_t_1);
17942 __Pyx_AddTraceback(
"cmeshTools.computeGeometricInfo_hexahedron", __pyx_clineno, __pyx_lineno, __pyx_filename);
17945 __Pyx_XGIVEREF(__pyx_r);
17946 __Pyx_RefNannyFinishContext();
17958 static PyObject *__pyx_pw_10cmeshTools_57computeGeometricInfo_quadrilateral(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17959 static void __pyx_f_10cmeshTools_computeGeometricInfo_quadrilateral(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
17960 __Pyx_RefNannyDeclarations
17961 __Pyx_RefNannySetupContext(
"computeGeometricInfo_quadrilateral", 0);
17981 __Pyx_RefNannyFinishContext();
17985 static PyObject *__pyx_pw_10cmeshTools_57computeGeometricInfo_quadrilateral(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
17986 static PyObject *__pyx_pw_10cmeshTools_57computeGeometricInfo_quadrilateral(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
17987 int __pyx_lineno = 0;
17988 const char *__pyx_filename = NULL;
17989 int __pyx_clineno = 0;
17990 PyObject *__pyx_r = 0;
17991 __Pyx_RefNannyDeclarations
17992 __Pyx_RefNannySetupContext(
"computeGeometricInfo_quadrilateral (wrapper)", 0);
17993 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 480, __pyx_L1_error)
17994 __pyx_r = __pyx_pf_10cmeshTools_56computeGeometricInfo_quadrilateral(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
18001 __Pyx_RefNannyFinishContext();
18005 static PyObject *__pyx_pf_10cmeshTools_56computeGeometricInfo_quadrilateral(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
18006 PyObject *__pyx_r = NULL;
18007 __Pyx_RefNannyDeclarations
18008 PyObject *__pyx_t_1 = NULL;
18009 int __pyx_lineno = 0;
18010 const char *__pyx_filename = NULL;
18011 int __pyx_clineno = 0;
18012 __Pyx_RefNannySetupContext(
"computeGeometricInfo_quadrilateral", 0);
18013 __Pyx_XDECREF(__pyx_r);
18014 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_computeGeometricInfo_quadrilateral(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 480, __pyx_L1_error)
18015 __Pyx_GOTREF(__pyx_t_1);
18016 __pyx_r = __pyx_t_1;
18022 __Pyx_XDECREF(__pyx_t_1);
18023 __Pyx_AddTraceback(
"cmeshTools.computeGeometricInfo_quadrilateral", __pyx_clineno, __pyx_lineno, __pyx_filename);
18026 __Pyx_XGIVEREF(__pyx_r);
18027 __Pyx_RefNannyFinishContext();
18039 static PyObject *__pyx_pw_10cmeshTools_59allocateGeometricInfo_hexahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
18040 static void __pyx_f_10cmeshTools_allocateGeometricInfo_hexahedron(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
18041 __Pyx_RefNannyDeclarations
18042 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_hexahedron", 0);
18062 __Pyx_RefNannyFinishContext();
18066 static PyObject *__pyx_pw_10cmeshTools_59allocateGeometricInfo_hexahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
18067 static PyObject *__pyx_pw_10cmeshTools_59allocateGeometricInfo_hexahedron(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
18068 int __pyx_lineno = 0;
18069 const char *__pyx_filename = NULL;
18070 int __pyx_clineno = 0;
18071 PyObject *__pyx_r = 0;
18072 __Pyx_RefNannyDeclarations
18073 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_hexahedron (wrapper)", 0);
18074 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 483, __pyx_L1_error)
18075 __pyx_r = __pyx_pf_10cmeshTools_58allocateGeometricInfo_hexahedron(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
18082 __Pyx_RefNannyFinishContext();
18086 static PyObject *__pyx_pf_10cmeshTools_58allocateGeometricInfo_hexahedron(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
18087 PyObject *__pyx_r = NULL;
18088 __Pyx_RefNannyDeclarations
18089 PyObject *__pyx_t_1 = NULL;
18090 int __pyx_lineno = 0;
18091 const char *__pyx_filename = NULL;
18092 int __pyx_clineno = 0;
18093 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_hexahedron", 0);
18094 __Pyx_XDECREF(__pyx_r);
18095 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_allocateGeometricInfo_hexahedron(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 483, __pyx_L1_error)
18096 __Pyx_GOTREF(__pyx_t_1);
18097 __pyx_r = __pyx_t_1;
18103 __Pyx_XDECREF(__pyx_t_1);
18104 __Pyx_AddTraceback(
"cmeshTools.allocateGeometricInfo_hexahedron", __pyx_clineno, __pyx_lineno, __pyx_filename);
18107 __Pyx_XGIVEREF(__pyx_r);
18108 __Pyx_RefNannyFinishContext();
18120 static PyObject *__pyx_pw_10cmeshTools_61allocateGeometricInfo_quadrilateral(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
18121 static void __pyx_f_10cmeshTools_allocateGeometricInfo_quadrilateral(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
18122 __Pyx_RefNannyDeclarations
18123 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_quadrilateral", 0);
18143 __Pyx_RefNannyFinishContext();
18147 static PyObject *__pyx_pw_10cmeshTools_61allocateGeometricInfo_quadrilateral(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
18148 static PyObject *__pyx_pw_10cmeshTools_61allocateGeometricInfo_quadrilateral(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
18149 int __pyx_lineno = 0;
18150 const char *__pyx_filename = NULL;
18151 int __pyx_clineno = 0;
18152 PyObject *__pyx_r = 0;
18153 __Pyx_RefNannyDeclarations
18154 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_quadrilateral (wrapper)", 0);
18155 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 486, __pyx_L1_error)
18156 __pyx_r = __pyx_pf_10cmeshTools_60allocateGeometricInfo_quadrilateral(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
18163 __Pyx_RefNannyFinishContext();
18167 static PyObject *__pyx_pf_10cmeshTools_60allocateGeometricInfo_quadrilateral(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
18168 PyObject *__pyx_r = NULL;
18169 __Pyx_RefNannyDeclarations
18170 PyObject *__pyx_t_1 = NULL;
18171 int __pyx_lineno = 0;
18172 const char *__pyx_filename = NULL;
18173 int __pyx_clineno = 0;
18174 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_quadrilateral", 0);
18175 __Pyx_XDECREF(__pyx_r);
18176 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_allocateGeometricInfo_quadrilateral(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 486, __pyx_L1_error)
18177 __Pyx_GOTREF(__pyx_t_1);
18178 __pyx_r = __pyx_t_1;
18184 __Pyx_XDECREF(__pyx_t_1);
18185 __Pyx_AddTraceback(
"cmeshTools.allocateGeometricInfo_quadrilateral", __pyx_clineno, __pyx_lineno, __pyx_filename);
18188 __Pyx_XGIVEREF(__pyx_r);
18189 __Pyx_RefNannyFinishContext();
18201 static PyObject *__pyx_pw_10cmeshTools_63computeGeometricInfo_NURBS(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
18202 static void __pyx_f_10cmeshTools_computeGeometricInfo_NURBS(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
18203 __Pyx_RefNannyDeclarations
18204 __Pyx_RefNannySetupContext(
"computeGeometricInfo_NURBS", 0);
18224 __Pyx_RefNannyFinishContext();
18228 static PyObject *__pyx_pw_10cmeshTools_63computeGeometricInfo_NURBS(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
18229 static PyObject *__pyx_pw_10cmeshTools_63computeGeometricInfo_NURBS(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
18230 int __pyx_lineno = 0;
18231 const char *__pyx_filename = NULL;
18232 int __pyx_clineno = 0;
18233 PyObject *__pyx_r = 0;
18234 __Pyx_RefNannyDeclarations
18235 __Pyx_RefNannySetupContext(
"computeGeometricInfo_NURBS (wrapper)", 0);
18236 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 489, __pyx_L1_error)
18237 __pyx_r = __pyx_pf_10cmeshTools_62computeGeometricInfo_NURBS(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
18244 __Pyx_RefNannyFinishContext();
18248 static PyObject *__pyx_pf_10cmeshTools_62computeGeometricInfo_NURBS(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
18249 PyObject *__pyx_r = NULL;
18250 __Pyx_RefNannyDeclarations
18251 PyObject *__pyx_t_1 = NULL;
18252 int __pyx_lineno = 0;
18253 const char *__pyx_filename = NULL;
18254 int __pyx_clineno = 0;
18255 __Pyx_RefNannySetupContext(
"computeGeometricInfo_NURBS", 0);
18256 __Pyx_XDECREF(__pyx_r);
18257 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_computeGeometricInfo_NURBS(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 489, __pyx_L1_error)
18258 __Pyx_GOTREF(__pyx_t_1);
18259 __pyx_r = __pyx_t_1;
18265 __Pyx_XDECREF(__pyx_t_1);
18266 __Pyx_AddTraceback(
"cmeshTools.computeGeometricInfo_NURBS", __pyx_clineno, __pyx_lineno, __pyx_filename);
18269 __Pyx_XGIVEREF(__pyx_r);
18270 __Pyx_RefNannyFinishContext();
18282 static PyObject *__pyx_pw_10cmeshTools_65allocateGeometricInfo_NURBS(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
18283 static void __pyx_f_10cmeshTools_allocateGeometricInfo_NURBS(
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh, CYTHON_UNUSED
int __pyx_skip_dispatch) {
18284 __Pyx_RefNannyDeclarations
18285 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_NURBS", 0);
18305 __Pyx_RefNannyFinishContext();
18309 static PyObject *__pyx_pw_10cmeshTools_65allocateGeometricInfo_NURBS(PyObject *__pyx_self, PyObject *__pyx_v_cmesh);
18310 static PyObject *__pyx_pw_10cmeshTools_65allocateGeometricInfo_NURBS(PyObject *__pyx_self, PyObject *__pyx_v_cmesh) {
18311 int __pyx_lineno = 0;
18312 const char *__pyx_filename = NULL;
18313 int __pyx_clineno = 0;
18314 PyObject *__pyx_r = 0;
18315 __Pyx_RefNannyDeclarations
18316 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_NURBS (wrapper)", 0);
18317 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmesh), __pyx_ptype_10cmeshTools_CMesh, 1,
"cmesh", 0))) __PYX_ERR(1, 492, __pyx_L1_error)
18318 __pyx_r = __pyx_pf_10cmeshTools_64allocateGeometricInfo_NURBS(__pyx_self, ((
struct __pyx_obj_10cmeshTools_CMesh *)__pyx_v_cmesh));
18325 __Pyx_RefNannyFinishContext();
18329 static PyObject *__pyx_pf_10cmeshTools_64allocateGeometricInfo_NURBS(CYTHON_UNUSED PyObject *__pyx_self,
struct __pyx_obj_10cmeshTools_CMesh *__pyx_v_cmesh) {
18330 PyObject *__pyx_r = NULL;
18331 __Pyx_RefNannyDeclarations
18332 PyObject *__pyx_t_1 = NULL;
18333 int __pyx_lineno = 0;
18334 const char *__pyx_filename = NULL;
18335 int __pyx_clineno = 0;
18336 __Pyx_RefNannySetupContext(
"allocateGeometricInfo_NURBS", 0);
18337 __Pyx_XDECREF(__pyx_r);
18338 __pyx_t_1 = __Pyx_void_to_None(__pyx_f_10cmeshTools_allocateGeometricInfo_NURBS(__pyx_v_cmesh, 0));
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 492, __pyx_L1_error)
18339 __Pyx_GOTREF(__pyx_t_1);
18340 __pyx_r = __pyx_t_1;
18346 __Pyx_XDECREF(__pyx_t_1);
18347 __Pyx_AddTraceback(
"cmeshTools.allocateGeometricInfo_NURBS", __pyx_clineno, __pyx_lineno, __pyx_filename);
18350 __Pyx_XGIVEREF(__pyx_r);
18351 __Pyx_RefNannyFinishContext();
18364 static PyObject *__pyx_pw_10cmeshTools_67locallyRefineMultilevelMesh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
18365 static PyMethodDef __pyx_mdef_10cmeshTools_67locallyRefineMultilevelMesh = {
"locallyRefineMultilevelMesh", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_67locallyRefineMultilevelMesh, METH_VARARGS|METH_KEYWORDS, 0};
18366 static PyObject *__pyx_pw_10cmeshTools_67locallyRefineMultilevelMesh(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
18367 int __pyx_v_nSpace;
18368 struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_cmultilevelMesh = 0;
18369 PyArrayObject *__pyx_v_elementTagArray = 0;
18370 int __pyx_v_refineTypeFlag;
18371 int __pyx_lineno = 0;
18372 const char *__pyx_filename = NULL;
18373 int __pyx_clineno = 0;
18374 PyObject *__pyx_r = 0;
18375 __Pyx_RefNannyDeclarations
18376 __Pyx_RefNannySetupContext(
"locallyRefineMultilevelMesh (wrapper)", 0);
18378 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nSpace,&__pyx_n_s_cmultilevelMesh,&__pyx_n_s_elementTagArray,&__pyx_n_s_refineTypeFlag,0};
18379 PyObject* values[4] = {0,0,0,0};
18380 if (unlikely(__pyx_kwds)) {
18381 Py_ssize_t kw_args;
18382 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
18383 switch (pos_args) {
18384 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
18385 CYTHON_FALLTHROUGH;
18386 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
18387 CYTHON_FALLTHROUGH;
18388 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
18389 CYTHON_FALLTHROUGH;
18390 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
18391 CYTHON_FALLTHROUGH;
18393 default:
goto __pyx_L5_argtuple_error;
18395 kw_args = PyDict_Size(__pyx_kwds);
18396 switch (pos_args) {
18398 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nSpace)) != 0)) kw_args--;
18399 else goto __pyx_L5_argtuple_error;
18400 CYTHON_FALLTHROUGH;
18402 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmultilevelMesh)) != 0)) kw_args--;
18404 __Pyx_RaiseArgtupleInvalid(
"locallyRefineMultilevelMesh", 0, 3, 4, 1); __PYX_ERR(1, 495, __pyx_L3_error)
18406 CYTHON_FALLTHROUGH;
18408 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_elementTagArray)) != 0)) kw_args--;
18410 __Pyx_RaiseArgtupleInvalid(
"locallyRefineMultilevelMesh", 0, 3, 4, 2); __PYX_ERR(1, 495, __pyx_L3_error)
18412 CYTHON_FALLTHROUGH;
18415 PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_refineTypeFlag);
18416 if (value) { values[3] = value; kw_args--; }
18419 if (unlikely(kw_args > 0)) {
18420 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"locallyRefineMultilevelMesh") < 0)) __PYX_ERR(1, 495, __pyx_L3_error)
18423 switch (PyTuple_GET_SIZE(__pyx_args)) {
18424 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
18425 CYTHON_FALLTHROUGH;
18426 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
18427 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
18428 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
18430 default:
goto __pyx_L5_argtuple_error;
18433 __pyx_v_nSpace = __Pyx_PyInt_As_int(values[0]);
if (unlikely((__pyx_v_nSpace == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 495, __pyx_L3_error)
18434 __pyx_v_cmultilevelMesh = ((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)values[1]);
18435 __pyx_v_elementTagArray = ((PyArrayObject *)values[2]);
18437 __pyx_v_refineTypeFlag = __Pyx_PyInt_As_int(values[3]);
if (unlikely((__pyx_v_refineTypeFlag == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 498, __pyx_L3_error)
18439 __pyx_v_refineTypeFlag = ((int)0);
18442 goto __pyx_L4_argument_unpacking_done;
18443 __pyx_L5_argtuple_error:;
18444 __Pyx_RaiseArgtupleInvalid(
"locallyRefineMultilevelMesh", 0, 3, 4, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 495, __pyx_L3_error)
18446 __Pyx_AddTraceback(
"cmeshTools.locallyRefineMultilevelMesh", __pyx_clineno, __pyx_lineno, __pyx_filename);
18447 __Pyx_RefNannyFinishContext();
18449 __pyx_L4_argument_unpacking_done:;
18450 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmultilevelMesh), __pyx_ptype_10cmeshTools_CMultilevelMesh, 1,
"cmultilevelMesh", 0))) __PYX_ERR(1, 496, __pyx_L1_error)
18451 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_elementTagArray), __pyx_ptype_5numpy_ndarray, 1,
"elementTagArray", 0))) __PYX_ERR(1, 497, __pyx_L1_error)
18452 __pyx_r = __pyx_pf_10cmeshTools_66locallyRefineMultilevelMesh(__pyx_self, __pyx_v_nSpace, __pyx_v_cmultilevelMesh, __pyx_v_elementTagArray, __pyx_v_refineTypeFlag);
18459 __Pyx_RefNannyFinishContext();
18463 static PyObject *__pyx_pf_10cmeshTools_66locallyRefineMultilevelMesh(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nSpace,
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_cmultilevelMesh, PyArrayObject *__pyx_v_elementTagArray,
int __pyx_v_refineTypeFlag) {
18464 CYTHON_UNUSED
int __pyx_v_failed;
18465 int __pyx_v_finestLevel;
18466 PyObject *__pyx_r = NULL;
18467 __Pyx_RefNannyDeclarations
18470 PyObject *__pyx_t_3 = NULL;
18471 PyObject *__pyx_t_4 = NULL;
18472 PyObject *__pyx_t_5 = NULL;
18473 PyObject *__pyx_t_6 = NULL;
18474 int __pyx_lineno = 0;
18475 const char *__pyx_filename = NULL;
18476 int __pyx_clineno = 0;
18477 __Pyx_RefNannySetupContext(
"locallyRefineMultilevelMesh", 0);
18486 switch (__pyx_v_nSpace) {
18496 __pyx_v_failed =
locallyRefineEdgeMesh(__pyx_v_cmultilevelMesh->multilevelMesh, ((
int *)__pyx_v_elementTagArray->data));
18505 __pyx_t_1 = __pyx_v_cmultilevelMesh->multilevelMesh.nLevels;
18506 __pyx_v_finestLevel = __pyx_t_1;
18542 __pyx_t_2 = ((__pyx_v_finestLevel > 1) != 0);
18552 (void)(
assignElementBoundaryMaterialTypesFromParent((__pyx_v_cmultilevelMesh->multilevelMesh.meshArray[(__pyx_v_finestLevel - 2)]), (__pyx_v_cmultilevelMesh->multilevelMesh.meshArray[(__pyx_v_finestLevel - 1)]), (__pyx_v_cmultilevelMesh->multilevelMesh.elementParentsArray[(__pyx_v_finestLevel - 1)]), 1));
18580 switch (__pyx_v_refineTypeFlag) {
18628 __pyx_v_failed =
locallyRefineTriangleMesh(__pyx_v_cmultilevelMesh->multilevelMesh, ((
int *)__pyx_v_elementTagArray->data));
18639 __pyx_t_1 = __pyx_v_cmultilevelMesh->multilevelMesh.nLevels;
18640 __pyx_v_finestLevel = __pyx_t_1;
18676 __pyx_t_2 = ((__pyx_v_finestLevel > 1) != 0);
18686 (void)(
assignElementBoundaryMaterialTypesFromParent((__pyx_v_cmultilevelMesh->multilevelMesh.meshArray[(__pyx_v_finestLevel - 2)]), (__pyx_v_cmultilevelMesh->multilevelMesh.meshArray[(__pyx_v_finestLevel - 1)]), (__pyx_v_cmultilevelMesh->multilevelMesh.elementParentsArray[(__pyx_v_finestLevel - 1)]), 2));
18714 __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_locallyRefine_nSpace_0_d_not_imp, __pyx_n_s_format);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 531, __pyx_L1_error)
18715 __Pyx_GOTREF(__pyx_t_4);
18716 __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_nSpace);
if (unlikely(!__pyx_t_5)) __PYX_ERR(1, 531, __pyx_L1_error)
18717 __Pyx_GOTREF(__pyx_t_5);
18719 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) {
18720 __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_4);
18721 if (likely(__pyx_t_6)) {
18722 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
18723 __Pyx_INCREF(__pyx_t_6);
18724 __Pyx_INCREF(
function);
18725 __Pyx_DECREF_SET(__pyx_t_4,
function);
18728 __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5);
18729 __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
18730 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
18731 if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 531, __pyx_L1_error)
18732 __Pyx_GOTREF(__pyx_t_3);
18733 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
18734 if (__Pyx_PrintOne(0, __pyx_t_3) < 0) __PYX_ERR(1, 531, __pyx_L1_error)
18735 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
18748 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
18751 __Pyx_XDECREF(__pyx_t_3);
18752 __Pyx_XDECREF(__pyx_t_4);
18753 __Pyx_XDECREF(__pyx_t_5);
18754 __Pyx_XDECREF(__pyx_t_6);
18755 __Pyx_AddTraceback(
"cmeshTools.locallyRefineMultilevelMesh", __pyx_clineno, __pyx_lineno, __pyx_filename);
18758 __Pyx_XGIVEREF(__pyx_r);
18759 __Pyx_RefNannyFinishContext();
18772 static PyObject *__pyx_pw_10cmeshTools_69setNewestNodeBases(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
18773 static PyMethodDef __pyx_mdef_10cmeshTools_69setNewestNodeBases = {
"setNewestNodeBases", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_69setNewestNodeBases, METH_VARARGS|METH_KEYWORDS, 0};
18774 static PyObject *__pyx_pw_10cmeshTools_69setNewestNodeBases(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
18775 int __pyx_v_nSpace;
18776 struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_cmultilevelMesh = 0;
18777 int __pyx_lineno = 0;
18778 const char *__pyx_filename = NULL;
18779 int __pyx_clineno = 0;
18780 PyObject *__pyx_r = 0;
18781 __Pyx_RefNannyDeclarations
18782 __Pyx_RefNannySetupContext(
"setNewestNodeBases (wrapper)", 0);
18784 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_nSpace,&__pyx_n_s_cmultilevelMesh,0};
18785 PyObject* values[2] = {0,0};
18786 if (unlikely(__pyx_kwds)) {
18787 Py_ssize_t kw_args;
18788 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
18789 switch (pos_args) {
18790 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
18791 CYTHON_FALLTHROUGH;
18792 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
18793 CYTHON_FALLTHROUGH;
18795 default:
goto __pyx_L5_argtuple_error;
18797 kw_args = PyDict_Size(__pyx_kwds);
18798 switch (pos_args) {
18800 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_nSpace)) != 0)) kw_args--;
18801 else goto __pyx_L5_argtuple_error;
18802 CYTHON_FALLTHROUGH;
18804 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_cmultilevelMesh)) != 0)) kw_args--;
18806 __Pyx_RaiseArgtupleInvalid(
"setNewestNodeBases", 1, 2, 2, 1); __PYX_ERR(1, 533, __pyx_L3_error)
18809 if (unlikely(kw_args > 0)) {
18810 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"setNewestNodeBases") < 0)) __PYX_ERR(1, 533, __pyx_L3_error)
18812 }
else if (PyTuple_GET_SIZE(__pyx_args) != 2) {
18813 goto __pyx_L5_argtuple_error;
18815 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
18816 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
18818 __pyx_v_nSpace = __Pyx_PyInt_As_int(values[0]);
if (unlikely((__pyx_v_nSpace == (
int)-1) && PyErr_Occurred())) __PYX_ERR(1, 533, __pyx_L3_error)
18819 __pyx_v_cmultilevelMesh = ((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)values[1]);
18821 goto __pyx_L4_argument_unpacking_done;
18822 __pyx_L5_argtuple_error:;
18823 __Pyx_RaiseArgtupleInvalid(
"setNewestNodeBases", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 533, __pyx_L3_error)
18825 __Pyx_AddTraceback(
"cmeshTools.setNewestNodeBases", __pyx_clineno, __pyx_lineno, __pyx_filename);
18826 __Pyx_RefNannyFinishContext();
18828 __pyx_L4_argument_unpacking_done:;
18829 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_cmultilevelMesh), __pyx_ptype_10cmeshTools_CMultilevelMesh, 1,
"cmultilevelMesh", 0))) __PYX_ERR(1, 533, __pyx_L1_error)
18830 __pyx_r = __pyx_pf_10cmeshTools_68setNewestNodeBases(__pyx_self, __pyx_v_nSpace, __pyx_v_cmultilevelMesh);
18837 __Pyx_RefNannyFinishContext();
18841 static PyObject *__pyx_pf_10cmeshTools_68setNewestNodeBases(CYTHON_UNUSED PyObject *__pyx_self,
int __pyx_v_nSpace,
struct __pyx_obj_10cmeshTools_CMultilevelMesh *__pyx_v_cmultilevelMesh) {
18842 CYTHON_UNUSED
int __pyx_v_failed;
18843 PyObject *__pyx_r = NULL;
18844 __Pyx_RefNannyDeclarations
18846 PyObject *__pyx_t_2 = NULL;
18847 PyObject *__pyx_t_3 = NULL;
18848 PyObject *__pyx_t_4 = NULL;
18849 PyObject *__pyx_t_5 = NULL;
18850 int __pyx_lineno = 0;
18851 const char *__pyx_filename = NULL;
18852 int __pyx_clineno = 0;
18853 __Pyx_RefNannySetupContext(
"setNewestNodeBases", 0);
18862 __pyx_t_1 = ((__pyx_v_nSpace == 2) != 0);
18890 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_kp_s_setNewestNodeBases_0_d_not_imple, __pyx_n_s_format);
if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 537, __pyx_L1_error)
18891 __Pyx_GOTREF(__pyx_t_3);
18892 __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_nSpace);
if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 537, __pyx_L1_error)
18893 __Pyx_GOTREF(__pyx_t_4);
18895 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) {
18896 __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_3);
18897 if (likely(__pyx_t_5)) {
18898 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
18899 __Pyx_INCREF(__pyx_t_5);
18900 __Pyx_INCREF(
function);
18901 __Pyx_DECREF_SET(__pyx_t_3,
function);
18904 __pyx_t_2 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4);
18905 __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
18906 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
18907 if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 537, __pyx_L1_error)
18908 __Pyx_GOTREF(__pyx_t_2);
18909 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
18910 if (__Pyx_PrintOne(0, __pyx_t_2) < 0) __PYX_ERR(1, 537, __pyx_L1_error)
18911 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
18924 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
18927 __Pyx_XDECREF(__pyx_t_2);
18928 __Pyx_XDECREF(__pyx_t_3);
18929 __Pyx_XDECREF(__pyx_t_4);
18930 __Pyx_XDECREF(__pyx_t_5);
18931 __Pyx_AddTraceback(
"cmeshTools.setNewestNodeBases", __pyx_clineno, __pyx_lineno, __pyx_filename);
18934 __Pyx_XGIVEREF(__pyx_r);
18935 __Pyx_RefNannyFinishContext();
18947 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew1(PyObject *__pyx_v_a) {
18948 PyObject *__pyx_r = NULL;
18949 __Pyx_RefNannyDeclarations
18950 PyObject *__pyx_t_1 = NULL;
18951 int __pyx_lineno = 0;
18952 const char *__pyx_filename = NULL;
18953 int __pyx_clineno = 0;
18954 __Pyx_RefNannySetupContext(
"PyArray_MultiIterNew1", 0);
18963 __Pyx_XDECREF(__pyx_r);
18964 __pyx_t_1 = PyArray_MultiIterNew(1, ((
void *)__pyx_v_a));
if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 736, __pyx_L1_error)
18965 __Pyx_GOTREF(__pyx_t_1);
18966 __pyx_r = __pyx_t_1;
18980 __Pyx_XDECREF(__pyx_t_1);
18981 __Pyx_AddTraceback(
"numpy.PyArray_MultiIterNew1", __pyx_clineno, __pyx_lineno, __pyx_filename);
18984 __Pyx_XGIVEREF(__pyx_r);
18985 __Pyx_RefNannyFinishContext();
18997 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew2(PyObject *__pyx_v_a, PyObject *__pyx_v_b) {
18998 PyObject *__pyx_r = NULL;
18999 __Pyx_RefNannyDeclarations
19000 PyObject *__pyx_t_1 = NULL;
19001 int __pyx_lineno = 0;
19002 const char *__pyx_filename = NULL;
19003 int __pyx_clineno = 0;
19004 __Pyx_RefNannySetupContext(
"PyArray_MultiIterNew2", 0);
19013 __Pyx_XDECREF(__pyx_r);
19014 __pyx_t_1 = PyArray_MultiIterNew(2, ((
void *)__pyx_v_a), ((
void *)__pyx_v_b));
if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 739, __pyx_L1_error)
19015 __Pyx_GOTREF(__pyx_t_1);
19016 __pyx_r = __pyx_t_1;
19030 __Pyx_XDECREF(__pyx_t_1);
19031 __Pyx_AddTraceback(
"numpy.PyArray_MultiIterNew2", __pyx_clineno, __pyx_lineno, __pyx_filename);
19034 __Pyx_XGIVEREF(__pyx_r);
19035 __Pyx_RefNannyFinishContext();
19047 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew3(PyObject *__pyx_v_a, PyObject *__pyx_v_b, PyObject *__pyx_v_c) {
19048 PyObject *__pyx_r = NULL;
19049 __Pyx_RefNannyDeclarations
19050 PyObject *__pyx_t_1 = NULL;
19051 int __pyx_lineno = 0;
19052 const char *__pyx_filename = NULL;
19053 int __pyx_clineno = 0;
19054 __Pyx_RefNannySetupContext(
"PyArray_MultiIterNew3", 0);
19063 __Pyx_XDECREF(__pyx_r);
19064 __pyx_t_1 = PyArray_MultiIterNew(3, ((
void *)__pyx_v_a), ((
void *)__pyx_v_b), ((
void *)__pyx_v_c));
if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 742, __pyx_L1_error)
19065 __Pyx_GOTREF(__pyx_t_1);
19066 __pyx_r = __pyx_t_1;
19080 __Pyx_XDECREF(__pyx_t_1);
19081 __Pyx_AddTraceback(
"numpy.PyArray_MultiIterNew3", __pyx_clineno, __pyx_lineno, __pyx_filename);
19084 __Pyx_XGIVEREF(__pyx_r);
19085 __Pyx_RefNannyFinishContext();
19097 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew4(PyObject *__pyx_v_a, PyObject *__pyx_v_b, PyObject *__pyx_v_c, PyObject *__pyx_v_d) {
19098 PyObject *__pyx_r = NULL;
19099 __Pyx_RefNannyDeclarations
19100 PyObject *__pyx_t_1 = NULL;
19101 int __pyx_lineno = 0;
19102 const char *__pyx_filename = NULL;
19103 int __pyx_clineno = 0;
19104 __Pyx_RefNannySetupContext(
"PyArray_MultiIterNew4", 0);
19113 __Pyx_XDECREF(__pyx_r);
19114 __pyx_t_1 = PyArray_MultiIterNew(4, ((
void *)__pyx_v_a), ((
void *)__pyx_v_b), ((
void *)__pyx_v_c), ((
void *)__pyx_v_d));
if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 745, __pyx_L1_error)
19115 __Pyx_GOTREF(__pyx_t_1);
19116 __pyx_r = __pyx_t_1;
19130 __Pyx_XDECREF(__pyx_t_1);
19131 __Pyx_AddTraceback(
"numpy.PyArray_MultiIterNew4", __pyx_clineno, __pyx_lineno, __pyx_filename);
19134 __Pyx_XGIVEREF(__pyx_r);
19135 __Pyx_RefNannyFinishContext();
19147 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyArray_MultiIterNew5(PyObject *__pyx_v_a, PyObject *__pyx_v_b, PyObject *__pyx_v_c, PyObject *__pyx_v_d, PyObject *__pyx_v_e) {
19148 PyObject *__pyx_r = NULL;
19149 __Pyx_RefNannyDeclarations
19150 PyObject *__pyx_t_1 = NULL;
19151 int __pyx_lineno = 0;
19152 const char *__pyx_filename = NULL;
19153 int __pyx_clineno = 0;
19154 __Pyx_RefNannySetupContext(
"PyArray_MultiIterNew5", 0);
19163 __Pyx_XDECREF(__pyx_r);
19164 __pyx_t_1 = PyArray_MultiIterNew(5, ((
void *)__pyx_v_a), ((
void *)__pyx_v_b), ((
void *)__pyx_v_c), ((
void *)__pyx_v_d), ((
void *)__pyx_v_e));
if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 748, __pyx_L1_error)
19165 __Pyx_GOTREF(__pyx_t_1);
19166 __pyx_r = __pyx_t_1;
19180 __Pyx_XDECREF(__pyx_t_1);
19181 __Pyx_AddTraceback(
"numpy.PyArray_MultiIterNew5", __pyx_clineno, __pyx_lineno, __pyx_filename);
19184 __Pyx_XGIVEREF(__pyx_r);
19185 __Pyx_RefNannyFinishContext();
19197 static CYTHON_INLINE PyObject *__pyx_f_5numpy_PyDataType_SHAPE(PyArray_Descr *__pyx_v_d) {
19198 PyObject *__pyx_r = NULL;
19199 __Pyx_RefNannyDeclarations
19201 __Pyx_RefNannySetupContext(
"PyDataType_SHAPE", 0);
19210 __pyx_t_1 = (PyDataType_HASSUBARRAY(__pyx_v_d) != 0);
19220 __Pyx_XDECREF(__pyx_r);
19221 __Pyx_INCREF(((PyObject*)__pyx_v_d->subarray->shape));
19222 __pyx_r = ((PyObject*)__pyx_v_d->subarray->shape);
19242 __Pyx_XDECREF(__pyx_r);
19243 __Pyx_INCREF(__pyx_empty_tuple);
19244 __pyx_r = __pyx_empty_tuple;
19258 __Pyx_XGIVEREF(__pyx_r);
19259 __Pyx_RefNannyFinishContext();
19271 static CYTHON_INLINE
void __pyx_f_5numpy_set_array_base(PyArrayObject *__pyx_v_arr, PyObject *__pyx_v_base) {
19272 __Pyx_RefNannyDeclarations
19273 __Pyx_RefNannySetupContext(
"set_array_base", 0);
19282 Py_INCREF(__pyx_v_base);
19291 (void)(PyArray_SetBaseObject(__pyx_v_arr, __pyx_v_base));
19302 __Pyx_RefNannyFinishContext();
19313 static CYTHON_INLINE PyObject *__pyx_f_5numpy_get_array_base(PyArrayObject *__pyx_v_arr) {
19314 PyObject *__pyx_v_base;
19315 PyObject *__pyx_r = NULL;
19316 __Pyx_RefNannyDeclarations
19318 __Pyx_RefNannySetupContext(
"get_array_base", 0);
19327 __pyx_v_base = PyArray_BASE(__pyx_v_arr);
19336 __pyx_t_1 = ((__pyx_v_base == NULL) != 0);
19346 __Pyx_XDECREF(__pyx_r);
19347 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
19366 __Pyx_XDECREF(__pyx_r);
19367 __Pyx_INCREF(((PyObject *)__pyx_v_base));
19368 __pyx_r = ((PyObject *)__pyx_v_base);
19381 __Pyx_XGIVEREF(__pyx_r);
19382 __Pyx_RefNannyFinishContext();
19394 static CYTHON_INLINE
int __pyx_f_5numpy_import_array(
void) {
19396 __Pyx_RefNannyDeclarations
19397 PyObject *__pyx_t_1 = NULL;
19398 PyObject *__pyx_t_2 = NULL;
19399 PyObject *__pyx_t_3 = NULL;
19401 PyObject *__pyx_t_5 = NULL;
19402 PyObject *__pyx_t_6 = NULL;
19403 PyObject *__pyx_t_7 = NULL;
19404 PyObject *__pyx_t_8 = NULL;
19405 int __pyx_lineno = 0;
19406 const char *__pyx_filename = NULL;
19407 int __pyx_clineno = 0;
19408 __Pyx_RefNannySetupContext(
"import_array", 0);
19418 __Pyx_PyThreadState_declare
19419 __Pyx_PyThreadState_assign
19420 __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
19421 __Pyx_XGOTREF(__pyx_t_1);
19422 __Pyx_XGOTREF(__pyx_t_2);
19423 __Pyx_XGOTREF(__pyx_t_3);
19433 __pyx_t_4 = _import_array();
if (unlikely(__pyx_t_4 == ((
int)-1))) __PYX_ERR(3, 943, __pyx_L3_error)
19443 __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
19444 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
19445 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
19446 goto __pyx_L8_try_end;
19456 __pyx_t_4 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])));
19458 __Pyx_AddTraceback(
"numpy.import_array", __pyx_clineno, __pyx_lineno, __pyx_filename);
19459 if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(3, 944, __pyx_L5_except_error)
19460 __Pyx_GOTREF(__pyx_t_5);
19461 __Pyx_GOTREF(__pyx_t_6);
19462 __Pyx_GOTREF(__pyx_t_7);
19471 __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_ImportError, __pyx_tuple__6, NULL);
if (unlikely(!__pyx_t_8)) __PYX_ERR(3, 945, __pyx_L5_except_error)
19472 __Pyx_GOTREF(__pyx_t_8);
19473 __Pyx_Raise(__pyx_t_8, 0, 0, 0);
19474 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
19475 __PYX_ERR(3, 945, __pyx_L5_except_error)
19477 goto __pyx_L5_except_error;
19478 __pyx_L5_except_error:;
19487 __Pyx_XGIVEREF(__pyx_t_1);
19488 __Pyx_XGIVEREF(__pyx_t_2);
19489 __Pyx_XGIVEREF(__pyx_t_3);
19490 __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
19491 goto __pyx_L1_error;
19507 __Pyx_XDECREF(__pyx_t_5);
19508 __Pyx_XDECREF(__pyx_t_6);
19509 __Pyx_XDECREF(__pyx_t_7);
19510 __Pyx_XDECREF(__pyx_t_8);
19511 __Pyx_AddTraceback(
"numpy.import_array", __pyx_clineno, __pyx_lineno, __pyx_filename);
19514 __Pyx_RefNannyFinishContext();
19526 static CYTHON_INLINE
int __pyx_f_5numpy_import_umath(
void) {
19528 __Pyx_RefNannyDeclarations
19529 PyObject *__pyx_t_1 = NULL;
19530 PyObject *__pyx_t_2 = NULL;
19531 PyObject *__pyx_t_3 = NULL;
19533 PyObject *__pyx_t_5 = NULL;
19534 PyObject *__pyx_t_6 = NULL;
19535 PyObject *__pyx_t_7 = NULL;
19536 PyObject *__pyx_t_8 = NULL;
19537 int __pyx_lineno = 0;
19538 const char *__pyx_filename = NULL;
19539 int __pyx_clineno = 0;
19540 __Pyx_RefNannySetupContext(
"import_umath", 0);
19550 __Pyx_PyThreadState_declare
19551 __Pyx_PyThreadState_assign
19552 __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
19553 __Pyx_XGOTREF(__pyx_t_1);
19554 __Pyx_XGOTREF(__pyx_t_2);
19555 __Pyx_XGOTREF(__pyx_t_3);
19565 __pyx_t_4 = _import_umath();
if (unlikely(__pyx_t_4 == ((
int)-1))) __PYX_ERR(3, 949, __pyx_L3_error)
19575 __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
19576 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
19577 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
19578 goto __pyx_L8_try_end;
19588 __pyx_t_4 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])));
19590 __Pyx_AddTraceback(
"numpy.import_umath", __pyx_clineno, __pyx_lineno, __pyx_filename);
19591 if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(3, 950, __pyx_L5_except_error)
19592 __Pyx_GOTREF(__pyx_t_5);
19593 __Pyx_GOTREF(__pyx_t_6);
19594 __Pyx_GOTREF(__pyx_t_7);
19603 __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_ImportError, __pyx_tuple__7, NULL);
if (unlikely(!__pyx_t_8)) __PYX_ERR(3, 951, __pyx_L5_except_error)
19604 __Pyx_GOTREF(__pyx_t_8);
19605 __Pyx_Raise(__pyx_t_8, 0, 0, 0);
19606 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
19607 __PYX_ERR(3, 951, __pyx_L5_except_error)
19609 goto __pyx_L5_except_error;
19610 __pyx_L5_except_error:;
19619 __Pyx_XGIVEREF(__pyx_t_1);
19620 __Pyx_XGIVEREF(__pyx_t_2);
19621 __Pyx_XGIVEREF(__pyx_t_3);
19622 __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
19623 goto __pyx_L1_error;
19639 __Pyx_XDECREF(__pyx_t_5);
19640 __Pyx_XDECREF(__pyx_t_6);
19641 __Pyx_XDECREF(__pyx_t_7);
19642 __Pyx_XDECREF(__pyx_t_8);
19643 __Pyx_AddTraceback(
"numpy.import_umath", __pyx_clineno, __pyx_lineno, __pyx_filename);
19646 __Pyx_RefNannyFinishContext();
19658 static CYTHON_INLINE
int __pyx_f_5numpy_import_ufunc(
void) {
19660 __Pyx_RefNannyDeclarations
19661 PyObject *__pyx_t_1 = NULL;
19662 PyObject *__pyx_t_2 = NULL;
19663 PyObject *__pyx_t_3 = NULL;
19665 PyObject *__pyx_t_5 = NULL;
19666 PyObject *__pyx_t_6 = NULL;
19667 PyObject *__pyx_t_7 = NULL;
19668 PyObject *__pyx_t_8 = NULL;
19669 int __pyx_lineno = 0;
19670 const char *__pyx_filename = NULL;
19671 int __pyx_clineno = 0;
19672 __Pyx_RefNannySetupContext(
"import_ufunc", 0);
19682 __Pyx_PyThreadState_declare
19683 __Pyx_PyThreadState_assign
19684 __Pyx_ExceptionSave(&__pyx_t_1, &__pyx_t_2, &__pyx_t_3);
19685 __Pyx_XGOTREF(__pyx_t_1);
19686 __Pyx_XGOTREF(__pyx_t_2);
19687 __Pyx_XGOTREF(__pyx_t_3);
19697 __pyx_t_4 = _import_umath();
if (unlikely(__pyx_t_4 == ((
int)-1))) __PYX_ERR(3, 955, __pyx_L3_error)
19707 __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
19708 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
19709 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
19710 goto __pyx_L8_try_end;
19720 __pyx_t_4 = __Pyx_PyErr_ExceptionMatches(((PyObject *)(&((PyTypeObject*)PyExc_Exception)[0])));
19722 __Pyx_AddTraceback(
"numpy.import_ufunc", __pyx_clineno, __pyx_lineno, __pyx_filename);
19723 if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_6, &__pyx_t_7) < 0) __PYX_ERR(3, 956, __pyx_L5_except_error)
19724 __Pyx_GOTREF(__pyx_t_5);
19725 __Pyx_GOTREF(__pyx_t_6);
19726 __Pyx_GOTREF(__pyx_t_7);
19735 __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_ImportError, __pyx_tuple__7, NULL);
if (unlikely(!__pyx_t_8)) __PYX_ERR(3, 957, __pyx_L5_except_error)
19736 __Pyx_GOTREF(__pyx_t_8);
19737 __Pyx_Raise(__pyx_t_8, 0, 0, 0);
19738 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
19739 __PYX_ERR(3, 957, __pyx_L5_except_error)
19741 goto __pyx_L5_except_error;
19742 __pyx_L5_except_error:;
19751 __Pyx_XGIVEREF(__pyx_t_1);
19752 __Pyx_XGIVEREF(__pyx_t_2);
19753 __Pyx_XGIVEREF(__pyx_t_3);
19754 __Pyx_ExceptionReset(__pyx_t_1, __pyx_t_2, __pyx_t_3);
19755 goto __pyx_L1_error;
19771 __Pyx_XDECREF(__pyx_t_5);
19772 __Pyx_XDECREF(__pyx_t_6);
19773 __Pyx_XDECREF(__pyx_t_7);
19774 __Pyx_XDECREF(__pyx_t_8);
19775 __Pyx_AddTraceback(
"numpy.import_ufunc", __pyx_clineno, __pyx_lineno, __pyx_filename);
19778 __Pyx_RefNannyFinishContext();
19790 static CYTHON_INLINE
int __pyx_f_5numpy_is_timedelta64_object(PyObject *__pyx_v_obj) {
19792 __Pyx_RefNannyDeclarations
19793 __Pyx_RefNannySetupContext(
"is_timedelta64_object", 0);
19802 __pyx_r = PyObject_TypeCheck(__pyx_v_obj, (&PyTimedeltaArrType_Type));
19815 __Pyx_RefNannyFinishContext();
19827 static CYTHON_INLINE
int __pyx_f_5numpy_is_datetime64_object(PyObject *__pyx_v_obj) {
19829 __Pyx_RefNannyDeclarations
19830 __Pyx_RefNannySetupContext(
"is_datetime64_object", 0);
19839 __pyx_r = PyObject_TypeCheck(__pyx_v_obj, (&PyDatetimeArrType_Type));
19852 __Pyx_RefNannyFinishContext();
19864 static CYTHON_INLINE npy_datetime __pyx_f_5numpy_get_datetime64_value(PyObject *__pyx_v_obj) {
19865 npy_datetime __pyx_r;
19874 __pyx_r = ((PyDatetimeScalarObject *)__pyx_v_obj)->obval;
19898 static CYTHON_INLINE npy_timedelta __pyx_f_5numpy_get_timedelta64_value(PyObject *__pyx_v_obj) {
19899 npy_timedelta __pyx_r;
19908 __pyx_r = ((PyTimedeltaScalarObject *)__pyx_v_obj)->obval;
19932 static CYTHON_INLINE NPY_DATETIMEUNIT __pyx_f_5numpy_get_datetime64_unit(PyObject *__pyx_v_obj) {
19933 NPY_DATETIMEUNIT __pyx_r;
19940 __pyx_r = ((NPY_DATETIMEUNIT)((PyDatetimeScalarObject *)__pyx_v_obj)->obmeta.base);
19965 static int __pyx_array___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
19966 static int __pyx_array___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
19967 PyObject *__pyx_v_shape = 0;
19968 Py_ssize_t __pyx_v_itemsize;
19969 PyObject *__pyx_v_format = 0;
19970 PyObject *__pyx_v_mode = 0;
19971 int __pyx_v_allocate_buffer;
19972 int __pyx_lineno = 0;
19973 const char *__pyx_filename = NULL;
19974 int __pyx_clineno = 0;
19976 __Pyx_RefNannyDeclarations
19977 __Pyx_RefNannySetupContext(
"__cinit__ (wrapper)", 0);
19979 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_shape,&__pyx_n_s_itemsize,&__pyx_n_s_format,&__pyx_n_s_mode,&__pyx_n_s_allocate_buffer,0};
19980 PyObject* values[5] = {0,0,0,0,0};
19981 values[3] = ((PyObject *)__pyx_n_s_c);
19982 if (unlikely(__pyx_kwds)) {
19983 Py_ssize_t kw_args;
19984 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
19985 switch (pos_args) {
19986 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
19987 CYTHON_FALLTHROUGH;
19988 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
19989 CYTHON_FALLTHROUGH;
19990 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
19991 CYTHON_FALLTHROUGH;
19992 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
19993 CYTHON_FALLTHROUGH;
19994 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
19995 CYTHON_FALLTHROUGH;
19997 default:
goto __pyx_L5_argtuple_error;
19999 kw_args = PyDict_Size(__pyx_kwds);
20000 switch (pos_args) {
20002 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_shape)) != 0)) kw_args--;
20003 else goto __pyx_L5_argtuple_error;
20004 CYTHON_FALLTHROUGH;
20006 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_itemsize)) != 0)) kw_args--;
20008 __Pyx_RaiseArgtupleInvalid(
"__cinit__", 0, 3, 5, 1); __PYX_ERR(0, 122, __pyx_L3_error)
20010 CYTHON_FALLTHROUGH;
20012 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_format)) != 0)) kw_args--;
20014 __Pyx_RaiseArgtupleInvalid(
"__cinit__", 0, 3, 5, 2); __PYX_ERR(0, 122, __pyx_L3_error)
20016 CYTHON_FALLTHROUGH;
20019 PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_mode);
20020 if (value) { values[3] = value; kw_args--; }
20022 CYTHON_FALLTHROUGH;
20025 PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_allocate_buffer);
20026 if (value) { values[4] = value; kw_args--; }
20029 if (unlikely(kw_args > 0)) {
20030 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"__cinit__") < 0)) __PYX_ERR(0, 122, __pyx_L3_error)
20033 switch (PyTuple_GET_SIZE(__pyx_args)) {
20034 case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
20035 CYTHON_FALLTHROUGH;
20036 case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
20037 CYTHON_FALLTHROUGH;
20038 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
20039 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
20040 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
20042 default:
goto __pyx_L5_argtuple_error;
20045 __pyx_v_shape = ((PyObject*)values[0]);
20046 __pyx_v_itemsize = __Pyx_PyIndex_AsSsize_t(values[1]);
if (unlikely((__pyx_v_itemsize == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 122, __pyx_L3_error)
20047 __pyx_v_format = values[2];
20048 __pyx_v_mode = values[3];
20050 __pyx_v_allocate_buffer = __Pyx_PyObject_IsTrue(values[4]);
if (unlikely((__pyx_v_allocate_buffer == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 123, __pyx_L3_error)
20060 __pyx_v_allocate_buffer = ((int)1);
20063 goto __pyx_L4_argument_unpacking_done;
20064 __pyx_L5_argtuple_error:;
20065 __Pyx_RaiseArgtupleInvalid(
"__cinit__", 0, 3, 5, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 122, __pyx_L3_error)
20067 __Pyx_AddTraceback(
"View.MemoryView.array.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
20068 __Pyx_RefNannyFinishContext();
20070 __pyx_L4_argument_unpacking_done:;
20071 if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_shape), (&PyTuple_Type), 1,
"shape", 1))) __PYX_ERR(0, 122, __pyx_L1_error)
20072 if (unlikely(((PyObject *)__pyx_v_format) == Py_None)) {
20073 PyErr_Format(PyExc_TypeError,
"Argument '%.200s' must not be None",
"format"); __PYX_ERR(0, 122, __pyx_L1_error)
20075 __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array___cinit__(((
struct __pyx_array_obj *)__pyx_v_self), __pyx_v_shape, __pyx_v_itemsize, __pyx_v_format, __pyx_v_mode, __pyx_v_allocate_buffer);
20090 __Pyx_RefNannyFinishContext();
20094 static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array___cinit__(
struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_shape, Py_ssize_t __pyx_v_itemsize, PyObject *__pyx_v_format, PyObject *__pyx_v_mode,
int __pyx_v_allocate_buffer) {
20096 Py_ssize_t __pyx_v_i;
20097 Py_ssize_t __pyx_v_dim;
20098 PyObject **__pyx_v_p;
20099 char __pyx_v_order;
20101 __Pyx_RefNannyDeclarations
20102 Py_ssize_t __pyx_t_1;
20104 PyObject *__pyx_t_3 = NULL;
20106 PyObject *__pyx_t_5 = NULL;
20107 PyObject *__pyx_t_6 = NULL;
20110 Py_ssize_t __pyx_t_9;
20111 PyObject *__pyx_t_10 = NULL;
20112 Py_ssize_t __pyx_t_11;
20113 int __pyx_lineno = 0;
20114 const char *__pyx_filename = NULL;
20115 int __pyx_clineno = 0;
20116 __Pyx_RefNannySetupContext(
"__cinit__", 0);
20117 __Pyx_INCREF(__pyx_v_format);
20126 if (unlikely(__pyx_v_shape == Py_None)) {
20127 PyErr_SetString(PyExc_TypeError,
"object of type 'NoneType' has no len()");
20128 __PYX_ERR(0, 129, __pyx_L1_error)
20130 __pyx_t_1 = PyTuple_GET_SIZE(__pyx_v_shape);
if (unlikely(__pyx_t_1 == ((Py_ssize_t)-1))) __PYX_ERR(0, 129, __pyx_L1_error)
20131 __pyx_v_self->ndim = ((int)__pyx_t_1);
20140 __pyx_v_self->itemsize = __pyx_v_itemsize;
20149 __pyx_t_2 = ((!(__pyx_v_self->ndim != 0)) != 0);
20150 if (unlikely(__pyx_t_2)) {
20159 __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__8, NULL);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 133, __pyx_L1_error)
20160 __Pyx_GOTREF(__pyx_t_3);
20161 __Pyx_Raise(__pyx_t_3, 0, 0, 0);
20162 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
20163 __PYX_ERR(0, 133, __pyx_L1_error)
20181 __pyx_t_2 = ((__pyx_v_itemsize <= 0) != 0);
20182 if (unlikely(__pyx_t_2)) {
20191 __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__9, NULL);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 136, __pyx_L1_error)
20192 __Pyx_GOTREF(__pyx_t_3);
20193 __Pyx_Raise(__pyx_t_3, 0, 0, 0);
20194 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
20195 __PYX_ERR(0, 136, __pyx_L1_error)
20213 __pyx_t_2 = PyBytes_Check(__pyx_v_format);
20214 __pyx_t_4 = ((!(__pyx_t_2 != 0)) != 0);
20224 __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_format, __pyx_n_s_encode);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 139, __pyx_L1_error)
20225 __Pyx_GOTREF(__pyx_t_5);
20227 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) {
20228 __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5);
20229 if (likely(__pyx_t_6)) {
20230 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_5);
20231 __Pyx_INCREF(__pyx_t_6);
20232 __Pyx_INCREF(
function);
20233 __Pyx_DECREF_SET(__pyx_t_5,
function);
20236 __pyx_t_3 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_n_s_ASCII) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_n_s_ASCII);
20237 __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
20238 if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 139, __pyx_L1_error)
20239 __Pyx_GOTREF(__pyx_t_3);
20240 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
20241 __Pyx_DECREF_SET(__pyx_v_format, __pyx_t_3);
20260 if (!(likely(PyBytes_CheckExact(__pyx_v_format))||((__pyx_v_format) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"bytes", Py_TYPE(__pyx_v_format)->tp_name), 0))) __PYX_ERR(0, 140, __pyx_L1_error)
20261 __pyx_t_3 = __pyx_v_format;
20262 __Pyx_INCREF(__pyx_t_3);
20263 __Pyx_GIVEREF(__pyx_t_3);
20264 __Pyx_GOTREF(__pyx_v_self->_format);
20265 __Pyx_DECREF(__pyx_v_self->_format);
20266 __pyx_v_self->_format = ((PyObject*)__pyx_t_3);
20276 if (unlikely(__pyx_v_self->_format == Py_None)) {
20277 PyErr_SetString(PyExc_TypeError,
"expected bytes, NoneType found");
20278 __PYX_ERR(0, 141, __pyx_L1_error)
20280 __pyx_t_7 = __Pyx_PyBytes_AsWritableString(__pyx_v_self->_format);
if (unlikely((!__pyx_t_7) && PyErr_Occurred())) __PYX_ERR(0, 141, __pyx_L1_error)
20281 __pyx_v_self->format = __pyx_t_7;
20290 __pyx_v_self->_shape = ((Py_ssize_t *)PyObject_Malloc((((
sizeof(Py_ssize_t)) * __pyx_v_self->ndim) * 2)));
20299 __pyx_v_self->_strides = (__pyx_v_self->_shape + __pyx_v_self->ndim);
20308 __pyx_t_4 = ((!(__pyx_v_self->_shape != 0)) != 0);
20309 if (unlikely(__pyx_t_4)) {
20318 __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_MemoryError, __pyx_tuple__10, NULL);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 148, __pyx_L1_error)
20319 __Pyx_GOTREF(__pyx_t_3);
20320 __Pyx_Raise(__pyx_t_3, 0, 0, 0);
20321 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
20322 __PYX_ERR(0, 148, __pyx_L1_error)
20341 __pyx_t_3 = __pyx_v_shape; __Pyx_INCREF(__pyx_t_3); __pyx_t_1 = 0;
20343 if (__pyx_t_1 >= PyTuple_GET_SIZE(__pyx_t_3))
break;
20344 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
20345 __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_1); __Pyx_INCREF(__pyx_t_5); __pyx_t_1++;
if (unlikely(0 < 0)) __PYX_ERR(0, 151, __pyx_L1_error)
20347 __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_1); __pyx_t_1++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 151, __pyx_L1_error)
20348 __Pyx_GOTREF(__pyx_t_5);
20350 __pyx_t_9 = __Pyx_PyIndex_AsSsize_t(__pyx_t_5);
if (unlikely((__pyx_t_9 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 151, __pyx_L1_error)
20351 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
20352 __pyx_v_dim = __pyx_t_9;
20353 __pyx_v_idx = __pyx_t_8;
20354 __pyx_t_8 = (__pyx_t_8 + 1);
20363 __pyx_t_4 = ((__pyx_v_dim <= 0) != 0);
20364 if (unlikely(__pyx_t_4)) {
20373 __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_idx);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 153, __pyx_L1_error)
20374 __Pyx_GOTREF(__pyx_t_5);
20375 __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_dim);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 153, __pyx_L1_error)
20376 __Pyx_GOTREF(__pyx_t_6);
20377 __pyx_t_10 = PyTuple_New(2);
if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 153, __pyx_L1_error)
20378 __Pyx_GOTREF(__pyx_t_10);
20379 __Pyx_GIVEREF(__pyx_t_5);
20380 PyTuple_SET_ITEM(__pyx_t_10, 0, __pyx_t_5);
20381 __Pyx_GIVEREF(__pyx_t_6);
20382 PyTuple_SET_ITEM(__pyx_t_10, 1, __pyx_t_6);
20385 __pyx_t_6 = __Pyx_PyString_Format(__pyx_kp_s_Invalid_shape_in_axis_d_d, __pyx_t_10);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 153, __pyx_L1_error)
20386 __Pyx_GOTREF(__pyx_t_6);
20387 __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
20388 __pyx_t_10 = __Pyx_PyObject_CallOneArg(__pyx_builtin_ValueError, __pyx_t_6);
if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 153, __pyx_L1_error)
20389 __Pyx_GOTREF(__pyx_t_10);
20390 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
20391 __Pyx_Raise(__pyx_t_10, 0, 0, 0);
20392 __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
20393 __PYX_ERR(0, 153, __pyx_L1_error)
20411 (__pyx_v_self->_shape[__pyx_v_idx]) = __pyx_v_dim;
20421 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
20430 __pyx_t_4 = (__Pyx_PyString_Equals(__pyx_v_mode, __pyx_n_s_fortran, Py_EQ));
if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 157, __pyx_L1_error)
20440 __pyx_v_order =
'F';
20449 __Pyx_INCREF(__pyx_n_u_fortran);
20450 __Pyx_GIVEREF(__pyx_n_u_fortran);
20451 __Pyx_GOTREF(__pyx_v_self->mode);
20452 __Pyx_DECREF(__pyx_v_self->mode);
20453 __pyx_v_self->mode = __pyx_n_u_fortran;
20472 __pyx_t_4 = (__Pyx_PyString_Equals(__pyx_v_mode, __pyx_n_s_c, Py_EQ));
if (unlikely(__pyx_t_4 < 0)) __PYX_ERR(0, 160, __pyx_L1_error)
20473 if (likely(__pyx_t_4)) {
20482 __pyx_v_order =
'C';
20491 __Pyx_INCREF(__pyx_n_u_c);
20492 __Pyx_GIVEREF(__pyx_n_u_c);
20493 __Pyx_GOTREF(__pyx_v_self->mode);
20494 __Pyx_DECREF(__pyx_v_self->mode);
20495 __pyx_v_self->mode = __pyx_n_u_c;
20515 __pyx_t_3 = __Pyx_PyString_FormatSafe(__pyx_kp_s_Invalid_mode_expected_c_or_fortr, __pyx_v_mode);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 164, __pyx_L1_error)
20516 __Pyx_GOTREF(__pyx_t_3);
20517 __pyx_t_10 = __Pyx_PyObject_CallOneArg(__pyx_builtin_ValueError, __pyx_t_3);
if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 164, __pyx_L1_error)
20518 __Pyx_GOTREF(__pyx_t_10);
20519 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
20520 __Pyx_Raise(__pyx_t_10, 0, 0, 0);
20521 __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
20522 __PYX_ERR(0, 164, __pyx_L1_error)
20533 __pyx_v_self->len = __pyx_fill_contig_strides_array(__pyx_v_self->_shape, __pyx_v_self->_strides, __pyx_v_itemsize, __pyx_v_self->ndim, __pyx_v_order);
20542 __pyx_v_self->free_data = __pyx_v_allocate_buffer;
20551 __pyx_t_10 = PyObject_RichCompare(__pyx_v_format, __pyx_n_b_O, Py_EQ); __Pyx_XGOTREF(__pyx_t_10);
if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 170, __pyx_L1_error)
20552 __pyx_t_4 = __Pyx_PyObject_IsTrue(__pyx_t_10);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 170, __pyx_L1_error)
20553 __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
20554 __pyx_v_self->dtype_is_object = __pyx_t_4;
20563 __pyx_t_4 = (__pyx_v_allocate_buffer != 0);
20573 __pyx_v_self->data = ((
char *)malloc(__pyx_v_self->len));
20582 __pyx_t_4 = ((!(__pyx_v_self->data != 0)) != 0);
20583 if (unlikely(__pyx_t_4)) {
20592 __pyx_t_10 = __Pyx_PyObject_Call(__pyx_builtin_MemoryError, __pyx_tuple__11, NULL);
if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 176, __pyx_L1_error)
20593 __Pyx_GOTREF(__pyx_t_10);
20594 __Pyx_Raise(__pyx_t_10, 0, 0, 0);
20595 __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
20596 __PYX_ERR(0, 176, __pyx_L1_error)
20614 __pyx_t_4 = (__pyx_v_self->dtype_is_object != 0);
20624 __pyx_v_p = ((PyObject **)__pyx_v_self->data);
20633 if (unlikely(__pyx_v_itemsize == 0)) {
20634 PyErr_SetString(PyExc_ZeroDivisionError,
"integer division or modulo by zero");
20635 __PYX_ERR(0, 180, __pyx_L1_error)
20637 else if (
sizeof(Py_ssize_t) ==
sizeof(
long) && (!(((Py_ssize_t)-1) > 0)) && unlikely(__pyx_v_itemsize == (Py_ssize_t)-1) && unlikely(UNARY_NEG_WOULD_OVERFLOW(__pyx_v_self->len))) {
20638 PyErr_SetString(PyExc_OverflowError,
"value too large to perform division");
20639 __PYX_ERR(0, 180, __pyx_L1_error)
20641 __pyx_t_1 = __Pyx_div_Py_ssize_t(__pyx_v_self->len, __pyx_v_itemsize);
20642 __pyx_t_9 = __pyx_t_1;
20643 for (__pyx_t_11 = 0; __pyx_t_11 < __pyx_t_9; __pyx_t_11+=1) {
20644 __pyx_v_i = __pyx_t_11;
20653 (__pyx_v_p[__pyx_v_i]) = Py_None;
20662 Py_INCREF(Py_None);
20695 __Pyx_XDECREF(__pyx_t_3);
20696 __Pyx_XDECREF(__pyx_t_5);
20697 __Pyx_XDECREF(__pyx_t_6);
20698 __Pyx_XDECREF(__pyx_t_10);
20699 __Pyx_AddTraceback(
"View.MemoryView.array.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
20702 __Pyx_XDECREF(__pyx_v_format);
20703 __Pyx_RefNannyFinishContext();
20716 static CYTHON_UNUSED
int __pyx_array_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags);
20717 static CYTHON_UNUSED
int __pyx_array_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags) {
20719 __Pyx_RefNannyDeclarations
20720 __Pyx_RefNannySetupContext(
"__getbuffer__ (wrapper)", 0);
20721 __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_2__getbuffer__(((
struct __pyx_array_obj *)__pyx_v_self), ((Py_buffer *)__pyx_v_info), ((
int)__pyx_v_flags));
20724 __Pyx_RefNannyFinishContext();
20728 static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array_2__getbuffer__(
struct __pyx_array_obj *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags) {
20729 int __pyx_v_bufmode;
20731 __Pyx_RefNannyDeclarations
20734 PyObject *__pyx_t_3 = NULL;
20736 Py_ssize_t __pyx_t_5;
20738 Py_ssize_t *__pyx_t_7;
20739 int __pyx_lineno = 0;
20740 const char *__pyx_filename = NULL;
20741 int __pyx_clineno = 0;
20742 if (__pyx_v_info == NULL) {
20743 PyErr_SetString(PyExc_BufferError,
"PyObject_GetBuffer: view==NULL argument is obsolete");
20746 __Pyx_RefNannySetupContext(
"__getbuffer__", 0);
20747 __pyx_v_info->obj = Py_None; __Pyx_INCREF(Py_None);
20748 __Pyx_GIVEREF(__pyx_v_info->obj);
20757 __pyx_v_bufmode = -1;
20766 __pyx_t_1 = (__Pyx_PyUnicode_Equals(__pyx_v_self->mode, __pyx_n_u_c, Py_EQ));
if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 187, __pyx_L1_error)
20767 __pyx_t_2 = (__pyx_t_1 != 0);
20777 __pyx_v_bufmode = (PyBUF_C_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS);
20796 __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_v_self->mode, __pyx_n_u_fortran, Py_EQ));
if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 189, __pyx_L1_error)
20797 __pyx_t_1 = (__pyx_t_2 != 0);
20807 __pyx_v_bufmode = (PyBUF_F_CONTIGUOUS | PyBUF_ANY_CONTIGUOUS);
20826 __pyx_t_1 = ((!((__pyx_v_flags & __pyx_v_bufmode) != 0)) != 0);
20827 if (unlikely(__pyx_t_1)) {
20836 __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__12, NULL);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 192, __pyx_L1_error)
20837 __Pyx_GOTREF(__pyx_t_3);
20838 __Pyx_Raise(__pyx_t_3, 0, 0, 0);
20839 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
20840 __PYX_ERR(0, 192, __pyx_L1_error)
20858 __pyx_t_4 = __pyx_v_self->data;
20859 __pyx_v_info->buf = __pyx_t_4;
20868 __pyx_t_5 = __pyx_v_self->len;
20869 __pyx_v_info->len = __pyx_t_5;
20878 __pyx_t_6 = __pyx_v_self->ndim;
20879 __pyx_v_info->ndim = __pyx_t_6;
20888 __pyx_t_7 = __pyx_v_self->_shape;
20889 __pyx_v_info->shape = __pyx_t_7;
20898 __pyx_t_7 = __pyx_v_self->_strides;
20899 __pyx_v_info->strides = __pyx_t_7;
20908 __pyx_v_info->suboffsets = NULL;
20917 __pyx_t_5 = __pyx_v_self->itemsize;
20918 __pyx_v_info->itemsize = __pyx_t_5;
20927 __pyx_v_info->readonly = 0;
20936 __pyx_t_1 = ((__pyx_v_flags & PyBUF_FORMAT) != 0);
20946 __pyx_t_4 = __pyx_v_self->format;
20947 __pyx_v_info->format = __pyx_t_4;
20967 __pyx_v_info->format = NULL;
20978 __Pyx_INCREF(((PyObject *)__pyx_v_self));
20979 __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
20980 __Pyx_GOTREF(__pyx_v_info->obj);
20981 __Pyx_DECREF(__pyx_v_info->obj);
20982 __pyx_v_info->obj = ((PyObject *)__pyx_v_self);
20996 __Pyx_XDECREF(__pyx_t_3);
20997 __Pyx_AddTraceback(
"View.MemoryView.array.__getbuffer__", __pyx_clineno, __pyx_lineno, __pyx_filename);
20999 if (__pyx_v_info->obj != NULL) {
21000 __Pyx_GOTREF(__pyx_v_info->obj);
21001 __Pyx_DECREF(__pyx_v_info->obj); __pyx_v_info->obj = 0;
21005 if (__pyx_v_info->obj == Py_None) {
21006 __Pyx_GOTREF(__pyx_v_info->obj);
21007 __Pyx_DECREF(__pyx_v_info->obj); __pyx_v_info->obj = 0;
21010 __Pyx_RefNannyFinishContext();
21023 static void __pyx_array___dealloc__(PyObject *__pyx_v_self);
21024 static void __pyx_array___dealloc__(PyObject *__pyx_v_self) {
21025 __Pyx_RefNannyDeclarations
21026 __Pyx_RefNannySetupContext(
"__dealloc__ (wrapper)", 0);
21027 __pyx_array___pyx_pf_15View_dot_MemoryView_5array_4__dealloc__(((
struct __pyx_array_obj *)__pyx_v_self));
21030 __Pyx_RefNannyFinishContext();
21033 static void __pyx_array___pyx_pf_15View_dot_MemoryView_5array_4__dealloc__(
struct __pyx_array_obj *__pyx_v_self) {
21034 __Pyx_RefNannyDeclarations
21036 __Pyx_RefNannySetupContext(
"__dealloc__", 0);
21045 __pyx_t_1 = ((__pyx_v_self->callback_free_data != NULL) != 0);
21055 __pyx_v_self->callback_free_data(__pyx_v_self->data);
21074 __pyx_t_1 = (__pyx_v_self->free_data != 0);
21084 __pyx_t_1 = (__pyx_v_self->dtype_is_object != 0);
21094 __pyx_memoryview_refcount_objects_in_slice(__pyx_v_self->data, __pyx_v_self->_shape, __pyx_v_self->_strides, __pyx_v_self->ndim, 0);
21112 free(__pyx_v_self->data);
21131 PyObject_Free(__pyx_v_self->_shape);
21142 __Pyx_RefNannyFinishContext();
21154 static PyObject *__pyx_pw_15View_dot_MemoryView_5array_7memview_1__get__(PyObject *__pyx_v_self);
21155 static PyObject *__pyx_pw_15View_dot_MemoryView_5array_7memview_1__get__(PyObject *__pyx_v_self) {
21156 PyObject *__pyx_r = 0;
21157 __Pyx_RefNannyDeclarations
21158 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
21159 __pyx_r = __pyx_pf_15View_dot_MemoryView_5array_7memview___get__(((
struct __pyx_array_obj *)__pyx_v_self));
21162 __Pyx_RefNannyFinishContext();
21166 static PyObject *__pyx_pf_15View_dot_MemoryView_5array_7memview___get__(
struct __pyx_array_obj *__pyx_v_self) {
21167 PyObject *__pyx_r = NULL;
21168 __Pyx_RefNannyDeclarations
21169 PyObject *__pyx_t_1 = NULL;
21170 int __pyx_lineno = 0;
21171 const char *__pyx_filename = NULL;
21172 int __pyx_clineno = 0;
21173 __Pyx_RefNannySetupContext(
"__get__", 0);
21182 __Pyx_XDECREF(__pyx_r);
21183 __pyx_t_1 = ((
struct __pyx_vtabstruct_array *)__pyx_v_self->__pyx_vtab)->get_memview(__pyx_v_self);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 223, __pyx_L1_error)
21184 __Pyx_GOTREF(__pyx_t_1);
21185 __pyx_r = __pyx_t_1;
21199 __Pyx_XDECREF(__pyx_t_1);
21200 __Pyx_AddTraceback(
"View.MemoryView.array.memview.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
21203 __Pyx_XGIVEREF(__pyx_r);
21204 __Pyx_RefNannyFinishContext();
21216 static PyObject *__pyx_array_get_memview(
struct __pyx_array_obj *__pyx_v_self) {
21218 PyObject *__pyx_r = NULL;
21219 __Pyx_RefNannyDeclarations
21220 PyObject *__pyx_t_1 = NULL;
21221 PyObject *__pyx_t_2 = NULL;
21222 PyObject *__pyx_t_3 = NULL;
21223 int __pyx_lineno = 0;
21224 const char *__pyx_filename = NULL;
21225 int __pyx_clineno = 0;
21226 __Pyx_RefNannySetupContext(
"get_memview", 0);
21235 __pyx_v_flags = ((PyBUF_ANY_CONTIGUOUS | PyBUF_FORMAT) | PyBUF_WRITABLE);
21244 __Pyx_XDECREF(__pyx_r);
21245 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_flags);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 228, __pyx_L1_error)
21246 __Pyx_GOTREF(__pyx_t_1);
21247 __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_v_self->dtype_is_object);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 228, __pyx_L1_error)
21248 __Pyx_GOTREF(__pyx_t_2);
21249 __pyx_t_3 = PyTuple_New(3);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 228, __pyx_L1_error)
21250 __Pyx_GOTREF(__pyx_t_3);
21251 __Pyx_INCREF(((PyObject *)__pyx_v_self));
21252 __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
21253 PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_v_self));
21254 __Pyx_GIVEREF(__pyx_t_1);
21255 PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1);
21256 __Pyx_GIVEREF(__pyx_t_2);
21257 PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2);
21260 __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_memoryview_type), __pyx_t_3, NULL);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 228, __pyx_L1_error)
21261 __Pyx_GOTREF(__pyx_t_2);
21262 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
21263 __pyx_r = __pyx_t_2;
21277 __Pyx_XDECREF(__pyx_t_1);
21278 __Pyx_XDECREF(__pyx_t_2);
21279 __Pyx_XDECREF(__pyx_t_3);
21280 __Pyx_AddTraceback(
"View.MemoryView.array.get_memview", __pyx_clineno, __pyx_lineno, __pyx_filename);
21283 __Pyx_XGIVEREF(__pyx_r);
21284 __Pyx_RefNannyFinishContext();
21297 static Py_ssize_t __pyx_array___len__(PyObject *__pyx_v_self);
21298 static Py_ssize_t __pyx_array___len__(PyObject *__pyx_v_self) {
21299 Py_ssize_t __pyx_r;
21300 __Pyx_RefNannyDeclarations
21301 __Pyx_RefNannySetupContext(
"__len__ (wrapper)", 0);
21302 __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_6__len__(((
struct __pyx_array_obj *)__pyx_v_self));
21305 __Pyx_RefNannyFinishContext();
21309 static Py_ssize_t __pyx_array___pyx_pf_15View_dot_MemoryView_5array_6__len__(
struct __pyx_array_obj *__pyx_v_self) {
21310 Py_ssize_t __pyx_r;
21311 __Pyx_RefNannyDeclarations
21312 __Pyx_RefNannySetupContext(
"__len__", 0);
21321 __pyx_r = (__pyx_v_self->_shape[0]);
21334 __Pyx_RefNannyFinishContext();
21347 static PyObject *__pyx_array___getattr__(PyObject *__pyx_v_self, PyObject *__pyx_v_attr);
21348 static PyObject *__pyx_array___getattr__(PyObject *__pyx_v_self, PyObject *__pyx_v_attr) {
21349 PyObject *__pyx_r = 0;
21350 __Pyx_RefNannyDeclarations
21351 __Pyx_RefNannySetupContext(
"__getattr__ (wrapper)", 0);
21352 __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_8__getattr__(((
struct __pyx_array_obj *)__pyx_v_self), ((PyObject *)__pyx_v_attr));
21355 __Pyx_RefNannyFinishContext();
21359 static PyObject *__pyx_array___pyx_pf_15View_dot_MemoryView_5array_8__getattr__(
struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_attr) {
21360 PyObject *__pyx_r = NULL;
21361 __Pyx_RefNannyDeclarations
21362 PyObject *__pyx_t_1 = NULL;
21363 PyObject *__pyx_t_2 = NULL;
21364 int __pyx_lineno = 0;
21365 const char *__pyx_filename = NULL;
21366 int __pyx_clineno = 0;
21367 __Pyx_RefNannySetupContext(
"__getattr__", 0);
21376 __Pyx_XDECREF(__pyx_r);
21377 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_memview);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 234, __pyx_L1_error)
21378 __Pyx_GOTREF(__pyx_t_1);
21379 __pyx_t_2 = __Pyx_GetAttr(__pyx_t_1, __pyx_v_attr);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 234, __pyx_L1_error)
21380 __Pyx_GOTREF(__pyx_t_2);
21381 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
21382 __pyx_r = __pyx_t_2;
21396 __Pyx_XDECREF(__pyx_t_1);
21397 __Pyx_XDECREF(__pyx_t_2);
21398 __Pyx_AddTraceback(
"View.MemoryView.array.__getattr__", __pyx_clineno, __pyx_lineno, __pyx_filename);
21401 __Pyx_XGIVEREF(__pyx_r);
21402 __Pyx_RefNannyFinishContext();
21415 static PyObject *__pyx_array___getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_item);
21416 static PyObject *__pyx_array___getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_item) {
21417 PyObject *__pyx_r = 0;
21418 __Pyx_RefNannyDeclarations
21419 __Pyx_RefNannySetupContext(
"__getitem__ (wrapper)", 0);
21420 __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_10__getitem__(((
struct __pyx_array_obj *)__pyx_v_self), ((PyObject *)__pyx_v_item));
21423 __Pyx_RefNannyFinishContext();
21427 static PyObject *__pyx_array___pyx_pf_15View_dot_MemoryView_5array_10__getitem__(
struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_item) {
21428 PyObject *__pyx_r = NULL;
21429 __Pyx_RefNannyDeclarations
21430 PyObject *__pyx_t_1 = NULL;
21431 PyObject *__pyx_t_2 = NULL;
21432 int __pyx_lineno = 0;
21433 const char *__pyx_filename = NULL;
21434 int __pyx_clineno = 0;
21435 __Pyx_RefNannySetupContext(
"__getitem__", 0);
21444 __Pyx_XDECREF(__pyx_r);
21445 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_memview);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 237, __pyx_L1_error)
21446 __Pyx_GOTREF(__pyx_t_1);
21447 __pyx_t_2 = __Pyx_PyObject_GetItem(__pyx_t_1, __pyx_v_item);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 237, __pyx_L1_error)
21448 __Pyx_GOTREF(__pyx_t_2);
21449 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
21450 __pyx_r = __pyx_t_2;
21464 __Pyx_XDECREF(__pyx_t_1);
21465 __Pyx_XDECREF(__pyx_t_2);
21466 __Pyx_AddTraceback(
"View.MemoryView.array.__getitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
21469 __Pyx_XGIVEREF(__pyx_r);
21470 __Pyx_RefNannyFinishContext();
21483 static int __pyx_array___setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_item, PyObject *__pyx_v_value);
21484 static int __pyx_array___setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_item, PyObject *__pyx_v_value) {
21486 __Pyx_RefNannyDeclarations
21487 __Pyx_RefNannySetupContext(
"__setitem__ (wrapper)", 0);
21488 __pyx_r = __pyx_array___pyx_pf_15View_dot_MemoryView_5array_12__setitem__(((
struct __pyx_array_obj *)__pyx_v_self), ((PyObject *)__pyx_v_item), ((PyObject *)__pyx_v_value));
21491 __Pyx_RefNannyFinishContext();
21495 static int __pyx_array___pyx_pf_15View_dot_MemoryView_5array_12__setitem__(
struct __pyx_array_obj *__pyx_v_self, PyObject *__pyx_v_item, PyObject *__pyx_v_value) {
21497 __Pyx_RefNannyDeclarations
21498 PyObject *__pyx_t_1 = NULL;
21499 int __pyx_lineno = 0;
21500 const char *__pyx_filename = NULL;
21501 int __pyx_clineno = 0;
21502 __Pyx_RefNannySetupContext(
"__setitem__", 0);
21511 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_memview);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 240, __pyx_L1_error)
21512 __Pyx_GOTREF(__pyx_t_1);
21513 if (unlikely(PyObject_SetItem(__pyx_t_1, __pyx_v_item, __pyx_v_value) < 0)) __PYX_ERR(0, 240, __pyx_L1_error)
21514 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
21528 __Pyx_XDECREF(__pyx_t_1);
21529 __Pyx_AddTraceback(
"View.MemoryView.array.__setitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
21532 __Pyx_RefNannyFinishContext();
21543 static PyObject *__pyx_pw___pyx_array_1__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
21544 static PyObject *__pyx_pw___pyx_array_1__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
21545 PyObject *__pyx_r = 0;
21546 __Pyx_RefNannyDeclarations
21547 __Pyx_RefNannySetupContext(
"__reduce_cython__ (wrapper)", 0);
21548 __pyx_r = __pyx_pf___pyx_array___reduce_cython__(((
struct __pyx_array_obj *)__pyx_v_self));
21551 __Pyx_RefNannyFinishContext();
21555 static PyObject *__pyx_pf___pyx_array___reduce_cython__(CYTHON_UNUSED
struct __pyx_array_obj *__pyx_v_self) {
21556 PyObject *__pyx_r = NULL;
21557 __Pyx_RefNannyDeclarations
21558 PyObject *__pyx_t_1 = NULL;
21559 int __pyx_lineno = 0;
21560 const char *__pyx_filename = NULL;
21561 int __pyx_clineno = 0;
21562 __Pyx_RefNannySetupContext(
"__reduce_cython__", 0);
21570 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__13, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 2, __pyx_L1_error)
21571 __Pyx_GOTREF(__pyx_t_1);
21572 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
21573 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
21574 __PYX_ERR(0, 2, __pyx_L1_error)
21584 __Pyx_XDECREF(__pyx_t_1);
21585 __Pyx_AddTraceback(
"View.MemoryView.array.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
21587 __Pyx_XGIVEREF(__pyx_r);
21588 __Pyx_RefNannyFinishContext();
21600 static PyObject *__pyx_pw___pyx_array_3__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state);
21601 static PyObject *__pyx_pw___pyx_array_3__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
21602 PyObject *__pyx_r = 0;
21603 __Pyx_RefNannyDeclarations
21604 __Pyx_RefNannySetupContext(
"__setstate_cython__ (wrapper)", 0);
21605 __pyx_r = __pyx_pf___pyx_array_2__setstate_cython__(((
struct __pyx_array_obj *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
21608 __Pyx_RefNannyFinishContext();
21612 static PyObject *__pyx_pf___pyx_array_2__setstate_cython__(CYTHON_UNUSED
struct __pyx_array_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
21613 PyObject *__pyx_r = NULL;
21614 __Pyx_RefNannyDeclarations
21615 PyObject *__pyx_t_1 = NULL;
21616 int __pyx_lineno = 0;
21617 const char *__pyx_filename = NULL;
21618 int __pyx_clineno = 0;
21619 __Pyx_RefNannySetupContext(
"__setstate_cython__", 0);
21626 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__14, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 4, __pyx_L1_error)
21627 __Pyx_GOTREF(__pyx_t_1);
21628 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
21629 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
21630 __PYX_ERR(0, 4, __pyx_L1_error)
21641 __Pyx_XDECREF(__pyx_t_1);
21642 __Pyx_AddTraceback(
"View.MemoryView.array.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
21644 __Pyx_XGIVEREF(__pyx_r);
21645 __Pyx_RefNannyFinishContext();
21657 static struct __pyx_array_obj *__pyx_array_new(PyObject *__pyx_v_shape, Py_ssize_t __pyx_v_itemsize,
char *__pyx_v_format,
char *__pyx_v_mode,
char *__pyx_v_buf) {
21658 struct __pyx_array_obj *__pyx_v_result = 0;
21659 struct __pyx_array_obj *__pyx_r = NULL;
21660 __Pyx_RefNannyDeclarations
21662 PyObject *__pyx_t_2 = NULL;
21663 PyObject *__pyx_t_3 = NULL;
21664 PyObject *__pyx_t_4 = NULL;
21665 PyObject *__pyx_t_5 = NULL;
21666 int __pyx_lineno = 0;
21667 const char *__pyx_filename = NULL;
21668 int __pyx_clineno = 0;
21669 __Pyx_RefNannySetupContext(
"array_cwrapper", 0);
21678 __pyx_t_1 = ((__pyx_v_buf == NULL) != 0);
21688 __pyx_t_2 = PyInt_FromSsize_t(__pyx_v_itemsize);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 249, __pyx_L1_error)
21689 __Pyx_GOTREF(__pyx_t_2);
21690 __pyx_t_3 = __Pyx_PyBytes_FromString(__pyx_v_format);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 249, __pyx_L1_error)
21691 __Pyx_GOTREF(__pyx_t_3);
21692 __pyx_t_4 = __Pyx_decode_c_string(__pyx_v_mode, 0, strlen(__pyx_v_mode), NULL, NULL, PyUnicode_DecodeASCII);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 249, __pyx_L1_error)
21693 __Pyx_GOTREF(__pyx_t_4);
21694 __pyx_t_5 = PyTuple_New(4);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 249, __pyx_L1_error)
21695 __Pyx_GOTREF(__pyx_t_5);
21696 __Pyx_INCREF(__pyx_v_shape);
21697 __Pyx_GIVEREF(__pyx_v_shape);
21698 PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_v_shape);
21699 __Pyx_GIVEREF(__pyx_t_2);
21700 PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_t_2);
21701 __Pyx_GIVEREF(__pyx_t_3);
21702 PyTuple_SET_ITEM(__pyx_t_5, 2, __pyx_t_3);
21703 __Pyx_GIVEREF(__pyx_t_4);
21704 PyTuple_SET_ITEM(__pyx_t_5, 3, __pyx_t_4);
21708 __pyx_t_4 = __Pyx_PyObject_Call(((PyObject *)__pyx_array_type), __pyx_t_5, NULL);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 249, __pyx_L1_error)
21709 __Pyx_GOTREF(__pyx_t_4);
21710 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
21711 __pyx_v_result = ((
struct __pyx_array_obj *)__pyx_t_4);
21732 __pyx_t_4 = PyInt_FromSsize_t(__pyx_v_itemsize);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 251, __pyx_L1_error)
21733 __Pyx_GOTREF(__pyx_t_4);
21734 __pyx_t_5 = __Pyx_PyBytes_FromString(__pyx_v_format);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 251, __pyx_L1_error)
21735 __Pyx_GOTREF(__pyx_t_5);
21736 __pyx_t_3 = __Pyx_decode_c_string(__pyx_v_mode, 0, strlen(__pyx_v_mode), NULL, NULL, PyUnicode_DecodeASCII);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 251, __pyx_L1_error)
21737 __Pyx_GOTREF(__pyx_t_3);
21738 __pyx_t_2 = PyTuple_New(4);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 251, __pyx_L1_error)
21739 __Pyx_GOTREF(__pyx_t_2);
21740 __Pyx_INCREF(__pyx_v_shape);
21741 __Pyx_GIVEREF(__pyx_v_shape);
21742 PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_shape);
21743 __Pyx_GIVEREF(__pyx_t_4);
21744 PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4);
21745 __Pyx_GIVEREF(__pyx_t_5);
21746 PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_t_5);
21747 __Pyx_GIVEREF(__pyx_t_3);
21748 PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_t_3);
21760 __pyx_t_3 = __Pyx_PyDict_NewPresized(1);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 252, __pyx_L1_error)
21761 __Pyx_GOTREF(__pyx_t_3);
21762 if (PyDict_SetItem(__pyx_t_3, __pyx_n_s_allocate_buffer, Py_False) < 0) __PYX_ERR(0, 252, __pyx_L1_error)
21771 __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)__pyx_array_type), __pyx_t_2, __pyx_t_3);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 251, __pyx_L1_error)
21772 __Pyx_GOTREF(__pyx_t_5);
21773 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
21774 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
21775 __pyx_v_result = ((
struct __pyx_array_obj *)__pyx_t_5);
21785 __pyx_v_result->data = __pyx_v_buf;
21796 __Pyx_XDECREF(((PyObject *)__pyx_r));
21797 __Pyx_INCREF(((PyObject *)__pyx_v_result));
21798 __pyx_r = __pyx_v_result;
21811 __Pyx_XDECREF(__pyx_t_2);
21812 __Pyx_XDECREF(__pyx_t_3);
21813 __Pyx_XDECREF(__pyx_t_4);
21814 __Pyx_XDECREF(__pyx_t_5);
21815 __Pyx_AddTraceback(
"View.MemoryView.array_cwrapper", __pyx_clineno, __pyx_lineno, __pyx_filename);
21818 __Pyx_XDECREF((PyObject *)__pyx_v_result);
21819 __Pyx_XGIVEREF((PyObject *)__pyx_r);
21820 __Pyx_RefNannyFinishContext();
21833 static int __pyx_MemviewEnum___init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
21834 static int __pyx_MemviewEnum___init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
21835 PyObject *__pyx_v_name = 0;
21836 int __pyx_lineno = 0;
21837 const char *__pyx_filename = NULL;
21838 int __pyx_clineno = 0;
21840 __Pyx_RefNannyDeclarations
21841 __Pyx_RefNannySetupContext(
"__init__ (wrapper)", 0);
21843 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_name,0};
21844 PyObject* values[1] = {0};
21845 if (unlikely(__pyx_kwds)) {
21846 Py_ssize_t kw_args;
21847 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
21848 switch (pos_args) {
21849 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
21850 CYTHON_FALLTHROUGH;
21852 default:
goto __pyx_L5_argtuple_error;
21854 kw_args = PyDict_Size(__pyx_kwds);
21855 switch (pos_args) {
21857 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--;
21858 else goto __pyx_L5_argtuple_error;
21860 if (unlikely(kw_args > 0)) {
21861 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"__init__") < 0)) __PYX_ERR(0, 281, __pyx_L3_error)
21863 }
else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
21864 goto __pyx_L5_argtuple_error;
21866 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
21868 __pyx_v_name = values[0];
21870 goto __pyx_L4_argument_unpacking_done;
21871 __pyx_L5_argtuple_error:;
21872 __Pyx_RaiseArgtupleInvalid(
"__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 281, __pyx_L3_error)
21874 __Pyx_AddTraceback(
"View.MemoryView.Enum.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
21875 __Pyx_RefNannyFinishContext();
21877 __pyx_L4_argument_unpacking_done:;
21878 __pyx_r = __pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum___init__(((
struct __pyx_MemviewEnum_obj *)__pyx_v_self), __pyx_v_name);
21881 __Pyx_RefNannyFinishContext();
21885 static int __pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum___init__(
struct __pyx_MemviewEnum_obj *__pyx_v_self, PyObject *__pyx_v_name) {
21887 __Pyx_RefNannyDeclarations
21888 __Pyx_RefNannySetupContext(
"__init__", 0);
21897 __Pyx_INCREF(__pyx_v_name);
21898 __Pyx_GIVEREF(__pyx_v_name);
21899 __Pyx_GOTREF(__pyx_v_self->name);
21900 __Pyx_DECREF(__pyx_v_self->name);
21901 __pyx_v_self->name = __pyx_v_name;
21913 __Pyx_RefNannyFinishContext();
21926 static PyObject *__pyx_MemviewEnum___repr__(PyObject *__pyx_v_self);
21927 static PyObject *__pyx_MemviewEnum___repr__(PyObject *__pyx_v_self) {
21928 PyObject *__pyx_r = 0;
21929 __Pyx_RefNannyDeclarations
21930 __Pyx_RefNannySetupContext(
"__repr__ (wrapper)", 0);
21931 __pyx_r = __pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum_2__repr__(((
struct __pyx_MemviewEnum_obj *)__pyx_v_self));
21934 __Pyx_RefNannyFinishContext();
21938 static PyObject *__pyx_MemviewEnum___pyx_pf_15View_dot_MemoryView_4Enum_2__repr__(
struct __pyx_MemviewEnum_obj *__pyx_v_self) {
21939 PyObject *__pyx_r = NULL;
21940 __Pyx_RefNannyDeclarations
21941 __Pyx_RefNannySetupContext(
"__repr__", 0);
21950 __Pyx_XDECREF(__pyx_r);
21951 __Pyx_INCREF(__pyx_v_self->name);
21952 __pyx_r = __pyx_v_self->name;
21965 __Pyx_XGIVEREF(__pyx_r);
21966 __Pyx_RefNannyFinishContext();
21977 static PyObject *__pyx_pw___pyx_MemviewEnum_1__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
21978 static PyObject *__pyx_pw___pyx_MemviewEnum_1__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
21979 PyObject *__pyx_r = 0;
21980 __Pyx_RefNannyDeclarations
21981 __Pyx_RefNannySetupContext(
"__reduce_cython__ (wrapper)", 0);
21982 __pyx_r = __pyx_pf___pyx_MemviewEnum___reduce_cython__(((
struct __pyx_MemviewEnum_obj *)__pyx_v_self));
21985 __Pyx_RefNannyFinishContext();
21989 static PyObject *__pyx_pf___pyx_MemviewEnum___reduce_cython__(
struct __pyx_MemviewEnum_obj *__pyx_v_self) {
21990 PyObject *__pyx_v_state = 0;
21991 PyObject *__pyx_v__dict = 0;
21992 int __pyx_v_use_setstate;
21993 PyObject *__pyx_r = NULL;
21994 __Pyx_RefNannyDeclarations
21995 PyObject *__pyx_t_1 = NULL;
21998 PyObject *__pyx_t_4 = NULL;
21999 PyObject *__pyx_t_5 = NULL;
22000 int __pyx_lineno = 0;
22001 const char *__pyx_filename = NULL;
22002 int __pyx_clineno = 0;
22003 __Pyx_RefNannySetupContext(
"__reduce_cython__", 0);
22012 __pyx_t_1 = PyTuple_New(1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 5, __pyx_L1_error)
22013 __Pyx_GOTREF(__pyx_t_1);
22014 __Pyx_INCREF(__pyx_v_self->name);
22015 __Pyx_GIVEREF(__pyx_v_self->name);
22016 PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->name);
22017 __pyx_v_state = ((PyObject*)__pyx_t_1);
22027 __pyx_t_1 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 6, __pyx_L1_error)
22028 __Pyx_GOTREF(__pyx_t_1);
22029 __pyx_v__dict = __pyx_t_1;
22039 __pyx_t_2 = (__pyx_v__dict != Py_None);
22040 __pyx_t_3 = (__pyx_t_2 != 0);
22050 __pyx_t_1 = PyTuple_New(1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 8, __pyx_L1_error)
22051 __Pyx_GOTREF(__pyx_t_1);
22052 __Pyx_INCREF(__pyx_v__dict);
22053 __Pyx_GIVEREF(__pyx_v__dict);
22054 PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v__dict);
22055 __pyx_t_4 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_1);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 8, __pyx_L1_error)
22056 __Pyx_GOTREF(__pyx_t_4);
22057 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
22058 __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_4));
22068 __pyx_v_use_setstate = 1;
22088 __pyx_t_3 = (__pyx_v_self->name != Py_None);
22089 __pyx_v_use_setstate = __pyx_t_3;
22100 __pyx_t_3 = (__pyx_v_use_setstate != 0);
22110 __Pyx_XDECREF(__pyx_r);
22111 __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_pyx_unpickle_Enum);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 13, __pyx_L1_error)
22112 __Pyx_GOTREF(__pyx_t_4);
22113 __pyx_t_1 = PyTuple_New(3);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 13, __pyx_L1_error)
22114 __Pyx_GOTREF(__pyx_t_1);
22115 __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
22116 __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
22117 PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
22118 __Pyx_INCREF(__pyx_int_184977713);
22119 __Pyx_GIVEREF(__pyx_int_184977713);
22120 PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_184977713);
22121 __Pyx_INCREF(Py_None);
22122 __Pyx_GIVEREF(Py_None);
22123 PyTuple_SET_ITEM(__pyx_t_1, 2, Py_None);
22124 __pyx_t_5 = PyTuple_New(3);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 13, __pyx_L1_error)
22125 __Pyx_GOTREF(__pyx_t_5);
22126 __Pyx_GIVEREF(__pyx_t_4);
22127 PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4);
22128 __Pyx_GIVEREF(__pyx_t_1);
22129 PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_t_1);
22130 __Pyx_INCREF(__pyx_v_state);
22131 __Pyx_GIVEREF(__pyx_v_state);
22132 PyTuple_SET_ITEM(__pyx_t_5, 2, __pyx_v_state);
22135 __pyx_r = __pyx_t_5;
22156 __Pyx_XDECREF(__pyx_r);
22157 __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_pyx_unpickle_Enum);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 15, __pyx_L1_error)
22158 __Pyx_GOTREF(__pyx_t_5);
22159 __pyx_t_1 = PyTuple_New(3);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 15, __pyx_L1_error)
22160 __Pyx_GOTREF(__pyx_t_1);
22161 __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
22162 __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
22163 PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
22164 __Pyx_INCREF(__pyx_int_184977713);
22165 __Pyx_GIVEREF(__pyx_int_184977713);
22166 PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_int_184977713);
22167 __Pyx_INCREF(__pyx_v_state);
22168 __Pyx_GIVEREF(__pyx_v_state);
22169 PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_state);
22170 __pyx_t_4 = PyTuple_New(2);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 15, __pyx_L1_error)
22171 __Pyx_GOTREF(__pyx_t_4);
22172 __Pyx_GIVEREF(__pyx_t_5);
22173 PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_5);
22174 __Pyx_GIVEREF(__pyx_t_1);
22175 PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1);
22178 __pyx_r = __pyx_t_4;
22191 __Pyx_XDECREF(__pyx_t_1);
22192 __Pyx_XDECREF(__pyx_t_4);
22193 __Pyx_XDECREF(__pyx_t_5);
22194 __Pyx_AddTraceback(
"View.MemoryView.Enum.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
22197 __Pyx_XDECREF(__pyx_v_state);
22198 __Pyx_XDECREF(__pyx_v__dict);
22199 __Pyx_XGIVEREF(__pyx_r);
22200 __Pyx_RefNannyFinishContext();
22212 static PyObject *__pyx_pw___pyx_MemviewEnum_3__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state);
22213 static PyObject *__pyx_pw___pyx_MemviewEnum_3__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
22214 PyObject *__pyx_r = 0;
22215 __Pyx_RefNannyDeclarations
22216 __Pyx_RefNannySetupContext(
"__setstate_cython__ (wrapper)", 0);
22217 __pyx_r = __pyx_pf___pyx_MemviewEnum_2__setstate_cython__(((
struct __pyx_MemviewEnum_obj *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
22220 __Pyx_RefNannyFinishContext();
22224 static PyObject *__pyx_pf___pyx_MemviewEnum_2__setstate_cython__(
struct __pyx_MemviewEnum_obj *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
22225 PyObject *__pyx_r = NULL;
22226 __Pyx_RefNannyDeclarations
22227 PyObject *__pyx_t_1 = NULL;
22228 int __pyx_lineno = 0;
22229 const char *__pyx_filename = NULL;
22230 int __pyx_clineno = 0;
22231 __Pyx_RefNannySetupContext(
"__setstate_cython__", 0);
22238 if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(0, 17, __pyx_L1_error)
22239 __pyx_t_1 = __pyx_unpickle_Enum__set_state(__pyx_v_self, ((PyObject*)__pyx_v___pyx_state));
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 17, __pyx_L1_error)
22240 __Pyx_GOTREF(__pyx_t_1);
22241 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
22251 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
22254 __Pyx_XDECREF(__pyx_t_1);
22255 __Pyx_AddTraceback(
"View.MemoryView.Enum.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
22258 __Pyx_XGIVEREF(__pyx_r);
22259 __Pyx_RefNannyFinishContext();
22271 static void *__pyx_align_pointer(
void *__pyx_v_memory,
size_t __pyx_v_alignment) {
22272 Py_intptr_t __pyx_v_aligned_p;
22273 size_t __pyx_v_offset;
22284 __pyx_v_aligned_p = ((Py_intptr_t)__pyx_v_memory);
22293 __pyx_v_offset = (__pyx_v_aligned_p % __pyx_v_alignment);
22302 __pyx_t_1 = ((__pyx_v_offset > 0) != 0);
22312 __pyx_v_aligned_p = (__pyx_v_aligned_p + (__pyx_v_alignment - __pyx_v_offset));
22330 __pyx_r = ((
void *)__pyx_v_aligned_p);
22355 static int __pyx_memoryview___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
22356 static int __pyx_memoryview___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
22357 PyObject *__pyx_v_obj = 0;
22359 int __pyx_v_dtype_is_object;
22360 int __pyx_lineno = 0;
22361 const char *__pyx_filename = NULL;
22362 int __pyx_clineno = 0;
22364 __Pyx_RefNannyDeclarations
22365 __Pyx_RefNannySetupContext(
"__cinit__ (wrapper)", 0);
22367 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_obj,&__pyx_n_s_flags,&__pyx_n_s_dtype_is_object,0};
22368 PyObject* values[3] = {0,0,0};
22369 if (unlikely(__pyx_kwds)) {
22370 Py_ssize_t kw_args;
22371 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
22372 switch (pos_args) {
22373 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
22374 CYTHON_FALLTHROUGH;
22375 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
22376 CYTHON_FALLTHROUGH;
22377 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
22378 CYTHON_FALLTHROUGH;
22380 default:
goto __pyx_L5_argtuple_error;
22382 kw_args = PyDict_Size(__pyx_kwds);
22383 switch (pos_args) {
22385 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_obj)) != 0)) kw_args--;
22386 else goto __pyx_L5_argtuple_error;
22387 CYTHON_FALLTHROUGH;
22389 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_flags)) != 0)) kw_args--;
22391 __Pyx_RaiseArgtupleInvalid(
"__cinit__", 0, 2, 3, 1); __PYX_ERR(0, 345, __pyx_L3_error)
22393 CYTHON_FALLTHROUGH;
22396 PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_dtype_is_object);
22397 if (value) { values[2] = value; kw_args--; }
22400 if (unlikely(kw_args > 0)) {
22401 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"__cinit__") < 0)) __PYX_ERR(0, 345, __pyx_L3_error)
22404 switch (PyTuple_GET_SIZE(__pyx_args)) {
22405 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
22406 CYTHON_FALLTHROUGH;
22407 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
22408 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
22410 default:
goto __pyx_L5_argtuple_error;
22413 __pyx_v_obj = values[0];
22414 __pyx_v_flags = __Pyx_PyInt_As_int(values[1]);
if (unlikely((__pyx_v_flags == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 345, __pyx_L3_error)
22416 __pyx_v_dtype_is_object = __Pyx_PyObject_IsTrue(values[2]);
if (unlikely((__pyx_v_dtype_is_object == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 345, __pyx_L3_error)
22418 __pyx_v_dtype_is_object = ((int)0);
22421 goto __pyx_L4_argument_unpacking_done;
22422 __pyx_L5_argtuple_error:;
22423 __Pyx_RaiseArgtupleInvalid(
"__cinit__", 0, 2, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 345, __pyx_L3_error)
22425 __Pyx_AddTraceback(
"View.MemoryView.memoryview.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
22426 __Pyx_RefNannyFinishContext();
22428 __pyx_L4_argument_unpacking_done:;
22429 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview___cinit__(((
struct __pyx_memoryview_obj *)__pyx_v_self), __pyx_v_obj, __pyx_v_flags, __pyx_v_dtype_is_object);
22432 __Pyx_RefNannyFinishContext();
22436 static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview___cinit__(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_obj,
int __pyx_v_flags,
int __pyx_v_dtype_is_object) {
22438 __Pyx_RefNannyDeclarations
22443 int __pyx_lineno = 0;
22444 const char *__pyx_filename = NULL;
22445 int __pyx_clineno = 0;
22446 __Pyx_RefNannySetupContext(
"__cinit__", 0);
22455 __Pyx_INCREF(__pyx_v_obj);
22456 __Pyx_GIVEREF(__pyx_v_obj);
22457 __Pyx_GOTREF(__pyx_v_self->obj);
22458 __Pyx_DECREF(__pyx_v_self->obj);
22459 __pyx_v_self->obj = __pyx_v_obj;
22468 __pyx_v_self->flags = __pyx_v_flags;
22477 __pyx_t_2 = (((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))) == ((PyObject *)__pyx_memoryview_type));
22478 __pyx_t_3 = (__pyx_t_2 != 0);
22481 __pyx_t_1 = __pyx_t_3;
22482 goto __pyx_L4_bool_binop_done;
22484 __pyx_t_3 = (__pyx_v_obj != Py_None);
22485 __pyx_t_2 = (__pyx_t_3 != 0);
22486 __pyx_t_1 = __pyx_t_2;
22487 __pyx_L4_bool_binop_done:;
22497 __pyx_t_4 = __Pyx_GetBuffer(__pyx_v_obj, (&__pyx_v_self->view), __pyx_v_flags);
if (unlikely(__pyx_t_4 == ((
int)-1))) __PYX_ERR(0, 349, __pyx_L1_error)
22506 __pyx_t_1 = ((((PyObject *)__pyx_v_self->view.obj) == NULL) != 0);
22516 ((Py_buffer *)(&__pyx_v_self->view))->obj = Py_None;
22525 Py_INCREF(Py_None);
22552 __pyx_t_1 = ((__pyx_memoryview_thread_locks_used < 8) != 0);
22562 __pyx_v_self->lock = (__pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]);
22571 __pyx_memoryview_thread_locks_used = (__pyx_memoryview_thread_locks_used + 1);
22589 __pyx_t_1 = ((__pyx_v_self->lock == NULL) != 0);
22599 __pyx_v_self->lock = PyThread_allocate_lock();
22608 __pyx_t_1 = ((__pyx_v_self->lock == NULL) != 0);
22609 if (unlikely(__pyx_t_1)) {
22618 PyErr_NoMemory(); __PYX_ERR(0, 361, __pyx_L1_error)
22645 __pyx_t_1 = ((__pyx_v_flags & PyBUF_FORMAT) != 0);
22655 __pyx_t_2 = (((__pyx_v_self->view.format[0]) ==
'O') != 0);
22658 __pyx_t_1 = __pyx_t_2;
22659 goto __pyx_L11_bool_binop_done;
22661 __pyx_t_2 = (((__pyx_v_self->view.format[1]) ==
'\x00') != 0);
22662 __pyx_t_1 = __pyx_t_2;
22663 __pyx_L11_bool_binop_done:;
22664 __pyx_v_self->dtype_is_object = __pyx_t_1;
22684 __pyx_v_self->dtype_is_object = __pyx_v_dtype_is_object;
22695 __pyx_v_self->acquisition_count_aligned_p = ((__pyx_atomic_int *)__pyx_align_pointer(((
void *)(&(__pyx_v_self->acquisition_count[0]))), (
sizeof(__pyx_atomic_int))));
22704 __pyx_v_self->typeinfo = NULL;
22718 __Pyx_AddTraceback(
"View.MemoryView.memoryview.__cinit__", __pyx_clineno, __pyx_lineno, __pyx_filename);
22721 __Pyx_RefNannyFinishContext();
22734 static void __pyx_memoryview___dealloc__(PyObject *__pyx_v_self);
22735 static void __pyx_memoryview___dealloc__(PyObject *__pyx_v_self) {
22736 __Pyx_RefNannyDeclarations
22737 __Pyx_RefNannySetupContext(
"__dealloc__ (wrapper)", 0);
22738 __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_2__dealloc__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
22741 __Pyx_RefNannyFinishContext();
22744 static void __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_2__dealloc__(
struct __pyx_memoryview_obj *__pyx_v_self) {
22746 __Pyx_RefNannyDeclarations
22752 PyThread_type_lock __pyx_t_6;
22753 PyThread_type_lock __pyx_t_7;
22754 __Pyx_RefNannySetupContext(
"__dealloc__", 0);
22763 __pyx_t_1 = (__pyx_v_self->obj != Py_None);
22764 __pyx_t_2 = (__pyx_t_1 != 0);
22774 __Pyx_ReleaseBuffer((&__pyx_v_self->view));
22793 __pyx_t_2 = ((((Py_buffer *)(&__pyx_v_self->view))->obj == Py_None) != 0);
22803 ((Py_buffer *)(&__pyx_v_self->view))->obj = NULL;
22812 Py_DECREF(Py_None);
22831 __pyx_t_2 = ((__pyx_v_self->lock != NULL) != 0);
22841 __pyx_t_3 = __pyx_memoryview_thread_locks_used;
22842 __pyx_t_4 = __pyx_t_3;
22843 for (__pyx_t_5 = 0; __pyx_t_5 < __pyx_t_4; __pyx_t_5+=1) {
22844 __pyx_v_i = __pyx_t_5;
22853 __pyx_t_2 = (((__pyx_memoryview_thread_locks[__pyx_v_i]) == __pyx_v_self->lock) != 0);
22863 __pyx_memoryview_thread_locks_used = (__pyx_memoryview_thread_locks_used - 1);
22872 __pyx_t_2 = ((__pyx_v_i != __pyx_memoryview_thread_locks_used) != 0);
22882 __pyx_t_6 = (__pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]);
22883 __pyx_t_7 = (__pyx_memoryview_thread_locks[__pyx_v_i]);
22892 (__pyx_memoryview_thread_locks[__pyx_v_i]) = __pyx_t_6;
22893 (__pyx_memoryview_thread_locks[__pyx_memoryview_thread_locks_used]) = __pyx_t_7;
22911 goto __pyx_L6_break;
22931 PyThread_free_lock(__pyx_v_self->lock);
22953 __Pyx_RefNannyFinishContext();
22964 static char *__pyx_memoryview_get_item_pointer(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index) {
22965 Py_ssize_t __pyx_v_dim;
22966 char *__pyx_v_itemp;
22967 PyObject *__pyx_v_idx = NULL;
22969 __Pyx_RefNannyDeclarations
22970 Py_ssize_t __pyx_t_1;
22971 PyObject *__pyx_t_2 = NULL;
22972 Py_ssize_t __pyx_t_3;
22973 PyObject *(*__pyx_t_4)(PyObject *);
22974 PyObject *__pyx_t_5 = NULL;
22975 Py_ssize_t __pyx_t_6;
22977 int __pyx_lineno = 0;
22978 const char *__pyx_filename = NULL;
22979 int __pyx_clineno = 0;
22980 __Pyx_RefNannySetupContext(
"get_item_pointer", 0);
22989 __pyx_v_itemp = ((
char *)__pyx_v_self->view.buf);
22999 if (likely(PyList_CheckExact(__pyx_v_index)) || PyTuple_CheckExact(__pyx_v_index)) {
23000 __pyx_t_2 = __pyx_v_index; __Pyx_INCREF(__pyx_t_2); __pyx_t_3 = 0;
23003 __pyx_t_3 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_v_index);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 397, __pyx_L1_error)
23004 __Pyx_GOTREF(__pyx_t_2);
23005 __pyx_t_4 = Py_TYPE(__pyx_t_2)->tp_iternext;
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 397, __pyx_L1_error)
23008 if (likely(!__pyx_t_4)) {
23009 if (likely(PyList_CheckExact(__pyx_t_2))) {
23010 if (__pyx_t_3 >= PyList_GET_SIZE(__pyx_t_2))
break;
23011 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
23012 __pyx_t_5 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_5); __pyx_t_3++;
if (unlikely(0 < 0)) __PYX_ERR(0, 397, __pyx_L1_error)
23014 __pyx_t_5 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 397, __pyx_L1_error)
23015 __Pyx_GOTREF(__pyx_t_5);
23018 if (__pyx_t_3 >= PyTuple_GET_SIZE(__pyx_t_2))
break;
23019 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
23020 __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_3); __Pyx_INCREF(__pyx_t_5); __pyx_t_3++;
if (unlikely(0 < 0)) __PYX_ERR(0, 397, __pyx_L1_error)
23022 __pyx_t_5 = PySequence_ITEM(__pyx_t_2, __pyx_t_3); __pyx_t_3++;
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 397, __pyx_L1_error)
23023 __Pyx_GOTREF(__pyx_t_5);
23027 __pyx_t_5 = __pyx_t_4(__pyx_t_2);
23028 if (unlikely(!__pyx_t_5)) {
23029 PyObject* exc_type = PyErr_Occurred();
23031 if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
23032 else __PYX_ERR(0, 397, __pyx_L1_error)
23036 __Pyx_GOTREF(__pyx_t_5);
23038 __Pyx_XDECREF_SET(__pyx_v_idx, __pyx_t_5);
23040 __pyx_v_dim = __pyx_t_1;
23041 __pyx_t_1 = (__pyx_t_1 + 1);
23050 __pyx_t_6 = __Pyx_PyIndex_AsSsize_t(__pyx_v_idx);
if (unlikely((__pyx_t_6 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 398, __pyx_L1_error)
23051 __pyx_t_7 = __pyx_pybuffer_index((&__pyx_v_self->view), __pyx_v_itemp, __pyx_t_6, __pyx_v_dim);
if (unlikely(__pyx_t_7 == ((
char *)NULL))) __PYX_ERR(0, 398, __pyx_L1_error)
23052 __pyx_v_itemp = __pyx_t_7;
23062 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
23071 __pyx_r = __pyx_v_itemp;
23084 __Pyx_XDECREF(__pyx_t_2);
23085 __Pyx_XDECREF(__pyx_t_5);
23086 __Pyx_AddTraceback(
"View.MemoryView.memoryview.get_item_pointer", __pyx_clineno, __pyx_lineno, __pyx_filename);
23089 __Pyx_XDECREF(__pyx_v_idx);
23090 __Pyx_RefNannyFinishContext();
23103 static PyObject *__pyx_memoryview___getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_index);
23104 static PyObject *__pyx_memoryview___getitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_index) {
23105 PyObject *__pyx_r = 0;
23106 __Pyx_RefNannyDeclarations
23107 __Pyx_RefNannySetupContext(
"__getitem__ (wrapper)", 0);
23108 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_4__getitem__(((
struct __pyx_memoryview_obj *)__pyx_v_self), ((PyObject *)__pyx_v_index));
23111 __Pyx_RefNannyFinishContext();
23115 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_4__getitem__(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index) {
23116 PyObject *__pyx_v_have_slices = NULL;
23117 PyObject *__pyx_v_indices = NULL;
23118 char *__pyx_v_itemp;
23119 PyObject *__pyx_r = NULL;
23120 __Pyx_RefNannyDeclarations
23123 PyObject *__pyx_t_3 = NULL;
23124 PyObject *__pyx_t_4 = NULL;
23125 PyObject *__pyx_t_5 = NULL;
23127 int __pyx_lineno = 0;
23128 const char *__pyx_filename = NULL;
23129 int __pyx_clineno = 0;
23130 __Pyx_RefNannySetupContext(
"__getitem__", 0);
23139 __pyx_t_1 = (__pyx_v_index == __pyx_builtin_Ellipsis);
23140 __pyx_t_2 = (__pyx_t_1 != 0);
23150 __Pyx_XDECREF(__pyx_r);
23151 __Pyx_INCREF(((PyObject *)__pyx_v_self));
23152 __pyx_r = ((PyObject *)__pyx_v_self);
23171 __pyx_t_3 = _unellipsify(__pyx_v_index, __pyx_v_self->view.ndim);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 407, __pyx_L1_error)
23172 __Pyx_GOTREF(__pyx_t_3);
23173 if (likely(__pyx_t_3 != Py_None)) {
23174 PyObject* sequence = __pyx_t_3;
23175 Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
23176 if (unlikely(size != 2)) {
23177 if (size > 2) __Pyx_RaiseTooManyValuesError(2);
23178 else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
23179 __PYX_ERR(0, 407, __pyx_L1_error)
23181 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
23182 __pyx_t_4 = PyTuple_GET_ITEM(sequence, 0);
23183 __pyx_t_5 = PyTuple_GET_ITEM(sequence, 1);
23184 __Pyx_INCREF(__pyx_t_4);
23185 __Pyx_INCREF(__pyx_t_5);
23187 __pyx_t_4 = PySequence_ITEM(sequence, 0);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 407, __pyx_L1_error)
23188 __Pyx_GOTREF(__pyx_t_4);
23189 __pyx_t_5 = PySequence_ITEM(sequence, 1);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 407, __pyx_L1_error)
23190 __Pyx_GOTREF(__pyx_t_5);
23192 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
23194 __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(0, 407, __pyx_L1_error)
23196 __pyx_v_have_slices = __pyx_t_4;
23198 __pyx_v_indices = __pyx_t_5;
23208 __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_v_have_slices);
if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 410, __pyx_L1_error)
23218 __Pyx_XDECREF(__pyx_r);
23219 __pyx_t_3 = ((PyObject *)__pyx_memview_slice(__pyx_v_self, __pyx_v_indices));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 411, __pyx_L1_error)
23220 __Pyx_GOTREF(__pyx_t_3);
23221 __pyx_r = __pyx_t_3;
23242 __pyx_t_6 = ((
struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->get_item_pointer(__pyx_v_self, __pyx_v_indices);
if (unlikely(__pyx_t_6 == ((
char *)NULL))) __PYX_ERR(0, 413, __pyx_L1_error)
23243 __pyx_v_itemp = __pyx_t_6;
23252 __Pyx_XDECREF(__pyx_r);
23253 __pyx_t_3 = ((
struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->convert_item_to_object(__pyx_v_self, __pyx_v_itemp);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 414, __pyx_L1_error)
23254 __Pyx_GOTREF(__pyx_t_3);
23255 __pyx_r = __pyx_t_3;
23270 __Pyx_XDECREF(__pyx_t_3);
23271 __Pyx_XDECREF(__pyx_t_4);
23272 __Pyx_XDECREF(__pyx_t_5);
23273 __Pyx_AddTraceback(
"View.MemoryView.memoryview.__getitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
23276 __Pyx_XDECREF(__pyx_v_have_slices);
23277 __Pyx_XDECREF(__pyx_v_indices);
23278 __Pyx_XGIVEREF(__pyx_r);
23279 __Pyx_RefNannyFinishContext();
23292 static int __pyx_memoryview___setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value);
23293 static int __pyx_memoryview___setitem__(PyObject *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value) {
23295 __Pyx_RefNannyDeclarations
23296 __Pyx_RefNannySetupContext(
"__setitem__ (wrapper)", 0);
23297 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_6__setitem__(((
struct __pyx_memoryview_obj *)__pyx_v_self), ((PyObject *)__pyx_v_index), ((PyObject *)__pyx_v_value));
23300 __Pyx_RefNannyFinishContext();
23304 static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_6__setitem__(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value) {
23305 PyObject *__pyx_v_have_slices = NULL;
23306 PyObject *__pyx_v_obj = NULL;
23308 __Pyx_RefNannyDeclarations
23310 PyObject *__pyx_t_2 = NULL;
23311 PyObject *__pyx_t_3 = NULL;
23312 PyObject *__pyx_t_4 = NULL;
23313 int __pyx_lineno = 0;
23314 const char *__pyx_filename = NULL;
23315 int __pyx_clineno = 0;
23316 __Pyx_RefNannySetupContext(
"__setitem__", 0);
23317 __Pyx_INCREF(__pyx_v_index);
23326 __pyx_t_1 = (__pyx_v_self->view.readonly != 0);
23327 if (unlikely(__pyx_t_1)) {
23336 __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__15, NULL);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 418, __pyx_L1_error)
23337 __Pyx_GOTREF(__pyx_t_2);
23338 __Pyx_Raise(__pyx_t_2, 0, 0, 0);
23339 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
23340 __PYX_ERR(0, 418, __pyx_L1_error)
23358 __pyx_t_2 = _unellipsify(__pyx_v_index, __pyx_v_self->view.ndim);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 420, __pyx_L1_error)
23359 __Pyx_GOTREF(__pyx_t_2);
23360 if (likely(__pyx_t_2 != Py_None)) {
23361 PyObject* sequence = __pyx_t_2;
23362 Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
23363 if (unlikely(size != 2)) {
23364 if (size > 2) __Pyx_RaiseTooManyValuesError(2);
23365 else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
23366 __PYX_ERR(0, 420, __pyx_L1_error)
23368 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
23369 __pyx_t_3 = PyTuple_GET_ITEM(sequence, 0);
23370 __pyx_t_4 = PyTuple_GET_ITEM(sequence, 1);
23371 __Pyx_INCREF(__pyx_t_3);
23372 __Pyx_INCREF(__pyx_t_4);
23374 __pyx_t_3 = PySequence_ITEM(sequence, 0);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 420, __pyx_L1_error)
23375 __Pyx_GOTREF(__pyx_t_3);
23376 __pyx_t_4 = PySequence_ITEM(sequence, 1);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 420, __pyx_L1_error)
23377 __Pyx_GOTREF(__pyx_t_4);
23379 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
23381 __Pyx_RaiseNoneNotIterableError(); __PYX_ERR(0, 420, __pyx_L1_error)
23383 __pyx_v_have_slices = __pyx_t_3;
23385 __Pyx_DECREF_SET(__pyx_v_index, __pyx_t_4);
23395 __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_have_slices);
if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 422, __pyx_L1_error)
23405 __pyx_t_2 = ((
struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->is_slice(__pyx_v_self, __pyx_v_value);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 423, __pyx_L1_error)
23406 __Pyx_GOTREF(__pyx_t_2);
23407 __pyx_v_obj = __pyx_t_2;
23417 __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_obj);
if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 424, __pyx_L1_error)
23427 __pyx_t_2 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_self), __pyx_v_index);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 425, __pyx_L1_error)
23428 __Pyx_GOTREF(__pyx_t_2);
23429 __pyx_t_4 = ((
struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->setitem_slice_assignment(__pyx_v_self, __pyx_t_2, __pyx_v_obj);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 425, __pyx_L1_error)
23430 __Pyx_GOTREF(__pyx_t_4);
23431 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
23432 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
23452 __pyx_t_4 = __Pyx_PyObject_GetItem(((PyObject *)__pyx_v_self), __pyx_v_index);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 427, __pyx_L1_error)
23453 __Pyx_GOTREF(__pyx_t_4);
23454 if (!(likely(((__pyx_t_4) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_4, __pyx_memoryview_type))))) __PYX_ERR(0, 427, __pyx_L1_error)
23455 __pyx_t_2 = ((
struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->setitem_slice_assign_scalar(__pyx_v_self, ((
struct __pyx_memoryview_obj *)__pyx_t_4), __pyx_v_value);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 427, __pyx_L1_error)
23456 __Pyx_GOTREF(__pyx_t_2);
23457 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
23458 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
23480 __pyx_t_2 = ((
struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->setitem_indexed(__pyx_v_self, __pyx_v_index, __pyx_v_value);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 429, __pyx_L1_error)
23481 __Pyx_GOTREF(__pyx_t_2);
23482 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
23498 __Pyx_XDECREF(__pyx_t_2);
23499 __Pyx_XDECREF(__pyx_t_3);
23500 __Pyx_XDECREF(__pyx_t_4);
23501 __Pyx_AddTraceback(
"View.MemoryView.memoryview.__setitem__", __pyx_clineno, __pyx_lineno, __pyx_filename);
23504 __Pyx_XDECREF(__pyx_v_have_slices);
23505 __Pyx_XDECREF(__pyx_v_obj);
23506 __Pyx_XDECREF(__pyx_v_index);
23507 __Pyx_RefNannyFinishContext();
23519 static PyObject *__pyx_memoryview_is_slice(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_obj) {
23520 PyObject *__pyx_r = NULL;
23521 __Pyx_RefNannyDeclarations
23524 PyObject *__pyx_t_3 = NULL;
23525 PyObject *__pyx_t_4 = NULL;
23526 PyObject *__pyx_t_5 = NULL;
23527 PyObject *__pyx_t_6 = NULL;
23528 PyObject *__pyx_t_7 = NULL;
23529 PyObject *__pyx_t_8 = NULL;
23531 int __pyx_lineno = 0;
23532 const char *__pyx_filename = NULL;
23533 int __pyx_clineno = 0;
23534 __Pyx_RefNannySetupContext(
"is_slice", 0);
23535 __Pyx_INCREF(__pyx_v_obj);
23544 __pyx_t_1 = __Pyx_TypeCheck(__pyx_v_obj, __pyx_memoryview_type);
23545 __pyx_t_2 = ((!(__pyx_t_1 != 0)) != 0);
23556 __Pyx_PyThreadState_declare
23557 __Pyx_PyThreadState_assign
23558 __Pyx_ExceptionSave(&__pyx_t_3, &__pyx_t_4, &__pyx_t_5);
23559 __Pyx_XGOTREF(__pyx_t_3);
23560 __Pyx_XGOTREF(__pyx_t_4);
23561 __Pyx_XGOTREF(__pyx_t_5);
23571 __pyx_t_6 = __Pyx_PyInt_From_int(((__pyx_v_self->flags & (~PyBUF_WRITABLE)) | PyBUF_ANY_CONTIGUOUS));
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 434, __pyx_L4_error)
23572 __Pyx_GOTREF(__pyx_t_6);
23581 __pyx_t_7 = __Pyx_PyBool_FromLong(__pyx_v_self->dtype_is_object);
if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 435, __pyx_L4_error)
23582 __Pyx_GOTREF(__pyx_t_7);
23591 __pyx_t_8 = PyTuple_New(3);
if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 434, __pyx_L4_error)
23592 __Pyx_GOTREF(__pyx_t_8);
23593 __Pyx_INCREF(__pyx_v_obj);
23594 __Pyx_GIVEREF(__pyx_v_obj);
23595 PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_v_obj);
23596 __Pyx_GIVEREF(__pyx_t_6);
23597 PyTuple_SET_ITEM(__pyx_t_8, 1, __pyx_t_6);
23598 __Pyx_GIVEREF(__pyx_t_7);
23599 PyTuple_SET_ITEM(__pyx_t_8, 2, __pyx_t_7);
23602 __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)__pyx_memoryview_type), __pyx_t_8, NULL);
if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 434, __pyx_L4_error)
23603 __Pyx_GOTREF(__pyx_t_7);
23604 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
23605 __Pyx_DECREF_SET(__pyx_v_obj, __pyx_t_7);
23616 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
23617 __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
23618 __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
23619 goto __pyx_L9_try_end;
23621 __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
23622 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
23623 __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
23632 __pyx_t_9 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_TypeError);
23634 __Pyx_AddTraceback(
"View.MemoryView.memoryview.is_slice", __pyx_clineno, __pyx_lineno, __pyx_filename);
23635 if (__Pyx_GetException(&__pyx_t_7, &__pyx_t_8, &__pyx_t_6) < 0) __PYX_ERR(0, 436, __pyx_L6_except_error)
23636 __Pyx_GOTREF(__pyx_t_7);
23637 __Pyx_GOTREF(__pyx_t_8);
23638 __Pyx_GOTREF(__pyx_t_6);
23647 __Pyx_XDECREF(__pyx_r);
23648 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
23649 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
23650 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
23651 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
23652 goto __pyx_L7_except_return;
23654 goto __pyx_L6_except_error;
23655 __pyx_L6_except_error:;
23664 __Pyx_XGIVEREF(__pyx_t_3);
23665 __Pyx_XGIVEREF(__pyx_t_4);
23666 __Pyx_XGIVEREF(__pyx_t_5);
23667 __Pyx_ExceptionReset(__pyx_t_3, __pyx_t_4, __pyx_t_5);
23668 goto __pyx_L1_error;
23669 __pyx_L7_except_return:;
23670 __Pyx_XGIVEREF(__pyx_t_3);
23671 __Pyx_XGIVEREF(__pyx_t_4);
23672 __Pyx_XGIVEREF(__pyx_t_5);
23673 __Pyx_ExceptionReset(__pyx_t_3, __pyx_t_4, __pyx_t_5);
23694 __Pyx_XDECREF(__pyx_r);
23695 __Pyx_INCREF(__pyx_v_obj);
23696 __pyx_r = __pyx_v_obj;
23709 __Pyx_XDECREF(__pyx_t_6);
23710 __Pyx_XDECREF(__pyx_t_7);
23711 __Pyx_XDECREF(__pyx_t_8);
23712 __Pyx_AddTraceback(
"View.MemoryView.memoryview.is_slice", __pyx_clineno, __pyx_lineno, __pyx_filename);
23715 __Pyx_XDECREF(__pyx_v_obj);
23716 __Pyx_XGIVEREF(__pyx_r);
23717 __Pyx_RefNannyFinishContext();
23729 static PyObject *__pyx_memoryview_setitem_slice_assignment(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_dst, PyObject *__pyx_v_src) {
23730 __Pyx_memviewslice __pyx_v_dst_slice;
23731 __Pyx_memviewslice __pyx_v_src_slice;
23732 PyObject *__pyx_r = NULL;
23733 __Pyx_RefNannyDeclarations
23734 __Pyx_memviewslice *__pyx_t_1;
23735 __Pyx_memviewslice *__pyx_t_2;
23736 PyObject *__pyx_t_3 = NULL;
23740 int __pyx_lineno = 0;
23741 const char *__pyx_filename = NULL;
23742 int __pyx_clineno = 0;
23743 __Pyx_RefNannySetupContext(
"setitem_slice_assignment", 0);
23752 if (!(likely(((__pyx_v_src) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_src, __pyx_memoryview_type))))) __PYX_ERR(0, 445, __pyx_L1_error)
23753 __pyx_t_1 = __pyx_memoryview_get_slice_from_memoryview(((
struct __pyx_memoryview_obj *)__pyx_v_src), (&__pyx_v_src_slice));
if (unlikely(__pyx_t_1 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(0, 445, __pyx_L1_error)
23762 if (!(likely(((__pyx_v_dst) == Py_None) || likely(__Pyx_TypeTest(__pyx_v_dst, __pyx_memoryview_type))))) __PYX_ERR(0, 446, __pyx_L1_error)
23763 __pyx_t_2 = __pyx_memoryview_get_slice_from_memoryview(((
struct __pyx_memoryview_obj *)__pyx_v_dst), (&__pyx_v_dst_slice));
if (unlikely(__pyx_t_2 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(0, 446, __pyx_L1_error)
23772 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_src, __pyx_n_s_ndim);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 447, __pyx_L1_error)
23773 __Pyx_GOTREF(__pyx_t_3);
23774 __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_4 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 447, __pyx_L1_error)
23775 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
23776 __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_dst, __pyx_n_s_ndim);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 447, __pyx_L1_error)
23777 __Pyx_GOTREF(__pyx_t_3);
23778 __pyx_t_5 = __Pyx_PyInt_As_int(__pyx_t_3);
if (unlikely((__pyx_t_5 == (
int)-1) && PyErr_Occurred())) __PYX_ERR(0, 447, __pyx_L1_error)
23779 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
23788 __pyx_t_6 = __pyx_memoryview_copy_contents((__pyx_t_1[0]), (__pyx_t_2[0]), __pyx_t_4, __pyx_t_5, __pyx_v_self->dtype_is_object);
if (unlikely(__pyx_t_6 == ((
int)-1))) __PYX_ERR(0, 445, __pyx_L1_error)
23799 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
23802 __Pyx_XDECREF(__pyx_t_3);
23803 __Pyx_AddTraceback(
"View.MemoryView.memoryview.setitem_slice_assignment", __pyx_clineno, __pyx_lineno, __pyx_filename);
23806 __Pyx_XGIVEREF(__pyx_r);
23807 __Pyx_RefNannyFinishContext();
23819 static PyObject *__pyx_memoryview_setitem_slice_assign_scalar(
struct __pyx_memoryview_obj *__pyx_v_self,
struct __pyx_memoryview_obj *__pyx_v_dst, PyObject *__pyx_v_value) {
23820 int __pyx_v_array[0x80];
23822 void *__pyx_v_item;
23823 __Pyx_memviewslice *__pyx_v_dst_slice;
23824 __Pyx_memviewslice __pyx_v_tmp_slice;
23825 PyObject *__pyx_r = NULL;
23826 __Pyx_RefNannyDeclarations
23827 __Pyx_memviewslice *__pyx_t_1;
23829 PyObject *__pyx_t_3 = NULL;
23832 char const *__pyx_t_6;
23833 PyObject *__pyx_t_7 = NULL;
23834 PyObject *__pyx_t_8 = NULL;
23835 PyObject *__pyx_t_9 = NULL;
23836 PyObject *__pyx_t_10 = NULL;
23837 PyObject *__pyx_t_11 = NULL;
23838 PyObject *__pyx_t_12 = NULL;
23839 int __pyx_lineno = 0;
23840 const char *__pyx_filename = NULL;
23841 int __pyx_clineno = 0;
23842 __Pyx_RefNannySetupContext(
"setitem_slice_assign_scalar", 0);
23851 __pyx_v_tmp = NULL;
23860 __pyx_t_1 = __pyx_memoryview_get_slice_from_memoryview(__pyx_v_dst, (&__pyx_v_tmp_slice));
if (unlikely(__pyx_t_1 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(0, 456, __pyx_L1_error)
23861 __pyx_v_dst_slice = __pyx_t_1;
23870 __pyx_t_2 = ((((size_t)__pyx_v_self->view.itemsize) > (
sizeof(__pyx_v_array))) != 0);
23880 __pyx_v_tmp = PyMem_Malloc(__pyx_v_self->view.itemsize);
23889 __pyx_t_2 = ((__pyx_v_tmp == NULL) != 0);
23890 if (unlikely(__pyx_t_2)) {
23899 PyErr_NoMemory(); __PYX_ERR(0, 461, __pyx_L1_error)
23917 __pyx_v_item = __pyx_v_tmp;
23937 __pyx_v_item = ((
void *)__pyx_v_array);
23957 __pyx_t_2 = (__pyx_v_self->dtype_is_object != 0);
23967 (((PyObject **)__pyx_v_item)[0]) = ((PyObject *)__pyx_v_value);
23987 __pyx_t_3 = ((
struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->assign_item_from_object(__pyx_v_self, ((
char *)__pyx_v_item), __pyx_v_value);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 470, __pyx_L6_error)
23988 __Pyx_GOTREF(__pyx_t_3);
23989 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
24000 __pyx_t_2 = ((__pyx_v_self->view.suboffsets != NULL) != 0);
24010 __pyx_t_3 = assert_direct_dimensions(__pyx_v_self->view.suboffsets, __pyx_v_self->view.ndim);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 475, __pyx_L6_error)
24011 __Pyx_GOTREF(__pyx_t_3);
24012 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
24030 __pyx_memoryview_slice_assign_scalar(__pyx_v_dst_slice, __pyx_v_dst->view.ndim, __pyx_v_self->view.itemsize, __pyx_v_item, __pyx_v_self->dtype_is_object);
24042 PyMem_Free(__pyx_v_tmp);
24047 __Pyx_PyThreadState_declare
24048 __Pyx_PyThreadState_assign
24049 __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_9 = 0; __pyx_t_10 = 0; __pyx_t_11 = 0; __pyx_t_12 = 0;
24050 __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
24051 if (PY_MAJOR_VERSION >= 3) __Pyx_ExceptionSwap(&__pyx_t_10, &__pyx_t_11, &__pyx_t_12);
24052 if ((PY_MAJOR_VERSION < 3) || unlikely(__Pyx_GetException(&__pyx_t_7, &__pyx_t_8, &__pyx_t_9) < 0)) __Pyx_ErrFetch(&__pyx_t_7, &__pyx_t_8, &__pyx_t_9);
24053 __Pyx_XGOTREF(__pyx_t_7);
24054 __Pyx_XGOTREF(__pyx_t_8);
24055 __Pyx_XGOTREF(__pyx_t_9);
24056 __Pyx_XGOTREF(__pyx_t_10);
24057 __Pyx_XGOTREF(__pyx_t_11);
24058 __Pyx_XGOTREF(__pyx_t_12);
24059 __pyx_t_4 = __pyx_lineno; __pyx_t_5 = __pyx_clineno; __pyx_t_6 = __pyx_filename;
24061 PyMem_Free(__pyx_v_tmp);
24063 if (PY_MAJOR_VERSION >= 3) {
24064 __Pyx_XGIVEREF(__pyx_t_10);
24065 __Pyx_XGIVEREF(__pyx_t_11);
24066 __Pyx_XGIVEREF(__pyx_t_12);
24067 __Pyx_ExceptionReset(__pyx_t_10, __pyx_t_11, __pyx_t_12);
24069 __Pyx_XGIVEREF(__pyx_t_7);
24070 __Pyx_XGIVEREF(__pyx_t_8);
24071 __Pyx_XGIVEREF(__pyx_t_9);
24072 __Pyx_ErrRestore(__pyx_t_7, __pyx_t_8, __pyx_t_9);
24073 __pyx_t_7 = 0; __pyx_t_8 = 0; __pyx_t_9 = 0; __pyx_t_10 = 0; __pyx_t_11 = 0; __pyx_t_12 = 0;
24074 __pyx_lineno = __pyx_t_4; __pyx_clineno = __pyx_t_5; __pyx_filename = __pyx_t_6;
24075 goto __pyx_L1_error;
24089 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
24092 __Pyx_XDECREF(__pyx_t_3);
24093 __Pyx_AddTraceback(
"View.MemoryView.memoryview.setitem_slice_assign_scalar", __pyx_clineno, __pyx_lineno, __pyx_filename);
24096 __Pyx_XGIVEREF(__pyx_r);
24097 __Pyx_RefNannyFinishContext();
24109 static PyObject *__pyx_memoryview_setitem_indexed(
struct __pyx_memoryview_obj *__pyx_v_self, PyObject *__pyx_v_index, PyObject *__pyx_v_value) {
24110 char *__pyx_v_itemp;
24111 PyObject *__pyx_r = NULL;
24112 __Pyx_RefNannyDeclarations
24114 PyObject *__pyx_t_2 = NULL;
24115 int __pyx_lineno = 0;
24116 const char *__pyx_filename = NULL;
24117 int __pyx_clineno = 0;
24118 __Pyx_RefNannySetupContext(
"setitem_indexed", 0);
24127 __pyx_t_1 = ((
struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->get_item_pointer(__pyx_v_self, __pyx_v_index);
if (unlikely(__pyx_t_1 == ((
char *)NULL))) __PYX_ERR(0, 482, __pyx_L1_error)
24128 __pyx_v_itemp = __pyx_t_1;
24137 __pyx_t_2 = ((
struct __pyx_vtabstruct_memoryview *)__pyx_v_self->__pyx_vtab)->assign_item_from_object(__pyx_v_self, __pyx_v_itemp, __pyx_v_value);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 483, __pyx_L1_error)
24138 __Pyx_GOTREF(__pyx_t_2);
24139 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
24150 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
24153 __Pyx_XDECREF(__pyx_t_2);
24154 __Pyx_AddTraceback(
"View.MemoryView.memoryview.setitem_indexed", __pyx_clineno, __pyx_lineno, __pyx_filename);
24157 __Pyx_XGIVEREF(__pyx_r);
24158 __Pyx_RefNannyFinishContext();
24170 static PyObject *__pyx_memoryview_convert_item_to_object(
struct __pyx_memoryview_obj *__pyx_v_self,
char *__pyx_v_itemp) {
24171 PyObject *__pyx_v_struct = NULL;
24172 PyObject *__pyx_v_bytesitem = 0;
24173 PyObject *__pyx_v_result = NULL;
24174 PyObject *__pyx_r = NULL;
24175 __Pyx_RefNannyDeclarations
24176 PyObject *__pyx_t_1 = NULL;
24177 PyObject *__pyx_t_2 = NULL;
24178 PyObject *__pyx_t_3 = NULL;
24179 PyObject *__pyx_t_4 = NULL;
24180 PyObject *__pyx_t_5 = NULL;
24181 PyObject *__pyx_t_6 = NULL;
24182 PyObject *__pyx_t_7 = NULL;
24184 PyObject *__pyx_t_9 = NULL;
24187 int __pyx_lineno = 0;
24188 const char *__pyx_filename = NULL;
24189 int __pyx_clineno = 0;
24190 __Pyx_RefNannySetupContext(
"convert_item_to_object", 0);
24199 __pyx_t_1 = __Pyx_Import(__pyx_n_s_struct, 0, 0);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 488, __pyx_L1_error)
24200 __Pyx_GOTREF(__pyx_t_1);
24201 __pyx_v_struct = __pyx_t_1;
24211 __pyx_t_1 = __Pyx_PyBytes_FromStringAndSize(__pyx_v_itemp + 0, __pyx_v_self->view.itemsize - 0);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 491, __pyx_L1_error)
24212 __Pyx_GOTREF(__pyx_t_1);
24213 __pyx_v_bytesitem = ((PyObject*)__pyx_t_1);
24224 __Pyx_PyThreadState_declare
24225 __Pyx_PyThreadState_assign
24226 __Pyx_ExceptionSave(&__pyx_t_2, &__pyx_t_3, &__pyx_t_4);
24227 __Pyx_XGOTREF(__pyx_t_2);
24228 __Pyx_XGOTREF(__pyx_t_3);
24229 __Pyx_XGOTREF(__pyx_t_4);
24239 __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_struct, __pyx_n_s_unpack);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 493, __pyx_L3_error)
24240 __Pyx_GOTREF(__pyx_t_5);
24241 __pyx_t_6 = __Pyx_PyBytes_FromString(__pyx_v_self->view.format);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 493, __pyx_L3_error)
24242 __Pyx_GOTREF(__pyx_t_6);
24245 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) {
24246 __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_5);
24247 if (likely(__pyx_t_7)) {
24248 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_5);
24249 __Pyx_INCREF(__pyx_t_7);
24250 __Pyx_INCREF(
function);
24251 __Pyx_DECREF_SET(__pyx_t_5,
function);
24255 #if CYTHON_FAST_PYCALL
24256 if (PyFunction_Check(__pyx_t_5)) {
24257 PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_t_6, __pyx_v_bytesitem};
24258 __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 493, __pyx_L3_error)
24259 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
24260 __Pyx_GOTREF(__pyx_t_1);
24261 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
24264 #if CYTHON_FAST_PYCCALL
24265 if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) {
24266 PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_t_6, __pyx_v_bytesitem};
24267 __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_8, 2+__pyx_t_8);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 493, __pyx_L3_error)
24268 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
24269 __Pyx_GOTREF(__pyx_t_1);
24270 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
24274 __pyx_t_9 = PyTuple_New(2+__pyx_t_8);
if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 493, __pyx_L3_error)
24275 __Pyx_GOTREF(__pyx_t_9);
24277 __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL;
24279 __Pyx_GIVEREF(__pyx_t_6);
24280 PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_8, __pyx_t_6);
24281 __Pyx_INCREF(__pyx_v_bytesitem);
24282 __Pyx_GIVEREF(__pyx_v_bytesitem);
24283 PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, __pyx_v_bytesitem);
24285 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_9, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 493, __pyx_L3_error)
24286 __Pyx_GOTREF(__pyx_t_1);
24287 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
24289 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
24290 __pyx_v_result = __pyx_t_1;
24310 __pyx_t_10 = strlen(__pyx_v_self->view.format);
24311 __pyx_t_11 = ((__pyx_t_10 == 1) != 0);
24321 __Pyx_XDECREF(__pyx_r);
24322 __pyx_t_1 = __Pyx_GetItemInt(__pyx_v_result, 0,
long, 1, __Pyx_PyInt_From_long, 0, 0, 1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 498, __pyx_L5_except_error)
24323 __Pyx_GOTREF(__pyx_t_1);
24324 __pyx_r = __pyx_t_1;
24326 goto __pyx_L6_except_return;
24344 __Pyx_XDECREF(__pyx_r);
24345 __Pyx_INCREF(__pyx_v_result);
24346 __pyx_r = __pyx_v_result;
24347 goto __pyx_L6_except_return;
24350 __Pyx_XDECREF(__pyx_t_1); __pyx_t_1 = 0;
24351 __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
24352 __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
24353 __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
24354 __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
24363 __Pyx_ErrFetch(&__pyx_t_1, &__pyx_t_5, &__pyx_t_9);
24364 __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_struct, __pyx_n_s_error);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 494, __pyx_L5_except_error)
24365 __Pyx_GOTREF(__pyx_t_6);
24366 __pyx_t_8 = __Pyx_PyErr_GivenExceptionMatches(__pyx_t_1, __pyx_t_6);
24367 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
24368 __Pyx_ErrRestore(__pyx_t_1, __pyx_t_5, __pyx_t_9);
24369 __pyx_t_1 = 0; __pyx_t_5 = 0; __pyx_t_9 = 0;
24371 __Pyx_AddTraceback(
"View.MemoryView.memoryview.convert_item_to_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
24372 if (__Pyx_GetException(&__pyx_t_9, &__pyx_t_5, &__pyx_t_1) < 0) __PYX_ERR(0, 494, __pyx_L5_except_error)
24373 __Pyx_GOTREF(__pyx_t_9);
24374 __Pyx_GOTREF(__pyx_t_5);
24375 __Pyx_GOTREF(__pyx_t_1);
24384 __pyx_t_6 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__16, NULL);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 495, __pyx_L5_except_error)
24385 __Pyx_GOTREF(__pyx_t_6);
24386 __Pyx_Raise(__pyx_t_6, 0, 0, 0);
24387 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
24388 __PYX_ERR(0, 495, __pyx_L5_except_error)
24390 goto __pyx_L5_except_error;
24391 __pyx_L5_except_error:;
24400 __Pyx_XGIVEREF(__pyx_t_2);
24401 __Pyx_XGIVEREF(__pyx_t_3);
24402 __Pyx_XGIVEREF(__pyx_t_4);
24403 __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4);
24404 goto __pyx_L1_error;
24405 __pyx_L6_except_return:;
24406 __Pyx_XGIVEREF(__pyx_t_2);
24407 __Pyx_XGIVEREF(__pyx_t_3);
24408 __Pyx_XGIVEREF(__pyx_t_4);
24409 __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4);
24423 __Pyx_XDECREF(__pyx_t_1);
24424 __Pyx_XDECREF(__pyx_t_5);
24425 __Pyx_XDECREF(__pyx_t_6);
24426 __Pyx_XDECREF(__pyx_t_7);
24427 __Pyx_XDECREF(__pyx_t_9);
24428 __Pyx_AddTraceback(
"View.MemoryView.memoryview.convert_item_to_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
24431 __Pyx_XDECREF(__pyx_v_struct);
24432 __Pyx_XDECREF(__pyx_v_bytesitem);
24433 __Pyx_XDECREF(__pyx_v_result);
24434 __Pyx_XGIVEREF(__pyx_r);
24435 __Pyx_RefNannyFinishContext();
24447 static PyObject *__pyx_memoryview_assign_item_from_object(
struct __pyx_memoryview_obj *__pyx_v_self,
char *__pyx_v_itemp, PyObject *__pyx_v_value) {
24448 PyObject *__pyx_v_struct = NULL;
24450 PyObject *__pyx_v_bytesvalue = 0;
24451 Py_ssize_t __pyx_v_i;
24452 PyObject *__pyx_r = NULL;
24453 __Pyx_RefNannyDeclarations
24454 PyObject *__pyx_t_1 = NULL;
24457 PyObject *__pyx_t_4 = NULL;
24458 PyObject *__pyx_t_5 = NULL;
24459 PyObject *__pyx_t_6 = NULL;
24461 PyObject *__pyx_t_8 = NULL;
24462 Py_ssize_t __pyx_t_9;
24463 PyObject *__pyx_t_10 = NULL;
24468 int __pyx_lineno = 0;
24469 const char *__pyx_filename = NULL;
24470 int __pyx_clineno = 0;
24471 __Pyx_RefNannySetupContext(
"assign_item_from_object", 0);
24480 __pyx_t_1 = __Pyx_Import(__pyx_n_s_struct, 0, 0);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 504, __pyx_L1_error)
24481 __Pyx_GOTREF(__pyx_t_1);
24482 __pyx_v_struct = __pyx_t_1;
24492 __pyx_t_2 = PyTuple_Check(__pyx_v_value);
24493 __pyx_t_3 = (__pyx_t_2 != 0);
24503 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_struct, __pyx_n_s_pack);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 510, __pyx_L1_error)
24504 __Pyx_GOTREF(__pyx_t_1);
24505 __pyx_t_4 = __Pyx_PyBytes_FromString(__pyx_v_self->view.format);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 510, __pyx_L1_error)
24506 __Pyx_GOTREF(__pyx_t_4);
24507 __pyx_t_5 = PyTuple_New(1);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 510, __pyx_L1_error)
24508 __Pyx_GOTREF(__pyx_t_5);
24509 __Pyx_GIVEREF(__pyx_t_4);
24510 PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4);
24512 __pyx_t_4 = __Pyx_PySequence_Tuple(__pyx_v_value);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 510, __pyx_L1_error)
24513 __Pyx_GOTREF(__pyx_t_4);
24514 __pyx_t_6 = PyNumber_Add(__pyx_t_5, __pyx_t_4);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 510, __pyx_L1_error)
24515 __Pyx_GOTREF(__pyx_t_6);
24516 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
24517 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
24518 __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_6, NULL);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 510, __pyx_L1_error)
24519 __Pyx_GOTREF(__pyx_t_4);
24520 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
24521 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
24522 if (!(likely(PyBytes_CheckExact(__pyx_t_4))||((__pyx_t_4) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"bytes", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 510, __pyx_L1_error)
24523 __pyx_v_bytesvalue = ((PyObject*)__pyx_t_4);
24544 __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_struct, __pyx_n_s_pack);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 512, __pyx_L1_error)
24545 __Pyx_GOTREF(__pyx_t_6);
24546 __pyx_t_1 = __Pyx_PyBytes_FromString(__pyx_v_self->view.format);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 512, __pyx_L1_error)
24547 __Pyx_GOTREF(__pyx_t_1);
24550 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_6))) {
24551 __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_6);
24552 if (likely(__pyx_t_5)) {
24553 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_6);
24554 __Pyx_INCREF(__pyx_t_5);
24555 __Pyx_INCREF(
function);
24556 __Pyx_DECREF_SET(__pyx_t_6,
function);
24560 #if CYTHON_FAST_PYCALL
24561 if (PyFunction_Check(__pyx_t_6)) {
24562 PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_t_1, __pyx_v_value};
24563 __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 512, __pyx_L1_error)
24564 __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
24565 __Pyx_GOTREF(__pyx_t_4);
24566 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
24569 #if CYTHON_FAST_PYCCALL
24570 if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) {
24571 PyObject *__pyx_temp[3] = {__pyx_t_5, __pyx_t_1, __pyx_v_value};
24572 __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_7, 2+__pyx_t_7);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 512, __pyx_L1_error)
24573 __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
24574 __Pyx_GOTREF(__pyx_t_4);
24575 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
24579 __pyx_t_8 = PyTuple_New(2+__pyx_t_7);
if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 512, __pyx_L1_error)
24580 __Pyx_GOTREF(__pyx_t_8);
24582 __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_5); __pyx_t_5 = NULL;
24584 __Pyx_GIVEREF(__pyx_t_1);
24585 PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_7, __pyx_t_1);
24586 __Pyx_INCREF(__pyx_v_value);
24587 __Pyx_GIVEREF(__pyx_v_value);
24588 PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_7, __pyx_v_value);
24590 __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_8, NULL);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 512, __pyx_L1_error)
24591 __Pyx_GOTREF(__pyx_t_4);
24592 __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
24594 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
24595 if (!(likely(PyBytes_CheckExact(__pyx_t_4))||((__pyx_t_4) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"bytes", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 512, __pyx_L1_error)
24596 __pyx_v_bytesvalue = ((PyObject*)__pyx_t_4);
24609 if (unlikely(__pyx_v_bytesvalue == Py_None)) {
24610 PyErr_SetString(PyExc_TypeError,
"'NoneType' is not iterable");
24611 __PYX_ERR(0, 514, __pyx_L1_error)
24613 __Pyx_INCREF(__pyx_v_bytesvalue);
24614 __pyx_t_10 = __pyx_v_bytesvalue;
24615 __pyx_t_12 = PyBytes_AS_STRING(__pyx_t_10);
24616 __pyx_t_13 = (__pyx_t_12 + PyBytes_GET_SIZE(__pyx_t_10));
24617 for (__pyx_t_14 = __pyx_t_12; __pyx_t_14 < __pyx_t_13; __pyx_t_14++) {
24618 __pyx_t_11 = __pyx_t_14;
24619 __pyx_v_c = (__pyx_t_11[0]);
24628 __pyx_v_i = __pyx_t_9;
24637 __pyx_t_9 = (__pyx_t_9 + 1);
24646 (__pyx_v_itemp[__pyx_v_i]) = __pyx_v_c;
24648 __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
24659 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
24662 __Pyx_XDECREF(__pyx_t_1);
24663 __Pyx_XDECREF(__pyx_t_4);
24664 __Pyx_XDECREF(__pyx_t_5);
24665 __Pyx_XDECREF(__pyx_t_6);
24666 __Pyx_XDECREF(__pyx_t_8);
24667 __Pyx_XDECREF(__pyx_t_10);
24668 __Pyx_AddTraceback(
"View.MemoryView.memoryview.assign_item_from_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
24671 __Pyx_XDECREF(__pyx_v_struct);
24672 __Pyx_XDECREF(__pyx_v_bytesvalue);
24673 __Pyx_XGIVEREF(__pyx_r);
24674 __Pyx_RefNannyFinishContext();
24687 static CYTHON_UNUSED
int __pyx_memoryview_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags);
24688 static CYTHON_UNUSED
int __pyx_memoryview_getbuffer(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags) {
24690 __Pyx_RefNannyDeclarations
24691 __Pyx_RefNannySetupContext(
"__getbuffer__ (wrapper)", 0);
24692 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_8__getbuffer__(((
struct __pyx_memoryview_obj *)__pyx_v_self), ((Py_buffer *)__pyx_v_info), ((
int)__pyx_v_flags));
24695 __Pyx_RefNannyFinishContext();
24699 static int __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_8__getbuffer__(
struct __pyx_memoryview_obj *__pyx_v_self, Py_buffer *__pyx_v_info,
int __pyx_v_flags) {
24701 __Pyx_RefNannyDeclarations
24704 PyObject *__pyx_t_3 = NULL;
24705 Py_ssize_t *__pyx_t_4;
24709 Py_ssize_t __pyx_t_8;
24710 int __pyx_lineno = 0;
24711 const char *__pyx_filename = NULL;
24712 int __pyx_clineno = 0;
24713 if (__pyx_v_info == NULL) {
24714 PyErr_SetString(PyExc_BufferError,
"PyObject_GetBuffer: view==NULL argument is obsolete");
24717 __Pyx_RefNannySetupContext(
"__getbuffer__", 0);
24718 __pyx_v_info->obj = Py_None; __Pyx_INCREF(Py_None);
24719 __Pyx_GIVEREF(__pyx_v_info->obj);
24728 __pyx_t_2 = ((__pyx_v_flags & PyBUF_WRITABLE) != 0);
24731 __pyx_t_1 = __pyx_t_2;
24732 goto __pyx_L4_bool_binop_done;
24734 __pyx_t_2 = (__pyx_v_self->view.readonly != 0);
24735 __pyx_t_1 = __pyx_t_2;
24736 __pyx_L4_bool_binop_done:;
24737 if (unlikely(__pyx_t_1)) {
24746 __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__17, NULL);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 520, __pyx_L1_error)
24747 __Pyx_GOTREF(__pyx_t_3);
24748 __Pyx_Raise(__pyx_t_3, 0, 0, 0);
24749 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
24750 __PYX_ERR(0, 520, __pyx_L1_error)
24768 __pyx_t_1 = ((__pyx_v_flags & PyBUF_ND) != 0);
24778 __pyx_t_4 = __pyx_v_self->view.shape;
24779 __pyx_v_info->shape = __pyx_t_4;
24799 __pyx_v_info->shape = NULL;
24810 __pyx_t_1 = ((__pyx_v_flags & PyBUF_STRIDES) != 0);
24820 __pyx_t_4 = __pyx_v_self->view.strides;
24821 __pyx_v_info->strides = __pyx_t_4;
24841 __pyx_v_info->strides = NULL;
24852 __pyx_t_1 = ((__pyx_v_flags & PyBUF_INDIRECT) != 0);
24862 __pyx_t_4 = __pyx_v_self->view.suboffsets;
24863 __pyx_v_info->suboffsets = __pyx_t_4;
24883 __pyx_v_info->suboffsets = NULL;
24894 __pyx_t_1 = ((__pyx_v_flags & PyBUF_FORMAT) != 0);
24904 __pyx_t_5 = __pyx_v_self->view.format;
24905 __pyx_v_info->format = __pyx_t_5;
24925 __pyx_v_info->format = NULL;
24936 __pyx_t_6 = __pyx_v_self->view.buf;
24937 __pyx_v_info->buf = __pyx_t_6;
24946 __pyx_t_7 = __pyx_v_self->view.ndim;
24947 __pyx_v_info->ndim = __pyx_t_7;
24956 __pyx_t_8 = __pyx_v_self->view.itemsize;
24957 __pyx_v_info->itemsize = __pyx_t_8;
24966 __pyx_t_8 = __pyx_v_self->view.len;
24967 __pyx_v_info->len = __pyx_t_8;
24976 __pyx_t_1 = __pyx_v_self->view.readonly;
24977 __pyx_v_info->readonly = __pyx_t_1;
24986 __Pyx_INCREF(((PyObject *)__pyx_v_self));
24987 __Pyx_GIVEREF(((PyObject *)__pyx_v_self));
24988 __Pyx_GOTREF(__pyx_v_info->obj);
24989 __Pyx_DECREF(__pyx_v_info->obj);
24990 __pyx_v_info->obj = ((PyObject *)__pyx_v_self);
25004 __Pyx_XDECREF(__pyx_t_3);
25005 __Pyx_AddTraceback(
"View.MemoryView.memoryview.__getbuffer__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25007 if (__pyx_v_info->obj != NULL) {
25008 __Pyx_GOTREF(__pyx_v_info->obj);
25009 __Pyx_DECREF(__pyx_v_info->obj); __pyx_v_info->obj = 0;
25013 if (__pyx_v_info->obj == Py_None) {
25014 __Pyx_GOTREF(__pyx_v_info->obj);
25015 __Pyx_DECREF(__pyx_v_info->obj); __pyx_v_info->obj = 0;
25018 __Pyx_RefNannyFinishContext();
25031 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_1T_1__get__(PyObject *__pyx_v_self);
25032 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_1T_1__get__(PyObject *__pyx_v_self) {
25033 PyObject *__pyx_r = 0;
25034 __Pyx_RefNannyDeclarations
25035 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
25036 __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_1T___get__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25039 __Pyx_RefNannyFinishContext();
25043 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_1T___get__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25044 struct __pyx_memoryviewslice_obj *__pyx_v_result = 0;
25045 PyObject *__pyx_r = NULL;
25046 __Pyx_RefNannyDeclarations
25047 PyObject *__pyx_t_1 = NULL;
25049 int __pyx_lineno = 0;
25050 const char *__pyx_filename = NULL;
25051 int __pyx_clineno = 0;
25052 __Pyx_RefNannySetupContext(
"__get__", 0);
25061 __pyx_t_1 = __pyx_memoryview_copy_object(__pyx_v_self);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 554, __pyx_L1_error)
25062 __Pyx_GOTREF(__pyx_t_1);
25063 if (!(likely(((__pyx_t_1) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_1, __pyx_memoryviewslice_type))))) __PYX_ERR(0, 554, __pyx_L1_error)
25064 __pyx_v_result = ((
struct __pyx_memoryviewslice_obj *)__pyx_t_1);
25074 __pyx_t_2 = __pyx_memslice_transpose((&__pyx_v_result->from_slice));
if (unlikely(__pyx_t_2 == ((
int)0))) __PYX_ERR(0, 555, __pyx_L1_error)
25083 __Pyx_XDECREF(__pyx_r);
25084 __Pyx_INCREF(((PyObject *)__pyx_v_result));
25085 __pyx_r = ((PyObject *)__pyx_v_result);
25098 __Pyx_XDECREF(__pyx_t_1);
25099 __Pyx_AddTraceback(
"View.MemoryView.memoryview.T.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25102 __Pyx_XDECREF((PyObject *)__pyx_v_result);
25103 __Pyx_XGIVEREF(__pyx_r);
25104 __Pyx_RefNannyFinishContext();
25117 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4base_1__get__(PyObject *__pyx_v_self);
25118 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4base_1__get__(PyObject *__pyx_v_self) {
25119 PyObject *__pyx_r = 0;
25120 __Pyx_RefNannyDeclarations
25121 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
25122 __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_4base___get__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25125 __Pyx_RefNannyFinishContext();
25129 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4base___get__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25130 PyObject *__pyx_r = NULL;
25131 __Pyx_RefNannyDeclarations
25132 __Pyx_RefNannySetupContext(
"__get__", 0);
25141 __Pyx_XDECREF(__pyx_r);
25142 __Pyx_INCREF(__pyx_v_self->obj);
25143 __pyx_r = __pyx_v_self->obj;
25156 __Pyx_XGIVEREF(__pyx_r);
25157 __Pyx_RefNannyFinishContext();
25170 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_5shape_1__get__(PyObject *__pyx_v_self);
25171 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_5shape_1__get__(PyObject *__pyx_v_self) {
25172 PyObject *__pyx_r = 0;
25173 __Pyx_RefNannyDeclarations
25174 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
25175 __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_5shape___get__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25178 __Pyx_RefNannyFinishContext();
25182 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_5shape___get__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25183 Py_ssize_t __pyx_v_length;
25184 PyObject *__pyx_r = NULL;
25185 __Pyx_RefNannyDeclarations
25186 PyObject *__pyx_t_1 = NULL;
25187 Py_ssize_t *__pyx_t_2;
25188 Py_ssize_t *__pyx_t_3;
25189 Py_ssize_t *__pyx_t_4;
25190 PyObject *__pyx_t_5 = NULL;
25191 int __pyx_lineno = 0;
25192 const char *__pyx_filename = NULL;
25193 int __pyx_clineno = 0;
25194 __Pyx_RefNannySetupContext(
"__get__", 0);
25203 __Pyx_XDECREF(__pyx_r);
25204 __pyx_t_1 = PyList_New(0);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 564, __pyx_L1_error)
25205 __Pyx_GOTREF(__pyx_t_1);
25206 __pyx_t_3 = (__pyx_v_self->view.shape + __pyx_v_self->view.ndim);
25207 for (__pyx_t_4 = __pyx_v_self->view.shape; __pyx_t_4 < __pyx_t_3; __pyx_t_4++) {
25208 __pyx_t_2 = __pyx_t_4;
25209 __pyx_v_length = (__pyx_t_2[0]);
25210 __pyx_t_5 = PyInt_FromSsize_t(__pyx_v_length);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 564, __pyx_L1_error)
25211 __Pyx_GOTREF(__pyx_t_5);
25212 if (unlikely(__Pyx_ListComp_Append(__pyx_t_1, (PyObject*)__pyx_t_5))) __PYX_ERR(0, 564, __pyx_L1_error)
25213 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
25215 __pyx_t_5 = PyList_AsTuple(((PyObject*)__pyx_t_1));
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 564, __pyx_L1_error)
25216 __Pyx_GOTREF(__pyx_t_5);
25217 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
25218 __pyx_r = __pyx_t_5;
25232 __Pyx_XDECREF(__pyx_t_1);
25233 __Pyx_XDECREF(__pyx_t_5);
25234 __Pyx_AddTraceback(
"View.MemoryView.memoryview.shape.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25237 __Pyx_XGIVEREF(__pyx_r);
25238 __Pyx_RefNannyFinishContext();
25251 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_7strides_1__get__(PyObject *__pyx_v_self);
25252 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_7strides_1__get__(PyObject *__pyx_v_self) {
25253 PyObject *__pyx_r = 0;
25254 __Pyx_RefNannyDeclarations
25255 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
25256 __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_7strides___get__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25259 __Pyx_RefNannyFinishContext();
25263 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_7strides___get__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25264 Py_ssize_t __pyx_v_stride;
25265 PyObject *__pyx_r = NULL;
25266 __Pyx_RefNannyDeclarations
25268 PyObject *__pyx_t_2 = NULL;
25269 Py_ssize_t *__pyx_t_3;
25270 Py_ssize_t *__pyx_t_4;
25271 Py_ssize_t *__pyx_t_5;
25272 PyObject *__pyx_t_6 = NULL;
25273 int __pyx_lineno = 0;
25274 const char *__pyx_filename = NULL;
25275 int __pyx_clineno = 0;
25276 __Pyx_RefNannySetupContext(
"__get__", 0);
25285 __pyx_t_1 = ((__pyx_v_self->view.strides == NULL) != 0);
25286 if (unlikely(__pyx_t_1)) {
25295 __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__18, NULL);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 570, __pyx_L1_error)
25296 __Pyx_GOTREF(__pyx_t_2);
25297 __Pyx_Raise(__pyx_t_2, 0, 0, 0);
25298 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
25299 __PYX_ERR(0, 570, __pyx_L1_error)
25317 __Pyx_XDECREF(__pyx_r);
25318 __pyx_t_2 = PyList_New(0);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 572, __pyx_L1_error)
25319 __Pyx_GOTREF(__pyx_t_2);
25320 __pyx_t_4 = (__pyx_v_self->view.strides + __pyx_v_self->view.ndim);
25321 for (__pyx_t_5 = __pyx_v_self->view.strides; __pyx_t_5 < __pyx_t_4; __pyx_t_5++) {
25322 __pyx_t_3 = __pyx_t_5;
25323 __pyx_v_stride = (__pyx_t_3[0]);
25324 __pyx_t_6 = PyInt_FromSsize_t(__pyx_v_stride);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 572, __pyx_L1_error)
25325 __Pyx_GOTREF(__pyx_t_6);
25326 if (unlikely(__Pyx_ListComp_Append(__pyx_t_2, (PyObject*)__pyx_t_6))) __PYX_ERR(0, 572, __pyx_L1_error)
25327 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
25329 __pyx_t_6 = PyList_AsTuple(((PyObject*)__pyx_t_2));
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 572, __pyx_L1_error)
25330 __Pyx_GOTREF(__pyx_t_6);
25331 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
25332 __pyx_r = __pyx_t_6;
25346 __Pyx_XDECREF(__pyx_t_2);
25347 __Pyx_XDECREF(__pyx_t_6);
25348 __Pyx_AddTraceback(
"View.MemoryView.memoryview.strides.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25351 __Pyx_XGIVEREF(__pyx_r);
25352 __Pyx_RefNannyFinishContext();
25365 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_10suboffsets_1__get__(PyObject *__pyx_v_self);
25366 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_10suboffsets_1__get__(PyObject *__pyx_v_self) {
25367 PyObject *__pyx_r = 0;
25368 __Pyx_RefNannyDeclarations
25369 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
25370 __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_10suboffsets___get__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25373 __Pyx_RefNannyFinishContext();
25377 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_10suboffsets___get__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25378 Py_ssize_t __pyx_v_suboffset;
25379 PyObject *__pyx_r = NULL;
25380 __Pyx_RefNannyDeclarations
25382 PyObject *__pyx_t_2 = NULL;
25383 PyObject *__pyx_t_3 = NULL;
25384 Py_ssize_t *__pyx_t_4;
25385 Py_ssize_t *__pyx_t_5;
25386 Py_ssize_t *__pyx_t_6;
25387 int __pyx_lineno = 0;
25388 const char *__pyx_filename = NULL;
25389 int __pyx_clineno = 0;
25390 __Pyx_RefNannySetupContext(
"__get__", 0);
25399 __pyx_t_1 = ((__pyx_v_self->view.suboffsets == NULL) != 0);
25409 __Pyx_XDECREF(__pyx_r);
25410 __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_self->view.ndim);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 577, __pyx_L1_error)
25411 __Pyx_GOTREF(__pyx_t_2);
25412 __pyx_t_3 = PyNumber_Multiply(__pyx_tuple__19, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 577, __pyx_L1_error)
25413 __Pyx_GOTREF(__pyx_t_3);
25414 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
25415 __pyx_r = __pyx_t_3;
25435 __Pyx_XDECREF(__pyx_r);
25436 __pyx_t_3 = PyList_New(0);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 579, __pyx_L1_error)
25437 __Pyx_GOTREF(__pyx_t_3);
25438 __pyx_t_5 = (__pyx_v_self->view.suboffsets + __pyx_v_self->view.ndim);
25439 for (__pyx_t_6 = __pyx_v_self->view.suboffsets; __pyx_t_6 < __pyx_t_5; __pyx_t_6++) {
25440 __pyx_t_4 = __pyx_t_6;
25441 __pyx_v_suboffset = (__pyx_t_4[0]);
25442 __pyx_t_2 = PyInt_FromSsize_t(__pyx_v_suboffset);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 579, __pyx_L1_error)
25443 __Pyx_GOTREF(__pyx_t_2);
25444 if (unlikely(__Pyx_ListComp_Append(__pyx_t_3, (PyObject*)__pyx_t_2))) __PYX_ERR(0, 579, __pyx_L1_error)
25445 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
25447 __pyx_t_2 = PyList_AsTuple(((PyObject*)__pyx_t_3));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 579, __pyx_L1_error)
25448 __Pyx_GOTREF(__pyx_t_2);
25449 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
25450 __pyx_r = __pyx_t_2;
25464 __Pyx_XDECREF(__pyx_t_2);
25465 __Pyx_XDECREF(__pyx_t_3);
25466 __Pyx_AddTraceback(
"View.MemoryView.memoryview.suboffsets.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25469 __Pyx_XGIVEREF(__pyx_r);
25470 __Pyx_RefNannyFinishContext();
25483 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4ndim_1__get__(PyObject *__pyx_v_self);
25484 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4ndim_1__get__(PyObject *__pyx_v_self) {
25485 PyObject *__pyx_r = 0;
25486 __Pyx_RefNannyDeclarations
25487 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
25488 __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_4ndim___get__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25491 __Pyx_RefNannyFinishContext();
25495 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4ndim___get__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25496 PyObject *__pyx_r = NULL;
25497 __Pyx_RefNannyDeclarations
25498 PyObject *__pyx_t_1 = NULL;
25499 int __pyx_lineno = 0;
25500 const char *__pyx_filename = NULL;
25501 int __pyx_clineno = 0;
25502 __Pyx_RefNannySetupContext(
"__get__", 0);
25511 __Pyx_XDECREF(__pyx_r);
25512 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_self->view.ndim);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 583, __pyx_L1_error)
25513 __Pyx_GOTREF(__pyx_t_1);
25514 __pyx_r = __pyx_t_1;
25528 __Pyx_XDECREF(__pyx_t_1);
25529 __Pyx_AddTraceback(
"View.MemoryView.memoryview.ndim.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25532 __Pyx_XGIVEREF(__pyx_r);
25533 __Pyx_RefNannyFinishContext();
25546 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_8itemsize_1__get__(PyObject *__pyx_v_self);
25547 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_8itemsize_1__get__(PyObject *__pyx_v_self) {
25548 PyObject *__pyx_r = 0;
25549 __Pyx_RefNannyDeclarations
25550 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
25551 __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_8itemsize___get__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25554 __Pyx_RefNannyFinishContext();
25558 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_8itemsize___get__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25559 PyObject *__pyx_r = NULL;
25560 __Pyx_RefNannyDeclarations
25561 PyObject *__pyx_t_1 = NULL;
25562 int __pyx_lineno = 0;
25563 const char *__pyx_filename = NULL;
25564 int __pyx_clineno = 0;
25565 __Pyx_RefNannySetupContext(
"__get__", 0);
25574 __Pyx_XDECREF(__pyx_r);
25575 __pyx_t_1 = PyInt_FromSsize_t(__pyx_v_self->view.itemsize);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 587, __pyx_L1_error)
25576 __Pyx_GOTREF(__pyx_t_1);
25577 __pyx_r = __pyx_t_1;
25591 __Pyx_XDECREF(__pyx_t_1);
25592 __Pyx_AddTraceback(
"View.MemoryView.memoryview.itemsize.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25595 __Pyx_XGIVEREF(__pyx_r);
25596 __Pyx_RefNannyFinishContext();
25609 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_6nbytes_1__get__(PyObject *__pyx_v_self);
25610 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_6nbytes_1__get__(PyObject *__pyx_v_self) {
25611 PyObject *__pyx_r = 0;
25612 __Pyx_RefNannyDeclarations
25613 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
25614 __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_6nbytes___get__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25617 __Pyx_RefNannyFinishContext();
25621 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_6nbytes___get__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25622 PyObject *__pyx_r = NULL;
25623 __Pyx_RefNannyDeclarations
25624 PyObject *__pyx_t_1 = NULL;
25625 PyObject *__pyx_t_2 = NULL;
25626 PyObject *__pyx_t_3 = NULL;
25627 int __pyx_lineno = 0;
25628 const char *__pyx_filename = NULL;
25629 int __pyx_clineno = 0;
25630 __Pyx_RefNannySetupContext(
"__get__", 0);
25639 __Pyx_XDECREF(__pyx_r);
25640 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_size);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 591, __pyx_L1_error)
25641 __Pyx_GOTREF(__pyx_t_1);
25642 __pyx_t_2 = PyInt_FromSsize_t(__pyx_v_self->view.itemsize);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 591, __pyx_L1_error)
25643 __Pyx_GOTREF(__pyx_t_2);
25644 __pyx_t_3 = PyNumber_Multiply(__pyx_t_1, __pyx_t_2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 591, __pyx_L1_error)
25645 __Pyx_GOTREF(__pyx_t_3);
25646 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
25647 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
25648 __pyx_r = __pyx_t_3;
25662 __Pyx_XDECREF(__pyx_t_1);
25663 __Pyx_XDECREF(__pyx_t_2);
25664 __Pyx_XDECREF(__pyx_t_3);
25665 __Pyx_AddTraceback(
"View.MemoryView.memoryview.nbytes.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25668 __Pyx_XGIVEREF(__pyx_r);
25669 __Pyx_RefNannyFinishContext();
25682 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4size_1__get__(PyObject *__pyx_v_self);
25683 static PyObject *__pyx_pw_15View_dot_MemoryView_10memoryview_4size_1__get__(PyObject *__pyx_v_self) {
25684 PyObject *__pyx_r = 0;
25685 __Pyx_RefNannyDeclarations
25686 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
25687 __pyx_r = __pyx_pf_15View_dot_MemoryView_10memoryview_4size___get__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25690 __Pyx_RefNannyFinishContext();
25694 static PyObject *__pyx_pf_15View_dot_MemoryView_10memoryview_4size___get__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25695 PyObject *__pyx_v_result = NULL;
25696 PyObject *__pyx_v_length = NULL;
25697 PyObject *__pyx_r = NULL;
25698 __Pyx_RefNannyDeclarations
25701 Py_ssize_t *__pyx_t_3;
25702 Py_ssize_t *__pyx_t_4;
25703 Py_ssize_t *__pyx_t_5;
25704 PyObject *__pyx_t_6 = NULL;
25705 int __pyx_lineno = 0;
25706 const char *__pyx_filename = NULL;
25707 int __pyx_clineno = 0;
25708 __Pyx_RefNannySetupContext(
"__get__", 0);
25717 __pyx_t_1 = (__pyx_v_self->_size == Py_None);
25718 __pyx_t_2 = (__pyx_t_1 != 0);
25728 __Pyx_INCREF(__pyx_int_1);
25729 __pyx_v_result = __pyx_int_1;
25738 __pyx_t_4 = (__pyx_v_self->view.shape + __pyx_v_self->view.ndim);
25739 for (__pyx_t_5 = __pyx_v_self->view.shape; __pyx_t_5 < __pyx_t_4; __pyx_t_5++) {
25740 __pyx_t_3 = __pyx_t_5;
25741 __pyx_t_6 = PyInt_FromSsize_t((__pyx_t_3[0]));
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 598, __pyx_L1_error)
25742 __Pyx_GOTREF(__pyx_t_6);
25743 __Pyx_XDECREF_SET(__pyx_v_length, __pyx_t_6);
25753 __pyx_t_6 = PyNumber_InPlaceMultiply(__pyx_v_result, __pyx_v_length);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 599, __pyx_L1_error)
25754 __Pyx_GOTREF(__pyx_t_6);
25755 __Pyx_DECREF_SET(__pyx_v_result, __pyx_t_6);
25766 __Pyx_INCREF(__pyx_v_result);
25767 __Pyx_GIVEREF(__pyx_v_result);
25768 __Pyx_GOTREF(__pyx_v_self->_size);
25769 __Pyx_DECREF(__pyx_v_self->_size);
25770 __pyx_v_self->_size = __pyx_v_result;
25788 __Pyx_XDECREF(__pyx_r);
25789 __Pyx_INCREF(__pyx_v_self->_size);
25790 __pyx_r = __pyx_v_self->_size;
25803 __Pyx_XDECREF(__pyx_t_6);
25804 __Pyx_AddTraceback(
"View.MemoryView.memoryview.size.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25807 __Pyx_XDECREF(__pyx_v_result);
25808 __Pyx_XDECREF(__pyx_v_length);
25809 __Pyx_XGIVEREF(__pyx_r);
25810 __Pyx_RefNannyFinishContext();
25823 static Py_ssize_t __pyx_memoryview___len__(PyObject *__pyx_v_self);
25824 static Py_ssize_t __pyx_memoryview___len__(PyObject *__pyx_v_self) {
25825 Py_ssize_t __pyx_r;
25826 __Pyx_RefNannyDeclarations
25827 __Pyx_RefNannySetupContext(
"__len__ (wrapper)", 0);
25828 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_10__len__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25831 __Pyx_RefNannyFinishContext();
25835 static Py_ssize_t __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_10__len__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25836 Py_ssize_t __pyx_r;
25837 __Pyx_RefNannyDeclarations
25839 __Pyx_RefNannySetupContext(
"__len__", 0);
25848 __pyx_t_1 = ((__pyx_v_self->view.ndim >= 1) != 0);
25858 __pyx_r = (__pyx_v_self->view.shape[0]);
25890 __Pyx_RefNannyFinishContext();
25903 static PyObject *__pyx_memoryview___repr__(PyObject *__pyx_v_self);
25904 static PyObject *__pyx_memoryview___repr__(PyObject *__pyx_v_self) {
25905 PyObject *__pyx_r = 0;
25906 __Pyx_RefNannyDeclarations
25907 __Pyx_RefNannySetupContext(
"__repr__ (wrapper)", 0);
25908 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_12__repr__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
25911 __Pyx_RefNannyFinishContext();
25915 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_12__repr__(
struct __pyx_memoryview_obj *__pyx_v_self) {
25916 PyObject *__pyx_r = NULL;
25917 __Pyx_RefNannyDeclarations
25918 PyObject *__pyx_t_1 = NULL;
25919 PyObject *__pyx_t_2 = NULL;
25920 PyObject *__pyx_t_3 = NULL;
25921 int __pyx_lineno = 0;
25922 const char *__pyx_filename = NULL;
25923 int __pyx_clineno = 0;
25924 __Pyx_RefNannySetupContext(
"__repr__", 0);
25933 __Pyx_XDECREF(__pyx_r);
25934 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_base);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 612, __pyx_L1_error)
25935 __Pyx_GOTREF(__pyx_t_1);
25936 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_class);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 612, __pyx_L1_error)
25937 __Pyx_GOTREF(__pyx_t_2);
25938 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
25939 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_name_2);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 612, __pyx_L1_error)
25940 __Pyx_GOTREF(__pyx_t_1);
25941 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
25950 __pyx_t_2 = __Pyx_PyObject_CallOneArg(__pyx_builtin_id, ((PyObject *)__pyx_v_self));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 613, __pyx_L1_error)
25951 __Pyx_GOTREF(__pyx_t_2);
25960 __pyx_t_3 = PyTuple_New(2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 612, __pyx_L1_error)
25961 __Pyx_GOTREF(__pyx_t_3);
25962 __Pyx_GIVEREF(__pyx_t_1);
25963 PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_1);
25964 __Pyx_GIVEREF(__pyx_t_2);
25965 PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_2);
25968 __pyx_t_2 = __Pyx_PyString_Format(__pyx_kp_s_MemoryView_of_r_at_0x_x, __pyx_t_3);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 612, __pyx_L1_error)
25969 __Pyx_GOTREF(__pyx_t_2);
25970 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
25971 __pyx_r = __pyx_t_2;
25985 __Pyx_XDECREF(__pyx_t_1);
25986 __Pyx_XDECREF(__pyx_t_2);
25987 __Pyx_XDECREF(__pyx_t_3);
25988 __Pyx_AddTraceback(
"View.MemoryView.memoryview.__repr__", __pyx_clineno, __pyx_lineno, __pyx_filename);
25991 __Pyx_XGIVEREF(__pyx_r);
25992 __Pyx_RefNannyFinishContext();
26005 static PyObject *__pyx_memoryview___str__(PyObject *__pyx_v_self);
26006 static PyObject *__pyx_memoryview___str__(PyObject *__pyx_v_self) {
26007 PyObject *__pyx_r = 0;
26008 __Pyx_RefNannyDeclarations
26009 __Pyx_RefNannySetupContext(
"__str__ (wrapper)", 0);
26010 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_14__str__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
26013 __Pyx_RefNannyFinishContext();
26017 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_14__str__(
struct __pyx_memoryview_obj *__pyx_v_self) {
26018 PyObject *__pyx_r = NULL;
26019 __Pyx_RefNannyDeclarations
26020 PyObject *__pyx_t_1 = NULL;
26021 PyObject *__pyx_t_2 = NULL;
26022 int __pyx_lineno = 0;
26023 const char *__pyx_filename = NULL;
26024 int __pyx_clineno = 0;
26025 __Pyx_RefNannySetupContext(
"__str__", 0);
26034 __Pyx_XDECREF(__pyx_r);
26035 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_base);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 616, __pyx_L1_error)
26036 __Pyx_GOTREF(__pyx_t_1);
26037 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_class);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 616, __pyx_L1_error)
26038 __Pyx_GOTREF(__pyx_t_2);
26039 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
26040 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_name_2);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 616, __pyx_L1_error)
26041 __Pyx_GOTREF(__pyx_t_1);
26042 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
26043 __pyx_t_2 = PyTuple_New(1);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 616, __pyx_L1_error)
26044 __Pyx_GOTREF(__pyx_t_2);
26045 __Pyx_GIVEREF(__pyx_t_1);
26046 PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1);
26048 __pyx_t_1 = __Pyx_PyString_Format(__pyx_kp_s_MemoryView_of_r_object, __pyx_t_2);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 616, __pyx_L1_error)
26049 __Pyx_GOTREF(__pyx_t_1);
26050 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
26051 __pyx_r = __pyx_t_1;
26065 __Pyx_XDECREF(__pyx_t_1);
26066 __Pyx_XDECREF(__pyx_t_2);
26067 __Pyx_AddTraceback(
"View.MemoryView.memoryview.__str__", __pyx_clineno, __pyx_lineno, __pyx_filename);
26070 __Pyx_XGIVEREF(__pyx_r);
26071 __Pyx_RefNannyFinishContext();
26084 static PyObject *__pyx_memoryview_is_c_contig(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
26085 static PyObject *__pyx_memoryview_is_c_contig(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
26086 PyObject *__pyx_r = 0;
26087 __Pyx_RefNannyDeclarations
26088 __Pyx_RefNannySetupContext(
"is_c_contig (wrapper)", 0);
26089 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_16is_c_contig(((
struct __pyx_memoryview_obj *)__pyx_v_self));
26092 __Pyx_RefNannyFinishContext();
26096 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_16is_c_contig(
struct __pyx_memoryview_obj *__pyx_v_self) {
26097 __Pyx_memviewslice *__pyx_v_mslice;
26098 __Pyx_memviewslice __pyx_v_tmp;
26099 PyObject *__pyx_r = NULL;
26100 __Pyx_RefNannyDeclarations
26101 __Pyx_memviewslice *__pyx_t_1;
26102 PyObject *__pyx_t_2 = NULL;
26103 int __pyx_lineno = 0;
26104 const char *__pyx_filename = NULL;
26105 int __pyx_clineno = 0;
26106 __Pyx_RefNannySetupContext(
"is_c_contig", 0);
26115 __pyx_t_1 = __pyx_memoryview_get_slice_from_memoryview(__pyx_v_self, (&__pyx_v_tmp));
if (unlikely(__pyx_t_1 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(0, 622, __pyx_L1_error)
26116 __pyx_v_mslice = __pyx_t_1;
26125 __Pyx_XDECREF(__pyx_r);
26126 __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_memviewslice_is_contig((__pyx_v_mslice[0]),
'C', __pyx_v_self->view.ndim));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 623, __pyx_L1_error)
26127 __Pyx_GOTREF(__pyx_t_2);
26128 __pyx_r = __pyx_t_2;
26142 __Pyx_XDECREF(__pyx_t_2);
26143 __Pyx_AddTraceback(
"View.MemoryView.memoryview.is_c_contig", __pyx_clineno, __pyx_lineno, __pyx_filename);
26146 __Pyx_XGIVEREF(__pyx_r);
26147 __Pyx_RefNannyFinishContext();
26160 static PyObject *__pyx_memoryview_is_f_contig(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
26161 static PyObject *__pyx_memoryview_is_f_contig(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
26162 PyObject *__pyx_r = 0;
26163 __Pyx_RefNannyDeclarations
26164 __Pyx_RefNannySetupContext(
"is_f_contig (wrapper)", 0);
26165 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_18is_f_contig(((
struct __pyx_memoryview_obj *)__pyx_v_self));
26168 __Pyx_RefNannyFinishContext();
26172 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_18is_f_contig(
struct __pyx_memoryview_obj *__pyx_v_self) {
26173 __Pyx_memviewslice *__pyx_v_mslice;
26174 __Pyx_memviewslice __pyx_v_tmp;
26175 PyObject *__pyx_r = NULL;
26176 __Pyx_RefNannyDeclarations
26177 __Pyx_memviewslice *__pyx_t_1;
26178 PyObject *__pyx_t_2 = NULL;
26179 int __pyx_lineno = 0;
26180 const char *__pyx_filename = NULL;
26181 int __pyx_clineno = 0;
26182 __Pyx_RefNannySetupContext(
"is_f_contig", 0);
26191 __pyx_t_1 = __pyx_memoryview_get_slice_from_memoryview(__pyx_v_self, (&__pyx_v_tmp));
if (unlikely(__pyx_t_1 == ((__Pyx_memviewslice *)NULL))) __PYX_ERR(0, 628, __pyx_L1_error)
26192 __pyx_v_mslice = __pyx_t_1;
26201 __Pyx_XDECREF(__pyx_r);
26202 __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_memviewslice_is_contig((__pyx_v_mslice[0]),
'F', __pyx_v_self->view.ndim));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 629, __pyx_L1_error)
26203 __Pyx_GOTREF(__pyx_t_2);
26204 __pyx_r = __pyx_t_2;
26218 __Pyx_XDECREF(__pyx_t_2);
26219 __Pyx_AddTraceback(
"View.MemoryView.memoryview.is_f_contig", __pyx_clineno, __pyx_lineno, __pyx_filename);
26222 __Pyx_XGIVEREF(__pyx_r);
26223 __Pyx_RefNannyFinishContext();
26236 static PyObject *__pyx_memoryview_copy(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
26237 static PyObject *__pyx_memoryview_copy(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
26238 PyObject *__pyx_r = 0;
26239 __Pyx_RefNannyDeclarations
26240 __Pyx_RefNannySetupContext(
"copy (wrapper)", 0);
26241 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_20copy(((
struct __pyx_memoryview_obj *)__pyx_v_self));
26244 __Pyx_RefNannyFinishContext();
26248 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_20copy(
struct __pyx_memoryview_obj *__pyx_v_self) {
26249 __Pyx_memviewslice __pyx_v_mslice;
26251 PyObject *__pyx_r = NULL;
26252 __Pyx_RefNannyDeclarations
26253 __Pyx_memviewslice __pyx_t_1;
26254 PyObject *__pyx_t_2 = NULL;
26255 int __pyx_lineno = 0;
26256 const char *__pyx_filename = NULL;
26257 int __pyx_clineno = 0;
26258 __Pyx_RefNannySetupContext(
"copy", 0);
26267 __pyx_v_flags = (__pyx_v_self->flags & (~PyBUF_F_CONTIGUOUS));
26276 __pyx_memoryview_slice_copy(__pyx_v_self, (&__pyx_v_mslice));
26285 __pyx_t_1 = __pyx_memoryview_copy_new_contig((&__pyx_v_mslice), ((
char *)
"c"), __pyx_v_self->view.ndim, __pyx_v_self->view.itemsize, (__pyx_v_flags | PyBUF_C_CONTIGUOUS), __pyx_v_self->dtype_is_object);
if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 636, __pyx_L1_error)
26286 __pyx_v_mslice = __pyx_t_1;
26295 __Pyx_XDECREF(__pyx_r);
26296 __pyx_t_2 = __pyx_memoryview_copy_object_from_slice(__pyx_v_self, (&__pyx_v_mslice));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 641, __pyx_L1_error)
26297 __Pyx_GOTREF(__pyx_t_2);
26298 __pyx_r = __pyx_t_2;
26312 __Pyx_XDECREF(__pyx_t_2);
26313 __Pyx_AddTraceback(
"View.MemoryView.memoryview.copy", __pyx_clineno, __pyx_lineno, __pyx_filename);
26316 __Pyx_XGIVEREF(__pyx_r);
26317 __Pyx_RefNannyFinishContext();
26330 static PyObject *__pyx_memoryview_copy_fortran(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
26331 static PyObject *__pyx_memoryview_copy_fortran(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
26332 PyObject *__pyx_r = 0;
26333 __Pyx_RefNannyDeclarations
26334 __Pyx_RefNannySetupContext(
"copy_fortran (wrapper)", 0);
26335 __pyx_r = __pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_22copy_fortran(((
struct __pyx_memoryview_obj *)__pyx_v_self));
26338 __Pyx_RefNannyFinishContext();
26342 static PyObject *__pyx_memoryview___pyx_pf_15View_dot_MemoryView_10memoryview_22copy_fortran(
struct __pyx_memoryview_obj *__pyx_v_self) {
26343 __Pyx_memviewslice __pyx_v_src;
26344 __Pyx_memviewslice __pyx_v_dst;
26346 PyObject *__pyx_r = NULL;
26347 __Pyx_RefNannyDeclarations
26348 __Pyx_memviewslice __pyx_t_1;
26349 PyObject *__pyx_t_2 = NULL;
26350 int __pyx_lineno = 0;
26351 const char *__pyx_filename = NULL;
26352 int __pyx_clineno = 0;
26353 __Pyx_RefNannySetupContext(
"copy_fortran", 0);
26362 __pyx_v_flags = (__pyx_v_self->flags & (~PyBUF_C_CONTIGUOUS));
26371 __pyx_memoryview_slice_copy(__pyx_v_self, (&__pyx_v_src));
26380 __pyx_t_1 = __pyx_memoryview_copy_new_contig((&__pyx_v_src), ((
char *)
"fortran"), __pyx_v_self->view.ndim, __pyx_v_self->view.itemsize, (__pyx_v_flags | PyBUF_F_CONTIGUOUS), __pyx_v_self->dtype_is_object);
if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 648, __pyx_L1_error)
26381 __pyx_v_dst = __pyx_t_1;
26390 __Pyx_XDECREF(__pyx_r);
26391 __pyx_t_2 = __pyx_memoryview_copy_object_from_slice(__pyx_v_self, (&__pyx_v_dst));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 653, __pyx_L1_error)
26392 __Pyx_GOTREF(__pyx_t_2);
26393 __pyx_r = __pyx_t_2;
26407 __Pyx_XDECREF(__pyx_t_2);
26408 __Pyx_AddTraceback(
"View.MemoryView.memoryview.copy_fortran", __pyx_clineno, __pyx_lineno, __pyx_filename);
26411 __Pyx_XGIVEREF(__pyx_r);
26412 __Pyx_RefNannyFinishContext();
26423 static PyObject *__pyx_pw___pyx_memoryview_1__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
26424 static PyObject *__pyx_pw___pyx_memoryview_1__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
26425 PyObject *__pyx_r = 0;
26426 __Pyx_RefNannyDeclarations
26427 __Pyx_RefNannySetupContext(
"__reduce_cython__ (wrapper)", 0);
26428 __pyx_r = __pyx_pf___pyx_memoryview___reduce_cython__(((
struct __pyx_memoryview_obj *)__pyx_v_self));
26431 __Pyx_RefNannyFinishContext();
26435 static PyObject *__pyx_pf___pyx_memoryview___reduce_cython__(CYTHON_UNUSED
struct __pyx_memoryview_obj *__pyx_v_self) {
26436 PyObject *__pyx_r = NULL;
26437 __Pyx_RefNannyDeclarations
26438 PyObject *__pyx_t_1 = NULL;
26439 int __pyx_lineno = 0;
26440 const char *__pyx_filename = NULL;
26441 int __pyx_clineno = 0;
26442 __Pyx_RefNannySetupContext(
"__reduce_cython__", 0);
26450 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__20, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 2, __pyx_L1_error)
26451 __Pyx_GOTREF(__pyx_t_1);
26452 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
26453 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
26454 __PYX_ERR(0, 2, __pyx_L1_error)
26464 __Pyx_XDECREF(__pyx_t_1);
26465 __Pyx_AddTraceback(
"View.MemoryView.memoryview.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
26467 __Pyx_XGIVEREF(__pyx_r);
26468 __Pyx_RefNannyFinishContext();
26480 static PyObject *__pyx_pw___pyx_memoryview_3__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state);
26481 static PyObject *__pyx_pw___pyx_memoryview_3__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
26482 PyObject *__pyx_r = 0;
26483 __Pyx_RefNannyDeclarations
26484 __Pyx_RefNannySetupContext(
"__setstate_cython__ (wrapper)", 0);
26485 __pyx_r = __pyx_pf___pyx_memoryview_2__setstate_cython__(((
struct __pyx_memoryview_obj *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
26488 __Pyx_RefNannyFinishContext();
26492 static PyObject *__pyx_pf___pyx_memoryview_2__setstate_cython__(CYTHON_UNUSED
struct __pyx_memoryview_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
26493 PyObject *__pyx_r = NULL;
26494 __Pyx_RefNannyDeclarations
26495 PyObject *__pyx_t_1 = NULL;
26496 int __pyx_lineno = 0;
26497 const char *__pyx_filename = NULL;
26498 int __pyx_clineno = 0;
26499 __Pyx_RefNannySetupContext(
"__setstate_cython__", 0);
26506 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__21, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 4, __pyx_L1_error)
26507 __Pyx_GOTREF(__pyx_t_1);
26508 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
26509 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
26510 __PYX_ERR(0, 4, __pyx_L1_error)
26521 __Pyx_XDECREF(__pyx_t_1);
26522 __Pyx_AddTraceback(
"View.MemoryView.memoryview.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
26524 __Pyx_XGIVEREF(__pyx_r);
26525 __Pyx_RefNannyFinishContext();
26537 static PyObject *__pyx_memoryview_new(PyObject *__pyx_v_o,
int __pyx_v_flags,
int __pyx_v_dtype_is_object, __Pyx_TypeInfo *__pyx_v_typeinfo) {
26538 struct __pyx_memoryview_obj *__pyx_v_result = 0;
26539 PyObject *__pyx_r = NULL;
26540 __Pyx_RefNannyDeclarations
26541 PyObject *__pyx_t_1 = NULL;
26542 PyObject *__pyx_t_2 = NULL;
26543 PyObject *__pyx_t_3 = NULL;
26544 int __pyx_lineno = 0;
26545 const char *__pyx_filename = NULL;
26546 int __pyx_clineno = 0;
26547 __Pyx_RefNannySetupContext(
"memoryview_cwrapper", 0);
26556 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_flags);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 658, __pyx_L1_error)
26557 __Pyx_GOTREF(__pyx_t_1);
26558 __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_v_dtype_is_object);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 658, __pyx_L1_error)
26559 __Pyx_GOTREF(__pyx_t_2);
26560 __pyx_t_3 = PyTuple_New(3);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 658, __pyx_L1_error)
26561 __Pyx_GOTREF(__pyx_t_3);
26562 __Pyx_INCREF(__pyx_v_o);
26563 __Pyx_GIVEREF(__pyx_v_o);
26564 PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_o);
26565 __Pyx_GIVEREF(__pyx_t_1);
26566 PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1);
26567 __Pyx_GIVEREF(__pyx_t_2);
26568 PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2);
26571 __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_memoryview_type), __pyx_t_3, NULL);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 658, __pyx_L1_error)
26572 __Pyx_GOTREF(__pyx_t_2);
26573 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
26574 __pyx_v_result = ((
struct __pyx_memoryview_obj *)__pyx_t_2);
26584 __pyx_v_result->typeinfo = __pyx_v_typeinfo;
26593 __Pyx_XDECREF(__pyx_r);
26594 __Pyx_INCREF(((PyObject *)__pyx_v_result));
26595 __pyx_r = ((PyObject *)__pyx_v_result);
26608 __Pyx_XDECREF(__pyx_t_1);
26609 __Pyx_XDECREF(__pyx_t_2);
26610 __Pyx_XDECREF(__pyx_t_3);
26611 __Pyx_AddTraceback(
"View.MemoryView.memoryview_cwrapper", __pyx_clineno, __pyx_lineno, __pyx_filename);
26614 __Pyx_XDECREF((PyObject *)__pyx_v_result);
26615 __Pyx_XGIVEREF(__pyx_r);
26616 __Pyx_RefNannyFinishContext();
26628 static CYTHON_INLINE
int __pyx_memoryview_check(PyObject *__pyx_v_o) {
26630 __Pyx_RefNannyDeclarations
26632 __Pyx_RefNannySetupContext(
"memoryview_check", 0);
26641 __pyx_t_1 = __Pyx_TypeCheck(__pyx_v_o, __pyx_memoryview_type);
26642 __pyx_r = __pyx_t_1;
26655 __Pyx_RefNannyFinishContext();
26667 static PyObject *_unellipsify(PyObject *__pyx_v_index,
int __pyx_v_ndim) {
26668 PyObject *__pyx_v_tup = NULL;
26669 PyObject *__pyx_v_result = NULL;
26670 int __pyx_v_have_slices;
26671 int __pyx_v_seen_ellipsis;
26672 CYTHON_UNUSED PyObject *__pyx_v_idx = NULL;
26673 PyObject *__pyx_v_item = NULL;
26674 Py_ssize_t __pyx_v_nslices;
26675 PyObject *__pyx_r = NULL;
26676 __Pyx_RefNannyDeclarations
26679 PyObject *__pyx_t_3 = NULL;
26680 PyObject *__pyx_t_4 = NULL;
26681 Py_ssize_t __pyx_t_5;
26682 PyObject *(*__pyx_t_6)(PyObject *);
26683 PyObject *__pyx_t_7 = NULL;
26684 Py_ssize_t __pyx_t_8;
26687 PyObject *__pyx_t_11 = NULL;
26688 int __pyx_lineno = 0;
26689 const char *__pyx_filename = NULL;
26690 int __pyx_clineno = 0;
26691 __Pyx_RefNannySetupContext(
"_unellipsify", 0);
26700 __pyx_t_1 = PyTuple_Check(__pyx_v_index);
26701 __pyx_t_2 = ((!(__pyx_t_1 != 0)) != 0);
26711 __pyx_t_3 = PyTuple_New(1);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 672, __pyx_L1_error)
26712 __Pyx_GOTREF(__pyx_t_3);
26713 __Pyx_INCREF(__pyx_v_index);
26714 __Pyx_GIVEREF(__pyx_v_index);
26715 PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_index);
26716 __pyx_v_tup = __pyx_t_3;
26737 __Pyx_INCREF(__pyx_v_index);
26738 __pyx_v_tup = __pyx_v_index;
26749 __pyx_t_3 = PyList_New(0);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 676, __pyx_L1_error)
26750 __Pyx_GOTREF(__pyx_t_3);
26751 __pyx_v_result = ((PyObject*)__pyx_t_3);
26761 __pyx_v_have_slices = 0;
26770 __pyx_v_seen_ellipsis = 0;
26779 __Pyx_INCREF(__pyx_int_0);
26780 __pyx_t_3 = __pyx_int_0;
26781 if (likely(PyList_CheckExact(__pyx_v_tup)) || PyTuple_CheckExact(__pyx_v_tup)) {
26782 __pyx_t_4 = __pyx_v_tup; __Pyx_INCREF(__pyx_t_4); __pyx_t_5 = 0;
26785 __pyx_t_5 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_v_tup);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 679, __pyx_L1_error)
26786 __Pyx_GOTREF(__pyx_t_4);
26787 __pyx_t_6 = Py_TYPE(__pyx_t_4)->tp_iternext;
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 679, __pyx_L1_error)
26790 if (likely(!__pyx_t_6)) {
26791 if (likely(PyList_CheckExact(__pyx_t_4))) {
26792 if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_4))
break;
26793 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
26794 __pyx_t_7 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_7); __pyx_t_5++;
if (unlikely(0 < 0)) __PYX_ERR(0, 679, __pyx_L1_error)
26796 __pyx_t_7 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++;
if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 679, __pyx_L1_error)
26797 __Pyx_GOTREF(__pyx_t_7);
26800 if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_4))
break;
26801 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
26802 __pyx_t_7 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_7); __pyx_t_5++;
if (unlikely(0 < 0)) __PYX_ERR(0, 679, __pyx_L1_error)
26804 __pyx_t_7 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++;
if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 679, __pyx_L1_error)
26805 __Pyx_GOTREF(__pyx_t_7);
26809 __pyx_t_7 = __pyx_t_6(__pyx_t_4);
26810 if (unlikely(!__pyx_t_7)) {
26811 PyObject* exc_type = PyErr_Occurred();
26813 if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
26814 else __PYX_ERR(0, 679, __pyx_L1_error)
26818 __Pyx_GOTREF(__pyx_t_7);
26820 __Pyx_XDECREF_SET(__pyx_v_item, __pyx_t_7);
26822 __Pyx_INCREF(__pyx_t_3);
26823 __Pyx_XDECREF_SET(__pyx_v_idx, __pyx_t_3);
26824 __pyx_t_7 = __Pyx_PyInt_AddObjC(__pyx_t_3, __pyx_int_1, 1, 0, 0);
if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 679, __pyx_L1_error)
26825 __Pyx_GOTREF(__pyx_t_7);
26826 __Pyx_DECREF(__pyx_t_3);
26827 __pyx_t_3 = __pyx_t_7;
26837 __pyx_t_2 = (__pyx_v_item == __pyx_builtin_Ellipsis);
26838 __pyx_t_1 = (__pyx_t_2 != 0);
26848 __pyx_t_1 = ((!(__pyx_v_seen_ellipsis != 0)) != 0);
26858 __pyx_t_8 = PyObject_Length(__pyx_v_tup);
if (unlikely(__pyx_t_8 == ((Py_ssize_t)-1))) __PYX_ERR(0, 682, __pyx_L1_error)
26859 __pyx_t_7 = PyList_New(1 * ((((__pyx_v_ndim - __pyx_t_8) + 1)<0) ? 0:((__pyx_v_ndim - __pyx_t_8) + 1)));
if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 682, __pyx_L1_error)
26860 __Pyx_GOTREF(__pyx_t_7);
26861 { Py_ssize_t __pyx_temp;
26862 for (__pyx_temp=0; __pyx_temp < ((__pyx_v_ndim - __pyx_t_8) + 1); __pyx_temp++) {
26863 __Pyx_INCREF(__pyx_slice__22);
26864 __Pyx_GIVEREF(__pyx_slice__22);
26865 PyList_SET_ITEM(__pyx_t_7, __pyx_temp, __pyx_slice__22);
26868 __pyx_t_9 = __Pyx_PyList_Extend(__pyx_v_result, __pyx_t_7);
if (unlikely(__pyx_t_9 == ((
int)-1))) __PYX_ERR(0, 682, __pyx_L1_error)
26869 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
26878 __pyx_v_seen_ellipsis = 1;
26898 __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_result, __pyx_slice__22);
if (unlikely(__pyx_t_9 == ((
int)-1))) __PYX_ERR(0, 685, __pyx_L1_error)
26909 __pyx_v_have_slices = 1;
26929 __pyx_t_2 = PySlice_Check(__pyx_v_item);
26930 __pyx_t_10 = ((!(__pyx_t_2 != 0)) != 0);
26933 __pyx_t_1 = __pyx_t_10;
26934 goto __pyx_L9_bool_binop_done;
26936 __pyx_t_10 = ((!(PyIndex_Check(__pyx_v_item) != 0)) != 0);
26937 __pyx_t_1 = __pyx_t_10;
26938 __pyx_L9_bool_binop_done:;
26939 if (unlikely(__pyx_t_1)) {
26948 __pyx_t_7 = __Pyx_PyString_FormatSafe(__pyx_kp_s_Cannot_index_with_type_s, ((PyObject *)Py_TYPE(__pyx_v_item)));
if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 689, __pyx_L1_error)
26949 __Pyx_GOTREF(__pyx_t_7);
26950 __pyx_t_11 = __Pyx_PyObject_CallOneArg(__pyx_builtin_TypeError, __pyx_t_7);
if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 689, __pyx_L1_error)
26951 __Pyx_GOTREF(__pyx_t_11);
26952 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
26953 __Pyx_Raise(__pyx_t_11, 0, 0, 0);
26954 __Pyx_DECREF(__pyx_t_11); __pyx_t_11 = 0;
26955 __PYX_ERR(0, 689, __pyx_L1_error)
26973 __pyx_t_10 = (__pyx_v_have_slices != 0);
26976 __pyx_t_1 = __pyx_t_10;
26977 goto __pyx_L11_bool_binop_done;
26979 __pyx_t_10 = PySlice_Check(__pyx_v_item);
26980 __pyx_t_2 = (__pyx_t_10 != 0);
26981 __pyx_t_1 = __pyx_t_2;
26982 __pyx_L11_bool_binop_done:;
26983 __pyx_v_have_slices = __pyx_t_1;
26992 __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_result, __pyx_v_item);
if (unlikely(__pyx_t_9 == ((
int)-1))) __PYX_ERR(0, 692, __pyx_L1_error)
27004 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
27005 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
27014 __pyx_t_5 = PyList_GET_SIZE(__pyx_v_result);
if (unlikely(__pyx_t_5 == ((Py_ssize_t)-1))) __PYX_ERR(0, 694, __pyx_L1_error)
27015 __pyx_v_nslices = (__pyx_v_ndim - __pyx_t_5);
27024 __pyx_t_1 = (__pyx_v_nslices != 0);
27034 __pyx_t_3 = PyList_New(1 * ((__pyx_v_nslices<0) ? 0:__pyx_v_nslices));
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 696, __pyx_L1_error)
27035 __Pyx_GOTREF(__pyx_t_3);
27036 { Py_ssize_t __pyx_temp;
27037 for (__pyx_temp=0; __pyx_temp < __pyx_v_nslices; __pyx_temp++) {
27038 __Pyx_INCREF(__pyx_slice__22);
27039 __Pyx_GIVEREF(__pyx_slice__22);
27040 PyList_SET_ITEM(__pyx_t_3, __pyx_temp, __pyx_slice__22);
27043 __pyx_t_9 = __Pyx_PyList_Extend(__pyx_v_result, __pyx_t_3);
if (unlikely(__pyx_t_9 == ((
int)-1))) __PYX_ERR(0, 696, __pyx_L1_error)
27044 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
27062 __Pyx_XDECREF(__pyx_r);
27063 if (!__pyx_v_have_slices) {
27065 __pyx_t_4 = __Pyx_PyBool_FromLong(__pyx_v_have_slices);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 698, __pyx_L1_error)
27066 __Pyx_GOTREF(__pyx_t_4);
27067 __pyx_t_3 = __pyx_t_4;
27069 goto __pyx_L14_bool_binop_done;
27071 __pyx_t_4 = PyInt_FromSsize_t(__pyx_v_nslices);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 698, __pyx_L1_error)
27072 __Pyx_GOTREF(__pyx_t_4);
27073 __pyx_t_3 = __pyx_t_4;
27075 __pyx_L14_bool_binop_done:;
27076 __pyx_t_4 = PyList_AsTuple(__pyx_v_result);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 698, __pyx_L1_error)
27077 __Pyx_GOTREF(__pyx_t_4);
27078 __pyx_t_11 = PyTuple_New(2);
if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 698, __pyx_L1_error)
27079 __Pyx_GOTREF(__pyx_t_11);
27080 __Pyx_GIVEREF(__pyx_t_3);
27081 PyTuple_SET_ITEM(__pyx_t_11, 0, __pyx_t_3);
27082 __Pyx_GIVEREF(__pyx_t_4);
27083 PyTuple_SET_ITEM(__pyx_t_11, 1, __pyx_t_4);
27086 __pyx_r = ((PyObject*)__pyx_t_11);
27100 __Pyx_XDECREF(__pyx_t_3);
27101 __Pyx_XDECREF(__pyx_t_4);
27102 __Pyx_XDECREF(__pyx_t_7);
27103 __Pyx_XDECREF(__pyx_t_11);
27104 __Pyx_AddTraceback(
"View.MemoryView._unellipsify", __pyx_clineno, __pyx_lineno, __pyx_filename);
27107 __Pyx_XDECREF(__pyx_v_tup);
27108 __Pyx_XDECREF(__pyx_v_result);
27109 __Pyx_XDECREF(__pyx_v_idx);
27110 __Pyx_XDECREF(__pyx_v_item);
27111 __Pyx_XGIVEREF(__pyx_r);
27112 __Pyx_RefNannyFinishContext();
27124 static PyObject *assert_direct_dimensions(Py_ssize_t *__pyx_v_suboffsets,
int __pyx_v_ndim) {
27125 Py_ssize_t __pyx_v_suboffset;
27126 PyObject *__pyx_r = NULL;
27127 __Pyx_RefNannyDeclarations
27128 Py_ssize_t *__pyx_t_1;
27129 Py_ssize_t *__pyx_t_2;
27130 Py_ssize_t *__pyx_t_3;
27132 PyObject *__pyx_t_5 = NULL;
27133 int __pyx_lineno = 0;
27134 const char *__pyx_filename = NULL;
27135 int __pyx_clineno = 0;
27136 __Pyx_RefNannySetupContext(
"assert_direct_dimensions", 0);
27145 __pyx_t_2 = (__pyx_v_suboffsets + __pyx_v_ndim);
27146 for (__pyx_t_3 = __pyx_v_suboffsets; __pyx_t_3 < __pyx_t_2; __pyx_t_3++) {
27147 __pyx_t_1 = __pyx_t_3;
27148 __pyx_v_suboffset = (__pyx_t_1[0]);
27157 __pyx_t_4 = ((__pyx_v_suboffset >= 0) != 0);
27158 if (unlikely(__pyx_t_4)) {
27167 __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__23, NULL);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 703, __pyx_L1_error)
27168 __Pyx_GOTREF(__pyx_t_5);
27169 __Pyx_Raise(__pyx_t_5, 0, 0, 0);
27170 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
27171 __PYX_ERR(0, 703, __pyx_L1_error)
27192 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
27195 __Pyx_XDECREF(__pyx_t_5);
27196 __Pyx_AddTraceback(
"View.MemoryView.assert_direct_dimensions", __pyx_clineno, __pyx_lineno, __pyx_filename);
27199 __Pyx_XGIVEREF(__pyx_r);
27200 __Pyx_RefNannyFinishContext();
27212 static struct __pyx_memoryview_obj *__pyx_memview_slice(
struct __pyx_memoryview_obj *__pyx_v_memview, PyObject *__pyx_v_indices) {
27213 int __pyx_v_new_ndim;
27214 int __pyx_v_suboffset_dim;
27216 __Pyx_memviewslice __pyx_v_src;
27217 __Pyx_memviewslice __pyx_v_dst;
27218 __Pyx_memviewslice *__pyx_v_p_src;
27219 struct __pyx_memoryviewslice_obj *__pyx_v_memviewsliceobj = 0;
27220 __Pyx_memviewslice *__pyx_v_p_dst;
27221 int *__pyx_v_p_suboffset_dim;
27222 Py_ssize_t __pyx_v_start;
27223 Py_ssize_t __pyx_v_stop;
27224 Py_ssize_t __pyx_v_step;
27225 int __pyx_v_have_start;
27226 int __pyx_v_have_stop;
27227 int __pyx_v_have_step;
27228 PyObject *__pyx_v_index = NULL;
27229 struct __pyx_memoryview_obj *__pyx_r = NULL;
27230 __Pyx_RefNannyDeclarations
27233 PyObject *__pyx_t_3 = NULL;
27234 struct __pyx_memoryview_obj *__pyx_t_4;
27237 Py_ssize_t __pyx_t_7;
27238 PyObject *(*__pyx_t_8)(PyObject *);
27239 PyObject *__pyx_t_9 = NULL;
27240 Py_ssize_t __pyx_t_10;
27242 Py_ssize_t __pyx_t_12;
27243 int __pyx_lineno = 0;
27244 const char *__pyx_filename = NULL;
27245 int __pyx_clineno = 0;
27246 __Pyx_RefNannySetupContext(
"memview_slice", 0);
27255 __pyx_v_new_ndim = 0;
27256 __pyx_v_suboffset_dim = -1;
27265 (void)(memset((&__pyx_v_dst), 0, (
sizeof(__pyx_v_dst))));
27274 #ifndef CYTHON_WITHOUT_ASSERTIONS
27275 if (unlikely(!Py_OptimizeFlag)) {
27276 if (unlikely(!((__pyx_v_memview->view.ndim > 0) != 0))) {
27277 PyErr_SetNone(PyExc_AssertionError);
27278 __PYX_ERR(0, 722, __pyx_L1_error)
27290 __pyx_t_1 = __Pyx_TypeCheck(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type);
27291 __pyx_t_2 = (__pyx_t_1 != 0);
27301 if (!(likely(((((PyObject *)__pyx_v_memview)) == Py_None) || likely(__Pyx_TypeTest(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type))))) __PYX_ERR(0, 725, __pyx_L1_error)
27302 __pyx_t_3 = ((PyObject *)__pyx_v_memview);
27303 __Pyx_INCREF(__pyx_t_3);
27304 __pyx_v_memviewsliceobj = ((
struct __pyx_memoryviewslice_obj *)__pyx_t_3);
27314 __pyx_v_p_src = (&__pyx_v_memviewsliceobj->from_slice);
27334 __pyx_memoryview_slice_copy(__pyx_v_memview, (&__pyx_v_src));
27343 __pyx_v_p_src = (&__pyx_v_src);
27354 __pyx_t_4 = __pyx_v_p_src->memview;
27355 __pyx_v_dst.memview = __pyx_t_4;
27364 __pyx_t_5 = __pyx_v_p_src->data;
27365 __pyx_v_dst.data = __pyx_t_5;
27374 __pyx_v_p_dst = (&__pyx_v_dst);
27383 __pyx_v_p_suboffset_dim = (&__pyx_v_suboffset_dim);
27393 if (likely(PyList_CheckExact(__pyx_v_indices)) || PyTuple_CheckExact(__pyx_v_indices)) {
27394 __pyx_t_3 = __pyx_v_indices; __Pyx_INCREF(__pyx_t_3); __pyx_t_7 = 0;
27397 __pyx_t_7 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_v_indices);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 746, __pyx_L1_error)
27398 __Pyx_GOTREF(__pyx_t_3);
27399 __pyx_t_8 = Py_TYPE(__pyx_t_3)->tp_iternext;
if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 746, __pyx_L1_error)
27402 if (likely(!__pyx_t_8)) {
27403 if (likely(PyList_CheckExact(__pyx_t_3))) {
27404 if (__pyx_t_7 >= PyList_GET_SIZE(__pyx_t_3))
break;
27405 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
27406 __pyx_t_9 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_7); __Pyx_INCREF(__pyx_t_9); __pyx_t_7++;
if (unlikely(0 < 0)) __PYX_ERR(0, 746, __pyx_L1_error)
27408 __pyx_t_9 = PySequence_ITEM(__pyx_t_3, __pyx_t_7); __pyx_t_7++;
if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 746, __pyx_L1_error)
27409 __Pyx_GOTREF(__pyx_t_9);
27412 if (__pyx_t_7 >= PyTuple_GET_SIZE(__pyx_t_3))
break;
27413 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
27414 __pyx_t_9 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_7); __Pyx_INCREF(__pyx_t_9); __pyx_t_7++;
if (unlikely(0 < 0)) __PYX_ERR(0, 746, __pyx_L1_error)
27416 __pyx_t_9 = PySequence_ITEM(__pyx_t_3, __pyx_t_7); __pyx_t_7++;
if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 746, __pyx_L1_error)
27417 __Pyx_GOTREF(__pyx_t_9);
27421 __pyx_t_9 = __pyx_t_8(__pyx_t_3);
27422 if (unlikely(!__pyx_t_9)) {
27423 PyObject* exc_type = PyErr_Occurred();
27425 if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
27426 else __PYX_ERR(0, 746, __pyx_L1_error)
27430 __Pyx_GOTREF(__pyx_t_9);
27432 __Pyx_XDECREF_SET(__pyx_v_index, __pyx_t_9);
27434 __pyx_v_dim = __pyx_t_6;
27435 __pyx_t_6 = (__pyx_t_6 + 1);
27444 __pyx_t_2 = (PyIndex_Check(__pyx_v_index) != 0);
27454 __pyx_t_10 = __Pyx_PyIndex_AsSsize_t(__pyx_v_index);
if (unlikely((__pyx_t_10 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 751, __pyx_L1_error)
27463 __pyx_t_11 = __pyx_memoryview_slice_memviewslice(__pyx_v_p_dst, (__pyx_v_p_src->shape[__pyx_v_dim]), (__pyx_v_p_src->strides[__pyx_v_dim]), (__pyx_v_p_src->suboffsets[__pyx_v_dim]), __pyx_v_dim, __pyx_v_new_ndim, __pyx_v_p_suboffset_dim, __pyx_t_10, 0, 0, 0, 0, 0, 0);
if (unlikely(__pyx_t_11 == ((
int)-1))) __PYX_ERR(0, 748, __pyx_L1_error)
27482 __pyx_t_2 = (__pyx_v_index == Py_None);
27483 __pyx_t_1 = (__pyx_t_2 != 0);
27493 (__pyx_v_p_dst->shape[__pyx_v_new_ndim]) = 1;
27502 (__pyx_v_p_dst->strides[__pyx_v_new_ndim]) = 0;
27511 (__pyx_v_p_dst->suboffsets[__pyx_v_new_ndim]) = -1
L;
27520 __pyx_v_new_ndim = (__pyx_v_new_ndim + 1);
27540 __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_start);
if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 760, __pyx_L1_error)
27541 __Pyx_GOTREF(__pyx_t_9);
27542 __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_9);
if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 760, __pyx_L1_error)
27544 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
27546 __pyx_t_12 = __Pyx_PyIndex_AsSsize_t(__pyx_t_9);
if (unlikely((__pyx_t_12 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 760, __pyx_L1_error)
27547 __pyx_t_10 = __pyx_t_12;
27548 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
27549 goto __pyx_L7_bool_binop_done;
27552 __pyx_L7_bool_binop_done:;
27553 __pyx_v_start = __pyx_t_10;
27562 __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_stop);
if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 761, __pyx_L1_error)
27563 __Pyx_GOTREF(__pyx_t_9);
27564 __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_9);
if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 761, __pyx_L1_error)
27566 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
27568 __pyx_t_12 = __Pyx_PyIndex_AsSsize_t(__pyx_t_9);
if (unlikely((__pyx_t_12 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 761, __pyx_L1_error)
27569 __pyx_t_10 = __pyx_t_12;
27570 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
27571 goto __pyx_L9_bool_binop_done;
27574 __pyx_L9_bool_binop_done:;
27575 __pyx_v_stop = __pyx_t_10;
27584 __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_step);
if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 762, __pyx_L1_error)
27585 __Pyx_GOTREF(__pyx_t_9);
27586 __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_9);
if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 762, __pyx_L1_error)
27588 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
27590 __pyx_t_12 = __Pyx_PyIndex_AsSsize_t(__pyx_t_9);
if (unlikely((__pyx_t_12 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 762, __pyx_L1_error)
27591 __pyx_t_10 = __pyx_t_12;
27592 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
27593 goto __pyx_L11_bool_binop_done;
27596 __pyx_L11_bool_binop_done:;
27597 __pyx_v_step = __pyx_t_10;
27606 __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_start);
if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 764, __pyx_L1_error)
27607 __Pyx_GOTREF(__pyx_t_9);
27608 __pyx_t_1 = (__pyx_t_9 != Py_None);
27609 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
27610 __pyx_v_have_start = __pyx_t_1;
27619 __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_stop);
if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 765, __pyx_L1_error)
27620 __Pyx_GOTREF(__pyx_t_9);
27621 __pyx_t_1 = (__pyx_t_9 != Py_None);
27622 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
27623 __pyx_v_have_stop = __pyx_t_1;
27632 __pyx_t_9 = __Pyx_PyObject_GetAttrStr(__pyx_v_index, __pyx_n_s_step);
if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 766, __pyx_L1_error)
27633 __Pyx_GOTREF(__pyx_t_9);
27634 __pyx_t_1 = (__pyx_t_9 != Py_None);
27635 __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
27636 __pyx_v_have_step = __pyx_t_1;
27645 __pyx_t_11 = __pyx_memoryview_slice_memviewslice(__pyx_v_p_dst, (__pyx_v_p_src->shape[__pyx_v_dim]), (__pyx_v_p_src->strides[__pyx_v_dim]), (__pyx_v_p_src->suboffsets[__pyx_v_dim]), __pyx_v_dim, __pyx_v_new_ndim, __pyx_v_p_suboffset_dim, __pyx_v_start, __pyx_v_stop, __pyx_v_step, __pyx_v_have_start, __pyx_v_have_stop, __pyx_v_have_step, 1);
if (unlikely(__pyx_t_11 == ((
int)-1))) __PYX_ERR(0, 768, __pyx_L1_error)
27654 __pyx_v_new_ndim = (__pyx_v_new_ndim + 1);
27666 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
27675 __pyx_t_1 = __Pyx_TypeCheck(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type);
27676 __pyx_t_2 = (__pyx_t_1 != 0);
27686 __Pyx_XDECREF(((PyObject *)__pyx_r));
27695 if (unlikely(!__pyx_v_memviewsliceobj)) { __Pyx_RaiseUnboundLocalError(
"memviewsliceobj"); __PYX_ERR(0, 778, __pyx_L1_error) }
27704 if (unlikely(!__pyx_v_memviewsliceobj)) { __Pyx_RaiseUnboundLocalError(
"memviewsliceobj"); __PYX_ERR(0, 779, __pyx_L1_error) }
27713 __pyx_t_3 = __pyx_memoryview_fromslice(__pyx_v_dst, __pyx_v_new_ndim, __pyx_v_memviewsliceobj->to_object_func, __pyx_v_memviewsliceobj->to_dtype_func, __pyx_v_memview->dtype_is_object);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 777, __pyx_L1_error)
27714 __Pyx_GOTREF(__pyx_t_3);
27715 if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_memoryview_type))))) __PYX_ERR(0, 777, __pyx_L1_error)
27716 __pyx_r = ((
struct __pyx_memoryview_obj *)__pyx_t_3);
27737 __Pyx_XDECREF(((PyObject *)__pyx_r));
27746 __pyx_t_3 = __pyx_memoryview_fromslice(__pyx_v_dst, __pyx_v_new_ndim, NULL, NULL, __pyx_v_memview->dtype_is_object);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 782, __pyx_L1_error)
27747 __Pyx_GOTREF(__pyx_t_3);
27756 if (!(likely(((__pyx_t_3) == Py_None) || likely(__Pyx_TypeTest(__pyx_t_3, __pyx_memoryview_type))))) __PYX_ERR(0, 782, __pyx_L1_error)
27757 __pyx_r = ((
struct __pyx_memoryview_obj *)__pyx_t_3);
27772 __Pyx_XDECREF(__pyx_t_3);
27773 __Pyx_XDECREF(__pyx_t_9);
27774 __Pyx_AddTraceback(
"View.MemoryView.memview_slice", __pyx_clineno, __pyx_lineno, __pyx_filename);
27777 __Pyx_XDECREF((PyObject *)__pyx_v_memviewsliceobj);
27778 __Pyx_XDECREF(__pyx_v_index);
27779 __Pyx_XGIVEREF((PyObject *)__pyx_r);
27780 __Pyx_RefNannyFinishContext();
27792 static int __pyx_memoryview_slice_memviewslice(__Pyx_memviewslice *__pyx_v_dst, Py_ssize_t __pyx_v_shape, Py_ssize_t __pyx_v_stride, Py_ssize_t __pyx_v_suboffset,
int __pyx_v_dim,
int __pyx_v_new_ndim,
int *__pyx_v_suboffset_dim, Py_ssize_t __pyx_v_start, Py_ssize_t __pyx_v_stop, Py_ssize_t __pyx_v_step,
int __pyx_v_have_start,
int __pyx_v_have_stop,
int __pyx_v_have_step,
int __pyx_v_is_slice) {
27793 Py_ssize_t __pyx_v_new_shape;
27794 int __pyx_v_negative_step;
27799 int __pyx_lineno = 0;
27800 const char *__pyx_filename = NULL;
27801 int __pyx_clineno = 0;
27810 __pyx_t_1 = ((!(__pyx_v_is_slice != 0)) != 0);
27820 __pyx_t_1 = ((__pyx_v_start < 0) != 0);
27830 __pyx_v_start = (__pyx_v_start + __pyx_v_shape);
27848 __pyx_t_1 = (0 <= __pyx_v_start);
27850 __pyx_t_1 = (__pyx_v_start < __pyx_v_shape);
27852 __pyx_t_2 = ((!(__pyx_t_1 != 0)) != 0);
27862 __pyx_t_3 = __pyx_memoryview_err_dim(__pyx_builtin_IndexError, ((
char *)
"Index out of bounds (axis %d)"), __pyx_v_dim);
if (unlikely(__pyx_t_3 == ((
int)-1))) __PYX_ERR(0, 832, __pyx_L1_error)
27891 __pyx_t_1 = ((__pyx_v_have_step != 0) != 0);
27894 __pyx_t_2 = __pyx_t_1;
27895 goto __pyx_L6_bool_binop_done;
27897 __pyx_t_1 = ((__pyx_v_step < 0) != 0);
27898 __pyx_t_2 = __pyx_t_1;
27899 __pyx_L6_bool_binop_done:;
27900 __pyx_v_negative_step = __pyx_t_2;
27909 __pyx_t_1 = (__pyx_v_have_step != 0);
27912 __pyx_t_2 = __pyx_t_1;
27913 goto __pyx_L9_bool_binop_done;
27915 __pyx_t_1 = ((__pyx_v_step == 0) != 0);
27916 __pyx_t_2 = __pyx_t_1;
27917 __pyx_L9_bool_binop_done:;
27927 __pyx_t_3 = __pyx_memoryview_err_dim(__pyx_builtin_ValueError, ((
char *)
"Step may not be zero (axis %d)"), __pyx_v_dim);
if (unlikely(__pyx_t_3 == ((
int)-1))) __PYX_ERR(0, 838, __pyx_L1_error)
27945 __pyx_t_2 = (__pyx_v_have_start != 0);
27955 __pyx_t_2 = ((__pyx_v_start < 0) != 0);
27965 __pyx_v_start = (__pyx_v_start + __pyx_v_shape);
27974 __pyx_t_2 = ((__pyx_v_start < 0) != 0);
28012 __pyx_t_2 = ((__pyx_v_start >= __pyx_v_shape) != 0);
28022 __pyx_t_2 = (__pyx_v_negative_step != 0);
28032 __pyx_v_start = (__pyx_v_shape - 1);
28052 __pyx_v_start = __pyx_v_shape;
28084 __pyx_t_2 = (__pyx_v_negative_step != 0);
28094 __pyx_v_start = (__pyx_v_shape - 1);
28127 __pyx_t_2 = (__pyx_v_have_stop != 0);
28137 __pyx_t_2 = ((__pyx_v_stop < 0) != 0);
28147 __pyx_v_stop = (__pyx_v_stop + __pyx_v_shape);
28156 __pyx_t_2 = ((__pyx_v_stop < 0) != 0);
28194 __pyx_t_2 = ((__pyx_v_stop > __pyx_v_shape) != 0);
28204 __pyx_v_stop = __pyx_v_shape;
28234 __pyx_t_2 = (__pyx_v_negative_step != 0);
28244 __pyx_v_stop = -1
L;
28264 __pyx_v_stop = __pyx_v_shape;
28277 __pyx_t_2 = ((!(__pyx_v_have_step != 0)) != 0);
28305 __pyx_v_new_shape = ((__pyx_v_stop - __pyx_v_start) / __pyx_v_step);
28314 __pyx_t_2 = (((__pyx_v_stop - __pyx_v_start) - (__pyx_v_step * __pyx_v_new_shape)) != 0);
28324 __pyx_v_new_shape = (__pyx_v_new_shape + 1);
28342 __pyx_t_2 = ((__pyx_v_new_shape < 0) != 0);
28352 __pyx_v_new_shape = 0;
28370 (__pyx_v_dst->strides[__pyx_v_new_ndim]) = (__pyx_v_stride * __pyx_v_step);
28379 (__pyx_v_dst->shape[__pyx_v_new_ndim]) = __pyx_v_new_shape;
28388 (__pyx_v_dst->suboffsets[__pyx_v_new_ndim]) = __pyx_v_suboffset;
28399 __pyx_t_2 = (((__pyx_v_suboffset_dim[0]) < 0) != 0);
28409 __pyx_v_dst->data = (__pyx_v_dst->data + (__pyx_v_start * __pyx_v_stride));
28429 __pyx_t_3 = (__pyx_v_suboffset_dim[0]);
28430 (__pyx_v_dst->suboffsets[__pyx_t_3]) = ((__pyx_v_dst->suboffsets[__pyx_t_3]) + (__pyx_v_start * __pyx_v_stride));
28441 __pyx_t_2 = ((__pyx_v_suboffset >= 0) != 0);
28451 __pyx_t_2 = ((!(__pyx_v_is_slice != 0)) != 0);
28461 __pyx_t_2 = ((__pyx_v_new_ndim == 0) != 0);
28471 __pyx_v_dst->data = ((((
char **)__pyx_v_dst->data)[0]) + __pyx_v_suboffset);
28499 __pyx_t_3 = __pyx_memoryview_err_dim(__pyx_builtin_IndexError, ((
char *)
"All dimensions preceding dimension %d must be indexed and not sliced"), __pyx_v_dim);
if (unlikely(__pyx_t_3 == ((
int)-1))) __PYX_ERR(0, 899, __pyx_L1_error)
28521 (__pyx_v_suboffset_dim[0]) = __pyx_v_new_ndim;
28556 PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
28558 __Pyx_AddTraceback(
"View.MemoryView.slice_memviewslice", __pyx_clineno, __pyx_lineno, __pyx_filename);
28560 __Pyx_PyGILState_Release(__pyx_gilstate_save);
28576 static char *__pyx_pybuffer_index(Py_buffer *__pyx_v_view,
char *__pyx_v_bufp, Py_ssize_t __pyx_v_index, Py_ssize_t __pyx_v_dim) {
28577 Py_ssize_t __pyx_v_shape;
28578 Py_ssize_t __pyx_v_stride;
28579 Py_ssize_t __pyx_v_suboffset;
28580 Py_ssize_t __pyx_v_itemsize;
28581 char *__pyx_v_resultp;
28583 __Pyx_RefNannyDeclarations
28584 Py_ssize_t __pyx_t_1;
28586 PyObject *__pyx_t_3 = NULL;
28587 PyObject *__pyx_t_4 = NULL;
28588 int __pyx_lineno = 0;
28589 const char *__pyx_filename = NULL;
28590 int __pyx_clineno = 0;
28591 __Pyx_RefNannySetupContext(
"pybuffer_index", 0);
28600 __pyx_v_suboffset = -1
L;
28609 __pyx_t_1 = __pyx_v_view->itemsize;
28610 __pyx_v_itemsize = __pyx_t_1;
28619 __pyx_t_2 = ((__pyx_v_view->ndim == 0) != 0);
28629 if (unlikely(__pyx_v_itemsize == 0)) {
28630 PyErr_SetString(PyExc_ZeroDivisionError,
"integer division or modulo by zero");
28631 __PYX_ERR(0, 917, __pyx_L1_error)
28633 else if (
sizeof(Py_ssize_t) ==
sizeof(
long) && (!(((Py_ssize_t)-1) > 0)) && unlikely(__pyx_v_itemsize == (Py_ssize_t)-1) && unlikely(UNARY_NEG_WOULD_OVERFLOW(__pyx_v_view->len))) {
28634 PyErr_SetString(PyExc_OverflowError,
"value too large to perform division");
28635 __PYX_ERR(0, 917, __pyx_L1_error)
28637 __pyx_v_shape = __Pyx_div_Py_ssize_t(__pyx_v_view->len, __pyx_v_itemsize);
28646 __pyx_v_stride = __pyx_v_itemsize;
28666 __pyx_v_shape = (__pyx_v_view->shape[__pyx_v_dim]);
28675 __pyx_v_stride = (__pyx_v_view->strides[__pyx_v_dim]);
28684 __pyx_t_2 = ((__pyx_v_view->suboffsets != NULL) != 0);
28694 __pyx_v_suboffset = (__pyx_v_view->suboffsets[__pyx_v_dim]);
28714 __pyx_t_2 = ((__pyx_v_index < 0) != 0);
28724 __pyx_v_index = (__pyx_v_index + (__pyx_v_view->shape[__pyx_v_dim]));
28733 __pyx_t_2 = ((__pyx_v_index < 0) != 0);
28734 if (unlikely(__pyx_t_2)) {
28743 __pyx_t_3 = PyInt_FromSsize_t(__pyx_v_dim);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 928, __pyx_L1_error)
28744 __Pyx_GOTREF(__pyx_t_3);
28745 __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Out_of_bounds_on_buffer_access_a, __pyx_t_3);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 928, __pyx_L1_error)
28746 __Pyx_GOTREF(__pyx_t_4);
28747 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
28748 __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_IndexError, __pyx_t_4);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 928, __pyx_L1_error)
28749 __Pyx_GOTREF(__pyx_t_3);
28750 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
28751 __Pyx_Raise(__pyx_t_3, 0, 0, 0);
28752 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
28753 __PYX_ERR(0, 928, __pyx_L1_error)
28780 __pyx_t_2 = ((__pyx_v_index >= __pyx_v_shape) != 0);
28781 if (unlikely(__pyx_t_2)) {
28790 __pyx_t_3 = PyInt_FromSsize_t(__pyx_v_dim);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 931, __pyx_L1_error)
28791 __Pyx_GOTREF(__pyx_t_3);
28792 __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Out_of_bounds_on_buffer_access_a, __pyx_t_3);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 931, __pyx_L1_error)
28793 __Pyx_GOTREF(__pyx_t_4);
28794 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
28795 __pyx_t_3 = __Pyx_PyObject_CallOneArg(__pyx_builtin_IndexError, __pyx_t_4);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 931, __pyx_L1_error)
28796 __Pyx_GOTREF(__pyx_t_3);
28797 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
28798 __Pyx_Raise(__pyx_t_3, 0, 0, 0);
28799 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
28800 __PYX_ERR(0, 931, __pyx_L1_error)
28818 __pyx_v_resultp = (__pyx_v_bufp + (__pyx_v_index * __pyx_v_stride));
28827 __pyx_t_2 = ((__pyx_v_suboffset >= 0) != 0);
28837 __pyx_v_resultp = ((((
char **)__pyx_v_resultp)[0]) + __pyx_v_suboffset);
28855 __pyx_r = __pyx_v_resultp;
28868 __Pyx_XDECREF(__pyx_t_3);
28869 __Pyx_XDECREF(__pyx_t_4);
28870 __Pyx_AddTraceback(
"View.MemoryView.pybuffer_index", __pyx_clineno, __pyx_lineno, __pyx_filename);
28873 __Pyx_RefNannyFinishContext();
28885 static int __pyx_memslice_transpose(__Pyx_memviewslice *__pyx_v_memslice) {
28887 Py_ssize_t *__pyx_v_shape;
28888 Py_ssize_t *__pyx_v_strides;
28893 Py_ssize_t *__pyx_t_2;
28896 Py_ssize_t __pyx_t_5;
28897 Py_ssize_t __pyx_t_6;
28901 int __pyx_lineno = 0;
28902 const char *__pyx_filename = NULL;
28903 int __pyx_clineno = 0;
28912 __pyx_t_1 = __pyx_v_memslice->memview->view.ndim;
28913 __pyx_v_ndim = __pyx_t_1;
28922 __pyx_t_2 = __pyx_v_memslice->shape;
28923 __pyx_v_shape = __pyx_t_2;
28932 __pyx_t_2 = __pyx_v_memslice->strides;
28933 __pyx_v_strides = __pyx_t_2;
28942 __pyx_t_3 = __Pyx_div_long(__pyx_v_ndim, 2);
28943 __pyx_t_4 = __pyx_t_3;
28944 for (__pyx_t_1 = 0; __pyx_t_1 < __pyx_t_4; __pyx_t_1+=1) {
28945 __pyx_v_i = __pyx_t_1;
28954 __pyx_v_j = ((__pyx_v_ndim - 1) - __pyx_v_i);
28963 __pyx_t_5 = (__pyx_v_strides[__pyx_v_j]);
28964 __pyx_t_6 = (__pyx_v_strides[__pyx_v_i]);
28965 (__pyx_v_strides[__pyx_v_i]) = __pyx_t_5;
28966 (__pyx_v_strides[__pyx_v_j]) = __pyx_t_6;
28975 __pyx_t_6 = (__pyx_v_shape[__pyx_v_j]);
28976 __pyx_t_5 = (__pyx_v_shape[__pyx_v_i]);
28977 (__pyx_v_shape[__pyx_v_i]) = __pyx_t_6;
28978 (__pyx_v_shape[__pyx_v_j]) = __pyx_t_5;
28987 __pyx_t_8 = (((__pyx_v_memslice->suboffsets[__pyx_v_i]) >= 0) != 0);
28990 __pyx_t_7 = __pyx_t_8;
28991 goto __pyx_L6_bool_binop_done;
28993 __pyx_t_8 = (((__pyx_v_memslice->suboffsets[__pyx_v_j]) >= 0) != 0);
28994 __pyx_t_7 = __pyx_t_8;
28995 __pyx_L6_bool_binop_done:;
29005 __pyx_t_9 = __pyx_memoryview_err(__pyx_builtin_ValueError, ((
char *)
"Cannot transpose memoryview with indirect dimensions"));
if (unlikely(__pyx_t_9 == ((
int)-1))) __PYX_ERR(0, 957, __pyx_L1_error)
29039 PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
29041 __Pyx_AddTraceback(
"View.MemoryView.transpose_memslice", __pyx_clineno, __pyx_lineno, __pyx_filename);
29043 __Pyx_PyGILState_Release(__pyx_gilstate_save);
29060 static void __pyx_memoryviewslice___dealloc__(PyObject *__pyx_v_self);
29061 static void __pyx_memoryviewslice___dealloc__(PyObject *__pyx_v_self) {
29062 __Pyx_RefNannyDeclarations
29063 __Pyx_RefNannySetupContext(
"__dealloc__ (wrapper)", 0);
29064 __pyx_memoryviewslice___pyx_pf_15View_dot_MemoryView_16_memoryviewslice___dealloc__(((
struct __pyx_memoryviewslice_obj *)__pyx_v_self));
29067 __Pyx_RefNannyFinishContext();
29070 static void __pyx_memoryviewslice___pyx_pf_15View_dot_MemoryView_16_memoryviewslice___dealloc__(
struct __pyx_memoryviewslice_obj *__pyx_v_self) {
29071 __Pyx_RefNannyDeclarations
29072 __Pyx_RefNannySetupContext(
"__dealloc__", 0);
29081 __PYX_XDEC_MEMVIEW((&__pyx_v_self->from_slice), 1);
29092 __Pyx_RefNannyFinishContext();
29103 static PyObject *__pyx_memoryviewslice_convert_item_to_object(
struct __pyx_memoryviewslice_obj *__pyx_v_self,
char *__pyx_v_itemp) {
29104 PyObject *__pyx_r = NULL;
29105 __Pyx_RefNannyDeclarations
29107 PyObject *__pyx_t_2 = NULL;
29108 int __pyx_lineno = 0;
29109 const char *__pyx_filename = NULL;
29110 int __pyx_clineno = 0;
29111 __Pyx_RefNannySetupContext(
"convert_item_to_object", 0);
29120 __pyx_t_1 = ((__pyx_v_self->to_object_func != NULL) != 0);
29130 __Pyx_XDECREF(__pyx_r);
29131 __pyx_t_2 = __pyx_v_self->to_object_func(__pyx_v_itemp);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 981, __pyx_L1_error)
29132 __Pyx_GOTREF(__pyx_t_2);
29133 __pyx_r = __pyx_t_2;
29154 __Pyx_XDECREF(__pyx_r);
29155 __pyx_t_2 = __pyx_memoryview_convert_item_to_object(((
struct __pyx_memoryview_obj *)__pyx_v_self), __pyx_v_itemp);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 983, __pyx_L1_error)
29156 __Pyx_GOTREF(__pyx_t_2);
29157 __pyx_r = __pyx_t_2;
29172 __Pyx_XDECREF(__pyx_t_2);
29173 __Pyx_AddTraceback(
"View.MemoryView._memoryviewslice.convert_item_to_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
29176 __Pyx_XGIVEREF(__pyx_r);
29177 __Pyx_RefNannyFinishContext();
29189 static PyObject *__pyx_memoryviewslice_assign_item_from_object(
struct __pyx_memoryviewslice_obj *__pyx_v_self,
char *__pyx_v_itemp, PyObject *__pyx_v_value) {
29190 PyObject *__pyx_r = NULL;
29191 __Pyx_RefNannyDeclarations
29194 PyObject *__pyx_t_3 = NULL;
29195 int __pyx_lineno = 0;
29196 const char *__pyx_filename = NULL;
29197 int __pyx_clineno = 0;
29198 __Pyx_RefNannySetupContext(
"assign_item_from_object", 0);
29207 __pyx_t_1 = ((__pyx_v_self->to_dtype_func != NULL) != 0);
29217 __pyx_t_2 = __pyx_v_self->to_dtype_func(__pyx_v_itemp, __pyx_v_value);
if (unlikely(__pyx_t_2 == ((
int)0))) __PYX_ERR(0, 987, __pyx_L1_error)
29237 __pyx_t_3 = __pyx_memoryview_assign_item_from_object(((
struct __pyx_memoryview_obj *)__pyx_v_self), __pyx_v_itemp, __pyx_v_value);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 989, __pyx_L1_error)
29238 __Pyx_GOTREF(__pyx_t_3);
29239 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
29252 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
29255 __Pyx_XDECREF(__pyx_t_3);
29256 __Pyx_AddTraceback(
"View.MemoryView._memoryviewslice.assign_item_from_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
29259 __Pyx_XGIVEREF(__pyx_r);
29260 __Pyx_RefNannyFinishContext();
29273 static PyObject *__pyx_pw_15View_dot_MemoryView_16_memoryviewslice_4base_1__get__(PyObject *__pyx_v_self);
29274 static PyObject *__pyx_pw_15View_dot_MemoryView_16_memoryviewslice_4base_1__get__(PyObject *__pyx_v_self) {
29275 PyObject *__pyx_r = 0;
29276 __Pyx_RefNannyDeclarations
29277 __Pyx_RefNannySetupContext(
"__get__ (wrapper)", 0);
29278 __pyx_r = __pyx_pf_15View_dot_MemoryView_16_memoryviewslice_4base___get__(((
struct __pyx_memoryviewslice_obj *)__pyx_v_self));
29281 __Pyx_RefNannyFinishContext();
29285 static PyObject *__pyx_pf_15View_dot_MemoryView_16_memoryviewslice_4base___get__(
struct __pyx_memoryviewslice_obj *__pyx_v_self) {
29286 PyObject *__pyx_r = NULL;
29287 __Pyx_RefNannyDeclarations
29288 __Pyx_RefNannySetupContext(
"__get__", 0);
29297 __Pyx_XDECREF(__pyx_r);
29298 __Pyx_INCREF(__pyx_v_self->from_object);
29299 __pyx_r = __pyx_v_self->from_object;
29312 __Pyx_XGIVEREF(__pyx_r);
29313 __Pyx_RefNannyFinishContext();
29324 static PyObject *__pyx_pw___pyx_memoryviewslice_1__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused);
29325 static PyObject *__pyx_pw___pyx_memoryviewslice_1__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
29326 PyObject *__pyx_r = 0;
29327 __Pyx_RefNannyDeclarations
29328 __Pyx_RefNannySetupContext(
"__reduce_cython__ (wrapper)", 0);
29329 __pyx_r = __pyx_pf___pyx_memoryviewslice___reduce_cython__(((
struct __pyx_memoryviewslice_obj *)__pyx_v_self));
29332 __Pyx_RefNannyFinishContext();
29336 static PyObject *__pyx_pf___pyx_memoryviewslice___reduce_cython__(CYTHON_UNUSED
struct __pyx_memoryviewslice_obj *__pyx_v_self) {
29337 PyObject *__pyx_r = NULL;
29338 __Pyx_RefNannyDeclarations
29339 PyObject *__pyx_t_1 = NULL;
29340 int __pyx_lineno = 0;
29341 const char *__pyx_filename = NULL;
29342 int __pyx_clineno = 0;
29343 __Pyx_RefNannySetupContext(
"__reduce_cython__", 0);
29351 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__24, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 2, __pyx_L1_error)
29352 __Pyx_GOTREF(__pyx_t_1);
29353 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
29354 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
29355 __PYX_ERR(0, 2, __pyx_L1_error)
29365 __Pyx_XDECREF(__pyx_t_1);
29366 __Pyx_AddTraceback(
"View.MemoryView._memoryviewslice.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
29368 __Pyx_XGIVEREF(__pyx_r);
29369 __Pyx_RefNannyFinishContext();
29381 static PyObject *__pyx_pw___pyx_memoryviewslice_3__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state);
29382 static PyObject *__pyx_pw___pyx_memoryviewslice_3__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
29383 PyObject *__pyx_r = 0;
29384 __Pyx_RefNannyDeclarations
29385 __Pyx_RefNannySetupContext(
"__setstate_cython__ (wrapper)", 0);
29386 __pyx_r = __pyx_pf___pyx_memoryviewslice_2__setstate_cython__(((
struct __pyx_memoryviewslice_obj *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
29389 __Pyx_RefNannyFinishContext();
29393 static PyObject *__pyx_pf___pyx_memoryviewslice_2__setstate_cython__(CYTHON_UNUSED
struct __pyx_memoryviewslice_obj *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
29394 PyObject *__pyx_r = NULL;
29395 __Pyx_RefNannyDeclarations
29396 PyObject *__pyx_t_1 = NULL;
29397 int __pyx_lineno = 0;
29398 const char *__pyx_filename = NULL;
29399 int __pyx_clineno = 0;
29400 __Pyx_RefNannySetupContext(
"__setstate_cython__", 0);
29407 __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__25, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 4, __pyx_L1_error)
29408 __Pyx_GOTREF(__pyx_t_1);
29409 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
29410 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
29411 __PYX_ERR(0, 4, __pyx_L1_error)
29422 __Pyx_XDECREF(__pyx_t_1);
29423 __Pyx_AddTraceback(
"View.MemoryView._memoryviewslice.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
29425 __Pyx_XGIVEREF(__pyx_r);
29426 __Pyx_RefNannyFinishContext();
29438 static PyObject *__pyx_memoryview_fromslice(__Pyx_memviewslice __pyx_v_memviewslice,
int __pyx_v_ndim, PyObject *(*__pyx_v_to_object_func)(
char *),
int (*__pyx_v_to_dtype_func)(
char *, PyObject *),
int __pyx_v_dtype_is_object) {
29439 struct __pyx_memoryviewslice_obj *__pyx_v_result = 0;
29440 Py_ssize_t __pyx_v_suboffset;
29441 PyObject *__pyx_v_length = NULL;
29442 PyObject *__pyx_r = NULL;
29443 __Pyx_RefNannyDeclarations
29445 PyObject *__pyx_t_2 = NULL;
29446 PyObject *__pyx_t_3 = NULL;
29447 __Pyx_TypeInfo *__pyx_t_4;
29448 Py_buffer __pyx_t_5;
29449 Py_ssize_t *__pyx_t_6;
29450 Py_ssize_t *__pyx_t_7;
29451 Py_ssize_t *__pyx_t_8;
29452 Py_ssize_t __pyx_t_9;
29453 int __pyx_lineno = 0;
29454 const char *__pyx_filename = NULL;
29455 int __pyx_clineno = 0;
29456 __Pyx_RefNannySetupContext(
"memoryview_fromslice", 0);
29465 __pyx_t_1 = ((((PyObject *)__pyx_v_memviewslice.memview) == Py_None) != 0);
29475 __Pyx_XDECREF(__pyx_r);
29476 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
29495 __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_v_dtype_is_object);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1013, __pyx_L1_error)
29496 __Pyx_GOTREF(__pyx_t_2);
29497 __pyx_t_3 = PyTuple_New(3);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1013, __pyx_L1_error)
29498 __Pyx_GOTREF(__pyx_t_3);
29499 __Pyx_INCREF(Py_None);
29500 __Pyx_GIVEREF(Py_None);
29501 PyTuple_SET_ITEM(__pyx_t_3, 0, Py_None);
29502 __Pyx_INCREF(__pyx_int_0);
29503 __Pyx_GIVEREF(__pyx_int_0);
29504 PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_int_0);
29505 __Pyx_GIVEREF(__pyx_t_2);
29506 PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2);
29508 __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_memoryviewslice_type), __pyx_t_3, NULL);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1013, __pyx_L1_error)
29509 __Pyx_GOTREF(__pyx_t_2);
29510 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
29511 __pyx_v_result = ((
struct __pyx_memoryviewslice_obj *)__pyx_t_2);
29521 __pyx_v_result->from_slice = __pyx_v_memviewslice;
29530 __PYX_INC_MEMVIEW((&__pyx_v_memviewslice), 1);
29539 __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_memviewslice.memview), __pyx_n_s_base);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1018, __pyx_L1_error)
29540 __Pyx_GOTREF(__pyx_t_2);
29541 __Pyx_GIVEREF(__pyx_t_2);
29542 __Pyx_GOTREF(__pyx_v_result->from_object);
29543 __Pyx_DECREF(__pyx_v_result->from_object);
29544 __pyx_v_result->from_object = __pyx_t_2;
29554 __pyx_t_4 = __pyx_v_memviewslice.memview->typeinfo;
29555 __pyx_v_result->__pyx_base.typeinfo = __pyx_t_4;
29564 __pyx_t_5 = __pyx_v_memviewslice.memview->view;
29565 __pyx_v_result->__pyx_base.view = __pyx_t_5;
29574 __pyx_v_result->__pyx_base.view.buf = ((
void *)__pyx_v_memviewslice.data);
29583 __pyx_v_result->__pyx_base.view.ndim = __pyx_v_ndim;
29592 ((Py_buffer *)(&__pyx_v_result->__pyx_base.view))->obj = Py_None;
29601 Py_INCREF(Py_None);
29610 __pyx_t_1 = ((((
struct __pyx_memoryview_obj *)__pyx_v_memviewslice.memview)->flags & PyBUF_WRITABLE) != 0);
29620 __pyx_v_result->__pyx_base.flags = PyBUF_RECORDS;
29640 __pyx_v_result->__pyx_base.flags = PyBUF_RECORDS_RO;
29651 __pyx_v_result->__pyx_base.view.shape = ((Py_ssize_t *)__pyx_v_result->from_slice.shape);
29660 __pyx_v_result->__pyx_base.view.strides = ((Py_ssize_t *)__pyx_v_result->from_slice.strides);
29669 __pyx_v_result->__pyx_base.view.suboffsets = NULL;
29678 __pyx_t_7 = (__pyx_v_result->from_slice.suboffsets + __pyx_v_ndim);
29679 for (__pyx_t_8 = __pyx_v_result->from_slice.suboffsets; __pyx_t_8 < __pyx_t_7; __pyx_t_8++) {
29680 __pyx_t_6 = __pyx_t_8;
29681 __pyx_v_suboffset = (__pyx_t_6[0]);
29690 __pyx_t_1 = ((__pyx_v_suboffset >= 0) != 0);
29700 __pyx_v_result->__pyx_base.view.suboffsets = ((Py_ssize_t *)__pyx_v_result->from_slice.suboffsets);
29709 goto __pyx_L6_break;
29729 __pyx_t_9 = __pyx_v_result->__pyx_base.view.itemsize;
29730 __pyx_v_result->__pyx_base.view.len = __pyx_t_9;
29739 __pyx_t_7 = (__pyx_v_result->__pyx_base.view.shape + __pyx_v_ndim);
29740 for (__pyx_t_8 = __pyx_v_result->__pyx_base.view.shape; __pyx_t_8 < __pyx_t_7; __pyx_t_8++) {
29741 __pyx_t_6 = __pyx_t_8;
29742 __pyx_t_2 = PyInt_FromSsize_t((__pyx_t_6[0]));
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1043, __pyx_L1_error)
29743 __Pyx_GOTREF(__pyx_t_2);
29744 __Pyx_XDECREF_SET(__pyx_v_length, __pyx_t_2);
29754 __pyx_t_2 = PyInt_FromSsize_t(__pyx_v_result->__pyx_base.view.len);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1044, __pyx_L1_error)
29755 __Pyx_GOTREF(__pyx_t_2);
29756 __pyx_t_3 = PyNumber_InPlaceMultiply(__pyx_t_2, __pyx_v_length);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1044, __pyx_L1_error)
29757 __Pyx_GOTREF(__pyx_t_3);
29758 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
29759 __pyx_t_9 = __Pyx_PyIndex_AsSsize_t(__pyx_t_3);
if (unlikely((__pyx_t_9 == (Py_ssize_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 1044, __pyx_L1_error)
29760 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
29761 __pyx_v_result->__pyx_base.view.len = __pyx_t_9;
29771 __pyx_v_result->to_object_func = __pyx_v_to_object_func;
29780 __pyx_v_result->to_dtype_func = __pyx_v_to_dtype_func;
29789 __Pyx_XDECREF(__pyx_r);
29790 __Pyx_INCREF(((PyObject *)__pyx_v_result));
29791 __pyx_r = ((PyObject *)__pyx_v_result);
29804 __Pyx_XDECREF(__pyx_t_2);
29805 __Pyx_XDECREF(__pyx_t_3);
29806 __Pyx_AddTraceback(
"View.MemoryView.memoryview_fromslice", __pyx_clineno, __pyx_lineno, __pyx_filename);
29809 __Pyx_XDECREF((PyObject *)__pyx_v_result);
29810 __Pyx_XDECREF(__pyx_v_length);
29811 __Pyx_XGIVEREF(__pyx_r);
29812 __Pyx_RefNannyFinishContext();
29824 static __Pyx_memviewslice *__pyx_memoryview_get_slice_from_memoryview(
struct __pyx_memoryview_obj *__pyx_v_memview, __Pyx_memviewslice *__pyx_v_mslice) {
29825 struct __pyx_memoryviewslice_obj *__pyx_v_obj = 0;
29826 __Pyx_memviewslice *__pyx_r;
29827 __Pyx_RefNannyDeclarations
29830 PyObject *__pyx_t_3 = NULL;
29831 int __pyx_lineno = 0;
29832 const char *__pyx_filename = NULL;
29833 int __pyx_clineno = 0;
29834 __Pyx_RefNannySetupContext(
"get_slice_from_memview", 0);
29843 __pyx_t_1 = __Pyx_TypeCheck(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type);
29844 __pyx_t_2 = (__pyx_t_1 != 0);
29854 if (!(likely(((((PyObject *)__pyx_v_memview)) == Py_None) || likely(__Pyx_TypeTest(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type))))) __PYX_ERR(0, 1056, __pyx_L1_error)
29855 __pyx_t_3 = ((PyObject *)__pyx_v_memview);
29856 __Pyx_INCREF(__pyx_t_3);
29857 __pyx_v_obj = ((
struct __pyx_memoryviewslice_obj *)__pyx_t_3);
29867 __pyx_r = (&__pyx_v_obj->from_slice);
29887 __pyx_memoryview_slice_copy(__pyx_v_memview, __pyx_v_mslice);
29896 __pyx_r = __pyx_v_mslice;
29910 __Pyx_XDECREF(__pyx_t_3);
29911 __Pyx_AddTraceback(
"View.MemoryView.get_slice_from_memview", __pyx_clineno, __pyx_lineno, __pyx_filename);
29914 __Pyx_XDECREF((PyObject *)__pyx_v_obj);
29915 __Pyx_RefNannyFinishContext();
29927 static void __pyx_memoryview_slice_copy(
struct __pyx_memoryview_obj *__pyx_v_memview, __Pyx_memviewslice *__pyx_v_dst) {
29929 Py_ssize_t *__pyx_v_shape;
29930 Py_ssize_t *__pyx_v_strides;
29931 Py_ssize_t *__pyx_v_suboffsets;
29932 __Pyx_RefNannyDeclarations
29933 Py_ssize_t *__pyx_t_1;
29937 Py_ssize_t __pyx_t_5;
29938 __Pyx_RefNannySetupContext(
"slice_copy", 0);
29947 __pyx_t_1 = __pyx_v_memview->view.shape;
29948 __pyx_v_shape = __pyx_t_1;
29957 __pyx_t_1 = __pyx_v_memview->view.strides;
29958 __pyx_v_strides = __pyx_t_1;
29967 __pyx_t_1 = __pyx_v_memview->view.suboffsets;
29968 __pyx_v_suboffsets = __pyx_t_1;
29977 __pyx_v_dst->memview = ((
struct __pyx_memoryview_obj *)__pyx_v_memview);
29986 __pyx_v_dst->data = ((
char *)__pyx_v_memview->view.buf);
29995 __pyx_t_2 = __pyx_v_memview->view.ndim;
29996 __pyx_t_3 = __pyx_t_2;
29997 for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
29998 __pyx_v_dim = __pyx_t_4;
30007 (__pyx_v_dst->shape[__pyx_v_dim]) = (__pyx_v_shape[__pyx_v_dim]);
30016 (__pyx_v_dst->strides[__pyx_v_dim]) = (__pyx_v_strides[__pyx_v_dim]);
30025 if ((__pyx_v_suboffsets != 0)) {
30026 __pyx_t_5 = (__pyx_v_suboffsets[__pyx_v_dim]);
30030 (__pyx_v_dst->suboffsets[__pyx_v_dim]) = __pyx_t_5;
30042 __Pyx_RefNannyFinishContext();
30053 static PyObject *__pyx_memoryview_copy_object(
struct __pyx_memoryview_obj *__pyx_v_memview) {
30054 __Pyx_memviewslice __pyx_v_memviewslice;
30055 PyObject *__pyx_r = NULL;
30056 __Pyx_RefNannyDeclarations
30057 PyObject *__pyx_t_1 = NULL;
30058 int __pyx_lineno = 0;
30059 const char *__pyx_filename = NULL;
30060 int __pyx_clineno = 0;
30061 __Pyx_RefNannySetupContext(
"memoryview_copy", 0);
30070 __pyx_memoryview_slice_copy(__pyx_v_memview, (&__pyx_v_memviewslice));
30079 __Pyx_XDECREF(__pyx_r);
30080 __pyx_t_1 = __pyx_memoryview_copy_object_from_slice(__pyx_v_memview, (&__pyx_v_memviewslice));
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1084, __pyx_L1_error)
30081 __Pyx_GOTREF(__pyx_t_1);
30082 __pyx_r = __pyx_t_1;
30096 __Pyx_XDECREF(__pyx_t_1);
30097 __Pyx_AddTraceback(
"View.MemoryView.memoryview_copy", __pyx_clineno, __pyx_lineno, __pyx_filename);
30100 __Pyx_XGIVEREF(__pyx_r);
30101 __Pyx_RefNannyFinishContext();
30113 static PyObject *__pyx_memoryview_copy_object_from_slice(
struct __pyx_memoryview_obj *__pyx_v_memview, __Pyx_memviewslice *__pyx_v_memviewslice) {
30114 PyObject *(*__pyx_v_to_object_func)(
char *);
30115 int (*__pyx_v_to_dtype_func)(
char *, PyObject *);
30116 PyObject *__pyx_r = NULL;
30117 __Pyx_RefNannyDeclarations
30120 PyObject *(*__pyx_t_3)(
char *);
30121 int (*__pyx_t_4)(
char *, PyObject *);
30122 PyObject *__pyx_t_5 = NULL;
30123 int __pyx_lineno = 0;
30124 const char *__pyx_filename = NULL;
30125 int __pyx_clineno = 0;
30126 __Pyx_RefNannySetupContext(
"memoryview_copy_from_slice", 0);
30135 __pyx_t_1 = __Pyx_TypeCheck(((PyObject *)__pyx_v_memview), __pyx_memoryviewslice_type);
30136 __pyx_t_2 = (__pyx_t_1 != 0);
30146 __pyx_t_3 = ((
struct __pyx_memoryviewslice_obj *)__pyx_v_memview)->to_object_func;
30147 __pyx_v_to_object_func = __pyx_t_3;
30156 __pyx_t_4 = ((
struct __pyx_memoryviewslice_obj *)__pyx_v_memview)->to_dtype_func;
30157 __pyx_v_to_dtype_func = __pyx_t_4;
30177 __pyx_v_to_object_func = NULL;
30186 __pyx_v_to_dtype_func = NULL;
30197 __Pyx_XDECREF(__pyx_r);
30206 __pyx_t_5 = __pyx_memoryview_fromslice((__pyx_v_memviewslice[0]), __pyx_v_memview->view.ndim, __pyx_v_to_object_func, __pyx_v_to_dtype_func, __pyx_v_memview->dtype_is_object);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1101, __pyx_L1_error)
30207 __Pyx_GOTREF(__pyx_t_5);
30208 __pyx_r = __pyx_t_5;
30222 __Pyx_XDECREF(__pyx_t_5);
30223 __Pyx_AddTraceback(
"View.MemoryView.memoryview_copy_from_slice", __pyx_clineno, __pyx_lineno, __pyx_filename);
30226 __Pyx_XGIVEREF(__pyx_r);
30227 __Pyx_RefNannyFinishContext();
30239 static Py_ssize_t abs_py_ssize_t(Py_ssize_t __pyx_v_arg) {
30240 Py_ssize_t __pyx_r;
30250 __pyx_t_1 = ((__pyx_v_arg < 0) != 0);
30260 __pyx_r = (-__pyx_v_arg);
30280 __pyx_r = __pyx_v_arg;
30305 static char __pyx_get_best_slice_order(__Pyx_memviewslice *__pyx_v_mslice,
int __pyx_v_ndim) {
30307 Py_ssize_t __pyx_v_c_stride;
30308 Py_ssize_t __pyx_v_f_stride;
30322 __pyx_v_c_stride = 0;
30331 __pyx_v_f_stride = 0;
30340 for (__pyx_t_1 = (__pyx_v_ndim - 1); __pyx_t_1 > -1; __pyx_t_1-=1) {
30341 __pyx_v_i = __pyx_t_1;
30350 __pyx_t_2 = (((__pyx_v_mslice->shape[__pyx_v_i]) > 1) != 0);
30360 __pyx_v_c_stride = (__pyx_v_mslice->strides[__pyx_v_i]);
30369 goto __pyx_L4_break;
30389 __pyx_t_1 = __pyx_v_ndim;
30390 __pyx_t_3 = __pyx_t_1;
30391 for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
30392 __pyx_v_i = __pyx_t_4;
30401 __pyx_t_2 = (((__pyx_v_mslice->shape[__pyx_v_i]) > 1) != 0);
30411 __pyx_v_f_stride = (__pyx_v_mslice->strides[__pyx_v_i]);
30420 goto __pyx_L7_break;
30440 __pyx_t_2 = ((abs_py_ssize_t(__pyx_v_c_stride) <= abs_py_ssize_t(__pyx_v_f_stride)) != 0);
30495 static void _copy_strided_to_strided(
char *__pyx_v_src_data, Py_ssize_t *__pyx_v_src_strides,
char *__pyx_v_dst_data, Py_ssize_t *__pyx_v_dst_strides, Py_ssize_t *__pyx_v_src_shape, Py_ssize_t *__pyx_v_dst_shape,
int __pyx_v_ndim,
size_t __pyx_v_itemsize) {
30496 CYTHON_UNUSED Py_ssize_t __pyx_v_i;
30497 CYTHON_UNUSED Py_ssize_t __pyx_v_src_extent;
30498 Py_ssize_t __pyx_v_dst_extent;
30499 Py_ssize_t __pyx_v_src_stride;
30500 Py_ssize_t __pyx_v_dst_stride;
30504 Py_ssize_t __pyx_t_4;
30505 Py_ssize_t __pyx_t_5;
30506 Py_ssize_t __pyx_t_6;
30515 __pyx_v_src_extent = (__pyx_v_src_shape[0]);
30524 __pyx_v_dst_extent = (__pyx_v_dst_shape[0]);
30533 __pyx_v_src_stride = (__pyx_v_src_strides[0]);
30542 __pyx_v_dst_stride = (__pyx_v_dst_strides[0]);
30551 __pyx_t_1 = ((__pyx_v_ndim == 1) != 0);
30561 __pyx_t_2 = ((__pyx_v_src_stride > 0) != 0);
30564 __pyx_t_1 = __pyx_t_2;
30565 goto __pyx_L5_bool_binop_done;
30567 __pyx_t_2 = ((__pyx_v_dst_stride > 0) != 0);
30570 __pyx_t_1 = __pyx_t_2;
30571 goto __pyx_L5_bool_binop_done;
30581 __pyx_t_2 = (((size_t)__pyx_v_src_stride) == __pyx_v_itemsize);
30583 __pyx_t_2 = (__pyx_v_itemsize == ((size_t)__pyx_v_dst_stride));
30585 __pyx_t_3 = (__pyx_t_2 != 0);
30586 __pyx_t_1 = __pyx_t_3;
30587 __pyx_L5_bool_binop_done:;
30605 (void)(memcpy(__pyx_v_dst_data, __pyx_v_src_data, (__pyx_v_itemsize * __pyx_v_dst_extent)));
30625 __pyx_t_4 = __pyx_v_dst_extent;
30626 __pyx_t_5 = __pyx_t_4;
30627 for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
30628 __pyx_v_i = __pyx_t_6;
30637 (void)(memcpy(__pyx_v_dst_data, __pyx_v_src_data, __pyx_v_itemsize));
30646 __pyx_v_src_data = (__pyx_v_src_data + __pyx_v_src_stride);
30655 __pyx_v_dst_data = (__pyx_v_dst_data + __pyx_v_dst_stride);
30678 __pyx_t_4 = __pyx_v_dst_extent;
30679 __pyx_t_5 = __pyx_t_4;
30680 for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
30681 __pyx_v_i = __pyx_t_6;
30690 _copy_strided_to_strided(__pyx_v_src_data, (__pyx_v_src_strides + 1), __pyx_v_dst_data, (__pyx_v_dst_strides + 1), (__pyx_v_src_shape + 1), (__pyx_v_dst_shape + 1), (__pyx_v_ndim - 1), __pyx_v_itemsize);
30699 __pyx_v_src_data = (__pyx_v_src_data + __pyx_v_src_stride);
30708 __pyx_v_dst_data = (__pyx_v_dst_data + __pyx_v_dst_stride);
30732 static void copy_strided_to_strided(__Pyx_memviewslice *__pyx_v_src, __Pyx_memviewslice *__pyx_v_dst,
int __pyx_v_ndim,
size_t __pyx_v_itemsize) {
30741 _copy_strided_to_strided(__pyx_v_src->data, __pyx_v_src->strides, __pyx_v_dst->data, __pyx_v_dst->strides, __pyx_v_src->shape, __pyx_v_dst->shape, __pyx_v_ndim, __pyx_v_itemsize);
30762 static Py_ssize_t __pyx_memoryview_slice_get_size(__Pyx_memviewslice *__pyx_v_src,
int __pyx_v_ndim) {
30763 Py_ssize_t __pyx_v_shape;
30764 Py_ssize_t __pyx_v_size;
30765 Py_ssize_t __pyx_r;
30766 Py_ssize_t __pyx_t_1;
30767 Py_ssize_t *__pyx_t_2;
30768 Py_ssize_t *__pyx_t_3;
30769 Py_ssize_t *__pyx_t_4;
30778 __pyx_t_1 = __pyx_v_src->memview->view.itemsize;
30779 __pyx_v_size = __pyx_t_1;
30788 __pyx_t_3 = (__pyx_v_src->shape + __pyx_v_ndim);
30789 for (__pyx_t_4 = __pyx_v_src->shape; __pyx_t_4 < __pyx_t_3; __pyx_t_4++) {
30790 __pyx_t_2 = __pyx_t_4;
30791 __pyx_v_shape = (__pyx_t_2[0]);
30800 __pyx_v_size = (__pyx_v_size * __pyx_v_shape);
30810 __pyx_r = __pyx_v_size;
30834 static Py_ssize_t __pyx_fill_contig_strides_array(Py_ssize_t *__pyx_v_shape, Py_ssize_t *__pyx_v_strides, Py_ssize_t __pyx_v_stride,
int __pyx_v_ndim,
char __pyx_v_order) {
30836 Py_ssize_t __pyx_r;
30849 __pyx_t_1 = ((__pyx_v_order ==
'F') != 0);
30859 __pyx_t_2 = __pyx_v_ndim;
30860 __pyx_t_3 = __pyx_t_2;
30861 for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
30862 __pyx_v_idx = __pyx_t_4;
30871 (__pyx_v_strides[__pyx_v_idx]) = __pyx_v_stride;
30880 __pyx_v_stride = (__pyx_v_stride * (__pyx_v_shape[__pyx_v_idx]));
30901 for (__pyx_t_2 = (__pyx_v_ndim - 1); __pyx_t_2 > -1; __pyx_t_2-=1) {
30902 __pyx_v_idx = __pyx_t_2;
30911 (__pyx_v_strides[__pyx_v_idx]) = __pyx_v_stride;
30920 __pyx_v_stride = (__pyx_v_stride * (__pyx_v_shape[__pyx_v_idx]));
30932 __pyx_r = __pyx_v_stride;
30956 static void *__pyx_memoryview_copy_data_to_temp(__Pyx_memviewslice *__pyx_v_src, __Pyx_memviewslice *__pyx_v_tmpslice,
char __pyx_v_order,
int __pyx_v_ndim) {
30958 void *__pyx_v_result;
30959 size_t __pyx_v_itemsize;
30960 size_t __pyx_v_size;
30962 Py_ssize_t __pyx_t_1;
30965 struct __pyx_memoryview_obj *__pyx_t_4;
30968 int __pyx_lineno = 0;
30969 const char *__pyx_filename = NULL;
30970 int __pyx_clineno = 0;
30979 __pyx_t_1 = __pyx_v_src->memview->view.itemsize;
30980 __pyx_v_itemsize = __pyx_t_1;
30989 __pyx_v_size = __pyx_memoryview_slice_get_size(__pyx_v_src, __pyx_v_ndim);
30998 __pyx_v_result = malloc(__pyx_v_size);
31007 __pyx_t_2 = ((!(__pyx_v_result != 0)) != 0);
31017 __pyx_t_3 = __pyx_memoryview_err(__pyx_builtin_MemoryError, NULL);
if (unlikely(__pyx_t_3 == ((
int)-1))) __PYX_ERR(0, 1224, __pyx_L1_error)
31035 __pyx_v_tmpslice->data = ((
char *)__pyx_v_result);
31044 __pyx_t_4 = __pyx_v_src->memview;
31045 __pyx_v_tmpslice->memview = __pyx_t_4;
31054 __pyx_t_3 = __pyx_v_ndim;
31055 __pyx_t_5 = __pyx_t_3;
31056 for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
31057 __pyx_v_i = __pyx_t_6;
31066 (__pyx_v_tmpslice->shape[__pyx_v_i]) = (__pyx_v_src->shape[__pyx_v_i]);
31075 (__pyx_v_tmpslice->suboffsets[__pyx_v_i]) = -1
L;
31085 (void)(__pyx_fill_contig_strides_array((&(__pyx_v_tmpslice->shape[0])), (&(__pyx_v_tmpslice->strides[0])), __pyx_v_itemsize, __pyx_v_ndim, __pyx_v_order));
31094 __pyx_t_3 = __pyx_v_ndim;
31095 __pyx_t_5 = __pyx_t_3;
31096 for (__pyx_t_6 = 0; __pyx_t_6 < __pyx_t_5; __pyx_t_6+=1) {
31097 __pyx_v_i = __pyx_t_6;
31106 __pyx_t_2 = (((__pyx_v_tmpslice->shape[__pyx_v_i]) == 1) != 0);
31116 (__pyx_v_tmpslice->strides[__pyx_v_i]) = 0;
31135 __pyx_t_2 = (__pyx_memviewslice_is_contig((__pyx_v_src[0]), __pyx_v_order, __pyx_v_ndim) != 0);
31145 (void)(memcpy(__pyx_v_result, __pyx_v_src->data, __pyx_v_size));
31165 copy_strided_to_strided(__pyx_v_src, __pyx_v_tmpslice, __pyx_v_ndim, __pyx_v_itemsize);
31176 __pyx_r = __pyx_v_result;
31191 PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
31193 __Pyx_AddTraceback(
"View.MemoryView.copy_data_to_temp", __pyx_clineno, __pyx_lineno, __pyx_filename);
31195 __Pyx_PyGILState_Release(__pyx_gilstate_save);
31211 static int __pyx_memoryview_err_extents(
int __pyx_v_i, Py_ssize_t __pyx_v_extent1, Py_ssize_t __pyx_v_extent2) {
31213 __Pyx_RefNannyDeclarations
31214 PyObject *__pyx_t_1 = NULL;
31215 PyObject *__pyx_t_2 = NULL;
31216 PyObject *__pyx_t_3 = NULL;
31217 PyObject *__pyx_t_4 = NULL;
31218 int __pyx_lineno = 0;
31219 const char *__pyx_filename = NULL;
31220 int __pyx_clineno = 0;
31222 PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
31224 __Pyx_RefNannySetupContext(
"_err_extents", 0);
31233 __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_i);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1254, __pyx_L1_error)
31234 __Pyx_GOTREF(__pyx_t_1);
31235 __pyx_t_2 = PyInt_FromSsize_t(__pyx_v_extent1);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1254, __pyx_L1_error)
31236 __Pyx_GOTREF(__pyx_t_2);
31237 __pyx_t_3 = PyInt_FromSsize_t(__pyx_v_extent2);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1254, __pyx_L1_error)
31238 __Pyx_GOTREF(__pyx_t_3);
31239 __pyx_t_4 = PyTuple_New(3);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1254, __pyx_L1_error)
31240 __Pyx_GOTREF(__pyx_t_4);
31241 __Pyx_GIVEREF(__pyx_t_1);
31242 PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_1);
31243 __Pyx_GIVEREF(__pyx_t_2);
31244 PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_2);
31245 __Pyx_GIVEREF(__pyx_t_3);
31246 PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_3);
31258 __pyx_t_3 = __Pyx_PyString_Format(__pyx_kp_s_got_differing_extents_in_dimensi, __pyx_t_4);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1253, __pyx_L1_error)
31259 __Pyx_GOTREF(__pyx_t_3);
31260 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
31261 __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_builtin_ValueError, __pyx_t_3);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1253, __pyx_L1_error)
31262 __Pyx_GOTREF(__pyx_t_4);
31263 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
31264 __Pyx_Raise(__pyx_t_4, 0, 0, 0);
31265 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
31266 __PYX_ERR(0, 1253, __pyx_L1_error)
31278 __Pyx_XDECREF(__pyx_t_1);
31279 __Pyx_XDECREF(__pyx_t_2);
31280 __Pyx_XDECREF(__pyx_t_3);
31281 __Pyx_XDECREF(__pyx_t_4);
31282 __Pyx_AddTraceback(
"View.MemoryView._err_extents", __pyx_clineno, __pyx_lineno, __pyx_filename);
31284 __Pyx_RefNannyFinishContext();
31286 __Pyx_PyGILState_Release(__pyx_gilstate_save);
31299 static int __pyx_memoryview_err_dim(PyObject *__pyx_v_error,
char *__pyx_v_msg,
int __pyx_v_dim) {
31301 __Pyx_RefNannyDeclarations
31302 PyObject *__pyx_t_1 = NULL;
31303 PyObject *__pyx_t_2 = NULL;
31304 PyObject *__pyx_t_3 = NULL;
31305 PyObject *__pyx_t_4 = NULL;
31306 int __pyx_lineno = 0;
31307 const char *__pyx_filename = NULL;
31308 int __pyx_clineno = 0;
31310 PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
31312 __Pyx_RefNannySetupContext(
"_err_dim", 0);
31313 __Pyx_INCREF(__pyx_v_error);
31322 __pyx_t_2 = __Pyx_decode_c_string(__pyx_v_msg, 0, strlen(__pyx_v_msg), NULL, NULL, PyUnicode_DecodeASCII);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1258, __pyx_L1_error)
31323 __Pyx_GOTREF(__pyx_t_2);
31324 __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_dim);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1258, __pyx_L1_error)
31325 __Pyx_GOTREF(__pyx_t_3);
31326 __pyx_t_4 = PyUnicode_Format(__pyx_t_2, __pyx_t_3);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1258, __pyx_L1_error)
31327 __Pyx_GOTREF(__pyx_t_4);
31328 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
31329 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
31330 __Pyx_INCREF(__pyx_v_error);
31331 __pyx_t_3 = __pyx_v_error; __pyx_t_2 = NULL;
31332 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
31333 __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_3);
31334 if (likely(__pyx_t_2)) {
31335 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_3);
31336 __Pyx_INCREF(__pyx_t_2);
31337 __Pyx_INCREF(
function);
31338 __Pyx_DECREF_SET(__pyx_t_3,
function);
31341 __pyx_t_1 = (__pyx_t_2) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_2, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_4);
31342 __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
31343 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
31344 if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1258, __pyx_L1_error)
31345 __Pyx_GOTREF(__pyx_t_1);
31346 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
31347 __Pyx_Raise(__pyx_t_1, 0, 0, 0);
31348 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
31349 __PYX_ERR(0, 1258, __pyx_L1_error)
31361 __Pyx_XDECREF(__pyx_t_1);
31362 __Pyx_XDECREF(__pyx_t_2);
31363 __Pyx_XDECREF(__pyx_t_3);
31364 __Pyx_XDECREF(__pyx_t_4);
31365 __Pyx_AddTraceback(
"View.MemoryView._err_dim", __pyx_clineno, __pyx_lineno, __pyx_filename);
31367 __Pyx_XDECREF(__pyx_v_error);
31368 __Pyx_RefNannyFinishContext();
31370 __Pyx_PyGILState_Release(__pyx_gilstate_save);
31383 static int __pyx_memoryview_err(PyObject *__pyx_v_error,
char *__pyx_v_msg) {
31385 __Pyx_RefNannyDeclarations
31387 PyObject *__pyx_t_2 = NULL;
31388 PyObject *__pyx_t_3 = NULL;
31389 PyObject *__pyx_t_4 = NULL;
31390 PyObject *__pyx_t_5 = NULL;
31391 int __pyx_lineno = 0;
31392 const char *__pyx_filename = NULL;
31393 int __pyx_clineno = 0;
31395 PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
31397 __Pyx_RefNannySetupContext(
"_err", 0);
31398 __Pyx_INCREF(__pyx_v_error);
31407 __pyx_t_1 = ((__pyx_v_msg != NULL) != 0);
31408 if (unlikely(__pyx_t_1)) {
31417 __pyx_t_3 = __Pyx_decode_c_string(__pyx_v_msg, 0, strlen(__pyx_v_msg), NULL, NULL, PyUnicode_DecodeASCII);
if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1263, __pyx_L1_error)
31418 __Pyx_GOTREF(__pyx_t_3);
31419 __Pyx_INCREF(__pyx_v_error);
31420 __pyx_t_4 = __pyx_v_error; __pyx_t_5 = NULL;
31421 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
31422 __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_4);
31423 if (likely(__pyx_t_5)) {
31424 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_4);
31425 __Pyx_INCREF(__pyx_t_5);
31426 __Pyx_INCREF(
function);
31427 __Pyx_DECREF_SET(__pyx_t_4,
function);
31430 __pyx_t_2 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_5, __pyx_t_3) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_3);
31431 __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
31432 __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
31433 if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1263, __pyx_L1_error)
31434 __Pyx_GOTREF(__pyx_t_2);
31435 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
31436 __Pyx_Raise(__pyx_t_2, 0, 0, 0);
31437 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
31438 __PYX_ERR(0, 1263, __pyx_L1_error)
31457 __Pyx_Raise(__pyx_v_error, 0, 0, 0);
31458 __PYX_ERR(0, 1265, __pyx_L1_error)
31471 __Pyx_XDECREF(__pyx_t_2);
31472 __Pyx_XDECREF(__pyx_t_3);
31473 __Pyx_XDECREF(__pyx_t_4);
31474 __Pyx_XDECREF(__pyx_t_5);
31475 __Pyx_AddTraceback(
"View.MemoryView._err", __pyx_clineno, __pyx_lineno, __pyx_filename);
31477 __Pyx_XDECREF(__pyx_v_error);
31478 __Pyx_RefNannyFinishContext();
31480 __Pyx_PyGILState_Release(__pyx_gilstate_save);
31493 static int __pyx_memoryview_copy_contents(__Pyx_memviewslice __pyx_v_src, __Pyx_memviewslice __pyx_v_dst,
int __pyx_v_src_ndim,
int __pyx_v_dst_ndim,
int __pyx_v_dtype_is_object) {
31494 void *__pyx_v_tmpdata;
31495 size_t __pyx_v_itemsize;
31497 char __pyx_v_order;
31498 int __pyx_v_broadcasting;
31499 int __pyx_v_direct_copy;
31500 __Pyx_memviewslice __pyx_v_tmp;
31503 Py_ssize_t __pyx_t_1;
31511 int __pyx_lineno = 0;
31512 const char *__pyx_filename = NULL;
31513 int __pyx_clineno = 0;
31522 __pyx_v_tmpdata = NULL;
31531 __pyx_t_1 = __pyx_v_src.memview->view.itemsize;
31532 __pyx_v_itemsize = __pyx_t_1;
31541 __pyx_v_order = __pyx_get_best_slice_order((&__pyx_v_src), __pyx_v_src_ndim);
31550 __pyx_v_broadcasting = 0;
31559 __pyx_v_direct_copy = 0;
31568 __pyx_t_2 = ((__pyx_v_src_ndim < __pyx_v_dst_ndim) != 0);
31578 __pyx_memoryview_broadcast_leading((&__pyx_v_src), __pyx_v_src_ndim, __pyx_v_dst_ndim);
31597 __pyx_t_2 = ((__pyx_v_dst_ndim < __pyx_v_src_ndim) != 0);
31607 __pyx_memoryview_broadcast_leading((&__pyx_v_dst), __pyx_v_dst_ndim, __pyx_v_src_ndim);
31626 __pyx_t_3 = __pyx_v_dst_ndim;
31627 __pyx_t_4 = __pyx_v_src_ndim;
31628 if (((__pyx_t_3 > __pyx_t_4) != 0)) {
31629 __pyx_t_5 = __pyx_t_3;
31631 __pyx_t_5 = __pyx_t_4;
31633 __pyx_v_ndim = __pyx_t_5;
31642 __pyx_t_5 = __pyx_v_ndim;
31643 __pyx_t_3 = __pyx_t_5;
31644 for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
31645 __pyx_v_i = __pyx_t_4;
31654 __pyx_t_2 = (((__pyx_v_src.shape[__pyx_v_i]) != (__pyx_v_dst.shape[__pyx_v_i])) != 0);
31664 __pyx_t_2 = (((__pyx_v_src.shape[__pyx_v_i]) == 1) != 0);
31674 __pyx_v_broadcasting = 1;
31683 (__pyx_v_src.strides[__pyx_v_i]) = 0;
31703 __pyx_t_6 = __pyx_memoryview_err_extents(__pyx_v_i, (__pyx_v_dst.shape[__pyx_v_i]), (__pyx_v_src.shape[__pyx_v_i]));
if (unlikely(__pyx_t_6 == ((
int)-1))) __PYX_ERR(0, 1297, __pyx_L1_error)
31723 __pyx_t_2 = (((__pyx_v_src.suboffsets[__pyx_v_i]) >= 0) != 0);
31733 __pyx_t_6 = __pyx_memoryview_err_dim(__pyx_builtin_ValueError, ((
char *)
"Dimension %d is not direct"), __pyx_v_i);
if (unlikely(__pyx_t_6 == ((
int)-1))) __PYX_ERR(0, 1300, __pyx_L1_error)
31752 __pyx_t_2 = (__pyx_slices_overlap((&__pyx_v_src), (&__pyx_v_dst), __pyx_v_ndim, __pyx_v_itemsize) != 0);
31762 __pyx_t_2 = ((!(__pyx_memviewslice_is_contig(__pyx_v_src, __pyx_v_order, __pyx_v_ndim) != 0)) != 0);
31772 __pyx_v_order = __pyx_get_best_slice_order((&__pyx_v_dst), __pyx_v_ndim);
31790 __pyx_t_7 = __pyx_memoryview_copy_data_to_temp((&__pyx_v_src), (&__pyx_v_tmp), __pyx_v_order, __pyx_v_ndim);
if (unlikely(__pyx_t_7 == ((
void *)NULL))) __PYX_ERR(0, 1307, __pyx_L1_error)
31791 __pyx_v_tmpdata = __pyx_t_7;
31800 __pyx_v_src = __pyx_v_tmp;
31818 __pyx_t_2 = ((!(__pyx_v_broadcasting != 0)) != 0);
31828 __pyx_t_2 = (__pyx_memviewslice_is_contig(__pyx_v_src,
'C', __pyx_v_ndim) != 0);
31838 __pyx_v_direct_copy = __pyx_memviewslice_is_contig(__pyx_v_dst,
'C', __pyx_v_ndim);
31857 __pyx_t_2 = (__pyx_memviewslice_is_contig(__pyx_v_src,
'F', __pyx_v_ndim) != 0);
31867 __pyx_v_direct_copy = __pyx_memviewslice_is_contig(__pyx_v_dst,
'F', __pyx_v_ndim);
31886 __pyx_t_2 = (__pyx_v_direct_copy != 0);
31896 __pyx_memoryview_refcount_copying((&__pyx_v_dst), __pyx_v_dtype_is_object, __pyx_v_ndim, 0);
31905 (void)(memcpy(__pyx_v_dst.data, __pyx_v_src.data, __pyx_memoryview_slice_get_size((&__pyx_v_src), __pyx_v_ndim)));
31914 __pyx_memoryview_refcount_copying((&__pyx_v_dst), __pyx_v_dtype_is_object, __pyx_v_ndim, 1);
31923 free(__pyx_v_tmpdata);
31960 __pyx_t_2 = (__pyx_v_order ==
'F');
31962 __pyx_t_2 = (
'F' == __pyx_get_best_slice_order((&__pyx_v_dst), __pyx_v_ndim));
31964 __pyx_t_8 = (__pyx_t_2 != 0);
31974 __pyx_t_5 = __pyx_memslice_transpose((&__pyx_v_src));
if (unlikely(__pyx_t_5 == ((
int)0))) __PYX_ERR(0, 1329, __pyx_L1_error)
31983 __pyx_t_5 = __pyx_memslice_transpose((&__pyx_v_dst));
if (unlikely(__pyx_t_5 == ((
int)0))) __PYX_ERR(0, 1330, __pyx_L1_error)
32001 __pyx_memoryview_refcount_copying((&__pyx_v_dst), __pyx_v_dtype_is_object, __pyx_v_ndim, 0);
32010 copy_strided_to_strided((&__pyx_v_src), (&__pyx_v_dst), __pyx_v_ndim, __pyx_v_itemsize);
32019 __pyx_memoryview_refcount_copying((&__pyx_v_dst), __pyx_v_dtype_is_object, __pyx_v_ndim, 1);
32028 free(__pyx_v_tmpdata);
32052 PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
32054 __Pyx_AddTraceback(
"View.MemoryView.memoryview_copy_contents", __pyx_clineno, __pyx_lineno, __pyx_filename);
32056 __Pyx_PyGILState_Release(__pyx_gilstate_save);
32072 static void __pyx_memoryview_broadcast_leading(__Pyx_memviewslice *__pyx_v_mslice,
int __pyx_v_ndim,
int __pyx_v_ndim_other) {
32074 int __pyx_v_offset;
32086 __pyx_v_offset = (__pyx_v_ndim_other - __pyx_v_ndim);
32095 for (__pyx_t_1 = (__pyx_v_ndim - 1); __pyx_t_1 > -1; __pyx_t_1-=1) {
32096 __pyx_v_i = __pyx_t_1;
32105 (__pyx_v_mslice->shape[(__pyx_v_i + __pyx_v_offset)]) = (__pyx_v_mslice->shape[__pyx_v_i]);
32114 (__pyx_v_mslice->strides[(__pyx_v_i + __pyx_v_offset)]) = (__pyx_v_mslice->strides[__pyx_v_i]);
32123 (__pyx_v_mslice->suboffsets[(__pyx_v_i + __pyx_v_offset)]) = (__pyx_v_mslice->suboffsets[__pyx_v_i]);
32133 __pyx_t_1 = __pyx_v_offset;
32134 __pyx_t_2 = __pyx_t_1;
32135 for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
32136 __pyx_v_i = __pyx_t_3;
32145 (__pyx_v_mslice->shape[__pyx_v_i]) = 1;
32154 (__pyx_v_mslice->strides[__pyx_v_i]) = (__pyx_v_mslice->strides[0]);
32163 (__pyx_v_mslice->suboffsets[__pyx_v_i]) = -1
L;
32185 static void __pyx_memoryview_refcount_copying(__Pyx_memviewslice *__pyx_v_dst,
int __pyx_v_dtype_is_object,
int __pyx_v_ndim,
int __pyx_v_inc) {
32195 __pyx_t_1 = (__pyx_v_dtype_is_object != 0);
32205 __pyx_memoryview_refcount_objects_in_slice_with_gil(__pyx_v_dst->data, __pyx_v_dst->shape, __pyx_v_dst->strides, __pyx_v_ndim, __pyx_v_inc);
32235 static void __pyx_memoryview_refcount_objects_in_slice_with_gil(
char *__pyx_v_data, Py_ssize_t *__pyx_v_shape, Py_ssize_t *__pyx_v_strides,
int __pyx_v_ndim,
int __pyx_v_inc) {
32236 __Pyx_RefNannyDeclarations
32238 PyGILState_STATE __pyx_gilstate_save = __Pyx_PyGILState_Ensure();
32240 __Pyx_RefNannySetupContext(
"refcount_objects_in_slice_with_gil", 0);
32249 __pyx_memoryview_refcount_objects_in_slice(__pyx_v_data, __pyx_v_shape, __pyx_v_strides, __pyx_v_ndim, __pyx_v_inc);
32260 __Pyx_RefNannyFinishContext();
32262 __Pyx_PyGILState_Release(__pyx_gilstate_save);
32274 static void __pyx_memoryview_refcount_objects_in_slice(
char *__pyx_v_data, Py_ssize_t *__pyx_v_shape, Py_ssize_t *__pyx_v_strides,
int __pyx_v_ndim,
int __pyx_v_inc) {
32275 CYTHON_UNUSED Py_ssize_t __pyx_v_i;
32276 __Pyx_RefNannyDeclarations
32277 Py_ssize_t __pyx_t_1;
32278 Py_ssize_t __pyx_t_2;
32279 Py_ssize_t __pyx_t_3;
32281 __Pyx_RefNannySetupContext(
"refcount_objects_in_slice", 0);
32290 __pyx_t_1 = (__pyx_v_shape[0]);
32291 __pyx_t_2 = __pyx_t_1;
32292 for (__pyx_t_3 = 0; __pyx_t_3 < __pyx_t_2; __pyx_t_3+=1) {
32293 __pyx_v_i = __pyx_t_3;
32302 __pyx_t_4 = ((__pyx_v_ndim == 1) != 0);
32312 __pyx_t_4 = (__pyx_v_inc != 0);
32322 Py_INCREF((((PyObject **)__pyx_v_data)[0]));
32342 Py_DECREF((((PyObject **)__pyx_v_data)[0]));
32372 __pyx_memoryview_refcount_objects_in_slice(__pyx_v_data, (__pyx_v_shape + 1), (__pyx_v_strides + 1), (__pyx_v_ndim - 1), __pyx_v_inc);
32383 __pyx_v_data = (__pyx_v_data + (__pyx_v_strides[0]));
32395 __Pyx_RefNannyFinishContext();
32406 static void __pyx_memoryview_slice_assign_scalar(__Pyx_memviewslice *__pyx_v_dst,
int __pyx_v_ndim,
size_t __pyx_v_itemsize,
void *__pyx_v_item,
int __pyx_v_dtype_is_object) {
32415 __pyx_memoryview_refcount_copying(__pyx_v_dst, __pyx_v_dtype_is_object, __pyx_v_ndim, 0);
32424 __pyx_memoryview__slice_assign_scalar(__pyx_v_dst->data, __pyx_v_dst->shape, __pyx_v_dst->strides, __pyx_v_ndim, __pyx_v_itemsize, __pyx_v_item);
32433 __pyx_memoryview_refcount_copying(__pyx_v_dst, __pyx_v_dtype_is_object, __pyx_v_ndim, 1);
32454 static void __pyx_memoryview__slice_assign_scalar(
char *__pyx_v_data, Py_ssize_t *__pyx_v_shape, Py_ssize_t *__pyx_v_strides,
int __pyx_v_ndim,
size_t __pyx_v_itemsize,
void *__pyx_v_item) {
32455 CYTHON_UNUSED Py_ssize_t __pyx_v_i;
32456 Py_ssize_t __pyx_v_stride;
32457 Py_ssize_t __pyx_v_extent;
32459 Py_ssize_t __pyx_t_2;
32460 Py_ssize_t __pyx_t_3;
32461 Py_ssize_t __pyx_t_4;
32470 __pyx_v_stride = (__pyx_v_strides[0]);
32479 __pyx_v_extent = (__pyx_v_shape[0]);
32488 __pyx_t_1 = ((__pyx_v_ndim == 1) != 0);
32498 __pyx_t_2 = __pyx_v_extent;
32499 __pyx_t_3 = __pyx_t_2;
32500 for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
32501 __pyx_v_i = __pyx_t_4;
32510 (void)(memcpy(__pyx_v_data, __pyx_v_item, __pyx_v_itemsize));
32519 __pyx_v_data = (__pyx_v_data + __pyx_v_stride);
32540 __pyx_t_2 = __pyx_v_extent;
32541 __pyx_t_3 = __pyx_t_2;
32542 for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_t_3; __pyx_t_4+=1) {
32543 __pyx_v_i = __pyx_t_4;
32552 __pyx_memoryview__slice_assign_scalar(__pyx_v_data, (__pyx_v_shape + 1), (__pyx_v_strides + 1), (__pyx_v_ndim - 1), __pyx_v_itemsize, __pyx_v_item);
32561 __pyx_v_data = (__pyx_v_data + __pyx_v_stride);
32584 static PyObject *__pyx_pw_15View_dot_MemoryView_1__pyx_unpickle_Enum(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds);
32585 static PyMethodDef __pyx_mdef_15View_dot_MemoryView_1__pyx_unpickle_Enum = {
"__pyx_unpickle_Enum", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_15View_dot_MemoryView_1__pyx_unpickle_Enum, METH_VARARGS|METH_KEYWORDS, 0};
32586 static PyObject *__pyx_pw_15View_dot_MemoryView_1__pyx_unpickle_Enum(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
32587 PyObject *__pyx_v___pyx_type = 0;
32588 long __pyx_v___pyx_checksum;
32589 PyObject *__pyx_v___pyx_state = 0;
32590 int __pyx_lineno = 0;
32591 const char *__pyx_filename = NULL;
32592 int __pyx_clineno = 0;
32593 PyObject *__pyx_r = 0;
32594 __Pyx_RefNannyDeclarations
32595 __Pyx_RefNannySetupContext(
"__pyx_unpickle_Enum (wrapper)", 0);
32597 static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_type,&__pyx_n_s_pyx_checksum,&__pyx_n_s_pyx_state,0};
32598 PyObject* values[3] = {0,0,0};
32599 if (unlikely(__pyx_kwds)) {
32600 Py_ssize_t kw_args;
32601 const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
32602 switch (pos_args) {
32603 case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
32604 CYTHON_FALLTHROUGH;
32605 case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
32606 CYTHON_FALLTHROUGH;
32607 case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
32608 CYTHON_FALLTHROUGH;
32610 default:
goto __pyx_L5_argtuple_error;
32612 kw_args = PyDict_Size(__pyx_kwds);
32613 switch (pos_args) {
32615 if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_type)) != 0)) kw_args--;
32616 else goto __pyx_L5_argtuple_error;
32617 CYTHON_FALLTHROUGH;
32619 if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_checksum)) != 0)) kw_args--;
32621 __Pyx_RaiseArgtupleInvalid(
"__pyx_unpickle_Enum", 1, 3, 3, 1); __PYX_ERR(0, 1, __pyx_L3_error)
32623 CYTHON_FALLTHROUGH;
32625 if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_state)) != 0)) kw_args--;
32627 __Pyx_RaiseArgtupleInvalid(
"__pyx_unpickle_Enum", 1, 3, 3, 2); __PYX_ERR(0, 1, __pyx_L3_error)
32630 if (unlikely(kw_args > 0)) {
32631 if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args,
"__pyx_unpickle_Enum") < 0)) __PYX_ERR(0, 1, __pyx_L3_error)
32633 }
else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
32634 goto __pyx_L5_argtuple_error;
32636 values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
32637 values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
32638 values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
32640 __pyx_v___pyx_type = values[0];
32641 __pyx_v___pyx_checksum = __Pyx_PyInt_As_long(values[1]);
if (unlikely((__pyx_v___pyx_checksum == (
long)-1) && PyErr_Occurred())) __PYX_ERR(0, 1, __pyx_L3_error)
32642 __pyx_v___pyx_state = values[2];
32644 goto __pyx_L4_argument_unpacking_done;
32645 __pyx_L5_argtuple_error:;
32646 __Pyx_RaiseArgtupleInvalid(
"__pyx_unpickle_Enum", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 1, __pyx_L3_error)
32648 __Pyx_AddTraceback(
"View.MemoryView.__pyx_unpickle_Enum", __pyx_clineno, __pyx_lineno, __pyx_filename);
32649 __Pyx_RefNannyFinishContext();
32651 __pyx_L4_argument_unpacking_done:;
32652 __pyx_r = __pyx_pf_15View_dot_MemoryView___pyx_unpickle_Enum(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state);
32655 __Pyx_RefNannyFinishContext();
32659 static PyObject *__pyx_pf_15View_dot_MemoryView___pyx_unpickle_Enum(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type,
long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) {
32660 PyObject *__pyx_v___pyx_PickleError = 0;
32661 PyObject *__pyx_v___pyx_result = 0;
32662 PyObject *__pyx_r = NULL;
32663 __Pyx_RefNannyDeclarations
32664 PyObject *__pyx_t_1 = NULL;
32667 PyObject *__pyx_t_4 = NULL;
32668 PyObject *__pyx_t_5 = NULL;
32669 PyObject *__pyx_t_6 = NULL;
32670 int __pyx_lineno = 0;
32671 const char *__pyx_filename = NULL;
32672 int __pyx_clineno = 0;
32673 __Pyx_RefNannySetupContext(
"__pyx_unpickle_Enum", 0);
32682 __pyx_t_1 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 4, __pyx_L1_error)
32683 __Pyx_GOTREF(__pyx_t_1);
32684 __pyx_t_2 = (__Pyx_PySequence_ContainsTF(__pyx_t_1, __pyx_tuple__26, Py_NE));
if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 4, __pyx_L1_error)
32685 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
32686 __pyx_t_3 = (__pyx_t_2 != 0);
32696 __pyx_t_1 = PyList_New(1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 5, __pyx_L1_error)
32697 __Pyx_GOTREF(__pyx_t_1);
32698 __Pyx_INCREF(__pyx_n_s_PickleError);
32699 __Pyx_GIVEREF(__pyx_n_s_PickleError);
32700 PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_PickleError);
32701 __pyx_t_4 = __Pyx_Import(__pyx_n_s_pickle, __pyx_t_1, 0);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 5, __pyx_L1_error)
32702 __Pyx_GOTREF(__pyx_t_4);
32703 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
32704 __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_4, __pyx_n_s_PickleError);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 5, __pyx_L1_error)
32705 __Pyx_GOTREF(__pyx_t_1);
32706 __Pyx_INCREF(__pyx_t_1);
32707 __pyx_v___pyx_PickleError = __pyx_t_1;
32708 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
32709 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
32718 __pyx_t_1 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 6, __pyx_L1_error)
32719 __Pyx_GOTREF(__pyx_t_1);
32720 __pyx_t_5 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_0x_x_vs_0, __pyx_t_1);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 6, __pyx_L1_error)
32721 __Pyx_GOTREF(__pyx_t_5);
32722 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
32723 __Pyx_INCREF(__pyx_v___pyx_PickleError);
32724 __pyx_t_1 = __pyx_v___pyx_PickleError; __pyx_t_6 = NULL;
32725 if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
32726 __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_1);
32727 if (likely(__pyx_t_6)) {
32728 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_1);
32729 __Pyx_INCREF(__pyx_t_6);
32730 __Pyx_INCREF(
function);
32731 __Pyx_DECREF_SET(__pyx_t_1,
function);
32734 __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_t_5);
32735 __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
32736 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
32737 if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 6, __pyx_L1_error)
32738 __Pyx_GOTREF(__pyx_t_4);
32739 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
32740 __Pyx_Raise(__pyx_t_4, 0, 0, 0);
32741 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
32742 __PYX_ERR(0, 6, __pyx_L1_error)
32760 __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_MemviewEnum_type), __pyx_n_s_new);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 7, __pyx_L1_error)
32761 __Pyx_GOTREF(__pyx_t_1);
32763 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) {
32764 __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_1);
32765 if (likely(__pyx_t_5)) {
32766 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_1);
32767 __Pyx_INCREF(__pyx_t_5);
32768 __Pyx_INCREF(
function);
32769 __Pyx_DECREF_SET(__pyx_t_1,
function);
32772 __pyx_t_4 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_1, __pyx_t_5, __pyx_v___pyx_type) : __Pyx_PyObject_CallOneArg(__pyx_t_1, __pyx_v___pyx_type);
32773 __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
32774 if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 7, __pyx_L1_error)
32775 __Pyx_GOTREF(__pyx_t_4);
32776 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
32777 __pyx_v___pyx_result = __pyx_t_4;
32787 __pyx_t_3 = (__pyx_v___pyx_state != Py_None);
32788 __pyx_t_2 = (__pyx_t_3 != 0);
32798 if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(0, 9, __pyx_L1_error)
32799 __pyx_t_4 = __pyx_unpickle_Enum__set_state(((
struct __pyx_MemviewEnum_obj *)__pyx_v___pyx_result), ((PyObject*)__pyx_v___pyx_state));
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 9, __pyx_L1_error)
32800 __Pyx_GOTREF(__pyx_t_4);
32801 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
32819 __Pyx_XDECREF(__pyx_r);
32820 __Pyx_INCREF(__pyx_v___pyx_result);
32821 __pyx_r = __pyx_v___pyx_result;
32832 __Pyx_XDECREF(__pyx_t_1);
32833 __Pyx_XDECREF(__pyx_t_4);
32834 __Pyx_XDECREF(__pyx_t_5);
32835 __Pyx_XDECREF(__pyx_t_6);
32836 __Pyx_AddTraceback(
"View.MemoryView.__pyx_unpickle_Enum", __pyx_clineno, __pyx_lineno, __pyx_filename);
32839 __Pyx_XDECREF(__pyx_v___pyx_PickleError);
32840 __Pyx_XDECREF(__pyx_v___pyx_result);
32841 __Pyx_XGIVEREF(__pyx_r);
32842 __Pyx_RefNannyFinishContext();
32854 static PyObject *__pyx_unpickle_Enum__set_state(
struct __pyx_MemviewEnum_obj *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) {
32855 PyObject *__pyx_r = NULL;
32856 __Pyx_RefNannyDeclarations
32857 PyObject *__pyx_t_1 = NULL;
32859 Py_ssize_t __pyx_t_3;
32862 PyObject *__pyx_t_6 = NULL;
32863 PyObject *__pyx_t_7 = NULL;
32864 PyObject *__pyx_t_8 = NULL;
32865 int __pyx_lineno = 0;
32866 const char *__pyx_filename = NULL;
32867 int __pyx_clineno = 0;
32868 __Pyx_RefNannySetupContext(
"__pyx_unpickle_Enum__set_state", 0);
32877 if (unlikely(__pyx_v___pyx_state == Py_None)) {
32878 PyErr_SetString(PyExc_TypeError,
"'NoneType' object is not subscriptable");
32879 __PYX_ERR(0, 12, __pyx_L1_error)
32881 __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0,
long, 1, __Pyx_PyInt_From_long, 0, 0, 1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 12, __pyx_L1_error)
32882 __Pyx_GOTREF(__pyx_t_1);
32883 __Pyx_GIVEREF(__pyx_t_1);
32884 __Pyx_GOTREF(__pyx_v___pyx_result->name);
32885 __Pyx_DECREF(__pyx_v___pyx_result->name);
32886 __pyx_v___pyx_result->name = __pyx_t_1;
32895 if (unlikely(__pyx_v___pyx_state == Py_None)) {
32896 PyErr_SetString(PyExc_TypeError,
"object of type 'NoneType' has no len()");
32897 __PYX_ERR(0, 13, __pyx_L1_error)
32899 __pyx_t_3 = PyTuple_GET_SIZE(__pyx_v___pyx_state);
if (unlikely(__pyx_t_3 == ((Py_ssize_t)-1))) __PYX_ERR(0, 13, __pyx_L1_error)
32900 __pyx_t_4 = ((__pyx_t_3 > 1) != 0);
32903 __pyx_t_2 = __pyx_t_4;
32904 goto __pyx_L4_bool_binop_done;
32906 __pyx_t_4 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict);
if (unlikely(__pyx_t_4 == ((
int)-1))) __PYX_ERR(0, 13, __pyx_L1_error)
32907 __pyx_t_5 = (__pyx_t_4 != 0);
32908 __pyx_t_2 = __pyx_t_5;
32909 __pyx_L4_bool_binop_done:;
32917 __pyx_t_6 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 14, __pyx_L1_error)
32918 __Pyx_GOTREF(__pyx_t_6);
32919 __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_t_6, __pyx_n_s_update);
if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 14, __pyx_L1_error)
32920 __Pyx_GOTREF(__pyx_t_7);
32921 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
32922 if (unlikely(__pyx_v___pyx_state == Py_None)) {
32923 PyErr_SetString(PyExc_TypeError,
"'NoneType' object is not subscriptable");
32924 __PYX_ERR(0, 14, __pyx_L1_error)
32926 __pyx_t_6 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1,
long, 1, __Pyx_PyInt_From_long, 0, 0, 1);
if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 14, __pyx_L1_error)
32927 __Pyx_GOTREF(__pyx_t_6);
32929 if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_7))) {
32930 __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_7);
32931 if (likely(__pyx_t_8)) {
32932 PyObject*
function = PyMethod_GET_FUNCTION(__pyx_t_7);
32933 __Pyx_INCREF(__pyx_t_8);
32934 __Pyx_INCREF(
function);
32935 __Pyx_DECREF_SET(__pyx_t_7,
function);
32938 __pyx_t_1 = (__pyx_t_8) ? __Pyx_PyObject_Call2Args(__pyx_t_7, __pyx_t_8, __pyx_t_6) : __Pyx_PyObject_CallOneArg(__pyx_t_7, __pyx_t_6);
32939 __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
32940 __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
32941 if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 14, __pyx_L1_error)
32942 __Pyx_GOTREF(__pyx_t_1);
32943 __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
32944 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
32963 __pyx_r = Py_None; __Pyx_INCREF(Py_None);
32966 __Pyx_XDECREF(__pyx_t_1);
32967 __Pyx_XDECREF(__pyx_t_6);
32968 __Pyx_XDECREF(__pyx_t_7);
32969 __Pyx_XDECREF(__pyx_t_8);
32970 __Pyx_AddTraceback(
"View.MemoryView.__pyx_unpickle_Enum__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename);
32973 __Pyx_XGIVEREF(__pyx_r);
32974 __Pyx_RefNannyFinishContext();
32986 static PyObject *__pyx_format_from_typeinfo(__Pyx_TypeInfo *__pyx_v_type) {
32987 __Pyx_StructField *__pyx_v_field;
32988 struct __pyx_typeinfo_string __pyx_v_fmt;
32989 PyObject *__pyx_v_part = 0;
32990 PyObject *__pyx_v_result = 0;
32991 PyObject *__pyx_v_alignment = NULL;
32992 PyObject *__pyx_v_parts = NULL;
32993 PyObject *__pyx_v_extents = NULL;
32995 PyObject *__pyx_r = NULL;
32996 __Pyx_RefNannyDeclarations
32998 PyObject *__pyx_t_2 = NULL;
32999 __Pyx_StructField *__pyx_t_3;
33000 PyObject *__pyx_t_4 = NULL;
33001 PyObject *__pyx_t_5 = NULL;
33006 int __pyx_lineno = 0;
33007 const char *__pyx_filename = NULL;
33008 int __pyx_clineno = 0;
33009 __Pyx_RefNannySetupContext(
"format_from_typeinfo", 0);
33018 __pyx_t_1 = ((__pyx_v_type->typegroup ==
'S') != 0);
33028 #ifndef CYTHON_WITHOUT_ASSERTIONS
33029 if (unlikely(!Py_OptimizeFlag)) {
33030 if (unlikely(!((__pyx_v_type->fields != NULL) != 0))) {
33031 PyErr_SetNone(PyExc_AssertionError);
33032 __PYX_ERR(0, 1469, __pyx_L1_error)
33044 #ifndef CYTHON_WITHOUT_ASSERTIONS
33045 if (unlikely(!Py_OptimizeFlag)) {
33046 if (unlikely(!((__pyx_v_type->fields->type != NULL) != 0))) {
33047 PyErr_SetNone(PyExc_AssertionError);
33048 __PYX_ERR(0, 1470, __pyx_L1_error)
33060 __pyx_t_1 = ((__pyx_v_type->flags & __PYX_BUF_FLAGS_PACKED_STRUCT) != 0);
33070 __Pyx_INCREF(__pyx_kp_b__27);
33071 __pyx_v_alignment = __pyx_kp_b__27;
33091 __Pyx_INCREF(__pyx_kp_b__28);
33092 __pyx_v_alignment = __pyx_kp_b__28;
33103 __pyx_t_2 = PyList_New(1);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1477, __pyx_L1_error)
33104 __Pyx_GOTREF(__pyx_t_2);
33105 __Pyx_INCREF(__pyx_kp_b_T);
33106 __Pyx_GIVEREF(__pyx_kp_b_T);
33107 PyList_SET_ITEM(__pyx_t_2, 0, __pyx_kp_b_T);
33108 __pyx_v_parts = ((PyObject*)__pyx_t_2);
33118 __pyx_t_3 = __pyx_v_type->fields;
33119 __pyx_v_field = __pyx_t_3;
33129 __pyx_t_1 = (__pyx_v_field->type != 0);
33130 if (!__pyx_t_1)
break;
33139 __pyx_t_2 = __pyx_format_from_typeinfo(__pyx_v_field->type);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1481, __pyx_L1_error)
33140 __Pyx_GOTREF(__pyx_t_2);
33141 __Pyx_XDECREF_SET(__pyx_v_part, ((PyObject*)__pyx_t_2));
33151 __pyx_t_2 = PyNumber_Add(__pyx_v_part, __pyx_kp_b__29);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1482, __pyx_L1_error)
33152 __Pyx_GOTREF(__pyx_t_2);
33153 __pyx_t_4 = __Pyx_PyBytes_FromString(__pyx_v_field->name);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1482, __pyx_L1_error)
33154 __Pyx_GOTREF(__pyx_t_4);
33155 __pyx_t_5 = PyNumber_Add(__pyx_t_2, __pyx_t_4);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1482, __pyx_L1_error)
33156 __Pyx_GOTREF(__pyx_t_5);
33157 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
33158 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
33159 __pyx_t_4 = PyNumber_Add(__pyx_t_5, __pyx_kp_b__29);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1482, __pyx_L1_error)
33160 __Pyx_GOTREF(__pyx_t_4);
33161 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
33162 __pyx_t_6 = __Pyx_PyList_Append(__pyx_v_parts, __pyx_t_4);
if (unlikely(__pyx_t_6 == ((
int)-1))) __PYX_ERR(0, 1482, __pyx_L1_error)
33163 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
33172 __pyx_v_field = (__pyx_v_field + 1);
33182 __pyx_t_4 = __Pyx_PyBytes_Join(__pyx_v_alignment, __pyx_v_parts);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1485, __pyx_L1_error)
33183 __Pyx_GOTREF(__pyx_t_4);
33184 __pyx_t_5 = PyNumber_Add(__pyx_t_4, __pyx_kp_b__30);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1485, __pyx_L1_error)
33185 __Pyx_GOTREF(__pyx_t_5);
33186 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
33187 if (!(likely(PyBytes_CheckExact(__pyx_t_5))||((__pyx_t_5) == Py_None)||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"bytes", Py_TYPE(__pyx_t_5)->tp_name), 0))) __PYX_ERR(0, 1485, __pyx_L1_error)
33188 __pyx_v_result = ((PyObject*)__pyx_t_5);
33209 __pyx_v_fmt = __Pyx_TypeInfoToFormat(__pyx_v_type);
33218 __pyx_t_1 = ((__pyx_v_type->arraysize[0]) != 0);
33228 __pyx_t_5 = PyList_New(0);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1489, __pyx_L1_error)
33229 __Pyx_GOTREF(__pyx_t_5);
33230 __pyx_t_7 = __pyx_v_type->ndim;
33231 __pyx_t_8 = __pyx_t_7;
33232 for (__pyx_t_9 = 0; __pyx_t_9 < __pyx_t_8; __pyx_t_9+=1) {
33233 __pyx_v_i = __pyx_t_9;
33234 __pyx_t_4 = __Pyx_PyInt_FromSize_t((__pyx_v_type->arraysize[__pyx_v_i]));
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1489, __pyx_L1_error)
33235 __Pyx_GOTREF(__pyx_t_4);
33236 __pyx_t_2 = __Pyx_PyObject_Unicode(__pyx_t_4);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1489, __pyx_L1_error)
33237 __Pyx_GOTREF(__pyx_t_2);
33238 __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
33239 if (unlikely(__Pyx_ListComp_Append(__pyx_t_5, (PyObject*)__pyx_t_2))) __PYX_ERR(0, 1489, __pyx_L1_error)
33240 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
33242 __pyx_v_extents = ((PyObject*)__pyx_t_5);
33252 __pyx_t_5 = PyUnicode_Join(__pyx_kp_u__31, __pyx_v_extents);
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1490, __pyx_L1_error)
33253 __Pyx_GOTREF(__pyx_t_5);
33254 __pyx_t_2 = PyUnicode_Format(__pyx_kp_u_s, __pyx_t_5);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1490, __pyx_L1_error)
33255 __Pyx_GOTREF(__pyx_t_2);
33256 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
33257 __pyx_t_5 = PyUnicode_AsASCIIString(((PyObject*)__pyx_t_2));
if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1490, __pyx_L1_error)
33258 __Pyx_GOTREF(__pyx_t_5);
33259 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
33260 __pyx_t_2 = __Pyx_PyObject_FromString(__pyx_v_fmt.string);
if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1490, __pyx_L1_error)
33261 __Pyx_GOTREF(__pyx_t_2);
33262 __pyx_t_4 = PyNumber_Add(__pyx_t_5, __pyx_t_2);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1490, __pyx_L1_error)
33263 __Pyx_GOTREF(__pyx_t_4);
33264 __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
33265 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
33266 if (!(likely(PyBytes_CheckExact(__pyx_t_4))||(PyErr_Format(PyExc_TypeError,
"Expected %.16s, got %.200s",
"bytes", Py_TYPE(__pyx_t_4)->tp_name), 0))) __PYX_ERR(0, 1490, __pyx_L1_error)
33267 __pyx_v_result = ((PyObject*)__pyx_t_4);
33288 __pyx_t_4 = __Pyx_PyObject_FromString(__pyx_v_fmt.string);
if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1492, __pyx_L1_error)
33289 __Pyx_GOTREF(__pyx_t_4);
33290 __pyx_v_result = ((PyObject*)__pyx_t_4);
33302 __Pyx_XDECREF(__pyx_r);
33303 __Pyx_INCREF(__pyx_v_result);
33304 __pyx_r = __pyx_v_result;
33317 __Pyx_XDECREF(__pyx_t_2);
33318 __Pyx_XDECREF(__pyx_t_4);
33319 __Pyx_XDECREF(__pyx_t_5);
33320 __Pyx_AddTraceback(
"BufferFormatFromTypeInfo.format_from_typeinfo", __pyx_clineno, __pyx_lineno, __pyx_filename);
33323 __Pyx_XDECREF(__pyx_v_part);
33324 __Pyx_XDECREF(__pyx_v_result);
33325 __Pyx_XDECREF(__pyx_v_alignment);
33326 __Pyx_XDECREF(__pyx_v_parts);
33327 __Pyx_XDECREF(__pyx_v_extents);
33328 __Pyx_XGIVEREF(__pyx_r);
33329 __Pyx_RefNannyFinishContext();
33333 static PyObject *__pyx_tp_new_10cmeshTools_CMesh(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
33334 struct __pyx_obj_10cmeshTools_CMesh *p;
33336 if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
33337 o = (*t->tp_alloc)(t, 0);
33339 o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
33341 if (unlikely(!o))
return 0;
33342 p = ((
struct __pyx_obj_10cmeshTools_CMesh *)o);
33343 p->elementNodesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33344 p->nodeElementsArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33345 p->nodeElementOffsets = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33346 p->elementNeighborsArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33347 p->elementBoundariesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33348 p->elementBoundaryNodesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33349 p->elementBoundaryElementsArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33350 p->elementBoundaryLocalElementBoundariesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33351 p->interiorElementBoundariesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33352 p->exteriorElementBoundariesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33353 p->edgeNodesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33354 p->nodeStarArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33355 p->nodeStarOffsets = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33356 p->elementMaterialTypes = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33357 p->elementBoundaryMaterialTypes = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33358 p->nodeMaterialTypes = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33359 p->nodeArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33360 p->elementIJK = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33361 p->weights = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33362 p->U_KNOT = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33363 p->V_KNOT = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33364 p->W_KNOT = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33365 p->elementDiametersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33366 p->elementInnerDiametersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33367 p->elementBoundaryDiametersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33368 p->elementBarycentersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33369 p->elementBoundaryBarycentersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33370 p->nodeDiametersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33371 p->nodeSupportArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33375 static void __pyx_tp_dealloc_10cmeshTools_CMesh(PyObject *o) {
33376 struct __pyx_obj_10cmeshTools_CMesh *p = (
struct __pyx_obj_10cmeshTools_CMesh *)o;
33377 #if CYTHON_USE_TP_FINALIZE
33378 if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
33379 if (PyObject_CallFinalizerFromDealloc(o))
return;
33382 PyObject_GC_UnTrack(o);
33383 Py_CLEAR(p->elementNodesArray);
33384 Py_CLEAR(p->nodeElementsArray);
33385 Py_CLEAR(p->nodeElementOffsets);
33386 Py_CLEAR(p->elementNeighborsArray);
33387 Py_CLEAR(p->elementBoundariesArray);
33388 Py_CLEAR(p->elementBoundaryNodesArray);
33389 Py_CLEAR(p->elementBoundaryElementsArray);
33390 Py_CLEAR(p->elementBoundaryLocalElementBoundariesArray);
33391 Py_CLEAR(p->interiorElementBoundariesArray);
33392 Py_CLEAR(p->exteriorElementBoundariesArray);
33393 Py_CLEAR(p->edgeNodesArray);
33394 Py_CLEAR(p->nodeStarArray);
33395 Py_CLEAR(p->nodeStarOffsets);
33396 Py_CLEAR(p->elementMaterialTypes);
33397 Py_CLEAR(p->elementBoundaryMaterialTypes);
33398 Py_CLEAR(p->nodeMaterialTypes);
33399 Py_CLEAR(p->nodeArray);
33400 Py_CLEAR(p->elementIJK);
33401 Py_CLEAR(p->weights);
33402 Py_CLEAR(p->U_KNOT);
33403 Py_CLEAR(p->V_KNOT);
33404 Py_CLEAR(p->W_KNOT);
33405 Py_CLEAR(p->elementDiametersArray);
33406 Py_CLEAR(p->elementInnerDiametersArray);
33407 Py_CLEAR(p->elementBoundaryDiametersArray);
33408 Py_CLEAR(p->elementBarycentersArray);
33409 Py_CLEAR(p->elementBoundaryBarycentersArray);
33410 Py_CLEAR(p->nodeDiametersArray);
33411 Py_CLEAR(p->nodeSupportArray);
33412 (*Py_TYPE(o)->tp_free)(o);
33415 static int __pyx_tp_traverse_10cmeshTools_CMesh(PyObject *o, visitproc
v,
void *a) {
33417 struct __pyx_obj_10cmeshTools_CMesh *p = (
struct __pyx_obj_10cmeshTools_CMesh *)o;
33418 if (p->elementNodesArray) {
33419 e = (*v)(((PyObject *)p->elementNodesArray), a);
if (e)
return e;
33421 if (p->nodeElementsArray) {
33422 e = (*v)(((PyObject *)p->nodeElementsArray), a);
if (e)
return e;
33424 if (p->nodeElementOffsets) {
33425 e = (*v)(((PyObject *)p->nodeElementOffsets), a);
if (e)
return e;
33427 if (p->elementNeighborsArray) {
33428 e = (*v)(((PyObject *)p->elementNeighborsArray), a);
if (e)
return e;
33430 if (p->elementBoundariesArray) {
33431 e = (*v)(((PyObject *)p->elementBoundariesArray), a);
if (e)
return e;
33433 if (p->elementBoundaryNodesArray) {
33434 e = (*v)(((PyObject *)p->elementBoundaryNodesArray), a);
if (e)
return e;
33436 if (p->elementBoundaryElementsArray) {
33437 e = (*v)(((PyObject *)p->elementBoundaryElementsArray), a);
if (e)
return e;
33439 if (p->elementBoundaryLocalElementBoundariesArray) {
33440 e = (*v)(((PyObject *)p->elementBoundaryLocalElementBoundariesArray), a);
if (e)
return e;
33442 if (p->interiorElementBoundariesArray) {
33443 e = (*v)(((PyObject *)p->interiorElementBoundariesArray), a);
if (e)
return e;
33445 if (p->exteriorElementBoundariesArray) {
33446 e = (*v)(((PyObject *)p->exteriorElementBoundariesArray), a);
if (e)
return e;
33448 if (p->edgeNodesArray) {
33449 e = (*v)(((PyObject *)p->edgeNodesArray), a);
if (e)
return e;
33451 if (p->nodeStarArray) {
33452 e = (*v)(((PyObject *)p->nodeStarArray), a);
if (e)
return e;
33454 if (p->nodeStarOffsets) {
33455 e = (*v)(((PyObject *)p->nodeStarOffsets), a);
if (e)
return e;
33457 if (p->elementMaterialTypes) {
33458 e = (*v)(((PyObject *)p->elementMaterialTypes), a);
if (e)
return e;
33460 if (p->elementBoundaryMaterialTypes) {
33461 e = (*v)(((PyObject *)p->elementBoundaryMaterialTypes), a);
if (e)
return e;
33463 if (p->nodeMaterialTypes) {
33464 e = (*v)(((PyObject *)p->nodeMaterialTypes), a);
if (e)
return e;
33466 if (p->nodeArray) {
33467 e = (*v)(((PyObject *)p->nodeArray), a);
if (e)
return e;
33469 if (p->elementIJK) {
33470 e = (*v)(((PyObject *)p->elementIJK), a);
if (e)
return e;
33473 e = (*v)(((PyObject *)p->weights), a);
if (e)
return e;
33476 e = (*v)(((PyObject *)p->U_KNOT), a);
if (e)
return e;
33479 e = (*v)(((PyObject *)p->V_KNOT), a);
if (e)
return e;
33482 e = (*v)(((PyObject *)p->W_KNOT), a);
if (e)
return e;
33484 if (p->elementDiametersArray) {
33485 e = (*v)(((PyObject *)p->elementDiametersArray), a);
if (e)
return e;
33487 if (p->elementInnerDiametersArray) {
33488 e = (*v)(((PyObject *)p->elementInnerDiametersArray), a);
if (e)
return e;
33490 if (p->elementBoundaryDiametersArray) {
33491 e = (*v)(((PyObject *)p->elementBoundaryDiametersArray), a);
if (e)
return e;
33493 if (p->elementBarycentersArray) {
33494 e = (*v)(((PyObject *)p->elementBarycentersArray), a);
if (e)
return e;
33496 if (p->elementBoundaryBarycentersArray) {
33497 e = (*v)(((PyObject *)p->elementBoundaryBarycentersArray), a);
if (e)
return e;
33499 if (p->nodeDiametersArray) {
33500 e = (*v)(((PyObject *)p->nodeDiametersArray), a);
if (e)
return e;
33502 if (p->nodeSupportArray) {
33503 e = (*v)(((PyObject *)p->nodeSupportArray), a);
if (e)
return e;
33508 static int __pyx_tp_clear_10cmeshTools_CMesh(PyObject *o) {
33510 struct __pyx_obj_10cmeshTools_CMesh *p = (
struct __pyx_obj_10cmeshTools_CMesh *)o;
33511 tmp = ((PyObject*)p->elementNodesArray);
33512 p->elementNodesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33514 tmp = ((PyObject*)p->nodeElementsArray);
33515 p->nodeElementsArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33517 tmp = ((PyObject*)p->nodeElementOffsets);
33518 p->nodeElementOffsets = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33520 tmp = ((PyObject*)p->elementNeighborsArray);
33521 p->elementNeighborsArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33523 tmp = ((PyObject*)p->elementBoundariesArray);
33524 p->elementBoundariesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33526 tmp = ((PyObject*)p->elementBoundaryNodesArray);
33527 p->elementBoundaryNodesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33529 tmp = ((PyObject*)p->elementBoundaryElementsArray);
33530 p->elementBoundaryElementsArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33532 tmp = ((PyObject*)p->elementBoundaryLocalElementBoundariesArray);
33533 p->elementBoundaryLocalElementBoundariesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33535 tmp = ((PyObject*)p->interiorElementBoundariesArray);
33536 p->interiorElementBoundariesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33538 tmp = ((PyObject*)p->exteriorElementBoundariesArray);
33539 p->exteriorElementBoundariesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33541 tmp = ((PyObject*)p->edgeNodesArray);
33542 p->edgeNodesArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33544 tmp = ((PyObject*)p->nodeStarArray);
33545 p->nodeStarArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33547 tmp = ((PyObject*)p->nodeStarOffsets);
33548 p->nodeStarOffsets = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33550 tmp = ((PyObject*)p->elementMaterialTypes);
33551 p->elementMaterialTypes = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33553 tmp = ((PyObject*)p->elementBoundaryMaterialTypes);
33554 p->elementBoundaryMaterialTypes = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33556 tmp = ((PyObject*)p->nodeMaterialTypes);
33557 p->nodeMaterialTypes = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33559 tmp = ((PyObject*)p->nodeArray);
33560 p->nodeArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33562 tmp = ((PyObject*)p->elementIJK);
33563 p->elementIJK = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33565 tmp = ((PyObject*)p->weights);
33566 p->weights = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33568 tmp = ((PyObject*)p->U_KNOT);
33569 p->U_KNOT = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33571 tmp = ((PyObject*)p->V_KNOT);
33572 p->V_KNOT = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33574 tmp = ((PyObject*)p->W_KNOT);
33575 p->W_KNOT = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33577 tmp = ((PyObject*)p->elementDiametersArray);
33578 p->elementDiametersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33580 tmp = ((PyObject*)p->elementInnerDiametersArray);
33581 p->elementInnerDiametersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33583 tmp = ((PyObject*)p->elementBoundaryDiametersArray);
33584 p->elementBoundaryDiametersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33586 tmp = ((PyObject*)p->elementBarycentersArray);
33587 p->elementBarycentersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33589 tmp = ((PyObject*)p->elementBoundaryBarycentersArray);
33590 p->elementBoundaryBarycentersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33592 tmp = ((PyObject*)p->nodeDiametersArray);
33593 p->nodeDiametersArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33595 tmp = ((PyObject*)p->nodeSupportArray);
33596 p->nodeSupportArray = ((PyArrayObject *)Py_None); Py_INCREF(Py_None);
33601 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nElements_global(PyObject *o, CYTHON_UNUSED
void *x) {
33602 return __pyx_pw_10cmeshTools_5CMesh_16nElements_global_1__get__(o);
33605 static int __pyx_setprop_10cmeshTools_5CMesh_nElements_global(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33607 return __pyx_pw_10cmeshTools_5CMesh_16nElements_global_3__set__(o,
v);
33610 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33615 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nNodes_global(PyObject *o, CYTHON_UNUSED
void *x) {
33616 return __pyx_pw_10cmeshTools_5CMesh_13nNodes_global_1__get__(o);
33619 static int __pyx_setprop_10cmeshTools_5CMesh_nNodes_global(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33621 return __pyx_pw_10cmeshTools_5CMesh_13nNodes_global_3__set__(o,
v);
33624 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33629 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nNodes_element(PyObject *o, CYTHON_UNUSED
void *x) {
33630 return __pyx_pw_10cmeshTools_5CMesh_14nNodes_element_1__get__(o);
33633 static int __pyx_setprop_10cmeshTools_5CMesh_nNodes_element(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33635 return __pyx_pw_10cmeshTools_5CMesh_14nNodes_element_3__set__(o,
v);
33638 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33643 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nNodes_elementBoundary(PyObject *o, CYTHON_UNUSED
void *x) {
33644 return __pyx_pw_10cmeshTools_5CMesh_22nNodes_elementBoundary_1__get__(o);
33647 static int __pyx_setprop_10cmeshTools_5CMesh_nNodes_elementBoundary(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33649 return __pyx_pw_10cmeshTools_5CMesh_22nNodes_elementBoundary_3__set__(o,
v);
33652 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33657 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nElementBoundaries_element(PyObject *o, CYTHON_UNUSED
void *x) {
33658 return __pyx_pw_10cmeshTools_5CMesh_26nElementBoundaries_element_1__get__(o);
33661 static int __pyx_setprop_10cmeshTools_5CMesh_nElementBoundaries_element(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33663 return __pyx_pw_10cmeshTools_5CMesh_26nElementBoundaries_element_3__set__(o,
v);
33666 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33671 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nElementBoundaries_global(PyObject *o, CYTHON_UNUSED
void *x) {
33672 return __pyx_pw_10cmeshTools_5CMesh_25nElementBoundaries_global_1__get__(o);
33675 static int __pyx_setprop_10cmeshTools_5CMesh_nElementBoundaries_global(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33677 return __pyx_pw_10cmeshTools_5CMesh_25nElementBoundaries_global_3__set__(o,
v);
33680 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33685 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nInteriorElementBoundaries_global(PyObject *o, CYTHON_UNUSED
void *x) {
33686 return __pyx_pw_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global_1__get__(o);
33689 static int __pyx_setprop_10cmeshTools_5CMesh_nInteriorElementBoundaries_global(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33691 return __pyx_pw_10cmeshTools_5CMesh_33nInteriorElementBoundaries_global_3__set__(o,
v);
33694 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33699 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nExteriorElementBoundaries_global(PyObject *o, CYTHON_UNUSED
void *x) {
33700 return __pyx_pw_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global_1__get__(o);
33703 static int __pyx_setprop_10cmeshTools_5CMesh_nExteriorElementBoundaries_global(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33705 return __pyx_pw_10cmeshTools_5CMesh_33nExteriorElementBoundaries_global_3__set__(o,
v);
33708 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33713 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_max_nElements_node(PyObject *o, CYTHON_UNUSED
void *x) {
33714 return __pyx_pw_10cmeshTools_5CMesh_18max_nElements_node_1__get__(o);
33717 static int __pyx_setprop_10cmeshTools_5CMesh_max_nElements_node(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33719 return __pyx_pw_10cmeshTools_5CMesh_18max_nElements_node_3__set__(o,
v);
33722 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33727 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nEdges_global(PyObject *o, CYTHON_UNUSED
void *x) {
33728 return __pyx_pw_10cmeshTools_5CMesh_13nEdges_global_1__get__(o);
33731 static int __pyx_setprop_10cmeshTools_5CMesh_nEdges_global(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33733 return __pyx_pw_10cmeshTools_5CMesh_13nEdges_global_3__set__(o,
v);
33736 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33741 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_max_nNodeNeighbors_node(PyObject *o, CYTHON_UNUSED
void *x) {
33742 return __pyx_pw_10cmeshTools_5CMesh_23max_nNodeNeighbors_node_1__get__(o);
33745 static int __pyx_setprop_10cmeshTools_5CMesh_max_nNodeNeighbors_node(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33747 return __pyx_pw_10cmeshTools_5CMesh_23max_nNodeNeighbors_node_3__set__(o,
v);
33750 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33755 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementNodesArray(PyObject *o, CYTHON_UNUSED
void *x) {
33756 return __pyx_pw_10cmeshTools_5CMesh_17elementNodesArray_1__get__(o);
33759 static int __pyx_setprop_10cmeshTools_5CMesh_elementNodesArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33761 return __pyx_pw_10cmeshTools_5CMesh_17elementNodesArray_3__set__(o,
v);
33764 return __pyx_pw_10cmeshTools_5CMesh_17elementNodesArray_5__del__(o);
33768 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nodeElementsArray(PyObject *o, CYTHON_UNUSED
void *x) {
33769 return __pyx_pw_10cmeshTools_5CMesh_17nodeElementsArray_1__get__(o);
33772 static int __pyx_setprop_10cmeshTools_5CMesh_nodeElementsArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33774 return __pyx_pw_10cmeshTools_5CMesh_17nodeElementsArray_3__set__(o,
v);
33777 return __pyx_pw_10cmeshTools_5CMesh_17nodeElementsArray_5__del__(o);
33781 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nodeElementOffsets(PyObject *o, CYTHON_UNUSED
void *x) {
33782 return __pyx_pw_10cmeshTools_5CMesh_18nodeElementOffsets_1__get__(o);
33785 static int __pyx_setprop_10cmeshTools_5CMesh_nodeElementOffsets(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33787 return __pyx_pw_10cmeshTools_5CMesh_18nodeElementOffsets_3__set__(o,
v);
33790 return __pyx_pw_10cmeshTools_5CMesh_18nodeElementOffsets_5__del__(o);
33794 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementNeighborsArray(PyObject *o, CYTHON_UNUSED
void *x) {
33795 return __pyx_pw_10cmeshTools_5CMesh_21elementNeighborsArray_1__get__(o);
33798 static int __pyx_setprop_10cmeshTools_5CMesh_elementNeighborsArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33800 return __pyx_pw_10cmeshTools_5CMesh_21elementNeighborsArray_3__set__(o,
v);
33803 return __pyx_pw_10cmeshTools_5CMesh_21elementNeighborsArray_5__del__(o);
33807 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementBoundariesArray(PyObject *o, CYTHON_UNUSED
void *x) {
33808 return __pyx_pw_10cmeshTools_5CMesh_22elementBoundariesArray_1__get__(o);
33811 static int __pyx_setprop_10cmeshTools_5CMesh_elementBoundariesArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33813 return __pyx_pw_10cmeshTools_5CMesh_22elementBoundariesArray_3__set__(o,
v);
33816 return __pyx_pw_10cmeshTools_5CMesh_22elementBoundariesArray_5__del__(o);
33820 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementBoundaryNodesArray(PyObject *o, CYTHON_UNUSED
void *x) {
33821 return __pyx_pw_10cmeshTools_5CMesh_25elementBoundaryNodesArray_1__get__(o);
33824 static int __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryNodesArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33826 return __pyx_pw_10cmeshTools_5CMesh_25elementBoundaryNodesArray_3__set__(o,
v);
33829 return __pyx_pw_10cmeshTools_5CMesh_25elementBoundaryNodesArray_5__del__(o);
33833 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementBoundaryElementsArray(PyObject *o, CYTHON_UNUSED
void *x) {
33834 return __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryElementsArray_1__get__(o);
33837 static int __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryElementsArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33839 return __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryElementsArray_3__set__(o,
v);
33842 return __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryElementsArray_5__del__(o);
33846 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementBoundaryLocalElementBoundariesArray(PyObject *o, CYTHON_UNUSED
void *x) {
33847 return __pyx_pw_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_1__get__(o);
33850 static int __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryLocalElementBoundariesArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33852 return __pyx_pw_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_3__set__(o,
v);
33855 return __pyx_pw_10cmeshTools_5CMesh_42elementBoundaryLocalElementBoundariesArray_5__del__(o);
33859 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_interiorElementBoundariesArray(PyObject *o, CYTHON_UNUSED
void *x) {
33860 return __pyx_pw_10cmeshTools_5CMesh_30interiorElementBoundariesArray_1__get__(o);
33863 static int __pyx_setprop_10cmeshTools_5CMesh_interiorElementBoundariesArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33865 return __pyx_pw_10cmeshTools_5CMesh_30interiorElementBoundariesArray_3__set__(o,
v);
33868 return __pyx_pw_10cmeshTools_5CMesh_30interiorElementBoundariesArray_5__del__(o);
33872 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_exteriorElementBoundariesArray(PyObject *o, CYTHON_UNUSED
void *x) {
33873 return __pyx_pw_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_1__get__(o);
33876 static int __pyx_setprop_10cmeshTools_5CMesh_exteriorElementBoundariesArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33878 return __pyx_pw_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_3__set__(o,
v);
33881 return __pyx_pw_10cmeshTools_5CMesh_30exteriorElementBoundariesArray_5__del__(o);
33885 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_edgeNodesArray(PyObject *o, CYTHON_UNUSED
void *x) {
33886 return __pyx_pw_10cmeshTools_5CMesh_14edgeNodesArray_1__get__(o);
33889 static int __pyx_setprop_10cmeshTools_5CMesh_edgeNodesArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33891 return __pyx_pw_10cmeshTools_5CMesh_14edgeNodesArray_3__set__(o,
v);
33894 return __pyx_pw_10cmeshTools_5CMesh_14edgeNodesArray_5__del__(o);
33898 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nodeStarArray(PyObject *o, CYTHON_UNUSED
void *x) {
33899 return __pyx_pw_10cmeshTools_5CMesh_13nodeStarArray_1__get__(o);
33902 static int __pyx_setprop_10cmeshTools_5CMesh_nodeStarArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33904 return __pyx_pw_10cmeshTools_5CMesh_13nodeStarArray_3__set__(o,
v);
33907 return __pyx_pw_10cmeshTools_5CMesh_13nodeStarArray_5__del__(o);
33911 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nodeStarOffsets(PyObject *o, CYTHON_UNUSED
void *x) {
33912 return __pyx_pw_10cmeshTools_5CMesh_15nodeStarOffsets_1__get__(o);
33915 static int __pyx_setprop_10cmeshTools_5CMesh_nodeStarOffsets(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33917 return __pyx_pw_10cmeshTools_5CMesh_15nodeStarOffsets_3__set__(o,
v);
33920 return __pyx_pw_10cmeshTools_5CMesh_15nodeStarOffsets_5__del__(o);
33924 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementMaterialTypes(PyObject *o, CYTHON_UNUSED
void *x) {
33925 return __pyx_pw_10cmeshTools_5CMesh_20elementMaterialTypes_1__get__(o);
33928 static int __pyx_setprop_10cmeshTools_5CMesh_elementMaterialTypes(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33930 return __pyx_pw_10cmeshTools_5CMesh_20elementMaterialTypes_3__set__(o,
v);
33933 return __pyx_pw_10cmeshTools_5CMesh_20elementMaterialTypes_5__del__(o);
33937 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementBoundaryMaterialTypes(PyObject *o, CYTHON_UNUSED
void *x) {
33938 return __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_1__get__(o);
33941 static int __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryMaterialTypes(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33943 return __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_3__set__(o,
v);
33946 return __pyx_pw_10cmeshTools_5CMesh_28elementBoundaryMaterialTypes_5__del__(o);
33950 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nodeMaterialTypes(PyObject *o, CYTHON_UNUSED
void *x) {
33951 return __pyx_pw_10cmeshTools_5CMesh_17nodeMaterialTypes_1__get__(o);
33954 static int __pyx_setprop_10cmeshTools_5CMesh_nodeMaterialTypes(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33956 return __pyx_pw_10cmeshTools_5CMesh_17nodeMaterialTypes_3__set__(o,
v);
33959 return __pyx_pw_10cmeshTools_5CMesh_17nodeMaterialTypes_5__del__(o);
33963 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nodeArray(PyObject *o, CYTHON_UNUSED
void *x) {
33964 return __pyx_pw_10cmeshTools_5CMesh_9nodeArray_1__get__(o);
33967 static int __pyx_setprop_10cmeshTools_5CMesh_nodeArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33969 return __pyx_pw_10cmeshTools_5CMesh_9nodeArray_3__set__(o,
v);
33972 return __pyx_pw_10cmeshTools_5CMesh_9nodeArray_5__del__(o);
33976 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nx(PyObject *o, CYTHON_UNUSED
void *x) {
33977 return __pyx_pw_10cmeshTools_5CMesh_2nx_1__get__(o);
33980 static int __pyx_setprop_10cmeshTools_5CMesh_nx(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33982 return __pyx_pw_10cmeshTools_5CMesh_2nx_3__set__(o,
v);
33985 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
33990 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_ny(PyObject *o, CYTHON_UNUSED
void *x) {
33991 return __pyx_pw_10cmeshTools_5CMesh_2ny_1__get__(o);
33994 static int __pyx_setprop_10cmeshTools_5CMesh_ny(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
33996 return __pyx_pw_10cmeshTools_5CMesh_2ny_3__set__(o,
v);
33999 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34004 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nz(PyObject *o, CYTHON_UNUSED
void *x) {
34005 return __pyx_pw_10cmeshTools_5CMesh_2nz_1__get__(o);
34008 static int __pyx_setprop_10cmeshTools_5CMesh_nz(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34010 return __pyx_pw_10cmeshTools_5CMesh_2nz_3__set__(o,
v);
34013 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34018 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_px(PyObject *o, CYTHON_UNUSED
void *x) {
34019 return __pyx_pw_10cmeshTools_5CMesh_2px_1__get__(o);
34022 static int __pyx_setprop_10cmeshTools_5CMesh_px(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34024 return __pyx_pw_10cmeshTools_5CMesh_2px_3__set__(o,
v);
34027 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34032 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_py(PyObject *o, CYTHON_UNUSED
void *x) {
34033 return __pyx_pw_10cmeshTools_5CMesh_2py_1__get__(o);
34036 static int __pyx_setprop_10cmeshTools_5CMesh_py(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34038 return __pyx_pw_10cmeshTools_5CMesh_2py_3__set__(o,
v);
34041 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34046 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_pz(PyObject *o, CYTHON_UNUSED
void *x) {
34047 return __pyx_pw_10cmeshTools_5CMesh_2pz_1__get__(o);
34050 static int __pyx_setprop_10cmeshTools_5CMesh_pz(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34052 return __pyx_pw_10cmeshTools_5CMesh_2pz_3__set__(o,
v);
34055 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34060 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementIJK(PyObject *o, CYTHON_UNUSED
void *x) {
34061 return __pyx_pw_10cmeshTools_5CMesh_10elementIJK_1__get__(o);
34064 static int __pyx_setprop_10cmeshTools_5CMesh_elementIJK(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34066 return __pyx_pw_10cmeshTools_5CMesh_10elementIJK_3__set__(o,
v);
34069 return __pyx_pw_10cmeshTools_5CMesh_10elementIJK_5__del__(o);
34073 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_weights(PyObject *o, CYTHON_UNUSED
void *x) {
34074 return __pyx_pw_10cmeshTools_5CMesh_7weights_1__get__(o);
34077 static int __pyx_setprop_10cmeshTools_5CMesh_weights(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34079 return __pyx_pw_10cmeshTools_5CMesh_7weights_3__set__(o,
v);
34082 return __pyx_pw_10cmeshTools_5CMesh_7weights_5__del__(o);
34086 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_U_KNOT(PyObject *o, CYTHON_UNUSED
void *x) {
34087 return __pyx_pw_10cmeshTools_5CMesh_6U_KNOT_1__get__(o);
34090 static int __pyx_setprop_10cmeshTools_5CMesh_U_KNOT(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34092 return __pyx_pw_10cmeshTools_5CMesh_6U_KNOT_3__set__(o,
v);
34095 return __pyx_pw_10cmeshTools_5CMesh_6U_KNOT_5__del__(o);
34099 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_V_KNOT(PyObject *o, CYTHON_UNUSED
void *x) {
34100 return __pyx_pw_10cmeshTools_5CMesh_6V_KNOT_1__get__(o);
34103 static int __pyx_setprop_10cmeshTools_5CMesh_V_KNOT(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34105 return __pyx_pw_10cmeshTools_5CMesh_6V_KNOT_3__set__(o,
v);
34108 return __pyx_pw_10cmeshTools_5CMesh_6V_KNOT_5__del__(o);
34112 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_W_KNOT(PyObject *o, CYTHON_UNUSED
void *x) {
34113 return __pyx_pw_10cmeshTools_5CMesh_6W_KNOT_1__get__(o);
34116 static int __pyx_setprop_10cmeshTools_5CMesh_W_KNOT(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34118 return __pyx_pw_10cmeshTools_5CMesh_6W_KNOT_3__set__(o,
v);
34121 return __pyx_pw_10cmeshTools_5CMesh_6W_KNOT_5__del__(o);
34125 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementDiametersArray(PyObject *o, CYTHON_UNUSED
void *x) {
34126 return __pyx_pw_10cmeshTools_5CMesh_21elementDiametersArray_1__get__(o);
34129 static int __pyx_setprop_10cmeshTools_5CMesh_elementDiametersArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34131 return __pyx_pw_10cmeshTools_5CMesh_21elementDiametersArray_3__set__(o,
v);
34134 return __pyx_pw_10cmeshTools_5CMesh_21elementDiametersArray_5__del__(o);
34138 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementInnerDiametersArray(PyObject *o, CYTHON_UNUSED
void *x) {
34139 return __pyx_pw_10cmeshTools_5CMesh_26elementInnerDiametersArray_1__get__(o);
34142 static int __pyx_setprop_10cmeshTools_5CMesh_elementInnerDiametersArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34144 return __pyx_pw_10cmeshTools_5CMesh_26elementInnerDiametersArray_3__set__(o,
v);
34147 return __pyx_pw_10cmeshTools_5CMesh_26elementInnerDiametersArray_5__del__(o);
34151 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementBoundaryDiametersArray(PyObject *o, CYTHON_UNUSED
void *x) {
34152 return __pyx_pw_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_1__get__(o);
34155 static int __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryDiametersArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34157 return __pyx_pw_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_3__set__(o,
v);
34160 return __pyx_pw_10cmeshTools_5CMesh_29elementBoundaryDiametersArray_5__del__(o);
34164 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementBarycentersArray(PyObject *o, CYTHON_UNUSED
void *x) {
34165 return __pyx_pw_10cmeshTools_5CMesh_23elementBarycentersArray_1__get__(o);
34168 static int __pyx_setprop_10cmeshTools_5CMesh_elementBarycentersArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34170 return __pyx_pw_10cmeshTools_5CMesh_23elementBarycentersArray_3__set__(o,
v);
34173 return __pyx_pw_10cmeshTools_5CMesh_23elementBarycentersArray_5__del__(o);
34177 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_elementBoundaryBarycentersArray(PyObject *o, CYTHON_UNUSED
void *x) {
34178 return __pyx_pw_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_1__get__(o);
34181 static int __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryBarycentersArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34183 return __pyx_pw_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_3__set__(o,
v);
34186 return __pyx_pw_10cmeshTools_5CMesh_31elementBoundaryBarycentersArray_5__del__(o);
34190 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nodeDiametersArray(PyObject *o, CYTHON_UNUSED
void *x) {
34191 return __pyx_pw_10cmeshTools_5CMesh_18nodeDiametersArray_1__get__(o);
34194 static int __pyx_setprop_10cmeshTools_5CMesh_nodeDiametersArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34196 return __pyx_pw_10cmeshTools_5CMesh_18nodeDiametersArray_3__set__(o,
v);
34199 return __pyx_pw_10cmeshTools_5CMesh_18nodeDiametersArray_5__del__(o);
34203 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_nodeSupportArray(PyObject *o, CYTHON_UNUSED
void *x) {
34204 return __pyx_pw_10cmeshTools_5CMesh_16nodeSupportArray_1__get__(o);
34207 static int __pyx_setprop_10cmeshTools_5CMesh_nodeSupportArray(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34209 return __pyx_pw_10cmeshTools_5CMesh_16nodeSupportArray_3__set__(o,
v);
34212 return __pyx_pw_10cmeshTools_5CMesh_16nodeSupportArray_5__del__(o);
34216 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_h(PyObject *o, CYTHON_UNUSED
void *x) {
34217 return __pyx_pw_10cmeshTools_5CMesh_1h_1__get__(o);
34220 static int __pyx_setprop_10cmeshTools_5CMesh_h(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34222 return __pyx_pw_10cmeshTools_5CMesh_1h_3__set__(o,
v);
34225 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34230 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_hMin(PyObject *o, CYTHON_UNUSED
void *x) {
34231 return __pyx_pw_10cmeshTools_5CMesh_4hMin_1__get__(o);
34234 static int __pyx_setprop_10cmeshTools_5CMesh_hMin(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34236 return __pyx_pw_10cmeshTools_5CMesh_4hMin_3__set__(o,
v);
34239 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34244 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_sigmaMax(PyObject *o, CYTHON_UNUSED
void *x) {
34245 return __pyx_pw_10cmeshTools_5CMesh_8sigmaMax_1__get__(o);
34248 static int __pyx_setprop_10cmeshTools_5CMesh_sigmaMax(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34250 return __pyx_pw_10cmeshTools_5CMesh_8sigmaMax_3__set__(o,
v);
34253 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34258 static PyObject *__pyx_getprop_10cmeshTools_5CMesh_volume(PyObject *o, CYTHON_UNUSED
void *x) {
34259 return __pyx_pw_10cmeshTools_5CMesh_6volume_1__get__(o);
34262 static int __pyx_setprop_10cmeshTools_5CMesh_volume(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34264 return __pyx_pw_10cmeshTools_5CMesh_6volume_3__set__(o,
v);
34267 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34272 static PyMethodDef __pyx_methods_10cmeshTools_CMesh[] = {
34273 {
"deleteCMesh", (PyCFunction)__pyx_pw_10cmeshTools_5CMesh_3deleteCMesh, METH_NOARGS, 0},
34274 {
"buildPythonMeshInterface", (PyCFunction)__pyx_pw_10cmeshTools_5CMesh_5buildPythonMeshInterface, METH_NOARGS, 0},
34275 {
"buildPythonMeshInterfaceNoArrays", (PyCFunction)__pyx_pw_10cmeshTools_5CMesh_7buildPythonMeshInterfaceNoArrays, METH_NOARGS, 0},
34276 {
"__reduce_cython__", (PyCFunction)__pyx_pw_10cmeshTools_5CMesh_9__reduce_cython__, METH_NOARGS, 0},
34277 {
"__setstate_cython__", (PyCFunction)__pyx_pw_10cmeshTools_5CMesh_11__setstate_cython__, METH_O, 0},
34281 static struct PyGetSetDef __pyx_getsets_10cmeshTools_CMesh[] = {
34282 {(
char *)
"nElements_global", __pyx_getprop_10cmeshTools_5CMesh_nElements_global, __pyx_setprop_10cmeshTools_5CMesh_nElements_global, (
char *)0, 0},
34283 {(
char *)
"nNodes_global", __pyx_getprop_10cmeshTools_5CMesh_nNodes_global, __pyx_setprop_10cmeshTools_5CMesh_nNodes_global, (
char *)0, 0},
34284 {(
char *)
"nNodes_element", __pyx_getprop_10cmeshTools_5CMesh_nNodes_element, __pyx_setprop_10cmeshTools_5CMesh_nNodes_element, (
char *)0, 0},
34285 {(
char *)
"nNodes_elementBoundary", __pyx_getprop_10cmeshTools_5CMesh_nNodes_elementBoundary, __pyx_setprop_10cmeshTools_5CMesh_nNodes_elementBoundary, (
char *)0, 0},
34286 {(
char *)
"nElementBoundaries_element", __pyx_getprop_10cmeshTools_5CMesh_nElementBoundaries_element, __pyx_setprop_10cmeshTools_5CMesh_nElementBoundaries_element, (
char *)0, 0},
34287 {(
char *)
"nElementBoundaries_global", __pyx_getprop_10cmeshTools_5CMesh_nElementBoundaries_global, __pyx_setprop_10cmeshTools_5CMesh_nElementBoundaries_global, (
char *)0, 0},
34288 {(
char *)
"nInteriorElementBoundaries_global", __pyx_getprop_10cmeshTools_5CMesh_nInteriorElementBoundaries_global, __pyx_setprop_10cmeshTools_5CMesh_nInteriorElementBoundaries_global, (
char *)0, 0},
34289 {(
char *)
"nExteriorElementBoundaries_global", __pyx_getprop_10cmeshTools_5CMesh_nExteriorElementBoundaries_global, __pyx_setprop_10cmeshTools_5CMesh_nExteriorElementBoundaries_global, (
char *)0, 0},
34290 {(
char *)
"max_nElements_node", __pyx_getprop_10cmeshTools_5CMesh_max_nElements_node, __pyx_setprop_10cmeshTools_5CMesh_max_nElements_node, (
char *)0, 0},
34291 {(
char *)
"nEdges_global", __pyx_getprop_10cmeshTools_5CMesh_nEdges_global, __pyx_setprop_10cmeshTools_5CMesh_nEdges_global, (
char *)0, 0},
34292 {(
char *)
"max_nNodeNeighbors_node", __pyx_getprop_10cmeshTools_5CMesh_max_nNodeNeighbors_node, __pyx_setprop_10cmeshTools_5CMesh_max_nNodeNeighbors_node, (
char *)0, 0},
34293 {(
char *)
"elementNodesArray", __pyx_getprop_10cmeshTools_5CMesh_elementNodesArray, __pyx_setprop_10cmeshTools_5CMesh_elementNodesArray, (
char *)0, 0},
34294 {(
char *)
"nodeElementsArray", __pyx_getprop_10cmeshTools_5CMesh_nodeElementsArray, __pyx_setprop_10cmeshTools_5CMesh_nodeElementsArray, (
char *)0, 0},
34295 {(
char *)
"nodeElementOffsets", __pyx_getprop_10cmeshTools_5CMesh_nodeElementOffsets, __pyx_setprop_10cmeshTools_5CMesh_nodeElementOffsets, (
char *)0, 0},
34296 {(
char *)
"elementNeighborsArray", __pyx_getprop_10cmeshTools_5CMesh_elementNeighborsArray, __pyx_setprop_10cmeshTools_5CMesh_elementNeighborsArray, (
char *)0, 0},
34297 {(
char *)
"elementBoundariesArray", __pyx_getprop_10cmeshTools_5CMesh_elementBoundariesArray, __pyx_setprop_10cmeshTools_5CMesh_elementBoundariesArray, (
char *)0, 0},
34298 {(
char *)
"elementBoundaryNodesArray", __pyx_getprop_10cmeshTools_5CMesh_elementBoundaryNodesArray, __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryNodesArray, (
char *)0, 0},
34299 {(
char *)
"elementBoundaryElementsArray", __pyx_getprop_10cmeshTools_5CMesh_elementBoundaryElementsArray, __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryElementsArray, (
char *)0, 0},
34300 {(
char *)
"elementBoundaryLocalElementBoundariesArray", __pyx_getprop_10cmeshTools_5CMesh_elementBoundaryLocalElementBoundariesArray, __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryLocalElementBoundariesArray, (
char *)0, 0},
34301 {(
char *)
"interiorElementBoundariesArray", __pyx_getprop_10cmeshTools_5CMesh_interiorElementBoundariesArray, __pyx_setprop_10cmeshTools_5CMesh_interiorElementBoundariesArray, (
char *)0, 0},
34302 {(
char *)
"exteriorElementBoundariesArray", __pyx_getprop_10cmeshTools_5CMesh_exteriorElementBoundariesArray, __pyx_setprop_10cmeshTools_5CMesh_exteriorElementBoundariesArray, (
char *)0, 0},
34303 {(
char *)
"edgeNodesArray", __pyx_getprop_10cmeshTools_5CMesh_edgeNodesArray, __pyx_setprop_10cmeshTools_5CMesh_edgeNodesArray, (
char *)0, 0},
34304 {(
char *)
"nodeStarArray", __pyx_getprop_10cmeshTools_5CMesh_nodeStarArray, __pyx_setprop_10cmeshTools_5CMesh_nodeStarArray, (
char *)0, 0},
34305 {(
char *)
"nodeStarOffsets", __pyx_getprop_10cmeshTools_5CMesh_nodeStarOffsets, __pyx_setprop_10cmeshTools_5CMesh_nodeStarOffsets, (
char *)0, 0},
34306 {(
char *)
"elementMaterialTypes", __pyx_getprop_10cmeshTools_5CMesh_elementMaterialTypes, __pyx_setprop_10cmeshTools_5CMesh_elementMaterialTypes, (
char *)0, 0},
34307 {(
char *)
"elementBoundaryMaterialTypes", __pyx_getprop_10cmeshTools_5CMesh_elementBoundaryMaterialTypes, __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryMaterialTypes, (
char *)0, 0},
34308 {(
char *)
"nodeMaterialTypes", __pyx_getprop_10cmeshTools_5CMesh_nodeMaterialTypes, __pyx_setprop_10cmeshTools_5CMesh_nodeMaterialTypes, (
char *)0, 0},
34309 {(
char *)
"nodeArray", __pyx_getprop_10cmeshTools_5CMesh_nodeArray, __pyx_setprop_10cmeshTools_5CMesh_nodeArray, (
char *)0, 0},
34310 {(
char *)
"nx", __pyx_getprop_10cmeshTools_5CMesh_nx, __pyx_setprop_10cmeshTools_5CMesh_nx, (
char *)0, 0},
34311 {(
char *)
"ny", __pyx_getprop_10cmeshTools_5CMesh_ny, __pyx_setprop_10cmeshTools_5CMesh_ny, (
char *)0, 0},
34312 {(
char *)
"nz", __pyx_getprop_10cmeshTools_5CMesh_nz, __pyx_setprop_10cmeshTools_5CMesh_nz, (
char *)0, 0},
34313 {(
char *)
"px", __pyx_getprop_10cmeshTools_5CMesh_px, __pyx_setprop_10cmeshTools_5CMesh_px, (
char *)0, 0},
34314 {(
char *)
"py", __pyx_getprop_10cmeshTools_5CMesh_py, __pyx_setprop_10cmeshTools_5CMesh_py, (
char *)0, 0},
34315 {(
char *)
"pz", __pyx_getprop_10cmeshTools_5CMesh_pz, __pyx_setprop_10cmeshTools_5CMesh_pz, (
char *)0, 0},
34316 {(
char *)
"elementIJK", __pyx_getprop_10cmeshTools_5CMesh_elementIJK, __pyx_setprop_10cmeshTools_5CMesh_elementIJK, (
char *)0, 0},
34317 {(
char *)
"weights", __pyx_getprop_10cmeshTools_5CMesh_weights, __pyx_setprop_10cmeshTools_5CMesh_weights, (
char *)0, 0},
34318 {(
char *)
"U_KNOT", __pyx_getprop_10cmeshTools_5CMesh_U_KNOT, __pyx_setprop_10cmeshTools_5CMesh_U_KNOT, (
char *)0, 0},
34319 {(
char *)
"V_KNOT", __pyx_getprop_10cmeshTools_5CMesh_V_KNOT, __pyx_setprop_10cmeshTools_5CMesh_V_KNOT, (
char *)0, 0},
34320 {(
char *)
"W_KNOT", __pyx_getprop_10cmeshTools_5CMesh_W_KNOT, __pyx_setprop_10cmeshTools_5CMesh_W_KNOT, (
char *)0, 0},
34321 {(
char *)
"elementDiametersArray", __pyx_getprop_10cmeshTools_5CMesh_elementDiametersArray, __pyx_setprop_10cmeshTools_5CMesh_elementDiametersArray, (
char *)0, 0},
34322 {(
char *)
"elementInnerDiametersArray", __pyx_getprop_10cmeshTools_5CMesh_elementInnerDiametersArray, __pyx_setprop_10cmeshTools_5CMesh_elementInnerDiametersArray, (
char *)0, 0},
34323 {(
char *)
"elementBoundaryDiametersArray", __pyx_getprop_10cmeshTools_5CMesh_elementBoundaryDiametersArray, __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryDiametersArray, (
char *)0, 0},
34324 {(
char *)
"elementBarycentersArray", __pyx_getprop_10cmeshTools_5CMesh_elementBarycentersArray, __pyx_setprop_10cmeshTools_5CMesh_elementBarycentersArray, (
char *)0, 0},
34325 {(
char *)
"elementBoundaryBarycentersArray", __pyx_getprop_10cmeshTools_5CMesh_elementBoundaryBarycentersArray, __pyx_setprop_10cmeshTools_5CMesh_elementBoundaryBarycentersArray, (
char *)0, 0},
34326 {(
char *)
"nodeDiametersArray", __pyx_getprop_10cmeshTools_5CMesh_nodeDiametersArray, __pyx_setprop_10cmeshTools_5CMesh_nodeDiametersArray, (
char *)0, 0},
34327 {(
char *)
"nodeSupportArray", __pyx_getprop_10cmeshTools_5CMesh_nodeSupportArray, __pyx_setprop_10cmeshTools_5CMesh_nodeSupportArray, (
char *)0, 0},
34328 {(
char *)
"h", __pyx_getprop_10cmeshTools_5CMesh_h, __pyx_setprop_10cmeshTools_5CMesh_h, (
char *)0, 0},
34329 {(
char *)
"hMin", __pyx_getprop_10cmeshTools_5CMesh_hMin, __pyx_setprop_10cmeshTools_5CMesh_hMin, (
char *)0, 0},
34330 {(
char *)
"sigmaMax", __pyx_getprop_10cmeshTools_5CMesh_sigmaMax, __pyx_setprop_10cmeshTools_5CMesh_sigmaMax, (
char *)0, 0},
34331 {(
char *)
"volume", __pyx_getprop_10cmeshTools_5CMesh_volume, __pyx_setprop_10cmeshTools_5CMesh_volume, (
char *)0, 0},
34335 static PyTypeObject __pyx_type_10cmeshTools_CMesh = {
34336 PyVarObject_HEAD_INIT(0, 0)
34337 "cmeshTools.CMesh",
34338 sizeof(
struct __pyx_obj_10cmeshTools_CMesh),
34340 __pyx_tp_dealloc_10cmeshTools_CMesh,
34341 #if PY_VERSION_HEX < 0x030800b4
34344 #if PY_VERSION_HEX >= 0x030800b4
34349 #if PY_MAJOR_VERSION < 3
34352 #if PY_MAJOR_VERSION >= 3
34365 Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
34367 __pyx_tp_traverse_10cmeshTools_CMesh,
34368 __pyx_tp_clear_10cmeshTools_CMesh,
34373 __pyx_methods_10cmeshTools_CMesh,
34375 __pyx_getsets_10cmeshTools_CMesh,
34381 __pyx_pw_10cmeshTools_5CMesh_1__init__,
34383 __pyx_tp_new_10cmeshTools_CMesh,
34393 #if PY_VERSION_HEX >= 0x030400a1
34396 #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
34399 #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
34402 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000
34407 static PyObject *__pyx_tp_new_10cmeshTools_CMultilevelMesh(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
34408 struct __pyx_obj_10cmeshTools_CMultilevelMesh *p;
34410 if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
34411 o = (*t->tp_alloc)(t, 0);
34413 o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
34415 if (unlikely(!o))
return 0;
34416 p = ((
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)o);
34417 p->cmeshList = ((PyObject*)Py_None); Py_INCREF(Py_None);
34418 p->elementParentsArrayList = ((PyObject*)Py_None); Py_INCREF(Py_None);
34419 p->elementChildrenArrayList = ((PyObject*)Py_None); Py_INCREF(Py_None);
34420 p->elementChildrenOffsetsList = ((PyObject*)Py_None); Py_INCREF(Py_None);
34424 static void __pyx_tp_dealloc_10cmeshTools_CMultilevelMesh(PyObject *o) {
34425 struct __pyx_obj_10cmeshTools_CMultilevelMesh *p = (
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)o;
34426 #if CYTHON_USE_TP_FINALIZE
34427 if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
34428 if (PyObject_CallFinalizerFromDealloc(o))
return;
34431 PyObject_GC_UnTrack(o);
34432 Py_CLEAR(p->cmeshList);
34433 Py_CLEAR(p->elementParentsArrayList);
34434 Py_CLEAR(p->elementChildrenArrayList);
34435 Py_CLEAR(p->elementChildrenOffsetsList);
34436 (*Py_TYPE(o)->tp_free)(o);
34439 static int __pyx_tp_traverse_10cmeshTools_CMultilevelMesh(PyObject *o, visitproc
v,
void *a) {
34441 struct __pyx_obj_10cmeshTools_CMultilevelMesh *p = (
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)o;
34442 if (p->cmeshList) {
34443 e = (*v)(p->cmeshList, a);
if (e)
return e;
34445 if (p->elementParentsArrayList) {
34446 e = (*v)(p->elementParentsArrayList, a);
if (e)
return e;
34448 if (p->elementChildrenArrayList) {
34449 e = (*v)(p->elementChildrenArrayList, a);
if (e)
return e;
34451 if (p->elementChildrenOffsetsList) {
34452 e = (*v)(p->elementChildrenOffsetsList, a);
if (e)
return e;
34457 static int __pyx_tp_clear_10cmeshTools_CMultilevelMesh(PyObject *o) {
34459 struct __pyx_obj_10cmeshTools_CMultilevelMesh *p = (
struct __pyx_obj_10cmeshTools_CMultilevelMesh *)o;
34460 tmp = ((PyObject*)p->cmeshList);
34461 p->cmeshList = ((PyObject*)Py_None); Py_INCREF(Py_None);
34463 tmp = ((PyObject*)p->elementParentsArrayList);
34464 p->elementParentsArrayList = ((PyObject*)Py_None); Py_INCREF(Py_None);
34466 tmp = ((PyObject*)p->elementChildrenArrayList);
34467 p->elementChildrenArrayList = ((PyObject*)Py_None); Py_INCREF(Py_None);
34469 tmp = ((PyObject*)p->elementChildrenOffsetsList);
34470 p->elementChildrenOffsetsList = ((PyObject*)Py_None); Py_INCREF(Py_None);
34475 static PyObject *__pyx_getprop_10cmeshTools_15CMultilevelMesh_nLevels(PyObject *o, CYTHON_UNUSED
void *x) {
34476 return __pyx_pw_10cmeshTools_15CMultilevelMesh_7nLevels_1__get__(o);
34479 static int __pyx_setprop_10cmeshTools_15CMultilevelMesh_nLevels(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34481 return __pyx_pw_10cmeshTools_15CMultilevelMesh_7nLevels_3__set__(o,
v);
34484 PyErr_SetString(PyExc_NotImplementedError,
"__del__");
34489 static PyObject *__pyx_getprop_10cmeshTools_15CMultilevelMesh_cmeshList(PyObject *o, CYTHON_UNUSED
void *x) {
34490 return __pyx_pw_10cmeshTools_15CMultilevelMesh_9cmeshList_1__get__(o);
34493 static int __pyx_setprop_10cmeshTools_15CMultilevelMesh_cmeshList(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34495 return __pyx_pw_10cmeshTools_15CMultilevelMesh_9cmeshList_3__set__(o,
v);
34498 return __pyx_pw_10cmeshTools_15CMultilevelMesh_9cmeshList_5__del__(o);
34502 static PyObject *__pyx_getprop_10cmeshTools_15CMultilevelMesh_elementParentsArrayList(PyObject *o, CYTHON_UNUSED
void *x) {
34503 return __pyx_pw_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_1__get__(o);
34506 static int __pyx_setprop_10cmeshTools_15CMultilevelMesh_elementParentsArrayList(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34508 return __pyx_pw_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_3__set__(o,
v);
34511 return __pyx_pw_10cmeshTools_15CMultilevelMesh_23elementParentsArrayList_5__del__(o);
34515 static PyObject *__pyx_getprop_10cmeshTools_15CMultilevelMesh_elementChildrenArrayList(PyObject *o, CYTHON_UNUSED
void *x) {
34516 return __pyx_pw_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_1__get__(o);
34519 static int __pyx_setprop_10cmeshTools_15CMultilevelMesh_elementChildrenArrayList(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34521 return __pyx_pw_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_3__set__(o,
v);
34524 return __pyx_pw_10cmeshTools_15CMultilevelMesh_24elementChildrenArrayList_5__del__(o);
34528 static PyObject *__pyx_getprop_10cmeshTools_15CMultilevelMesh_elementChildrenOffsetsList(PyObject *o, CYTHON_UNUSED
void *x) {
34529 return __pyx_pw_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_1__get__(o);
34532 static int __pyx_setprop_10cmeshTools_15CMultilevelMesh_elementChildrenOffsetsList(PyObject *o, PyObject *
v, CYTHON_UNUSED
void *x) {
34534 return __pyx_pw_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_3__set__(o,
v);
34537 return __pyx_pw_10cmeshTools_15CMultilevelMesh_26elementChildrenOffsetsList_5__del__(o);
34541 static PyMethodDef __pyx_methods_10cmeshTools_CMultilevelMesh[] = {
34542 {
"buildPythonMultilevelMeshInterface", (PyCFunction)__pyx_pw_10cmeshTools_15CMultilevelMesh_3buildPythonMultilevelMeshInterface, METH_NOARGS, 0},
34543 {
"__reduce_cython__", (PyCFunction)__pyx_pw_10cmeshTools_15CMultilevelMesh_5__reduce_cython__, METH_NOARGS, 0},
34544 {
"__setstate_cython__", (PyCFunction)__pyx_pw_10cmeshTools_15CMultilevelMesh_7__setstate_cython__, METH_O, 0},
34548 static struct PyGetSetDef __pyx_getsets_10cmeshTools_CMultilevelMesh[] = {
34549 {(
char *)
"nLevels", __pyx_getprop_10cmeshTools_15CMultilevelMesh_nLevels, __pyx_setprop_10cmeshTools_15CMultilevelMesh_nLevels, (
char *)0, 0},
34550 {(
char *)
"cmeshList", __pyx_getprop_10cmeshTools_15CMultilevelMesh_cmeshList, __pyx_setprop_10cmeshTools_15CMultilevelMesh_cmeshList, (
char *)0, 0},
34551 {(
char *)
"elementParentsArrayList", __pyx_getprop_10cmeshTools_15CMultilevelMesh_elementParentsArrayList, __pyx_setprop_10cmeshTools_15CMultilevelMesh_elementParentsArrayList, (
char *)0, 0},
34552 {(
char *)
"elementChildrenArrayList", __pyx_getprop_10cmeshTools_15CMultilevelMesh_elementChildrenArrayList, __pyx_setprop_10cmeshTools_15CMultilevelMesh_elementChildrenArrayList, (
char *)0, 0},
34553 {(
char *)
"elementChildrenOffsetsList", __pyx_getprop_10cmeshTools_15CMultilevelMesh_elementChildrenOffsetsList, __pyx_setprop_10cmeshTools_15CMultilevelMesh_elementChildrenOffsetsList, (
char *)0, 0},
34557 static PyTypeObject __pyx_type_10cmeshTools_CMultilevelMesh = {
34558 PyVarObject_HEAD_INIT(0, 0)
34559 "cmeshTools.CMultilevelMesh",
34560 sizeof(
struct __pyx_obj_10cmeshTools_CMultilevelMesh),
34562 __pyx_tp_dealloc_10cmeshTools_CMultilevelMesh,
34563 #if PY_VERSION_HEX < 0x030800b4
34566 #if PY_VERSION_HEX >= 0x030800b4
34571 #if PY_MAJOR_VERSION < 3
34574 #if PY_MAJOR_VERSION >= 3
34587 Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
34589 __pyx_tp_traverse_10cmeshTools_CMultilevelMesh,
34590 __pyx_tp_clear_10cmeshTools_CMultilevelMesh,
34595 __pyx_methods_10cmeshTools_CMultilevelMesh,
34597 __pyx_getsets_10cmeshTools_CMultilevelMesh,
34603 __pyx_pw_10cmeshTools_15CMultilevelMesh_1__init__,
34605 __pyx_tp_new_10cmeshTools_CMultilevelMesh,
34615 #if PY_VERSION_HEX >= 0x030400a1
34618 #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
34621 #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
34624 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000
34628 static struct __pyx_vtabstruct_array __pyx_vtable_array;
34630 static PyObject *__pyx_tp_new_array(PyTypeObject *t, PyObject *a, PyObject *k) {
34631 struct __pyx_array_obj *p;
34633 if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
34634 o = (*t->tp_alloc)(t, 0);
34636 o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
34638 if (unlikely(!o))
return 0;
34639 p = ((
struct __pyx_array_obj *)o);
34640 p->__pyx_vtab = __pyx_vtabptr_array;
34641 p->mode = ((PyObject*)Py_None); Py_INCREF(Py_None);
34642 p->_format = ((PyObject*)Py_None); Py_INCREF(Py_None);
34643 if (unlikely(__pyx_array___cinit__(o, a, k) < 0))
goto bad;
34646 Py_DECREF(o); o = 0;
34650 static void __pyx_tp_dealloc_array(PyObject *o) {
34651 struct __pyx_array_obj *p = (
struct __pyx_array_obj *)o;
34652 #if CYTHON_USE_TP_FINALIZE
34653 if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && (!PyType_IS_GC(Py_TYPE(o)) || !_PyGC_FINALIZED(o))) {
34654 if (PyObject_CallFinalizerFromDealloc(o))
return;
34658 PyObject *etype, *eval, *etb;
34659 PyErr_Fetch(&etype, &eval, &etb);
34660 __Pyx_SET_REFCNT(o, Py_REFCNT(o) + 1);
34661 __pyx_array___dealloc__(o);
34662 __Pyx_SET_REFCNT(o, Py_REFCNT(o) - 1);
34663 PyErr_Restore(etype, eval, etb);
34666 Py_CLEAR(p->_format);
34667 (*Py_TYPE(o)->tp_free)(o);
34669 static PyObject *__pyx_sq_item_array(PyObject *o, Py_ssize_t i) {
34671 PyObject *x = PyInt_FromSsize_t(i);
if(!x)
return 0;
34672 r = Py_TYPE(o)->tp_as_mapping->mp_subscript(o, x);
34677 static int __pyx_mp_ass_subscript_array(PyObject *o, PyObject *i, PyObject *
v) {
34679 return __pyx_array___setitem__(o, i,
v);
34682 PyErr_Format(PyExc_NotImplementedError,
34683 "Subscript deletion not supported by %.200s", Py_TYPE(o)->tp_name);
34688 static PyObject *__pyx_tp_getattro_array(PyObject *o, PyObject *
n) {
34689 PyObject *
v = __Pyx_PyObject_GenericGetAttr(o,
n);
34690 if (!
v && PyErr_ExceptionMatches(PyExc_AttributeError)) {
34692 v = __pyx_array___getattr__(o,
n);
34697 static PyObject *__pyx_getprop___pyx_array_memview(PyObject *o, CYTHON_UNUSED
void *x) {
34698 return __pyx_pw_15View_dot_MemoryView_5array_7memview_1__get__(o);
34701 static PyMethodDef __pyx_methods_array[] = {
34702 {
"__getattr__", (PyCFunction)__pyx_array___getattr__, METH_O|METH_COEXIST, 0},
34703 {
"__reduce_cython__", (PyCFunction)__pyx_pw___pyx_array_1__reduce_cython__, METH_NOARGS, 0},
34704 {
"__setstate_cython__", (PyCFunction)__pyx_pw___pyx_array_3__setstate_cython__, METH_O, 0},
34708 static struct PyGetSetDef __pyx_getsets_array[] = {
34709 {(
char *)
"memview", __pyx_getprop___pyx_array_memview, 0, (
char *)0, 0},
34713 static PySequenceMethods __pyx_tp_as_sequence_array = {
34714 __pyx_array___len__,
34717 __pyx_sq_item_array,
34726 static PyMappingMethods __pyx_tp_as_mapping_array = {
34727 __pyx_array___len__,
34728 __pyx_array___getitem__,
34729 __pyx_mp_ass_subscript_array,
34732 static PyBufferProcs __pyx_tp_as_buffer_array = {
34733 #if PY_MAJOR_VERSION < 3
34736 #if PY_MAJOR_VERSION < 3
34739 #if PY_MAJOR_VERSION < 3
34742 #if PY_MAJOR_VERSION < 3
34745 __pyx_array_getbuffer,
34749 static PyTypeObject __pyx_type___pyx_array = {
34750 PyVarObject_HEAD_INIT(0, 0)
34751 "cmeshTools.array",
34752 sizeof(
struct __pyx_array_obj),
34754 __pyx_tp_dealloc_array,
34755 #if PY_VERSION_HEX < 0x030800b4
34758 #if PY_VERSION_HEX >= 0x030800b4
34763 #if PY_MAJOR_VERSION < 3
34766 #if PY_MAJOR_VERSION >= 3
34771 &__pyx_tp_as_sequence_array,
34772 &__pyx_tp_as_mapping_array,
34776 __pyx_tp_getattro_array,
34778 &__pyx_tp_as_buffer_array,
34779 Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE,
34787 __pyx_methods_array,
34789 __pyx_getsets_array,
34797 __pyx_tp_new_array,
34807 #if PY_VERSION_HEX >= 0x030400a1
34810 #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
34813 #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
34816 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000
34821 static PyObject *__pyx_tp_new_Enum(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
34822 struct __pyx_MemviewEnum_obj *p;
34824 if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
34825 o = (*t->tp_alloc)(t, 0);
34827 o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
34829 if (unlikely(!o))
return 0;
34830 p = ((
struct __pyx_MemviewEnum_obj *)o);
34831 p->name = Py_None; Py_INCREF(Py_None);
34835 static void __pyx_tp_dealloc_Enum(PyObject *o) {
34836 struct __pyx_MemviewEnum_obj *p = (
struct __pyx_MemviewEnum_obj *)o;
34837 #if CYTHON_USE_TP_FINALIZE
34838 if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
34839 if (PyObject_CallFinalizerFromDealloc(o))
return;
34842 PyObject_GC_UnTrack(o);
34844 (*Py_TYPE(o)->tp_free)(o);
34847 static int __pyx_tp_traverse_Enum(PyObject *o, visitproc
v,
void *a) {
34849 struct __pyx_MemviewEnum_obj *p = (
struct __pyx_MemviewEnum_obj *)o;
34851 e = (*v)(p->name, a);
if (e)
return e;
34856 static int __pyx_tp_clear_Enum(PyObject *o) {
34858 struct __pyx_MemviewEnum_obj *p = (
struct __pyx_MemviewEnum_obj *)o;
34859 tmp = ((PyObject*)p->name);
34860 p->name = Py_None; Py_INCREF(Py_None);
34865 static PyMethodDef __pyx_methods_Enum[] = {
34866 {
"__reduce_cython__", (PyCFunction)__pyx_pw___pyx_MemviewEnum_1__reduce_cython__, METH_NOARGS, 0},
34867 {
"__setstate_cython__", (PyCFunction)__pyx_pw___pyx_MemviewEnum_3__setstate_cython__, METH_O, 0},
34871 static PyTypeObject __pyx_type___pyx_MemviewEnum = {
34872 PyVarObject_HEAD_INIT(0, 0)
34874 sizeof(
struct __pyx_MemviewEnum_obj),
34876 __pyx_tp_dealloc_Enum,
34877 #if PY_VERSION_HEX < 0x030800b4
34880 #if PY_VERSION_HEX >= 0x030800b4
34885 #if PY_MAJOR_VERSION < 3
34888 #if PY_MAJOR_VERSION >= 3
34891 __pyx_MemviewEnum___repr__,
34901 Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
34903 __pyx_tp_traverse_Enum,
34904 __pyx_tp_clear_Enum,
34909 __pyx_methods_Enum,
34917 __pyx_MemviewEnum___init__,
34929 #if PY_VERSION_HEX >= 0x030400a1
34932 #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
34935 #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
34938 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000
34942 static struct __pyx_vtabstruct_memoryview __pyx_vtable_memoryview;
34944 static PyObject *__pyx_tp_new_memoryview(PyTypeObject *t, PyObject *a, PyObject *k) {
34945 struct __pyx_memoryview_obj *p;
34947 if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
34948 o = (*t->tp_alloc)(t, 0);
34950 o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
34952 if (unlikely(!o))
return 0;
34953 p = ((
struct __pyx_memoryview_obj *)o);
34954 p->__pyx_vtab = __pyx_vtabptr_memoryview;
34955 p->obj = Py_None; Py_INCREF(Py_None);
34956 p->_size = Py_None; Py_INCREF(Py_None);
34957 p->_array_interface = Py_None; Py_INCREF(Py_None);
34958 p->view.obj = NULL;
34959 if (unlikely(__pyx_memoryview___cinit__(o, a, k) < 0))
goto bad;
34962 Py_DECREF(o); o = 0;
34966 static void __pyx_tp_dealloc_memoryview(PyObject *o) {
34967 struct __pyx_memoryview_obj *p = (
struct __pyx_memoryview_obj *)o;
34968 #if CYTHON_USE_TP_FINALIZE
34969 if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
34970 if (PyObject_CallFinalizerFromDealloc(o))
return;
34973 PyObject_GC_UnTrack(o);
34975 PyObject *etype, *eval, *etb;
34976 PyErr_Fetch(&etype, &eval, &etb);
34977 __Pyx_SET_REFCNT(o, Py_REFCNT(o) + 1);
34978 __pyx_memoryview___dealloc__(o);
34979 __Pyx_SET_REFCNT(o, Py_REFCNT(o) - 1);
34980 PyErr_Restore(etype, eval, etb);
34983 Py_CLEAR(p->_size);
34984 Py_CLEAR(p->_array_interface);
34985 (*Py_TYPE(o)->tp_free)(o);
34988 static int __pyx_tp_traverse_memoryview(PyObject *o, visitproc
v,
void *a) {
34990 struct __pyx_memoryview_obj *p = (
struct __pyx_memoryview_obj *)o;
34992 e = (*v)(p->obj, a);
if (e)
return e;
34995 e = (*v)(p->_size, a);
if (e)
return e;
34997 if (p->_array_interface) {
34998 e = (*v)(p->_array_interface, a);
if (e)
return e;
35001 e = (*v)(p->view.obj, a);
if (e)
return e;
35006 static int __pyx_tp_clear_memoryview(PyObject *o) {
35008 struct __pyx_memoryview_obj *p = (
struct __pyx_memoryview_obj *)o;
35009 tmp = ((PyObject*)p->obj);
35010 p->obj = Py_None; Py_INCREF(Py_None);
35012 tmp = ((PyObject*)p->_size);
35013 p->_size = Py_None; Py_INCREF(Py_None);
35015 tmp = ((PyObject*)p->_array_interface);
35016 p->_array_interface = Py_None; Py_INCREF(Py_None);
35018 Py_CLEAR(p->view.obj);
35021 static PyObject *__pyx_sq_item_memoryview(PyObject *o, Py_ssize_t i) {
35023 PyObject *x = PyInt_FromSsize_t(i);
if(!x)
return 0;
35024 r = Py_TYPE(o)->tp_as_mapping->mp_subscript(o, x);
35029 static int __pyx_mp_ass_subscript_memoryview(PyObject *o, PyObject *i, PyObject *
v) {
35031 return __pyx_memoryview___setitem__(o, i,
v);
35034 PyErr_Format(PyExc_NotImplementedError,
35035 "Subscript deletion not supported by %.200s", Py_TYPE(o)->tp_name);
35040 static PyObject *__pyx_getprop___pyx_memoryview_T(PyObject *o, CYTHON_UNUSED
void *x) {
35041 return __pyx_pw_15View_dot_MemoryView_10memoryview_1T_1__get__(o);
35044 static PyObject *__pyx_getprop___pyx_memoryview_base(PyObject *o, CYTHON_UNUSED
void *x) {
35045 return __pyx_pw_15View_dot_MemoryView_10memoryview_4base_1__get__(o);
35048 static PyObject *__pyx_getprop___pyx_memoryview_shape(PyObject *o, CYTHON_UNUSED
void *x) {
35049 return __pyx_pw_15View_dot_MemoryView_10memoryview_5shape_1__get__(o);
35052 static PyObject *__pyx_getprop___pyx_memoryview_strides(PyObject *o, CYTHON_UNUSED
void *x) {
35053 return __pyx_pw_15View_dot_MemoryView_10memoryview_7strides_1__get__(o);
35056 static PyObject *__pyx_getprop___pyx_memoryview_suboffsets(PyObject *o, CYTHON_UNUSED
void *x) {
35057 return __pyx_pw_15View_dot_MemoryView_10memoryview_10suboffsets_1__get__(o);
35060 static PyObject *__pyx_getprop___pyx_memoryview_ndim(PyObject *o, CYTHON_UNUSED
void *x) {
35061 return __pyx_pw_15View_dot_MemoryView_10memoryview_4ndim_1__get__(o);
35064 static PyObject *__pyx_getprop___pyx_memoryview_itemsize(PyObject *o, CYTHON_UNUSED
void *x) {
35065 return __pyx_pw_15View_dot_MemoryView_10memoryview_8itemsize_1__get__(o);
35068 static PyObject *__pyx_getprop___pyx_memoryview_nbytes(PyObject *o, CYTHON_UNUSED
void *x) {
35069 return __pyx_pw_15View_dot_MemoryView_10memoryview_6nbytes_1__get__(o);
35072 static PyObject *__pyx_getprop___pyx_memoryview_size(PyObject *o, CYTHON_UNUSED
void *x) {
35073 return __pyx_pw_15View_dot_MemoryView_10memoryview_4size_1__get__(o);
35076 static PyMethodDef __pyx_methods_memoryview[] = {
35077 {
"is_c_contig", (PyCFunction)__pyx_memoryview_is_c_contig, METH_NOARGS, 0},
35078 {
"is_f_contig", (PyCFunction)__pyx_memoryview_is_f_contig, METH_NOARGS, 0},
35079 {
"copy", (PyCFunction)__pyx_memoryview_copy, METH_NOARGS, 0},
35080 {
"copy_fortran", (PyCFunction)__pyx_memoryview_copy_fortran, METH_NOARGS, 0},
35081 {
"__reduce_cython__", (PyCFunction)__pyx_pw___pyx_memoryview_1__reduce_cython__, METH_NOARGS, 0},
35082 {
"__setstate_cython__", (PyCFunction)__pyx_pw___pyx_memoryview_3__setstate_cython__, METH_O, 0},
35086 static struct PyGetSetDef __pyx_getsets_memoryview[] = {
35087 {(
char *)
"T", __pyx_getprop___pyx_memoryview_T, 0, (
char *)0, 0},
35088 {(
char *)
"base", __pyx_getprop___pyx_memoryview_base, 0, (
char *)0, 0},
35089 {(
char *)
"shape", __pyx_getprop___pyx_memoryview_shape, 0, (
char *)0, 0},
35090 {(
char *)
"strides", __pyx_getprop___pyx_memoryview_strides, 0, (
char *)0, 0},
35091 {(
char *)
"suboffsets", __pyx_getprop___pyx_memoryview_suboffsets, 0, (
char *)0, 0},
35092 {(
char *)
"ndim", __pyx_getprop___pyx_memoryview_ndim, 0, (
char *)0, 0},
35093 {(
char *)
"itemsize", __pyx_getprop___pyx_memoryview_itemsize, 0, (
char *)0, 0},
35094 {(
char *)
"nbytes", __pyx_getprop___pyx_memoryview_nbytes, 0, (
char *)0, 0},
35095 {(
char *)
"size", __pyx_getprop___pyx_memoryview_size, 0, (
char *)0, 0},
35099 static PySequenceMethods __pyx_tp_as_sequence_memoryview = {
35100 __pyx_memoryview___len__,
35103 __pyx_sq_item_memoryview,
35112 static PyMappingMethods __pyx_tp_as_mapping_memoryview = {
35113 __pyx_memoryview___len__,
35114 __pyx_memoryview___getitem__,
35115 __pyx_mp_ass_subscript_memoryview,
35118 static PyBufferProcs __pyx_tp_as_buffer_memoryview = {
35119 #if PY_MAJOR_VERSION < 3
35122 #if PY_MAJOR_VERSION < 3
35125 #if PY_MAJOR_VERSION < 3
35128 #if PY_MAJOR_VERSION < 3
35131 __pyx_memoryview_getbuffer,
35135 static PyTypeObject __pyx_type___pyx_memoryview = {
35136 PyVarObject_HEAD_INIT(0, 0)
35137 "cmeshTools.memoryview",
35138 sizeof(
struct __pyx_memoryview_obj),
35140 __pyx_tp_dealloc_memoryview,
35141 #if PY_VERSION_HEX < 0x030800b4
35144 #if PY_VERSION_HEX >= 0x030800b4
35149 #if PY_MAJOR_VERSION < 3
35152 #if PY_MAJOR_VERSION >= 3
35155 __pyx_memoryview___repr__,
35157 &__pyx_tp_as_sequence_memoryview,
35158 &__pyx_tp_as_mapping_memoryview,
35161 __pyx_memoryview___str__,
35164 &__pyx_tp_as_buffer_memoryview,
35165 Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
35167 __pyx_tp_traverse_memoryview,
35168 __pyx_tp_clear_memoryview,
35173 __pyx_methods_memoryview,
35175 __pyx_getsets_memoryview,
35183 __pyx_tp_new_memoryview,
35193 #if PY_VERSION_HEX >= 0x030400a1
35196 #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
35199 #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
35202 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000
35206 static struct __pyx_vtabstruct__memoryviewslice __pyx_vtable__memoryviewslice;
35208 static PyObject *__pyx_tp_new__memoryviewslice(PyTypeObject *t, PyObject *a, PyObject *k) {
35209 struct __pyx_memoryviewslice_obj *p;
35210 PyObject *o = __pyx_tp_new_memoryview(t, a, k);
35211 if (unlikely(!o))
return 0;
35212 p = ((
struct __pyx_memoryviewslice_obj *)o);
35213 p->__pyx_base.__pyx_vtab = (
struct __pyx_vtabstruct_memoryview*)__pyx_vtabptr__memoryviewslice;
35214 p->from_object = Py_None; Py_INCREF(Py_None);
35215 p->from_slice.memview = NULL;
35219 static void __pyx_tp_dealloc__memoryviewslice(PyObject *o) {
35220 struct __pyx_memoryviewslice_obj *p = (
struct __pyx_memoryviewslice_obj *)o;
35221 #if CYTHON_USE_TP_FINALIZE
35222 if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
35223 if (PyObject_CallFinalizerFromDealloc(o))
return;
35226 PyObject_GC_UnTrack(o);
35228 PyObject *etype, *eval, *etb;
35229 PyErr_Fetch(&etype, &eval, &etb);
35230 __Pyx_SET_REFCNT(o, Py_REFCNT(o) + 1);
35231 __pyx_memoryviewslice___dealloc__(o);
35232 __Pyx_SET_REFCNT(o, Py_REFCNT(o) - 1);
35233 PyErr_Restore(etype, eval, etb);
35235 Py_CLEAR(p->from_object);
35236 PyObject_GC_Track(o);
35237 __pyx_tp_dealloc_memoryview(o);
35240 static int __pyx_tp_traverse__memoryviewslice(PyObject *o, visitproc
v,
void *a) {
35242 struct __pyx_memoryviewslice_obj *p = (
struct __pyx_memoryviewslice_obj *)o;
35243 e = __pyx_tp_traverse_memoryview(o,
v, a);
if (e)
return e;
35244 if (p->from_object) {
35245 e = (*v)(p->from_object, a);
if (e)
return e;
35250 static int __pyx_tp_clear__memoryviewslice(PyObject *o) {
35252 struct __pyx_memoryviewslice_obj *p = (
struct __pyx_memoryviewslice_obj *)o;
35253 __pyx_tp_clear_memoryview(o);
35254 tmp = ((PyObject*)p->from_object);
35255 p->from_object = Py_None; Py_INCREF(Py_None);
35257 __PYX_XDEC_MEMVIEW(&p->from_slice, 1);
35261 static PyObject *__pyx_getprop___pyx_memoryviewslice_base(PyObject *o, CYTHON_UNUSED
void *x) {
35262 return __pyx_pw_15View_dot_MemoryView_16_memoryviewslice_4base_1__get__(o);
35265 static PyMethodDef __pyx_methods__memoryviewslice[] = {
35266 {
"__reduce_cython__", (PyCFunction)__pyx_pw___pyx_memoryviewslice_1__reduce_cython__, METH_NOARGS, 0},
35267 {
"__setstate_cython__", (PyCFunction)__pyx_pw___pyx_memoryviewslice_3__setstate_cython__, METH_O, 0},
35271 static struct PyGetSetDef __pyx_getsets__memoryviewslice[] = {
35272 {(
char *)
"base", __pyx_getprop___pyx_memoryviewslice_base, 0, (
char *)0, 0},
35276 static PyTypeObject __pyx_type___pyx_memoryviewslice = {
35277 PyVarObject_HEAD_INIT(0, 0)
35278 "cmeshTools._memoryviewslice",
35279 sizeof(
struct __pyx_memoryviewslice_obj),
35281 __pyx_tp_dealloc__memoryviewslice,
35282 #if PY_VERSION_HEX < 0x030800b4
35285 #if PY_VERSION_HEX >= 0x030800b4
35290 #if PY_MAJOR_VERSION < 3
35293 #if PY_MAJOR_VERSION >= 3
35296 #if CYTHON_COMPILING_IN_PYPY
35297 __pyx_memoryview___repr__,
35306 #if CYTHON_COMPILING_IN_PYPY
35307 __pyx_memoryview___str__,
35314 Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC,
35315 "Internal class for passing memoryview slices to Python",
35316 __pyx_tp_traverse__memoryviewslice,
35317 __pyx_tp_clear__memoryviewslice,
35322 __pyx_methods__memoryviewslice,
35324 __pyx_getsets__memoryviewslice,
35332 __pyx_tp_new__memoryviewslice,
35342 #if PY_VERSION_HEX >= 0x030400a1
35345 #if PY_VERSION_HEX >= 0x030800b1 && (!CYTHON_COMPILING_IN_PYPY || PYPY_VERSION_NUM >= 0x07030800)
35348 #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
35351 #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX >= 0x03090000
35356 static PyMethodDef __pyx_methods[] = {
35357 {
"generateTetrahedralMeshFromRectangularGrid", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_7generateTetrahedralMeshFromRectangularGrid, METH_VARARGS|METH_KEYWORDS, 0},
35358 {
"cmeshToolsComputeGeometricInfo_tetrahedron", (PyCFunction)__pyx_pw_10cmeshTools_9cmeshToolsComputeGeometricInfo_tetrahedron, METH_O, 0},
35359 {
"generateFromTriangleFiles", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_11generateFromTriangleFiles, METH_VARARGS|METH_KEYWORDS, 0},
35360 {
"writeTriangleFiles", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_13writeTriangleFiles, METH_VARARGS|METH_KEYWORDS, 0},
35361 {
"generateFromTetgenFiles", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_15generateFromTetgenFiles, METH_VARARGS|METH_KEYWORDS, 0},
35362 {
"generateFromTetgenFilesParallel", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_17generateFromTetgenFilesParallel, METH_VARARGS|METH_KEYWORDS, 0},
35363 {
"writeTetgenFiles", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_19writeTetgenFiles, METH_VARARGS|METH_KEYWORDS, 0},
35364 {
"write3dmFiles", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_21write3dmFiles, METH_VARARGS|METH_KEYWORDS, 0},
35365 {
"write2dmFiles", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_23write2dmFiles, METH_VARARGS|METH_KEYWORDS, 0},
35366 {
"generateFromHexFile", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_25generateFromHexFile, METH_VARARGS|METH_KEYWORDS, 0},
35367 {
"generateFrom3DMFile", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_27generateFrom3DMFile, METH_VARARGS|METH_KEYWORDS, 0},
35368 {
"generateFrom2DMFile", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_29generateFrom2DMFile, METH_VARARGS|METH_KEYWORDS, 0},
35369 {
"computeGeometricInfo_tetrahedron", (PyCFunction)__pyx_pw_10cmeshTools_31computeGeometricInfo_tetrahedron, METH_O, 0},
35370 {
"allocateGeometricInfo_tetrahedron", (PyCFunction)__pyx_pw_10cmeshTools_33allocateGeometricInfo_tetrahedron, METH_O, 0},
35371 {
"allocateNodeAndElementNodeDataStructures", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_35allocateNodeAndElementNodeDataStructures, METH_VARARGS|METH_KEYWORDS, 0},
35372 {
"constructElementBoundaryElementsArray", (PyCFunction)__pyx_pw_10cmeshTools_37constructElementBoundaryElementsArray, METH_O, 0},
35373 {
"generateTriangularMeshFromRectangularGrid", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_39generateTriangularMeshFromRectangularGrid, METH_VARARGS|METH_KEYWORDS, 0},
35374 {
"generateHexahedralMeshFromRectangularGrid", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_41generateHexahedralMeshFromRectangularGrid, METH_VARARGS|METH_KEYWORDS, 0},
35375 {
"generateQuadrilateralMeshFromRectangularGrid", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_43generateQuadrilateralMeshFromRectangularGrid, METH_VARARGS|METH_KEYWORDS, 0},
35376 {
"computeGeometricInfo_triangle", (PyCFunction)__pyx_pw_10cmeshTools_45computeGeometricInfo_triangle, METH_O, 0},
35377 {
"allocateGeometricInfo_triangle", (PyCFunction)__pyx_pw_10cmeshTools_47allocateGeometricInfo_triangle, METH_O, 0},
35378 {
"generateEdgeMeshFromRectangularGrid", (PyCFunction)(
void*)(PyCFunctionWithKeywords)__pyx_pw_10cmeshTools_49generateEdgeMeshFromRectangularGrid, METH_VARARGS|METH_KEYWORDS, 0},
35379 {
"computeGeometricInfo_edge", (PyCFunction)__pyx_pw_10cmeshTools_51computeGeometricInfo_edge, METH_O, 0},
35380 {
"allocateGeometricInfo_edge", (PyCFunction)__pyx_pw_10cmeshTools_53allocateGeometricInfo_edge, METH_O, 0},
35381 {
"computeGeometricInfo_hexahedron", (PyCFunction)__pyx_pw_10cmeshTools_55computeGeometricInfo_hexahedron, METH_O, 0},
35382 {
"computeGeometricInfo_quadrilateral", (PyCFunction)__pyx_pw_10cmeshTools_57computeGeometricInfo_quadrilateral, METH_O, 0},
35383 {
"allocateGeometricInfo_hexahedron", (PyCFunction)__pyx_pw_10cmeshTools_59allocateGeometricInfo_hexahedron, METH_O, 0},
35384 {
"allocateGeometricInfo_quadrilateral", (PyCFunction)__pyx_pw_10cmeshTools_61allocateGeometricInfo_quadrilateral, METH_O, 0},
35385 {
"computeGeometricInfo_NURBS", (PyCFunction)__pyx_pw_10cmeshTools_63computeGeometricInfo_NURBS, METH_O, 0},
35386 {
"allocateGeometricInfo_NURBS", (PyCFunction)__pyx_pw_10cmeshTools_65allocateGeometricInfo_NURBS, METH_O, 0},
35390 #if PY_MAJOR_VERSION >= 3
35391 #if CYTHON_PEP489_MULTI_PHASE_INIT
35392 static PyObject* __pyx_pymod_create(PyObject *spec, PyModuleDef *def);
35393 static int __pyx_pymod_exec_cmeshTools(PyObject* module);
35394 static PyModuleDef_Slot __pyx_moduledef_slots[] = {
35395 {Py_mod_create, (
void*)__pyx_pymod_create},
35396 {Py_mod_exec, (
void*)__pyx_pymod_exec_cmeshTools},
35401 static struct PyModuleDef __pyx_moduledef = {
35402 PyModuleDef_HEAD_INIT,
35405 #if CYTHON_PEP489_MULTI_PHASE_INIT
35411 #if CYTHON_PEP489_MULTI_PHASE_INIT
35412 __pyx_moduledef_slots,
35421 #ifndef CYTHON_SMALL_CODE
35422 #if defined(__clang__)
35423 #define CYTHON_SMALL_CODE
35424 #elif defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))
35425 #define CYTHON_SMALL_CODE __attribute__((cold))
35427 #define CYTHON_SMALL_CODE
35431 static __Pyx_StringTabEntry __pyx_string_tab[] = {
35432 {&__pyx_n_s_ASCII, __pyx_k_ASCII,
sizeof(__pyx_k_ASCII), 0, 0, 1, 1},
35433 {&__pyx_kp_s_Buffer_view_does_not_expose_stri, __pyx_k_Buffer_view_does_not_expose_stri,
sizeof(__pyx_k_Buffer_view_does_not_expose_stri), 0, 0, 1, 0},
35434 {&__pyx_n_s_CMesh, __pyx_k_CMesh,
sizeof(__pyx_k_CMesh), 0, 0, 1, 1},
35435 {&__pyx_n_s_CMultilevelMesh, __pyx_k_CMultilevelMesh,
sizeof(__pyx_k_CMultilevelMesh), 0, 0, 1, 1},
35436 {&__pyx_kp_s_Can_only_create_a_buffer_that_is, __pyx_k_Can_only_create_a_buffer_that_is,
sizeof(__pyx_k_Can_only_create_a_buffer_that_is), 0, 0, 1, 0},
35437 {&__pyx_kp_s_Cannot_assign_to_read_only_memor, __pyx_k_Cannot_assign_to_read_only_memor,
sizeof(__pyx_k_Cannot_assign_to_read_only_memor), 0, 0, 1, 0},
35438 {&__pyx_kp_s_Cannot_create_writable_memory_vi, __pyx_k_Cannot_create_writable_memory_vi,
sizeof(__pyx_k_Cannot_create_writable_memory_vi), 0, 0, 1, 0},
35439 {&__pyx_kp_s_Cannot_index_with_type_s, __pyx_k_Cannot_index_with_type_s,
sizeof(__pyx_k_Cannot_index_with_type_s), 0, 0, 1, 0},
35440 {&__pyx_n_s_Comm, __pyx_k_Comm,
sizeof(__pyx_k_Comm), 0, 0, 1, 1},
35441 {&__pyx_n_s_Ellipsis, __pyx_k_Ellipsis,
sizeof(__pyx_k_Ellipsis), 0, 0, 1, 1},
35442 {&__pyx_kp_s_Empty_shape_tuple_for_cython_arr, __pyx_k_Empty_shape_tuple_for_cython_arr,
sizeof(__pyx_k_Empty_shape_tuple_for_cython_arr), 0, 0, 1, 0},
35443 {&__pyx_n_s_ImportError, __pyx_k_ImportError,
sizeof(__pyx_k_ImportError), 0, 0, 1, 1},
35444 {&__pyx_kp_s_Incompatible_checksums_0x_x_vs_0, __pyx_k_Incompatible_checksums_0x_x_vs_0,
sizeof(__pyx_k_Incompatible_checksums_0x_x_vs_0), 0, 0, 1, 0},
35445 {&__pyx_n_s_IndexError, __pyx_k_IndexError,
sizeof(__pyx_k_IndexError), 0, 0, 1, 1},
35446 {&__pyx_kp_s_Indirect_dimensions_not_supporte, __pyx_k_Indirect_dimensions_not_supporte,
sizeof(__pyx_k_Indirect_dimensions_not_supporte), 0, 0, 1, 0},
35447 {&__pyx_kp_s_Invalid_mode_expected_c_or_fortr, __pyx_k_Invalid_mode_expected_c_or_fortr,
sizeof(__pyx_k_Invalid_mode_expected_c_or_fortr), 0, 0, 1, 0},
35448 {&__pyx_kp_s_Invalid_shape_in_axis_d_d, __pyx_k_Invalid_shape_in_axis_d_d,
sizeof(__pyx_k_Invalid_shape_in_axis_d_d), 0, 0, 1, 0},
35449 {&__pyx_n_s_Lx, __pyx_k_Lx,
sizeof(__pyx_k_Lx), 0, 0, 1, 1},
35450 {&__pyx_n_s_Ly, __pyx_k_Ly,
sizeof(__pyx_k_Ly), 0, 0, 1, 1},
35451 {&__pyx_n_s_Lz, __pyx_k_Lz,
sizeof(__pyx_k_Lz), 0, 0, 1, 1},
35452 {&__pyx_n_s_MPI, __pyx_k_MPI,
sizeof(__pyx_k_MPI), 0, 0, 1, 1},
35453 {&__pyx_n_s_MemoryError, __pyx_k_MemoryError,
sizeof(__pyx_k_MemoryError), 0, 0, 1, 1},
35454 {&__pyx_kp_s_MemoryView_of_r_at_0x_x, __pyx_k_MemoryView_of_r_at_0x_x,
sizeof(__pyx_k_MemoryView_of_r_at_0x_x), 0, 0, 1, 0},
35455 {&__pyx_kp_s_MemoryView_of_r_object, __pyx_k_MemoryView_of_r_object,
sizeof(__pyx_k_MemoryView_of_r_object), 0, 0, 1, 0},
35456 {&__pyx_n_b_O, __pyx_k_O,
sizeof(__pyx_k_O), 0, 0, 0, 1},
35457 {&__pyx_kp_s_Out_of_bounds_on_buffer_access_a, __pyx_k_Out_of_bounds_on_buffer_access_a,
sizeof(__pyx_k_Out_of_bounds_on_buffer_access_a), 0, 0, 1, 0},
35458 {&__pyx_n_s_PickleError, __pyx_k_PickleError,
sizeof(__pyx_k_PickleError), 0, 0, 1, 1},
35459 {&__pyx_kp_b_T, __pyx_k_T,
sizeof(__pyx_k_T), 0, 0, 0, 0},
35460 {&__pyx_n_s_TypeError, __pyx_k_TypeError,
sizeof(__pyx_k_TypeError), 0, 0, 1, 1},
35461 {&__pyx_n_s_U_KNOT, __pyx_k_U_KNOT,
sizeof(__pyx_k_U_KNOT), 0, 0, 1, 1},
35462 {&__pyx_kp_s_Unable_to_convert_item_to_object, __pyx_k_Unable_to_convert_item_to_object,
sizeof(__pyx_k_Unable_to_convert_item_to_object), 0, 0, 1, 0},
35463 {&__pyx_n_s_V_KNOT, __pyx_k_V_KNOT,
sizeof(__pyx_k_V_KNOT), 0, 0, 1, 1},
35464 {&__pyx_n_s_ValueError, __pyx_k_ValueError,
sizeof(__pyx_k_ValueError), 0, 0, 1, 1},
35465 {&__pyx_n_s_View_MemoryView, __pyx_k_View_MemoryView,
sizeof(__pyx_k_View_MemoryView), 0, 0, 1, 1},
35466 {&__pyx_n_s_W_KNOT, __pyx_k_W_KNOT,
sizeof(__pyx_k_W_KNOT), 0, 0, 1, 1},
35467 {&__pyx_kp_b__27, __pyx_k__27,
sizeof(__pyx_k__27), 0, 0, 0, 0},
35468 {&__pyx_kp_b__28, __pyx_k__28,
sizeof(__pyx_k__28), 0, 0, 0, 0},
35469 {&__pyx_kp_b__29, __pyx_k__29,
sizeof(__pyx_k__29), 0, 0, 0, 0},
35470 {&__pyx_kp_b__30, __pyx_k__30,
sizeof(__pyx_k__30), 0, 0, 0, 0},
35471 {&__pyx_kp_u__31, __pyx_k__31,
sizeof(__pyx_k__31), 0, 1, 0, 0},
35472 {&__pyx_n_s_allocate_buffer, __pyx_k_allocate_buffer,
sizeof(__pyx_k_allocate_buffer), 0, 0, 1, 1},
35473 {&__pyx_n_s_asarray, __pyx_k_asarray,
sizeof(__pyx_k_asarray), 0, 0, 1, 1},
35474 {&__pyx_n_s_base, __pyx_k_base,
sizeof(__pyx_k_base), 0, 0, 1, 1},
35475 {&__pyx_n_s_buildPythonMeshInterface, __pyx_k_buildPythonMeshInterface,
sizeof(__pyx_k_buildPythonMeshInterface), 0, 0, 1, 1},
35476 {&__pyx_n_s_buildPythonMeshInterfaceNoArrays, __pyx_k_buildPythonMeshInterfaceNoArrays,
sizeof(__pyx_k_buildPythonMeshInterfaceNoArrays), 0, 0, 1, 1},
35477 {&__pyx_n_s_buildPythonMultilevelMeshInterfa, __pyx_k_buildPythonMultilevelMeshInterfa,
sizeof(__pyx_k_buildPythonMultilevelMeshInterfa), 0, 0, 1, 1},
35478 {&__pyx_n_s_c, __pyx_k_c,
sizeof(__pyx_k_c), 0, 0, 1, 1},
35479 {&__pyx_n_u_c, __pyx_k_c,
sizeof(__pyx_k_c), 0, 1, 0, 1},
35480 {&__pyx_n_s_class, __pyx_k_class,
sizeof(__pyx_k_class), 0, 0, 1, 1},
35481 {&__pyx_n_s_cline_in_traceback, __pyx_k_cline_in_traceback,
sizeof(__pyx_k_cline_in_traceback), 0, 0, 1, 1},
35482 {&__pyx_n_s_cmesh, __pyx_k_cmesh,
sizeof(__pyx_k_cmesh), 0, 0, 1, 1},
35483 {&__pyx_n_s_cmeshList, __pyx_k_cmeshList,
sizeof(__pyx_k_cmeshList), 0, 0, 1, 1},
35484 {&__pyx_n_s_cmeshTools, __pyx_k_cmeshTools,
sizeof(__pyx_k_cmeshTools), 0, 0, 1, 1},
35485 {&__pyx_n_s_cmultilevelMesh, __pyx_k_cmultilevelMesh,
sizeof(__pyx_k_cmultilevelMesh), 0, 0, 1, 1},
35486 {&__pyx_kp_s_contiguous_and_direct, __pyx_k_contiguous_and_direct,
sizeof(__pyx_k_contiguous_and_direct), 0, 0, 1, 0},
35487 {&__pyx_kp_s_contiguous_and_indirect, __pyx_k_contiguous_and_indirect,
sizeof(__pyx_k_contiguous_and_indirect), 0, 0, 1, 0},
35488 {&__pyx_n_s_dict, __pyx_k_dict,
sizeof(__pyx_k_dict), 0, 0, 1, 1},
35489 {&__pyx_n_s_dtype, __pyx_k_dtype,
sizeof(__pyx_k_dtype), 0, 0, 1, 1},
35490 {&__pyx_n_s_dtype_is_object, __pyx_k_dtype_is_object,
sizeof(__pyx_k_dtype_is_object), 0, 0, 1, 1},
35491 {&__pyx_n_s_edgeNodesArray, __pyx_k_edgeNodesArray,
sizeof(__pyx_k_edgeNodesArray), 0, 0, 1, 1},
35492 {&__pyx_n_s_elementBarycentersArray, __pyx_k_elementBarycentersArray,
sizeof(__pyx_k_elementBarycentersArray), 0, 0, 1, 1},
35493 {&__pyx_n_s_elementBoundariesArray, __pyx_k_elementBoundariesArray,
sizeof(__pyx_k_elementBoundariesArray), 0, 0, 1, 1},
35494 {&__pyx_n_s_elementBoundaryBarycentersArray, __pyx_k_elementBoundaryBarycentersArray,
sizeof(__pyx_k_elementBoundaryBarycentersArray), 0, 0, 1, 1},
35495 {&__pyx_n_s_elementBoundaryDiametersArray, __pyx_k_elementBoundaryDiametersArray,
sizeof(__pyx_k_elementBoundaryDiametersArray), 0, 0, 1, 1},
35496 {&__pyx_n_s_elementBoundaryElementsArray, __pyx_k_elementBoundaryElementsArray,
sizeof(__pyx_k_elementBoundaryElementsArray), 0, 0, 1, 1},
35497 {&__pyx_n_s_elementBoundaryLocalElementBound, __pyx_k_elementBoundaryLocalElementBound,
sizeof(__pyx_k_elementBoundaryLocalElementBound), 0, 0, 1, 1},
35498 {&__pyx_n_s_elementBoundaryMaterialTypes, __pyx_k_elementBoundaryMaterialTypes,
sizeof(__pyx_k_elementBoundaryMaterialTypes), 0, 0, 1, 1},
35499 {&__pyx_n_s_elementBoundaryNodesArray, __pyx_k_elementBoundaryNodesArray,
sizeof(__pyx_k_elementBoundaryNodesArray), 0, 0, 1, 1},
35500 {&__pyx_n_s_elementChildrenArrayList, __pyx_k_elementChildrenArrayList,
sizeof(__pyx_k_elementChildrenArrayList), 0, 0, 1, 1},
35501 {&__pyx_n_s_elementChildrenOffsetsList, __pyx_k_elementChildrenOffsetsList,
sizeof(__pyx_k_elementChildrenOffsetsList), 0, 0, 1, 1},
35502 {&__pyx_n_s_elementDiametersArray, __pyx_k_elementDiametersArray,
sizeof(__pyx_k_elementDiametersArray), 0, 0, 1, 1},
35503 {&__pyx_n_s_elementIJK, __pyx_k_elementIJK,
sizeof(__pyx_k_elementIJK), 0, 0, 1, 1},
35504 {&__pyx_n_s_elementInnerDiametersArray, __pyx_k_elementInnerDiametersArray,
sizeof(__pyx_k_elementInnerDiametersArray), 0, 0, 1, 1},
35505 {&__pyx_n_s_elementMaterialTypes, __pyx_k_elementMaterialTypes,
sizeof(__pyx_k_elementMaterialTypes), 0, 0, 1, 1},
35506 {&__pyx_n_s_elementNeighborsArray, __pyx_k_elementNeighborsArray,
sizeof(__pyx_k_elementNeighborsArray), 0, 0, 1, 1},
35507 {&__pyx_n_s_elementNodesArray, __pyx_k_elementNodesArray,
sizeof(__pyx_k_elementNodesArray), 0, 0, 1, 1},
35508 {&__pyx_n_s_elementParentsArrayList, __pyx_k_elementParentsArrayList,
sizeof(__pyx_k_elementParentsArrayList), 0, 0, 1, 1},
35509 {&__pyx_n_s_elementTagArray, __pyx_k_elementTagArray,
sizeof(__pyx_k_elementTagArray), 0, 0, 1, 1},
35510 {&__pyx_n_s_empty, __pyx_k_empty,
sizeof(__pyx_k_empty), 0, 0, 1, 1},
35511 {&__pyx_n_s_encode, __pyx_k_encode,
sizeof(__pyx_k_encode), 0, 0, 1, 1},
35512 {&__pyx_n_s_end, __pyx_k_end,
sizeof(__pyx_k_end), 0, 0, 1, 1},
35513 {&__pyx_n_s_enumerate, __pyx_k_enumerate,
sizeof(__pyx_k_enumerate), 0, 0, 1, 1},
35514 {&__pyx_n_s_error, __pyx_k_error,
sizeof(__pyx_k_error), 0, 0, 1, 1},
35515 {&__pyx_n_s_exteriorElementBoundariesArray, __pyx_k_exteriorElementBoundariesArray,
sizeof(__pyx_k_exteriorElementBoundariesArray), 0, 0, 1, 1},
35516 {&__pyx_n_s_failed, __pyx_k_failed,
sizeof(__pyx_k_failed), 0, 0, 1, 1},
35517 {&__pyx_n_s_file, __pyx_k_file,
sizeof(__pyx_k_file), 0, 0, 1, 1},
35518 {&__pyx_n_s_filebase, __pyx_k_filebase,
sizeof(__pyx_k_filebase), 0, 0, 1, 1},
35519 {&__pyx_n_s_finestLevel, __pyx_k_finestLevel,
sizeof(__pyx_k_finestLevel), 0, 0, 1, 1},
35520 {&__pyx_n_s_flags, __pyx_k_flags,
sizeof(__pyx_k_flags), 0, 0, 1, 1},
35521 {&__pyx_n_s_format, __pyx_k_format,
sizeof(__pyx_k_format), 0, 0, 1, 1},
35522 {&__pyx_n_s_fortran, __pyx_k_fortran,
sizeof(__pyx_k_fortran), 0, 0, 1, 1},
35523 {&__pyx_n_u_fortran, __pyx_k_fortran,
sizeof(__pyx_k_fortran), 0, 1, 0, 1},
35524 {&__pyx_n_s_getstate, __pyx_k_getstate,
sizeof(__pyx_k_getstate), 0, 0, 1, 1},
35525 {&__pyx_kp_s_got_differing_extents_in_dimensi, __pyx_k_got_differing_extents_in_dimensi,
sizeof(__pyx_k_got_differing_extents_in_dimensi), 0, 0, 1, 0},
35526 {&__pyx_n_s_h, __pyx_k_h,
sizeof(__pyx_k_h), 0, 0, 1, 1},
35527 {&__pyx_n_s_hMin, __pyx_k_hMin,
sizeof(__pyx_k_hMin), 0, 0, 1, 1},
35528 {&__pyx_n_s_id, __pyx_k_id,
sizeof(__pyx_k_id), 0, 0, 1, 1},
35529 {&__pyx_n_s_import, __pyx_k_import,
sizeof(__pyx_k_import), 0, 0, 1, 1},
35530 {&__pyx_n_s_int32, __pyx_k_int32,
sizeof(__pyx_k_int32), 0, 0, 1, 1},
35531 {&__pyx_n_s_interiorElementBoundariesArray, __pyx_k_interiorElementBoundariesArray,
sizeof(__pyx_k_interiorElementBoundariesArray), 0, 0, 1, 1},
35532 {&__pyx_n_s_itemsize, __pyx_k_itemsize,
sizeof(__pyx_k_itemsize), 0, 0, 1, 1},
35533 {&__pyx_kp_s_itemsize_0_for_cython_array, __pyx_k_itemsize_0_for_cython_array,
sizeof(__pyx_k_itemsize_0_for_cython_array), 0, 0, 1, 0},
35534 {&__pyx_n_s_join, __pyx_k_join,
sizeof(__pyx_k_join), 0, 0, 1, 1},
35535 {&__pyx_n_s_locallyRefineMultilevelMesh, __pyx_k_locallyRefineMultilevelMesh,
sizeof(__pyx_k_locallyRefineMultilevelMesh), 0, 0, 1, 1},
35536 {&__pyx_kp_s_locallyRefine_nSpace_0_d_not_imp, __pyx_k_locallyRefine_nSpace_0_d_not_imp,
sizeof(__pyx_k_locallyRefine_nSpace_0_d_not_imp), 0, 0, 1, 0},
35537 {&__pyx_n_s_main, __pyx_k_main,
sizeof(__pyx_k_main), 0, 0, 1, 1},
35538 {&__pyx_n_s_max_nElements_node, __pyx_k_max_nElements_node,
sizeof(__pyx_k_max_nElements_node), 0, 0, 1, 1},
35539 {&__pyx_n_s_max_nNodeNeighbors_node, __pyx_k_max_nNodeNeighbors_node,
sizeof(__pyx_k_max_nNodeNeighbors_node), 0, 0, 1, 1},
35540 {&__pyx_n_s_memview, __pyx_k_memview,
sizeof(__pyx_k_memview), 0, 0, 1, 1},
35541 {&__pyx_n_s_mode, __pyx_k_mode,
sizeof(__pyx_k_mode), 0, 0, 1, 1},
35542 {&__pyx_n_s_mpi4py, __pyx_k_mpi4py,
sizeof(__pyx_k_mpi4py), 0, 0, 1, 1},
35543 {&__pyx_n_s_nEdges_global, __pyx_k_nEdges_global,
sizeof(__pyx_k_nEdges_global), 0, 0, 1, 1},
35544 {&__pyx_n_s_nElementBoundaries_element, __pyx_k_nElementBoundaries_element,
sizeof(__pyx_k_nElementBoundaries_element), 0, 0, 1, 1},
35545 {&__pyx_n_s_nElementBoundaries_global, __pyx_k_nElementBoundaries_global,
sizeof(__pyx_k_nElementBoundaries_global), 0, 0, 1, 1},
35546 {&__pyx_n_s_nElements_global, __pyx_k_nElements_global,
sizeof(__pyx_k_nElements_global), 0, 0, 1, 1},
35547 {&__pyx_n_s_nExteriorElementBoundaries_globa, __pyx_k_nExteriorElementBoundaries_globa,
sizeof(__pyx_k_nExteriorElementBoundaries_globa), 0, 0, 1, 1},
35548 {&__pyx_n_s_nInteriorElementBoundaries_globa, __pyx_k_nInteriorElementBoundaries_globa,
sizeof(__pyx_k_nInteriorElementBoundaries_globa), 0, 0, 1, 1},
35549 {&__pyx_n_s_nLevels, __pyx_k_nLevels,
sizeof(__pyx_k_nLevels), 0, 0, 1, 1},
35550 {&__pyx_n_s_nNodes_element, __pyx_k_nNodes_element,
sizeof(__pyx_k_nNodes_element), 0, 0, 1, 1},
35551 {&__pyx_n_s_nNodes_elementBoundary, __pyx_k_nNodes_elementBoundary,
sizeof(__pyx_k_nNodes_elementBoundary), 0, 0, 1, 1},
35552 {&__pyx_n_s_nNodes_global, __pyx_k_nNodes_global,
sizeof(__pyx_k_nNodes_global), 0, 0, 1, 1},
35553 {&__pyx_n_s_nSpace, __pyx_k_nSpace,
sizeof(__pyx_k_nSpace), 0, 0, 1, 1},
35554 {&__pyx_n_s_name, __pyx_k_name,
sizeof(__pyx_k_name), 0, 0, 1, 1},
35555 {&__pyx_n_s_name_2, __pyx_k_name_2,
sizeof(__pyx_k_name_2), 0, 0, 1, 1},
35556 {&__pyx_n_s_ndim, __pyx_k_ndim,
sizeof(__pyx_k_ndim), 0, 0, 1, 1},
35557 {&__pyx_n_s_new, __pyx_k_new,
sizeof(__pyx_k_new), 0, 0, 1, 1},
35558 {&__pyx_kp_s_no_default___reduce___due_to_non, __pyx_k_no_default___reduce___due_to_non,
sizeof(__pyx_k_no_default___reduce___due_to_non), 0, 0, 1, 0},
35559 {&__pyx_n_s_nodeArray, __pyx_k_nodeArray,
sizeof(__pyx_k_nodeArray), 0, 0, 1, 1},
35560 {&__pyx_n_s_nodeDiametersArray, __pyx_k_nodeDiametersArray,
sizeof(__pyx_k_nodeDiametersArray), 0, 0, 1, 1},
35561 {&__pyx_n_s_nodeElementOffsets, __pyx_k_nodeElementOffsets,
sizeof(__pyx_k_nodeElementOffsets), 0, 0, 1, 1},
35562 {&__pyx_n_s_nodeElementsArray, __pyx_k_nodeElementsArray,
sizeof(__pyx_k_nodeElementsArray), 0, 0, 1, 1},
35563 {&__pyx_n_s_nodeMaterialTypes, __pyx_k_nodeMaterialTypes,
sizeof(__pyx_k_nodeMaterialTypes), 0, 0, 1, 1},
35564 {&__pyx_n_s_nodeStarArray, __pyx_k_nodeStarArray,
sizeof(__pyx_k_nodeStarArray), 0, 0, 1, 1},
35565 {&__pyx_n_s_nodeStarOffsets, __pyx_k_nodeStarOffsets,
sizeof(__pyx_k_nodeStarOffsets), 0, 0, 1, 1},
35566 {&__pyx_n_s_nodeSupportArray, __pyx_k_nodeSupportArray,
sizeof(__pyx_k_nodeSupportArray), 0, 0, 1, 1},
35567 {&__pyx_n_s_np, __pyx_k_np,
sizeof(__pyx_k_np), 0, 0, 1, 1},
35568 {&__pyx_n_s_numpy, __pyx_k_numpy,
sizeof(__pyx_k_numpy), 0, 0, 1, 1},
35569 {&__pyx_kp_s_numpy_core_multiarray_failed_to, __pyx_k_numpy_core_multiarray_failed_to,
sizeof(__pyx_k_numpy_core_multiarray_failed_to), 0, 0, 1, 0},
35570 {&__pyx_kp_s_numpy_core_umath_failed_to_impor, __pyx_k_numpy_core_umath_failed_to_impor,
sizeof(__pyx_k_numpy_core_umath_failed_to_impor), 0, 0, 1, 0},
35571 {&__pyx_n_s_nx, __pyx_k_nx,
sizeof(__pyx_k_nx), 0, 0, 1, 1},
35572 {&__pyx_n_s_ny, __pyx_k_ny,
sizeof(__pyx_k_ny), 0, 0, 1, 1},
35573 {&__pyx_n_s_nz, __pyx_k_nz,
sizeof(__pyx_k_nz), 0, 0, 1, 1},
35574 {&__pyx_n_s_obj, __pyx_k_obj,
sizeof(__pyx_k_obj), 0, 0, 1, 1},
35575 {&__pyx_n_s_pack, __pyx_k_pack,
sizeof(__pyx_k_pack), 0, 0, 1, 1},
35576 {&__pyx_n_s_pickle, __pyx_k_pickle,
sizeof(__pyx_k_pickle), 0, 0, 1, 1},
35577 {&__pyx_n_s_print, __pyx_k_print,
sizeof(__pyx_k_print), 0, 0, 1, 1},
35578 {&__pyx_n_s_proteus, __pyx_k_proteus,
sizeof(__pyx_k_proteus), 0, 0, 1, 1},
35579 {&__pyx_kp_s_proteus_cmeshTools_pyx, __pyx_k_proteus_cmeshTools_pyx,
sizeof(__pyx_k_proteus_cmeshTools_pyx), 0, 0, 1, 0},
35580 {&__pyx_n_s_px, __pyx_k_px,
sizeof(__pyx_k_px), 0, 0, 1, 1},
35581 {&__pyx_n_s_py, __pyx_k_py,
sizeof(__pyx_k_py), 0, 0, 1, 1},
35582 {&__pyx_n_s_pyx_PickleError, __pyx_k_pyx_PickleError,
sizeof(__pyx_k_pyx_PickleError), 0, 0, 1, 1},
35583 {&__pyx_n_s_pyx_checksum, __pyx_k_pyx_checksum,
sizeof(__pyx_k_pyx_checksum), 0, 0, 1, 1},
35584 {&__pyx_n_s_pyx_getbuffer, __pyx_k_pyx_getbuffer,
sizeof(__pyx_k_pyx_getbuffer), 0, 0, 1, 1},
35585 {&__pyx_n_s_pyx_result, __pyx_k_pyx_result,
sizeof(__pyx_k_pyx_result), 0, 0, 1, 1},
35586 {&__pyx_n_s_pyx_state, __pyx_k_pyx_state,
sizeof(__pyx_k_pyx_state), 0, 0, 1, 1},
35587 {&__pyx_n_s_pyx_type, __pyx_k_pyx_type,
sizeof(__pyx_k_pyx_type), 0, 0, 1, 1},
35588 {&__pyx_n_s_pyx_unpickle_Enum, __pyx_k_pyx_unpickle_Enum,
sizeof(__pyx_k_pyx_unpickle_Enum), 0, 0, 1, 1},
35589 {&__pyx_n_s_pyx_vtable, __pyx_k_pyx_vtable,
sizeof(__pyx_k_pyx_vtable), 0, 0, 1, 1},
35590 {&__pyx_n_s_pz, __pyx_k_pz,
sizeof(__pyx_k_pz), 0, 0, 1, 1},
35591 {&__pyx_n_s_range, __pyx_k_range,
sizeof(__pyx_k_range), 0, 0, 1, 1},
35592 {&__pyx_n_s_reduce, __pyx_k_reduce,
sizeof(__pyx_k_reduce), 0, 0, 1, 1},
35593 {&__pyx_n_s_reduce_cython, __pyx_k_reduce_cython,
sizeof(__pyx_k_reduce_cython), 0, 0, 1, 1},
35594 {&__pyx_n_s_reduce_ex, __pyx_k_reduce_ex,
sizeof(__pyx_k_reduce_ex), 0, 0, 1, 1},
35595 {&__pyx_n_s_refineTypeFlag, __pyx_k_refineTypeFlag,
sizeof(__pyx_k_refineTypeFlag), 0, 0, 1, 1},
35596 {&__pyx_kp_u_s, __pyx_k_s,
sizeof(__pyx_k_s), 0, 1, 0, 0},
35597 {&__pyx_kp_s_self_mesh_cannot_be_converted_to, __pyx_k_self_mesh_cannot_be_converted_to,
sizeof(__pyx_k_self_mesh_cannot_be_converted_to), 0, 0, 1, 0},
35598 {&__pyx_kp_s_self_multilevelMesh_cannot_be_co, __pyx_k_self_multilevelMesh_cannot_be_co,
sizeof(__pyx_k_self_multilevelMesh_cannot_be_co), 0, 0, 1, 0},
35599 {&__pyx_n_s_setNewestNodeBases, __pyx_k_setNewestNodeBases,
sizeof(__pyx_k_setNewestNodeBases), 0, 0, 1, 1},
35600 {&__pyx_kp_s_setNewestNodeBases_0_d_not_imple, __pyx_k_setNewestNodeBases_0_d_not_imple,
sizeof(__pyx_k_setNewestNodeBases_0_d_not_imple), 0, 0, 1, 0},
35601 {&__pyx_n_s_setstate, __pyx_k_setstate,
sizeof(__pyx_k_setstate), 0, 0, 1, 1},
35602 {&__pyx_n_s_setstate_cython, __pyx_k_setstate_cython,
sizeof(__pyx_k_setstate_cython), 0, 0, 1, 1},
35603 {&__pyx_n_s_shape, __pyx_k_shape,
sizeof(__pyx_k_shape), 0, 0, 1, 1},
35604 {&__pyx_n_s_sigmaMax, __pyx_k_sigmaMax,
sizeof(__pyx_k_sigmaMax), 0, 0, 1, 1},
35605 {&__pyx_n_s_size, __pyx_k_size,
sizeof(__pyx_k_size), 0, 0, 1, 1},
35606 {&__pyx_n_s_start, __pyx_k_start,
sizeof(__pyx_k_start), 0, 0, 1, 1},
35607 {&__pyx_n_s_step, __pyx_k_step,
sizeof(__pyx_k_step), 0, 0, 1, 1},
35608 {&__pyx_n_s_stop, __pyx_k_stop,
sizeof(__pyx_k_stop), 0, 0, 1, 1},
35609 {&__pyx_kp_s_strided_and_direct, __pyx_k_strided_and_direct,
sizeof(__pyx_k_strided_and_direct), 0, 0, 1, 0},
35610 {&__pyx_kp_s_strided_and_direct_or_indirect, __pyx_k_strided_and_direct_or_indirect,
sizeof(__pyx_k_strided_and_direct_or_indirect), 0, 0, 1, 0},
35611 {&__pyx_kp_s_strided_and_indirect, __pyx_k_strided_and_indirect,
sizeof(__pyx_k_strided_and_indirect), 0, 0, 1, 0},
35612 {&__pyx_kp_s_stringsource, __pyx_k_stringsource,
sizeof(__pyx_k_stringsource), 0, 0, 1, 0},
35613 {&__pyx_n_s_struct, __pyx_k_struct,
sizeof(__pyx_k_struct), 0, 0, 1, 1},
35614 {&__pyx_n_s_test, __pyx_k_test,
sizeof(__pyx_k_test), 0, 0, 1, 1},
35615 {&__pyx_n_s_triangleFlag, __pyx_k_triangleFlag,
sizeof(__pyx_k_triangleFlag), 0, 0, 1, 1},
35616 {&__pyx_kp_s_unable_to_allocate_array_data, __pyx_k_unable_to_allocate_array_data,
sizeof(__pyx_k_unable_to_allocate_array_data), 0, 0, 1, 0},
35617 {&__pyx_kp_s_unable_to_allocate_shape_and_str, __pyx_k_unable_to_allocate_shape_and_str,
sizeof(__pyx_k_unable_to_allocate_shape_and_str), 0, 0, 1, 0},
35618 {&__pyx_n_s_unpack, __pyx_k_unpack,
sizeof(__pyx_k_unpack), 0, 0, 1, 1},
35619 {&__pyx_n_s_update, __pyx_k_update,
sizeof(__pyx_k_update), 0, 0, 1, 1},
35620 {&__pyx_n_s_volume, __pyx_k_volume,
sizeof(__pyx_k_volume), 0, 0, 1, 1},
35621 {&__pyx_n_s_weights, __pyx_k_weights,
sizeof(__pyx_k_weights), 0, 0, 1, 1},
35622 {&__pyx_kp_s_wrong_nLevels, __pyx_k_wrong_nLevels,
sizeof(__pyx_k_wrong_nLevels), 0, 0, 1, 0},
35623 {&__pyx_n_s_zeros, __pyx_k_zeros,
sizeof(__pyx_k_zeros), 0, 0, 1, 1},
35624 {0, 0, 0, 0, 0, 0, 0}
35626 static CYTHON_SMALL_CODE
int __Pyx_InitCachedBuiltins(
void) {
35627 __pyx_builtin_TypeError = __Pyx_GetBuiltinName(__pyx_n_s_TypeError);
if (!__pyx_builtin_TypeError) __PYX_ERR(0, 2, __pyx_L1_error)
35628 __pyx_builtin_range = __Pyx_GetBuiltinName(__pyx_n_s_range);
if (!__pyx_builtin_range) __PYX_ERR(1, 217, __pyx_L1_error)
35629 __pyx_builtin_ImportError = __Pyx_GetBuiltinName(__pyx_n_s_ImportError);
if (!__pyx_builtin_ImportError) __PYX_ERR(3, 945, __pyx_L1_error)
35630 __pyx_builtin_ValueError = __Pyx_GetBuiltinName(__pyx_n_s_ValueError);
if (!__pyx_builtin_ValueError) __PYX_ERR(0, 133, __pyx_L1_error)
35631 __pyx_builtin_MemoryError = __Pyx_GetBuiltinName(__pyx_n_s_MemoryError);
if (!__pyx_builtin_MemoryError) __PYX_ERR(0, 148, __pyx_L1_error)
35632 __pyx_builtin_enumerate = __Pyx_GetBuiltinName(__pyx_n_s_enumerate);
if (!__pyx_builtin_enumerate) __PYX_ERR(0, 151, __pyx_L1_error)
35633 __pyx_builtin_Ellipsis = __Pyx_GetBuiltinName(__pyx_n_s_Ellipsis);
if (!__pyx_builtin_Ellipsis) __PYX_ERR(0, 404, __pyx_L1_error)
35634 __pyx_builtin_id = __Pyx_GetBuiltinName(__pyx_n_s_id);
if (!__pyx_builtin_id) __PYX_ERR(0, 613, __pyx_L1_error)
35635 __pyx_builtin_IndexError = __Pyx_GetBuiltinName(__pyx_n_s_IndexError);
if (!__pyx_builtin_IndexError) __PYX_ERR(0, 832, __pyx_L1_error)
35641 static CYTHON_SMALL_CODE
int __Pyx_InitCachedConstants(
void) {
35642 __Pyx_RefNannyDeclarations
35643 __Pyx_RefNannySetupContext(
"__Pyx_InitCachedConstants", 0);
35652 __pyx_tuple_ = PyTuple_Pack(1, __pyx_int_0);
if (unlikely(!__pyx_tuple_)) __PYX_ERR(1, 37, __pyx_L1_error)
35653 __Pyx_GOTREF(__pyx_tuple_);
35654 __Pyx_GIVEREF(__pyx_tuple_);
35662 __pyx_tuple__2 = PyTuple_Pack(1, __pyx_kp_s_self_mesh_cannot_be_converted_to);
if (unlikely(!__pyx_tuple__2)) __PYX_ERR(0, 2, __pyx_L1_error)
35663 __Pyx_GOTREF(__pyx_tuple__2);
35664 __Pyx_GIVEREF(__pyx_tuple__2);
35671 __pyx_tuple__3 = PyTuple_Pack(1, __pyx_kp_s_self_mesh_cannot_be_converted_to);
if (unlikely(!__pyx_tuple__3)) __PYX_ERR(0, 4, __pyx_L1_error)
35672 __Pyx_GOTREF(__pyx_tuple__3);
35673 __Pyx_GIVEREF(__pyx_tuple__3);
35681 __pyx_tuple__4 = PyTuple_Pack(1, __pyx_kp_s_self_multilevelMesh_cannot_be_co);
if (unlikely(!__pyx_tuple__4)) __PYX_ERR(0, 2, __pyx_L1_error)
35682 __Pyx_GOTREF(__pyx_tuple__4);
35683 __Pyx_GIVEREF(__pyx_tuple__4);
35690 __pyx_tuple__5 = PyTuple_Pack(1, __pyx_kp_s_self_multilevelMesh_cannot_be_co);
if (unlikely(!__pyx_tuple__5)) __PYX_ERR(0, 4, __pyx_L1_error)
35691 __Pyx_GOTREF(__pyx_tuple__5);
35692 __Pyx_GIVEREF(__pyx_tuple__5);
35701 __pyx_tuple__6 = PyTuple_Pack(1, __pyx_kp_s_numpy_core_multiarray_failed_to);
if (unlikely(!__pyx_tuple__6)) __PYX_ERR(3, 945, __pyx_L1_error)
35702 __Pyx_GOTREF(__pyx_tuple__6);
35703 __Pyx_GIVEREF(__pyx_tuple__6);
35712 __pyx_tuple__7 = PyTuple_Pack(1, __pyx_kp_s_numpy_core_umath_failed_to_impor);
if (unlikely(!__pyx_tuple__7)) __PYX_ERR(3, 951, __pyx_L1_error)
35713 __Pyx_GOTREF(__pyx_tuple__7);
35714 __Pyx_GIVEREF(__pyx_tuple__7);
35723 __pyx_tuple__8 = PyTuple_Pack(1, __pyx_kp_s_Empty_shape_tuple_for_cython_arr);
if (unlikely(!__pyx_tuple__8)) __PYX_ERR(0, 133, __pyx_L1_error)
35724 __Pyx_GOTREF(__pyx_tuple__8);
35725 __Pyx_GIVEREF(__pyx_tuple__8);
35734 __pyx_tuple__9 = PyTuple_Pack(1, __pyx_kp_s_itemsize_0_for_cython_array);
if (unlikely(!__pyx_tuple__9)) __PYX_ERR(0, 136, __pyx_L1_error)
35735 __Pyx_GOTREF(__pyx_tuple__9);
35736 __Pyx_GIVEREF(__pyx_tuple__9);
35745 __pyx_tuple__10 = PyTuple_Pack(1, __pyx_kp_s_unable_to_allocate_shape_and_str);
if (unlikely(!__pyx_tuple__10)) __PYX_ERR(0, 148, __pyx_L1_error)
35746 __Pyx_GOTREF(__pyx_tuple__10);
35747 __Pyx_GIVEREF(__pyx_tuple__10);
35756 __pyx_tuple__11 = PyTuple_Pack(1, __pyx_kp_s_unable_to_allocate_array_data);
if (unlikely(!__pyx_tuple__11)) __PYX_ERR(0, 176, __pyx_L1_error)
35757 __Pyx_GOTREF(__pyx_tuple__11);
35758 __Pyx_GIVEREF(__pyx_tuple__11);
35767 __pyx_tuple__12 = PyTuple_Pack(1, __pyx_kp_s_Can_only_create_a_buffer_that_is);
if (unlikely(!__pyx_tuple__12)) __PYX_ERR(0, 192, __pyx_L1_error)
35768 __Pyx_GOTREF(__pyx_tuple__12);
35769 __Pyx_GIVEREF(__pyx_tuple__12);
35777 __pyx_tuple__13 = PyTuple_Pack(1, __pyx_kp_s_no_default___reduce___due_to_non);
if (unlikely(!__pyx_tuple__13)) __PYX_ERR(0, 2, __pyx_L1_error)
35778 __Pyx_GOTREF(__pyx_tuple__13);
35779 __Pyx_GIVEREF(__pyx_tuple__13);
35786 __pyx_tuple__14 = PyTuple_Pack(1, __pyx_kp_s_no_default___reduce___due_to_non);
if (unlikely(!__pyx_tuple__14)) __PYX_ERR(0, 4, __pyx_L1_error)
35787 __Pyx_GOTREF(__pyx_tuple__14);
35788 __Pyx_GIVEREF(__pyx_tuple__14);
35797 __pyx_tuple__15 = PyTuple_Pack(1, __pyx_kp_s_Cannot_assign_to_read_only_memor);
if (unlikely(!__pyx_tuple__15)) __PYX_ERR(0, 418, __pyx_L1_error)
35798 __Pyx_GOTREF(__pyx_tuple__15);
35799 __Pyx_GIVEREF(__pyx_tuple__15);
35808 __pyx_tuple__16 = PyTuple_Pack(1, __pyx_kp_s_Unable_to_convert_item_to_object);
if (unlikely(!__pyx_tuple__16)) __PYX_ERR(0, 495, __pyx_L1_error)
35809 __Pyx_GOTREF(__pyx_tuple__16);
35810 __Pyx_GIVEREF(__pyx_tuple__16);
35819 __pyx_tuple__17 = PyTuple_Pack(1, __pyx_kp_s_Cannot_create_writable_memory_vi);
if (unlikely(!__pyx_tuple__17)) __PYX_ERR(0, 520, __pyx_L1_error)
35820 __Pyx_GOTREF(__pyx_tuple__17);
35821 __Pyx_GIVEREF(__pyx_tuple__17);
35830 __pyx_tuple__18 = PyTuple_Pack(1, __pyx_kp_s_Buffer_view_does_not_expose_stri);
if (unlikely(!__pyx_tuple__18)) __PYX_ERR(0, 570, __pyx_L1_error)
35831 __Pyx_GOTREF(__pyx_tuple__18);
35832 __Pyx_GIVEREF(__pyx_tuple__18);
35841 __pyx_tuple__19 = PyTuple_New(1);
if (unlikely(!__pyx_tuple__19)) __PYX_ERR(0, 577, __pyx_L1_error)
35842 __Pyx_GOTREF(__pyx_tuple__19);
35843 __Pyx_INCREF(__pyx_int_neg_1);
35844 __Pyx_GIVEREF(__pyx_int_neg_1);
35845 PyTuple_SET_ITEM(__pyx_tuple__19, 0, __pyx_int_neg_1);
35846 __Pyx_GIVEREF(__pyx_tuple__19);
35854 __pyx_tuple__20 = PyTuple_Pack(1, __pyx_kp_s_no_default___reduce___due_to_non);
if (unlikely(!__pyx_tuple__20)) __PYX_ERR(0, 2, __pyx_L1_error)
35855 __Pyx_GOTREF(__pyx_tuple__20);
35856 __Pyx_GIVEREF(__pyx_tuple__20);
35863 __pyx_tuple__21 = PyTuple_Pack(1, __pyx_kp_s_no_default___reduce___due_to_non);
if (unlikely(!__pyx_tuple__21)) __PYX_ERR(0, 4, __pyx_L1_error)
35864 __Pyx_GOTREF(__pyx_tuple__21);
35865 __Pyx_GIVEREF(__pyx_tuple__21);
35874 __pyx_slice__22 = PySlice_New(Py_None, Py_None, Py_None);
if (unlikely(!__pyx_slice__22)) __PYX_ERR(0, 682, __pyx_L1_error)
35875 __Pyx_GOTREF(__pyx_slice__22);
35876 __Pyx_GIVEREF(__pyx_slice__22);
35885 __pyx_tuple__23 = PyTuple_Pack(1, __pyx_kp_s_Indirect_dimensions_not_supporte);
if (unlikely(!__pyx_tuple__23)) __PYX_ERR(0, 703, __pyx_L1_error)
35886 __Pyx_GOTREF(__pyx_tuple__23);
35887 __Pyx_GIVEREF(__pyx_tuple__23);
35895 __pyx_tuple__24 = PyTuple_Pack(1, __pyx_kp_s_no_default___reduce___due_to_non);
if (unlikely(!__pyx_tuple__24)) __PYX_ERR(0, 2, __pyx_L1_error)
35896 __Pyx_GOTREF(__pyx_tuple__24);
35897 __Pyx_GIVEREF(__pyx_tuple__24);
35904 __pyx_tuple__25 = PyTuple_Pack(1, __pyx_kp_s_no_default___reduce___due_to_non);
if (unlikely(!__pyx_tuple__25)) __PYX_ERR(0, 4, __pyx_L1_error)
35905 __Pyx_GOTREF(__pyx_tuple__25);
35906 __Pyx_GIVEREF(__pyx_tuple__25);
35907 __pyx_tuple__26 = PyTuple_Pack(3, __pyx_int_184977713, __pyx_int_136983863, __pyx_int_112105877);
if (unlikely(!__pyx_tuple__26)) __PYX_ERR(0, 4, __pyx_L1_error)
35908 __Pyx_GOTREF(__pyx_tuple__26);
35909 __Pyx_GIVEREF(__pyx_tuple__26);
35918 __pyx_tuple__32 = PyTuple_Pack(1, __pyx_n_s_cmesh);
if (unlikely(!__pyx_tuple__32)) __PYX_ERR(1, 120, __pyx_L1_error)
35919 __Pyx_GOTREF(__pyx_tuple__32);
35920 __Pyx_GIVEREF(__pyx_tuple__32);
35921 __pyx_codeobj__33 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__32, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cmeshTools_pyx, __pyx_n_s_buildPythonMeshInterface, 120, __pyx_empty_bytes);
if (unlikely(!__pyx_codeobj__33)) __PYX_ERR(1, 120, __pyx_L1_error)
35930 __pyx_tuple__34 = PyTuple_Pack(1, __pyx_n_s_cmesh);
if (unlikely(!__pyx_tuple__34)) __PYX_ERR(1, 176, __pyx_L1_error)
35931 __Pyx_GOTREF(__pyx_tuple__34);
35932 __Pyx_GIVEREF(__pyx_tuple__34);
35933 __pyx_codeobj__35 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__34, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cmeshTools_pyx, __pyx_n_s_buildPythonMeshInterfaceNoArrays, 176, __pyx_empty_bytes);
if (unlikely(!__pyx_codeobj__35)) __PYX_ERR(1, 176, __pyx_L1_error)
35942 __pyx_tuple__36 = PyTuple_Pack(1, __pyx_n_s_cmultilevelMesh);
if (unlikely(!__pyx_tuple__36)) __PYX_ERR(1, 300, __pyx_L1_error)
35943 __Pyx_GOTREF(__pyx_tuple__36);
35944 __Pyx_GIVEREF(__pyx_tuple__36);
35945 __pyx_codeobj__37 = (PyObject*)__Pyx_PyCode_New(1, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__36, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cmeshTools_pyx, __pyx_n_s_buildPythonMultilevelMeshInterfa, 300, __pyx_empty_bytes);
if (unlikely(!__pyx_codeobj__37)) __PYX_ERR(1, 300, __pyx_L1_error)
35954 __pyx_tuple__38 = PyTuple_Pack(6, __pyx_n_s_nSpace, __pyx_n_s_cmultilevelMesh, __pyx_n_s_elementTagArray, __pyx_n_s_refineTypeFlag, __pyx_n_s_failed, __pyx_n_s_finestLevel);
if (unlikely(!__pyx_tuple__38)) __PYX_ERR(1, 495, __pyx_L1_error)
35955 __Pyx_GOTREF(__pyx_tuple__38);
35956 __Pyx_GIVEREF(__pyx_tuple__38);
35957 __pyx_codeobj__39 = (PyObject*)__Pyx_PyCode_New(4, 0, 6, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__38, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cmeshTools_pyx, __pyx_n_s_locallyRefineMultilevelMesh, 495, __pyx_empty_bytes);
if (unlikely(!__pyx_codeobj__39)) __PYX_ERR(1, 495, __pyx_L1_error)
35966 __pyx_tuple__40 = PyTuple_Pack(3, __pyx_n_s_nSpace, __pyx_n_s_cmultilevelMesh, __pyx_n_s_failed);
if (unlikely(!__pyx_tuple__40)) __PYX_ERR(1, 533, __pyx_L1_error)
35967 __Pyx_GOTREF(__pyx_tuple__40);
35968 __Pyx_GIVEREF(__pyx_tuple__40);
35969 __pyx_codeobj__41 = (PyObject*)__Pyx_PyCode_New(2, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__40, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_proteus_cmeshTools_pyx, __pyx_n_s_setNewestNodeBases, 533, __pyx_empty_bytes);
if (unlikely(!__pyx_codeobj__41)) __PYX_ERR(1, 533, __pyx_L1_error)
35978 __pyx_tuple__42 = PyTuple_Pack(1, __pyx_kp_s_strided_and_direct_or_indirect);
if (unlikely(!__pyx_tuple__42)) __PYX_ERR(0, 286, __pyx_L1_error)
35979 __Pyx_GOTREF(__pyx_tuple__42);
35980 __Pyx_GIVEREF(__pyx_tuple__42);
35989 __pyx_tuple__43 = PyTuple_Pack(1, __pyx_kp_s_strided_and_direct);
if (unlikely(!__pyx_tuple__43)) __PYX_ERR(0, 287, __pyx_L1_error)
35990 __Pyx_GOTREF(__pyx_tuple__43);
35991 __Pyx_GIVEREF(__pyx_tuple__43);
36000 __pyx_tuple__44 = PyTuple_Pack(1, __pyx_kp_s_strided_and_indirect);
if (unlikely(!__pyx_tuple__44)) __PYX_ERR(0, 288, __pyx_L1_error)
36001 __Pyx_GOTREF(__pyx_tuple__44);
36002 __Pyx_GIVEREF(__pyx_tuple__44);
36011 __pyx_tuple__45 = PyTuple_Pack(1, __pyx_kp_s_contiguous_and_direct);
if (unlikely(!__pyx_tuple__45)) __PYX_ERR(0, 291, __pyx_L1_error)
36012 __Pyx_GOTREF(__pyx_tuple__45);
36013 __Pyx_GIVEREF(__pyx_tuple__45);
36022 __pyx_tuple__46 = PyTuple_Pack(1, __pyx_kp_s_contiguous_and_indirect);
if (unlikely(!__pyx_tuple__46)) __PYX_ERR(0, 292, __pyx_L1_error)
36023 __Pyx_GOTREF(__pyx_tuple__46);
36024 __Pyx_GIVEREF(__pyx_tuple__46);
36031 __pyx_tuple__47 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result);
if (unlikely(!__pyx_tuple__47)) __PYX_ERR(0, 1, __pyx_L1_error)
36032 __Pyx_GOTREF(__pyx_tuple__47);
36033 __Pyx_GIVEREF(__pyx_tuple__47);
36034 __pyx_codeobj__48 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__47, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Enum, 1, __pyx_empty_bytes);
if (unlikely(!__pyx_codeobj__48)) __PYX_ERR(0, 1, __pyx_L1_error)
36035 __Pyx_RefNannyFinishContext();
36038 __Pyx_RefNannyFinishContext();
36042 static CYTHON_SMALL_CODE
int __Pyx_InitGlobals(
void) {
36043 if (__Pyx_InitStrings(__pyx_string_tab) < 0) __PYX_ERR(1, 1, __pyx_L1_error);
36044 __pyx_int_0 = PyInt_FromLong(0);
if (unlikely(!__pyx_int_0)) __PYX_ERR(1, 1, __pyx_L1_error)
36045 __pyx_int_1 = PyInt_FromLong(1);
if (unlikely(!__pyx_int_1)) __PYX_ERR(1, 1, __pyx_L1_error)
36046 __pyx_int_112105877 = PyInt_FromLong(112105877
L);
if (unlikely(!__pyx_int_112105877)) __PYX_ERR(1, 1, __pyx_L1_error)
36047 __pyx_int_136983863 = PyInt_FromLong(136983863
L);
if (unlikely(!__pyx_int_136983863)) __PYX_ERR(1, 1, __pyx_L1_error)
36048 __pyx_int_184977713 = PyInt_FromLong(184977713
L);
if (unlikely(!__pyx_int_184977713)) __PYX_ERR(1, 1, __pyx_L1_error)
36049 __pyx_int_neg_1 = PyInt_FromLong(-1);
if (unlikely(!__pyx_int_neg_1)) __PYX_ERR(1, 1, __pyx_L1_error)
36055 static CYTHON_SMALL_CODE
int __Pyx_modinit_global_init_code(
void);
36056 static CYTHON_SMALL_CODE
int __Pyx_modinit_variable_export_code(
void);
36057 static CYTHON_SMALL_CODE
int __Pyx_modinit_function_export_code(
void);
36058 static CYTHON_SMALL_CODE
int __Pyx_modinit_type_init_code(
void);
36059 static CYTHON_SMALL_CODE
int __Pyx_modinit_type_import_code(
void);
36060 static CYTHON_SMALL_CODE
int __Pyx_modinit_variable_import_code(
void);
36061 static CYTHON_SMALL_CODE
int __Pyx_modinit_function_import_code(
void);
36063 static int __Pyx_modinit_global_init_code(
void) {
36064 __Pyx_RefNannyDeclarations
36065 __Pyx_RefNannySetupContext(
"__Pyx_modinit_global_init_code", 0);
36067 generic = Py_None; Py_INCREF(Py_None);
36068 strided = Py_None; Py_INCREF(Py_None);
36069 indirect = Py_None; Py_INCREF(Py_None);
36070 contiguous = Py_None; Py_INCREF(Py_None);
36071 indirect_contiguous = Py_None; Py_INCREF(Py_None);
36072 __Pyx_RefNannyFinishContext();
36076 static int __Pyx_modinit_variable_export_code(
void) {
36077 __Pyx_RefNannyDeclarations
36078 __Pyx_RefNannySetupContext(
"__Pyx_modinit_variable_export_code", 0);
36080 __Pyx_RefNannyFinishContext();
36084 static int __Pyx_modinit_function_export_code(
void) {
36085 __Pyx_RefNannyDeclarations
36086 __Pyx_RefNannySetupContext(
"__Pyx_modinit_function_export_code", 0);
36088 __Pyx_RefNannyFinishContext();
36092 static int __Pyx_modinit_type_init_code(
void) {
36093 __Pyx_RefNannyDeclarations
36094 int __pyx_lineno = 0;
36095 const char *__pyx_filename = NULL;
36096 int __pyx_clineno = 0;
36097 __Pyx_RefNannySetupContext(
"__Pyx_modinit_type_init_code", 0);
36099 if (PyType_Ready(&__pyx_type_10cmeshTools_CMesh) < 0) __PYX_ERR(1, 11, __pyx_L1_error)
36100 #if PY_VERSION_HEX < 0x030800B1
36101 __pyx_type_10cmeshTools_CMesh.tp_print = 0;
36103 if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_10cmeshTools_CMesh.tp_dictoffset && __pyx_type_10cmeshTools_CMesh.tp_getattro == PyObject_GenericGetAttr)) {
36104 __pyx_type_10cmeshTools_CMesh.tp_getattro = __Pyx_PyObject_GenericGetAttr;
36106 if (PyObject_SetAttr(__pyx_m, __pyx_n_s_CMesh, (PyObject *)&__pyx_type_10cmeshTools_CMesh) < 0) __PYX_ERR(1, 11, __pyx_L1_error)
36107 if (__Pyx_setup_reduce((PyObject*)&__pyx_type_10cmeshTools_CMesh) < 0) __PYX_ERR(1, 11, __pyx_L1_error)
36108 __pyx_ptype_10cmeshTools_CMesh = &__pyx_type_10cmeshTools_CMesh;
36109 if (PyType_Ready(&__pyx_type_10cmeshTools_CMultilevelMesh) < 0) __PYX_ERR(1, 202, __pyx_L1_error)
36110 #if PY_VERSION_HEX < 0x030800B1
36111 __pyx_type_10cmeshTools_CMultilevelMesh.tp_print = 0;
36113 if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_10cmeshTools_CMultilevelMesh.tp_dictoffset && __pyx_type_10cmeshTools_CMultilevelMesh.tp_getattro == PyObject_GenericGetAttr)) {
36114 __pyx_type_10cmeshTools_CMultilevelMesh.tp_getattro = __Pyx_PyObject_GenericGetAttr;
36116 if (PyObject_SetAttr(__pyx_m, __pyx_n_s_CMultilevelMesh, (PyObject *)&__pyx_type_10cmeshTools_CMultilevelMesh) < 0) __PYX_ERR(1, 202, __pyx_L1_error)
36117 if (__Pyx_setup_reduce((PyObject*)&__pyx_type_10cmeshTools_CMultilevelMesh) < 0) __PYX_ERR(1, 202, __pyx_L1_error)
36118 __pyx_ptype_10cmeshTools_CMultilevelMesh = &__pyx_type_10cmeshTools_CMultilevelMesh;
36119 __pyx_vtabptr_array = &__pyx_vtable_array;
36120 __pyx_vtable_array.get_memview = (PyObject *(*)(
struct __pyx_array_obj *))__pyx_array_get_memview;
36121 if (PyType_Ready(&__pyx_type___pyx_array) < 0) __PYX_ERR(0, 105, __pyx_L1_error)
36122 #if PY_VERSION_HEX < 0x030800B1
36123 __pyx_type___pyx_array.tp_print = 0;
36125 if (__Pyx_SetVtable(__pyx_type___pyx_array.tp_dict, __pyx_vtabptr_array) < 0) __PYX_ERR(0, 105, __pyx_L1_error)
36126 if (__Pyx_setup_reduce((PyObject*)&__pyx_type___pyx_array) < 0) __PYX_ERR(0, 105, __pyx_L1_error)
36127 __pyx_array_type = &__pyx_type___pyx_array;
36128 if (PyType_Ready(&__pyx_type___pyx_MemviewEnum) < 0) __PYX_ERR(0, 279, __pyx_L1_error)
36129 #if PY_VERSION_HEX < 0x030800B1
36130 __pyx_type___pyx_MemviewEnum.tp_print = 0;
36132 if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type___pyx_MemviewEnum.tp_dictoffset && __pyx_type___pyx_MemviewEnum.tp_getattro == PyObject_GenericGetAttr)) {
36133 __pyx_type___pyx_MemviewEnum.tp_getattro = __Pyx_PyObject_GenericGetAttr;
36135 if (__Pyx_setup_reduce((PyObject*)&__pyx_type___pyx_MemviewEnum) < 0) __PYX_ERR(0, 279, __pyx_L1_error)
36136 __pyx_MemviewEnum_type = &__pyx_type___pyx_MemviewEnum;
36137 __pyx_vtabptr_memoryview = &__pyx_vtable_memoryview;
36138 __pyx_vtable_memoryview.get_item_pointer = (
char *(*)(
struct __pyx_memoryview_obj *, PyObject *))__pyx_memoryview_get_item_pointer;
36139 __pyx_vtable_memoryview.is_slice = (PyObject *(*)(
struct __pyx_memoryview_obj *, PyObject *))__pyx_memoryview_is_slice;
36140 __pyx_vtable_memoryview.setitem_slice_assignment = (PyObject *(*)(
struct __pyx_memoryview_obj *, PyObject *, PyObject *))__pyx_memoryview_setitem_slice_assignment;
36141 __pyx_vtable_memoryview.setitem_slice_assign_scalar = (PyObject *(*)(
struct __pyx_memoryview_obj *,
struct __pyx_memoryview_obj *, PyObject *))__pyx_memoryview_setitem_slice_assign_scalar;
36142 __pyx_vtable_memoryview.setitem_indexed = (PyObject *(*)(
struct __pyx_memoryview_obj *, PyObject *, PyObject *))__pyx_memoryview_setitem_indexed;
36143 __pyx_vtable_memoryview.convert_item_to_object = (PyObject *(*)(
struct __pyx_memoryview_obj *,
char *))__pyx_memoryview_convert_item_to_object;
36144 __pyx_vtable_memoryview.assign_item_from_object = (PyObject *(*)(
struct __pyx_memoryview_obj *,
char *, PyObject *))__pyx_memoryview_assign_item_from_object;
36145 if (PyType_Ready(&__pyx_type___pyx_memoryview) < 0) __PYX_ERR(0, 330, __pyx_L1_error)
36146 #if PY_VERSION_HEX < 0x030800B1
36147 __pyx_type___pyx_memoryview.tp_print = 0;
36149 if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type___pyx_memoryview.tp_dictoffset && __pyx_type___pyx_memoryview.tp_getattro == PyObject_GenericGetAttr)) {
36150 __pyx_type___pyx_memoryview.tp_getattro = __Pyx_PyObject_GenericGetAttr;
36152 if (__Pyx_SetVtable(__pyx_type___pyx_memoryview.tp_dict, __pyx_vtabptr_memoryview) < 0) __PYX_ERR(0, 330, __pyx_L1_error)
36153 if (__Pyx_setup_reduce((PyObject*)&__pyx_type___pyx_memoryview) < 0) __PYX_ERR(0, 330, __pyx_L1_error)
36154 __pyx_memoryview_type = &__pyx_type___pyx_memoryview;
36155 __pyx_vtabptr__memoryviewslice = &__pyx_vtable__memoryviewslice;
36156 __pyx_vtable__memoryviewslice.__pyx_base = *__pyx_vtabptr_memoryview;
36157 __pyx_vtable__memoryviewslice.__pyx_base.convert_item_to_object = (PyObject *(*)(
struct __pyx_memoryview_obj *,
char *))__pyx_memoryviewslice_convert_item_to_object;
36158 __pyx_vtable__memoryviewslice.__pyx_base.assign_item_from_object = (PyObject *(*)(
struct __pyx_memoryview_obj *,
char *, PyObject *))__pyx_memoryviewslice_assign_item_from_object;
36159 __pyx_type___pyx_memoryviewslice.tp_base = __pyx_memoryview_type;
36160 if (PyType_Ready(&__pyx_type___pyx_memoryviewslice) < 0) __PYX_ERR(0, 965, __pyx_L1_error)
36161 #if PY_VERSION_HEX < 0x030800B1
36162 __pyx_type___pyx_memoryviewslice.tp_print = 0;
36164 if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type___pyx_memoryviewslice.tp_dictoffset && __pyx_type___pyx_memoryviewslice.tp_getattro == PyObject_GenericGetAttr)) {
36165 __pyx_type___pyx_memoryviewslice.tp_getattro = __Pyx_PyObject_GenericGetAttr;
36167 if (__Pyx_SetVtable(__pyx_type___pyx_memoryviewslice.tp_dict, __pyx_vtabptr__memoryviewslice) < 0) __PYX_ERR(0, 965, __pyx_L1_error)
36168 if (__Pyx_setup_reduce((PyObject*)&__pyx_type___pyx_memoryviewslice) < 0) __PYX_ERR(0, 965, __pyx_L1_error)
36169 __pyx_memoryviewslice_type = &__pyx_type___pyx_memoryviewslice;
36170 __Pyx_RefNannyFinishContext();
36173 __Pyx_RefNannyFinishContext();
36177 static int __Pyx_modinit_type_import_code(
void) {
36178 __Pyx_RefNannyDeclarations
36179 PyObject *__pyx_t_1 = NULL;
36180 int __pyx_lineno = 0;
36181 const char *__pyx_filename = NULL;
36182 int __pyx_clineno = 0;
36183 __Pyx_RefNannySetupContext(
"__Pyx_modinit_type_import_code", 0);
36185 __pyx_t_1 = PyImport_ImportModule(__Pyx_BUILTIN_MODULE_NAME);
if (unlikely(!__pyx_t_1)) __PYX_ERR(4, 9, __pyx_L1_error)
36186 __Pyx_GOTREF(__pyx_t_1);
36187 __pyx_ptype_7cpython_4type_type = __Pyx_ImportType(__pyx_t_1, __Pyx_BUILTIN_MODULE_NAME,
"type",
36188 #
if defined(PYPY_VERSION_NUM) && PYPY_VERSION_NUM < 0x050B0000
36189 sizeof(PyTypeObject),
36191 sizeof(PyHeapTypeObject),
36193 __Pyx_ImportType_CheckSize_Warn);
36194 if (!__pyx_ptype_7cpython_4type_type) __PYX_ERR(4, 9, __pyx_L1_error)
36195 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36196 __pyx_t_1 = PyImport_ImportModule(
"numpy");
if (unlikely(!__pyx_t_1)) __PYX_ERR(3, 200, __pyx_L1_error)
36197 __Pyx_GOTREF(__pyx_t_1);
36198 __pyx_ptype_5numpy_dtype = __Pyx_ImportType(__pyx_t_1,
"numpy",
"dtype",
sizeof(PyArray_Descr), __Pyx_ImportType_CheckSize_Ignore);
36199 if (!__pyx_ptype_5numpy_dtype) __PYX_ERR(3, 200, __pyx_L1_error)
36200 __pyx_ptype_5numpy_flatiter = __Pyx_ImportType(__pyx_t_1,
"numpy",
"flatiter",
sizeof(PyArrayIterObject), __Pyx_ImportType_CheckSize_Ignore);
36201 if (!__pyx_ptype_5numpy_flatiter) __PYX_ERR(3, 223, __pyx_L1_error)
36202 __pyx_ptype_5numpy_broadcast = __Pyx_ImportType(__pyx_t_1,
"numpy",
"broadcast",
sizeof(PyArrayMultiIterObject), __Pyx_ImportType_CheckSize_Ignore);
36203 if (!__pyx_ptype_5numpy_broadcast) __PYX_ERR(3, 227, __pyx_L1_error)
36204 __pyx_ptype_5numpy_ndarray = __Pyx_ImportType(__pyx_t_1,
"numpy",
"ndarray",
sizeof(PyArrayObject), __Pyx_ImportType_CheckSize_Ignore);
36205 if (!__pyx_ptype_5numpy_ndarray) __PYX_ERR(3, 239, __pyx_L1_error)
36206 __pyx_ptype_5numpy_generic = __Pyx_ImportType(__pyx_t_1,
"numpy",
"generic",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36207 if (!__pyx_ptype_5numpy_generic) __PYX_ERR(3, 771, __pyx_L1_error)
36208 __pyx_ptype_5numpy_number = __Pyx_ImportType(__pyx_t_1,
"numpy",
"number",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36209 if (!__pyx_ptype_5numpy_number) __PYX_ERR(3, 773, __pyx_L1_error)
36210 __pyx_ptype_5numpy_integer = __Pyx_ImportType(__pyx_t_1,
"numpy",
"integer",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36211 if (!__pyx_ptype_5numpy_integer) __PYX_ERR(3, 775, __pyx_L1_error)
36212 __pyx_ptype_5numpy_signedinteger = __Pyx_ImportType(__pyx_t_1,
"numpy",
"signedinteger",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36213 if (!__pyx_ptype_5numpy_signedinteger) __PYX_ERR(3, 777, __pyx_L1_error)
36214 __pyx_ptype_5numpy_unsignedinteger = __Pyx_ImportType(__pyx_t_1,
"numpy",
"unsignedinteger",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36215 if (!__pyx_ptype_5numpy_unsignedinteger) __PYX_ERR(3, 779, __pyx_L1_error)
36216 __pyx_ptype_5numpy_inexact = __Pyx_ImportType(__pyx_t_1,
"numpy",
"inexact",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36217 if (!__pyx_ptype_5numpy_inexact) __PYX_ERR(3, 781, __pyx_L1_error)
36218 __pyx_ptype_5numpy_floating = __Pyx_ImportType(__pyx_t_1,
"numpy",
"floating",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36219 if (!__pyx_ptype_5numpy_floating) __PYX_ERR(3, 783, __pyx_L1_error)
36220 __pyx_ptype_5numpy_complexfloating = __Pyx_ImportType(__pyx_t_1,
"numpy",
"complexfloating",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36221 if (!__pyx_ptype_5numpy_complexfloating) __PYX_ERR(3, 785, __pyx_L1_error)
36222 __pyx_ptype_5numpy_flexible = __Pyx_ImportType(__pyx_t_1,
"numpy",
"flexible",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36223 if (!__pyx_ptype_5numpy_flexible) __PYX_ERR(3, 787, __pyx_L1_error)
36224 __pyx_ptype_5numpy_character = __Pyx_ImportType(__pyx_t_1,
"numpy",
"character",
sizeof(PyObject), __Pyx_ImportType_CheckSize_Warn);
36225 if (!__pyx_ptype_5numpy_character) __PYX_ERR(3, 789, __pyx_L1_error)
36226 __pyx_ptype_5numpy_ufunc = __Pyx_ImportType(__pyx_t_1,
"numpy",
"ufunc",
sizeof(PyUFuncObject), __Pyx_ImportType_CheckSize_Ignore);
36227 if (!__pyx_ptype_5numpy_ufunc) __PYX_ERR(3, 827, __pyx_L1_error)
36228 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36229 __Pyx_RefNannyFinishContext();
36232 __Pyx_XDECREF(__pyx_t_1);
36233 __Pyx_RefNannyFinishContext();
36237 static int __Pyx_modinit_variable_import_code(
void) {
36238 __Pyx_RefNannyDeclarations
36239 __Pyx_RefNannySetupContext(
"__Pyx_modinit_variable_import_code", 0);
36241 __Pyx_RefNannyFinishContext();
36245 static int __Pyx_modinit_function_import_code(
void) {
36246 __Pyx_RefNannyDeclarations
36247 __Pyx_RefNannySetupContext(
"__Pyx_modinit_function_import_code", 0);
36249 __Pyx_RefNannyFinishContext();
36254 #ifndef CYTHON_NO_PYINIT_EXPORT
36255 #define __Pyx_PyMODINIT_FUNC PyMODINIT_FUNC
36256 #elif PY_MAJOR_VERSION < 3
36258 #define __Pyx_PyMODINIT_FUNC extern "C" void
36260 #define __Pyx_PyMODINIT_FUNC void
36264 #define __Pyx_PyMODINIT_FUNC extern "C" PyObject *
36266 #define __Pyx_PyMODINIT_FUNC PyObject *
36271 #if PY_MAJOR_VERSION < 3
36272 __Pyx_PyMODINIT_FUNC initcmeshTools(
void) CYTHON_SMALL_CODE;
36273 __Pyx_PyMODINIT_FUNC initcmeshTools(
void)
36275 __Pyx_PyMODINIT_FUNC PyInit_cmeshTools(
void) CYTHON_SMALL_CODE;
36276 __Pyx_PyMODINIT_FUNC PyInit_cmeshTools(
void)
36277 #if CYTHON_PEP489_MULTI_PHASE_INIT
36279 return PyModuleDef_Init(&__pyx_moduledef);
36281 static CYTHON_SMALL_CODE
int __Pyx_check_single_interpreter(
void) {
36282 #if PY_VERSION_HEX >= 0x030700A1
36283 static PY_INT64_T main_interpreter_id = -1;
36284 PY_INT64_T current_id = PyInterpreterState_GetID(PyThreadState_Get()->interp);
36285 if (main_interpreter_id == -1) {
36286 main_interpreter_id = current_id;
36287 return (unlikely(current_id == -1)) ? -1 : 0;
36288 }
else if (unlikely(main_interpreter_id != current_id))
36290 static PyInterpreterState *main_interpreter = NULL;
36291 PyInterpreterState *current_interpreter = PyThreadState_Get()->interp;
36292 if (!main_interpreter) {
36293 main_interpreter = current_interpreter;
36294 }
else if (unlikely(main_interpreter != current_interpreter))
36299 "Interpreter change detected - this module can only be loaded into one interpreter per process.");
36304 static CYTHON_SMALL_CODE
int __Pyx_copy_spec_to_module(PyObject *spec, PyObject *moddict,
const char* from_name,
const char* to_name,
int allow_none) {
36305 PyObject *value = PyObject_GetAttrString(spec, from_name);
36307 if (likely(value)) {
36308 if (allow_none || value != Py_None) {
36309 result = PyDict_SetItemString(moddict, to_name, value);
36312 }
else if (PyErr_ExceptionMatches(PyExc_AttributeError)) {
36319 static CYTHON_SMALL_CODE PyObject* __pyx_pymod_create(PyObject *spec, CYTHON_UNUSED PyModuleDef *def) {
36320 PyObject *module = NULL, *moddict, *modname;
36321 if (__Pyx_check_single_interpreter())
36324 return __Pyx_NewRef(__pyx_m);
36325 modname = PyObject_GetAttrString(spec,
"name");
36326 if (unlikely(!modname))
goto bad;
36327 module = PyModule_NewObject(modname);
36328 Py_DECREF(modname);
36329 if (unlikely(!module))
goto bad;
36330 moddict = PyModule_GetDict(module);
36331 if (unlikely(!moddict))
goto bad;
36332 if (unlikely(__Pyx_copy_spec_to_module(spec, moddict,
"loader",
"__loader__", 1) < 0))
goto bad;
36333 if (unlikely(__Pyx_copy_spec_to_module(spec, moddict,
"origin",
"__file__", 1) < 0))
goto bad;
36334 if (unlikely(__Pyx_copy_spec_to_module(spec, moddict,
"parent",
"__package__", 1) < 0))
goto bad;
36335 if (unlikely(__Pyx_copy_spec_to_module(spec, moddict,
"submodule_search_locations",
"__path__", 0) < 0))
goto bad;
36338 Py_XDECREF(module);
36343 static CYTHON_SMALL_CODE
int __pyx_pymod_exec_cmeshTools(PyObject *__pyx_pyinit_module)
36347 PyObject *__pyx_t_1 = NULL;
36348 PyObject *__pyx_t_2 = NULL;
36349 static PyThread_type_lock __pyx_t_3[8];
36350 int __pyx_lineno = 0;
36351 const char *__pyx_filename = NULL;
36352 int __pyx_clineno = 0;
36353 __Pyx_RefNannyDeclarations
36354 #if CYTHON_PEP489_MULTI_PHASE_INIT
36356 if (__pyx_m == __pyx_pyinit_module)
return 0;
36357 PyErr_SetString(PyExc_RuntimeError,
"Module 'cmeshTools' has already been imported. Re-initialisation is not supported.");
36360 #elif PY_MAJOR_VERSION >= 3
36361 if (__pyx_m)
return __Pyx_NewRef(__pyx_m);
36363 #if CYTHON_REFNANNY
36364 __Pyx_RefNanny = __Pyx_RefNannyImportAPI(
"refnanny");
36365 if (!__Pyx_RefNanny) {
36367 __Pyx_RefNanny = __Pyx_RefNannyImportAPI(
"Cython.Runtime.refnanny");
36368 if (!__Pyx_RefNanny)
36369 Py_FatalError(
"failed to import 'refnanny' module");
36372 __Pyx_RefNannySetupContext(
"__Pyx_PyMODINIT_FUNC PyInit_cmeshTools(void)", 0);
36373 if (__Pyx_check_binary_version() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36374 #ifdef __Pxy_PyFrame_Initialize_Offsets
36375 __Pxy_PyFrame_Initialize_Offsets();
36377 __pyx_empty_tuple = PyTuple_New(0);
if (unlikely(!__pyx_empty_tuple)) __PYX_ERR(1, 1, __pyx_L1_error)
36378 __pyx_empty_bytes = PyBytes_FromStringAndSize(
"", 0);
if (unlikely(!__pyx_empty_bytes)) __PYX_ERR(1, 1, __pyx_L1_error)
36379 __pyx_empty_unicode = PyUnicode_FromStringAndSize(
"", 0);
if (unlikely(!__pyx_empty_unicode)) __PYX_ERR(1, 1, __pyx_L1_error)
36380 #ifdef __Pyx_CyFunction_USED
36381 if (__pyx_CyFunction_init() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36383 #ifdef __Pyx_FusedFunction_USED
36384 if (__pyx_FusedFunction_init() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36386 #ifdef __Pyx_Coroutine_USED
36387 if (__pyx_Coroutine_init() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36389 #ifdef __Pyx_Generator_USED
36390 if (__pyx_Generator_init() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36392 #ifdef __Pyx_AsyncGen_USED
36393 if (__pyx_AsyncGen_init() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36395 #ifdef __Pyx_StopAsyncIteration_USED
36396 if (__pyx_StopAsyncIteration_init() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36400 #if defined(WITH_THREAD) && PY_VERSION_HEX < 0x030700F0 && defined(__PYX_FORCE_INIT_THREADS) && __PYX_FORCE_INIT_THREADS
36401 PyEval_InitThreads();
36404 #if CYTHON_PEP489_MULTI_PHASE_INIT
36405 __pyx_m = __pyx_pyinit_module;
36406 Py_INCREF(__pyx_m);
36408 #if PY_MAJOR_VERSION < 3
36409 __pyx_m = Py_InitModule4(
"cmeshTools", __pyx_methods, 0, 0, PYTHON_API_VERSION); Py_XINCREF(__pyx_m);
36411 __pyx_m = PyModule_Create(&__pyx_moduledef);
36413 if (unlikely(!__pyx_m)) __PYX_ERR(1, 1, __pyx_L1_error)
36415 __pyx_d = PyModule_GetDict(__pyx_m);
if (unlikely(!__pyx_d)) __PYX_ERR(1, 1, __pyx_L1_error)
36416 Py_INCREF(__pyx_d);
36417 __pyx_b = PyImport_AddModule(__Pyx_BUILTIN_MODULE_NAME);
if (unlikely(!__pyx_b)) __PYX_ERR(1, 1, __pyx_L1_error)
36418 Py_INCREF(__pyx_b);
36419 __pyx_cython_runtime = PyImport_AddModule((
char *)
"cython_runtime");
if (unlikely(!__pyx_cython_runtime)) __PYX_ERR(1, 1, __pyx_L1_error)
36420 Py_INCREF(__pyx_cython_runtime);
36421 if (PyObject_SetAttrString(__pyx_m,
"__builtins__", __pyx_b) < 0) __PYX_ERR(1, 1, __pyx_L1_error);
36423 if (__Pyx_InitGlobals() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36424 #if PY_MAJOR_VERSION < 3 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)
36425 if (__Pyx_init_sys_getdefaultencoding_params() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36427 if (__pyx_module_is_main_cmeshTools) {
36428 if (PyObject_SetAttr(__pyx_m, __pyx_n_s_name_2, __pyx_n_s_main) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36430 #if PY_MAJOR_VERSION >= 3
36432 PyObject *modules = PyImport_GetModuleDict();
if (unlikely(!modules)) __PYX_ERR(1, 1, __pyx_L1_error)
36433 if (!PyDict_GetItemString(modules,
"cmeshTools")) {
36434 if (unlikely(PyDict_SetItemString(modules,
"cmeshTools", __pyx_m) < 0)) __PYX_ERR(1, 1, __pyx_L1_error)
36439 if (__Pyx_InitCachedBuiltins() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36441 if (__Pyx_InitCachedConstants() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36443 (void)__Pyx_modinit_global_init_code();
36444 (void)__Pyx_modinit_variable_export_code();
36445 (void)__Pyx_modinit_function_export_code();
36446 if (unlikely(__Pyx_modinit_type_init_code() < 0)) __PYX_ERR(1, 1, __pyx_L1_error)
36447 if (unlikely(__Pyx_modinit_type_import_code() < 0)) __PYX_ERR(1, 1, __pyx_L1_error)
36448 (void)__Pyx_modinit_variable_import_code();
36449 (void)__Pyx_modinit_function_import_code();
36451 #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
36452 if (__Pyx_patch_abc() < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36462 __pyx_t_1 = __Pyx_Import(__pyx_n_s_numpy, 0, -1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 4, __pyx_L1_error)
36463 __Pyx_GOTREF(__pyx_t_1);
36464 if (PyDict_SetItem(__pyx_d, __pyx_n_s_np, __pyx_t_1) < 0) __PYX_ERR(1, 4, __pyx_L1_error)
36465 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36474 __pyx_t_1 = PyList_New(1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 7, __pyx_L1_error)
36475 __Pyx_GOTREF(__pyx_t_1);
36476 __Pyx_INCREF(__pyx_n_s_MPI);
36477 __Pyx_GIVEREF(__pyx_n_s_MPI);
36478 PyList_SET_ITEM(__pyx_t_1, 0, __pyx_n_s_MPI);
36479 __pyx_t_2 = __Pyx_Import(__pyx_n_s_mpi4py, __pyx_t_1, -1);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 7, __pyx_L1_error)
36480 __Pyx_GOTREF(__pyx_t_2);
36481 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36482 __pyx_t_1 = __Pyx_ImportFrom(__pyx_t_2, __pyx_n_s_MPI);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 7, __pyx_L1_error)
36483 __Pyx_GOTREF(__pyx_t_1);
36484 if (PyDict_SetItem(__pyx_d, __pyx_n_s_MPI, __pyx_t_1) < 0) __PYX_ERR(1, 7, __pyx_L1_error)
36485 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36486 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
36495 __pyx_t_2 = PyList_New(1);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 9, __pyx_L1_error)
36496 __Pyx_GOTREF(__pyx_t_2);
36497 __Pyx_INCREF(__pyx_n_s_Comm);
36498 __Pyx_GIVEREF(__pyx_n_s_Comm);
36499 PyList_SET_ITEM(__pyx_t_2, 0, __pyx_n_s_Comm);
36500 __pyx_t_1 = __Pyx_Import(__pyx_n_s_proteus, __pyx_t_2, -1);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 9, __pyx_L1_error)
36501 __Pyx_GOTREF(__pyx_t_1);
36502 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
36503 __pyx_t_2 = __Pyx_ImportFrom(__pyx_t_1, __pyx_n_s_Comm);
if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 9, __pyx_L1_error)
36504 __Pyx_GOTREF(__pyx_t_2);
36505 if (PyDict_SetItem(__pyx_d, __pyx_n_s_Comm, __pyx_t_2) < 0) __PYX_ERR(1, 9, __pyx_L1_error)
36506 __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
36507 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36516 __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_10cmeshTools_1buildPythonMeshInterface, NULL, __pyx_n_s_cmeshTools);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 120, __pyx_L1_error)
36517 __Pyx_GOTREF(__pyx_t_1);
36518 if (PyDict_SetItem(__pyx_d, __pyx_n_s_buildPythonMeshInterface, __pyx_t_1) < 0) __PYX_ERR(1, 120, __pyx_L1_error)
36519 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36528 __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_10cmeshTools_3buildPythonMeshInterfaceNoArrays, NULL, __pyx_n_s_cmeshTools);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 176, __pyx_L1_error)
36529 __Pyx_GOTREF(__pyx_t_1);
36530 if (PyDict_SetItem(__pyx_d, __pyx_n_s_buildPythonMeshInterfaceNoArrays, __pyx_t_1) < 0) __PYX_ERR(1, 176, __pyx_L1_error)
36531 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36540 __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_10cmeshTools_5buildPythonMultilevelMeshInterface, NULL, __pyx_n_s_cmeshTools);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 300, __pyx_L1_error)
36541 __Pyx_GOTREF(__pyx_t_1);
36542 if (PyDict_SetItem(__pyx_d, __pyx_n_s_buildPythonMultilevelMeshInterfa, __pyx_t_1) < 0) __PYX_ERR(1, 300, __pyx_L1_error)
36543 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36552 __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_10cmeshTools_67locallyRefineMultilevelMesh, NULL, __pyx_n_s_cmeshTools);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 495, __pyx_L1_error)
36553 __Pyx_GOTREF(__pyx_t_1);
36554 if (PyDict_SetItem(__pyx_d, __pyx_n_s_locallyRefineMultilevelMesh, __pyx_t_1) < 0) __PYX_ERR(1, 495, __pyx_L1_error)
36555 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36564 __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_10cmeshTools_69setNewestNodeBases, NULL, __pyx_n_s_cmeshTools);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 533, __pyx_L1_error)
36565 __Pyx_GOTREF(__pyx_t_1);
36566 if (PyDict_SetItem(__pyx_d, __pyx_n_s_setNewestNodeBases, __pyx_t_1) < 0) __PYX_ERR(1, 533, __pyx_L1_error)
36567 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36574 __pyx_t_1 = __Pyx_PyDict_NewPresized(0);
if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1, __pyx_L1_error)
36575 __Pyx_GOTREF(__pyx_t_1);
36576 if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_1) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
36577 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36586 __pyx_t_1 = __pyx_capsule_create(((
void *)(&__pyx_array_getbuffer)), ((
char *)
"getbuffer(obj, view, flags)"));
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 209, __pyx_L1_error)
36587 __Pyx_GOTREF(__pyx_t_1);
36588 if (PyDict_SetItem((PyObject *)__pyx_array_type->tp_dict, __pyx_n_s_pyx_getbuffer, __pyx_t_1) < 0) __PYX_ERR(0, 209, __pyx_L1_error)
36589 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36590 PyType_Modified(__pyx_array_type);
36599 __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__42, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 286, __pyx_L1_error)
36600 __Pyx_GOTREF(__pyx_t_1);
36601 __Pyx_XGOTREF(
generic);
36602 __Pyx_DECREF_SET(
generic, __pyx_t_1);
36603 __Pyx_GIVEREF(__pyx_t_1);
36613 __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__43, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 287, __pyx_L1_error)
36614 __Pyx_GOTREF(__pyx_t_1);
36615 __Pyx_XGOTREF(strided);
36616 __Pyx_DECREF_SET(strided, __pyx_t_1);
36617 __Pyx_GIVEREF(__pyx_t_1);
36627 __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__44, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 288, __pyx_L1_error)
36628 __Pyx_GOTREF(__pyx_t_1);
36629 __Pyx_XGOTREF(indirect);
36630 __Pyx_DECREF_SET(indirect, __pyx_t_1);
36631 __Pyx_GIVEREF(__pyx_t_1);
36641 __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__45, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 291, __pyx_L1_error)
36642 __Pyx_GOTREF(__pyx_t_1);
36643 __Pyx_XGOTREF(contiguous);
36644 __Pyx_DECREF_SET(contiguous, __pyx_t_1);
36645 __Pyx_GIVEREF(__pyx_t_1);
36655 __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_MemviewEnum_type), __pyx_tuple__46, NULL);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 292, __pyx_L1_error)
36656 __Pyx_GOTREF(__pyx_t_1);
36657 __Pyx_XGOTREF(indirect_contiguous);
36658 __Pyx_DECREF_SET(indirect_contiguous, __pyx_t_1);
36659 __Pyx_GIVEREF(__pyx_t_1);
36669 __pyx_memoryview_thread_locks_used = 0;
36678 __pyx_t_3[0] = PyThread_allocate_lock();
36679 __pyx_t_3[1] = PyThread_allocate_lock();
36680 __pyx_t_3[2] = PyThread_allocate_lock();
36681 __pyx_t_3[3] = PyThread_allocate_lock();
36682 __pyx_t_3[4] = PyThread_allocate_lock();
36683 __pyx_t_3[5] = PyThread_allocate_lock();
36684 __pyx_t_3[6] = PyThread_allocate_lock();
36685 __pyx_t_3[7] = PyThread_allocate_lock();
36686 memcpy(&(__pyx_memoryview_thread_locks[0]), __pyx_t_3,
sizeof(__pyx_memoryview_thread_locks[0]) * (8));
36695 __pyx_t_1 = __pyx_capsule_create(((
void *)(&__pyx_memoryview_getbuffer)), ((
char *)
"getbuffer(obj, view, flags)"));
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 549, __pyx_L1_error)
36696 __Pyx_GOTREF(__pyx_t_1);
36697 if (PyDict_SetItem((PyObject *)__pyx_memoryview_type->tp_dict, __pyx_n_s_pyx_getbuffer, __pyx_t_1) < 0) __PYX_ERR(0, 549, __pyx_L1_error)
36698 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36699 PyType_Modified(__pyx_memoryview_type);
36708 __pyx_t_1 = __pyx_capsule_create(((
void *)(&__pyx_memoryview_getbuffer)), ((
char *)
"getbuffer(obj, view, flags)"));
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 995, __pyx_L1_error)
36709 __Pyx_GOTREF(__pyx_t_1);
36710 if (PyDict_SetItem((PyObject *)__pyx_memoryviewslice_type->tp_dict, __pyx_n_s_pyx_getbuffer, __pyx_t_1) < 0) __PYX_ERR(0, 995, __pyx_L1_error)
36711 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36712 PyType_Modified(__pyx_memoryviewslice_type);
36719 __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_15View_dot_MemoryView_1__pyx_unpickle_Enum, NULL, __pyx_n_s_View_MemoryView);
if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1, __pyx_L1_error)
36720 __Pyx_GOTREF(__pyx_t_1);
36721 if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Enum, __pyx_t_1) < 0) __PYX_ERR(0, 1, __pyx_L1_error)
36722 __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
36736 __Pyx_XDECREF(__pyx_t_1);
36737 __Pyx_XDECREF(__pyx_t_2);
36740 __Pyx_AddTraceback(
"init cmeshTools", __pyx_clineno, __pyx_lineno, __pyx_filename);
36743 }
else if (!PyErr_Occurred()) {
36744 PyErr_SetString(PyExc_ImportError,
"init cmeshTools");
36747 __Pyx_RefNannyFinishContext();
36748 #if CYTHON_PEP489_MULTI_PHASE_INIT
36749 return (__pyx_m != NULL) ? 0 : -1;
36750 #elif PY_MAJOR_VERSION >= 3
36759 #if CYTHON_REFNANNY
36760 static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(
const char *modname) {
36761 PyObject *m = NULL, *p = NULL;
36763 m = PyImport_ImportModule(modname);
36765 p = PyObject_GetAttrString(m,
"RefNannyAPI");
36767 r = PyLong_AsVoidPtr(p);
36771 return (__Pyx_RefNannyAPIStruct *)
r;
36776 #if CYTHON_USE_TYPE_SLOTS
36777 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name) {
36778 PyTypeObject* tp = Py_TYPE(obj);
36779 if (likely(tp->tp_getattro))
36780 return tp->tp_getattro(obj, attr_name);
36781 #if PY_MAJOR_VERSION < 3
36782 if (likely(tp->tp_getattr))
36783 return tp->tp_getattr(obj, PyString_AS_STRING(attr_name));
36785 return PyObject_GetAttr(obj, attr_name);
36790 static PyObject *__Pyx_GetBuiltinName(PyObject *name) {
36791 PyObject* result = __Pyx_PyObject_GetAttrStr(__pyx_b, name);
36792 if (unlikely(!result)) {
36793 PyErr_Format(PyExc_NameError,
36794 #
if PY_MAJOR_VERSION >= 3
36795 "name '%U' is not defined", name);
36797 "name '%.200s' is not defined", PyString_AS_STRING(name));
36804 static void __Pyx_RaiseArgtupleInvalid(
36805 const char* func_name,
36807 Py_ssize_t num_min,
36808 Py_ssize_t num_max,
36809 Py_ssize_t num_found)
36811 Py_ssize_t num_expected;
36812 const char *more_or_less;
36813 if (num_found < num_min) {
36814 num_expected = num_min;
36815 more_or_less =
"at least";
36817 num_expected = num_max;
36818 more_or_less =
"at most";
36821 more_or_less =
"exactly";
36823 PyErr_Format(PyExc_TypeError,
36824 "%.200s() takes %.8s %" CYTHON_FORMAT_SSIZE_T
"d positional argument%.1s (%" CYTHON_FORMAT_SSIZE_T
"d given)",
36825 func_name, more_or_less, num_expected,
36826 (num_expected == 1) ?
"" :
"s", num_found);
36830 static int __Pyx_CheckKeywordStrings(
36832 const char* function_name,
36836 Py_ssize_t
pos = 0;
36837 #if CYTHON_COMPILING_IN_PYPY
36838 if (!kw_allowed && PyDict_Next(kwdict, &
pos, &key, 0))
36839 goto invalid_keyword;
36842 while (PyDict_Next(kwdict, &
pos, &key, 0)) {
36843 #if PY_MAJOR_VERSION < 3
36844 if (unlikely(!PyString_Check(key)))
36846 if (unlikely(!PyUnicode_Check(key)))
36847 goto invalid_keyword_type;
36849 if ((!kw_allowed) && unlikely(key))
36850 goto invalid_keyword;
36852 invalid_keyword_type:
36853 PyErr_Format(PyExc_TypeError,
36854 "%.200s() keywords must be strings", function_name);
36858 PyErr_Format(PyExc_TypeError,
36859 #
if PY_MAJOR_VERSION < 3
36860 "%.200s() got an unexpected keyword argument '%.200s'",
36861 function_name, PyString_AsString(key));
36863 "%s() got an unexpected keyword argument '%U'",
36864 function_name, key);
36870 #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
36871 static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj) {
36872 PyObject *dict = Py_TYPE(obj)->tp_dict;
36873 return likely(dict) ? __PYX_GET_DICT_VERSION(dict) : 0;
36875 static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj) {
36876 PyObject **dictptr = NULL;
36877 Py_ssize_t offset = Py_TYPE(obj)->tp_dictoffset;
36879 #if CYTHON_COMPILING_IN_CPYTHON
36880 dictptr = (likely(offset > 0)) ? (PyObject **) ((
char *)obj + offset) : _PyObject_GetDictPtr(obj);
36882 dictptr = _PyObject_GetDictPtr(obj);
36885 return (dictptr && *dictptr) ? __PYX_GET_DICT_VERSION(*dictptr) : 0;
36887 static CYTHON_INLINE
int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version) {
36888 PyObject *dict = Py_TYPE(obj)->tp_dict;
36889 if (unlikely(!dict) || unlikely(tp_dict_version != __PYX_GET_DICT_VERSION(dict)))
36891 return obj_dict_version == __Pyx_get_object_dict_version(obj);
36896 #if CYTHON_USE_DICT_VERSIONS
36897 static PyObject *__Pyx__GetModuleGlobalName(PyObject *name, PY_UINT64_T *dict_version, PyObject **dict_cached_value)
36899 static CYTHON_INLINE PyObject *__Pyx__GetModuleGlobalName(PyObject *name)
36903 #if !CYTHON_AVOID_BORROWED_REFS
36904 #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030500A1
36905 result = _PyDict_GetItem_KnownHash(__pyx_d, name, ((PyASCIIObject *) name)->hash);
36906 __PYX_UPDATE_DICT_CACHE(__pyx_d, result, *dict_cached_value, *dict_version)
36907 if (likely(result)) {
36908 return __Pyx_NewRef(result);
36909 }
else if (unlikely(PyErr_Occurred())) {
36913 result = PyDict_GetItem(__pyx_d, name);
36914 __PYX_UPDATE_DICT_CACHE(__pyx_d, result, *dict_cached_value, *dict_version)
36915 if (likely(result)) {
36916 return __Pyx_NewRef(result);
36920 result = PyObject_GetItem(__pyx_d, name);
36921 __PYX_UPDATE_DICT_CACHE(__pyx_d, result, *dict_cached_value, *dict_version)
36922 if (likely(result)) {
36923 return __Pyx_NewRef(result);
36927 return __Pyx_GetBuiltinName(name);
36931 #if CYTHON_FAST_PYCCALL
36932 static CYTHON_INLINE PyObject * __Pyx_PyCFunction_FastCall(PyObject *func_obj, PyObject **args, Py_ssize_t nargs) {
36933 PyCFunctionObject *func = (PyCFunctionObject*)func_obj;
36934 PyCFunction meth = PyCFunction_GET_FUNCTION(func);
36935 PyObject *
self = PyCFunction_GET_SELF(func);
36936 int flags = PyCFunction_GET_FLAGS(func);
36937 assert(PyCFunction_Check(func));
36938 assert(METH_FASTCALL == (flags & ~(METH_CLASS | METH_STATIC | METH_COEXIST | METH_KEYWORDS | METH_STACKLESS)));
36939 assert(nargs >= 0);
36940 assert(nargs == 0 || args != NULL);
36944 assert(!PyErr_Occurred());
36945 if ((PY_VERSION_HEX < 0x030700A0) || unlikely(flags & METH_KEYWORDS)) {
36946 return (*((__Pyx_PyCFunctionFastWithKeywords)(
void*)meth)) (
self, args, nargs, NULL);
36948 return (*((__Pyx_PyCFunctionFast)(
void*)meth)) (
self, args, nargs);
36954 #if CYTHON_FAST_PYCALL
36955 static PyObject* __Pyx_PyFunction_FastCallNoKw(PyCodeObject *co, PyObject **args, Py_ssize_t na,
36956 PyObject *globals) {
36958 PyThreadState *tstate = __Pyx_PyThreadState_Current;
36959 PyObject **fastlocals;
36962 assert(globals != NULL);
36967 assert(tstate != NULL);
36968 f = PyFrame_New(tstate, co, globals, NULL);
36972 fastlocals = __Pyx_PyFrame_GetLocalsplus(
f);
36973 for (i = 0; i < na; i++) {
36975 fastlocals[i] = *args++;
36977 result = PyEval_EvalFrameEx(
f,0);
36978 ++tstate->recursion_depth;
36980 --tstate->recursion_depth;
36983 #if 1 || PY_VERSION_HEX < 0x030600B1
36984 static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, Py_ssize_t nargs, PyObject *kwargs) {
36985 PyCodeObject *co = (PyCodeObject *)PyFunction_GET_CODE(func);
36986 PyObject *globals = PyFunction_GET_GLOBALS(func);
36987 PyObject *argdefs = PyFunction_GET_DEFAULTS(func);
36989 #if PY_MAJOR_VERSION >= 3
36992 PyObject *kwtuple, **k;
36997 assert(kwargs == NULL || PyDict_Check(kwargs));
36998 nk = kwargs ? PyDict_Size(kwargs) : 0;
36999 if (Py_EnterRecursiveCall((
char*)
" while calling a Python object")) {
37003 #
if PY_MAJOR_VERSION >= 3
37004 co->co_kwonlyargcount == 0 &&
37006 likely(kwargs == NULL || nk == 0) &&
37007 co->co_flags == (CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE)) {
37008 if (argdefs == NULL && co->co_argcount == nargs) {
37009 result = __Pyx_PyFunction_FastCallNoKw(co, args, nargs, globals);
37012 else if (nargs == 0 && argdefs != NULL
37013 && co->co_argcount == Py_SIZE(argdefs)) {
37016 args = &PyTuple_GET_ITEM(argdefs, 0);
37017 result =__Pyx_PyFunction_FastCallNoKw(co, args, Py_SIZE(argdefs), globals);
37021 if (kwargs != NULL) {
37023 kwtuple = PyTuple_New(2 * nk);
37024 if (kwtuple == NULL) {
37028 k = &PyTuple_GET_ITEM(kwtuple, 0);
37030 while (PyDict_Next(kwargs, &
pos, &k[i], &k[i+1])) {
37041 closure = PyFunction_GET_CLOSURE(func);
37042 #if PY_MAJOR_VERSION >= 3
37043 kwdefs = PyFunction_GET_KW_DEFAULTS(func);
37045 if (argdefs != NULL) {
37046 d = &PyTuple_GET_ITEM(argdefs, 0);
37047 nd = Py_SIZE(argdefs);
37053 #if PY_MAJOR_VERSION >= 3
37054 result = PyEval_EvalCodeEx((PyObject*)co, globals, (PyObject *)NULL,
37057 d, (
int)nd, kwdefs, closure);
37059 result = PyEval_EvalCodeEx(co, globals, (PyObject *)NULL,
37062 d, (
int)nd, closure);
37064 Py_XDECREF(kwtuple);
37066 Py_LeaveRecursiveCall();
37073 #if CYTHON_COMPILING_IN_CPYTHON
37074 static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw) {
37076 ternaryfunc call = Py_TYPE(func)->tp_call;
37077 if (unlikely(!call))
37078 return PyObject_Call(func, arg, kw);
37079 if (unlikely(Py_EnterRecursiveCall((
char*)
" while calling a Python object")))
37081 result = (*call)(func, arg, kw);
37082 Py_LeaveRecursiveCall();
37083 if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
37086 "NULL result without error in PyObject_Call");
37093 static CYTHON_UNUSED PyObject* __Pyx_PyObject_Call2Args(PyObject*
function, PyObject* arg1, PyObject* arg2) {
37094 PyObject *args, *result = NULL;
37095 #if CYTHON_FAST_PYCALL
37096 if (PyFunction_Check(
function)) {
37097 PyObject *args[2] = {arg1, arg2};
37098 return __Pyx_PyFunction_FastCall(
function, args, 2);
37101 #if CYTHON_FAST_PYCCALL
37102 if (__Pyx_PyFastCFunction_Check(
function)) {
37103 PyObject *args[2] = {arg1, arg2};
37104 return __Pyx_PyCFunction_FastCall(
function, args, 2);
37107 args = PyTuple_New(2);
37108 if (unlikely(!args))
goto done;
37110 PyTuple_SET_ITEM(args, 0, arg1);
37112 PyTuple_SET_ITEM(args, 1, arg2);
37113 Py_INCREF(
function);
37114 result = __Pyx_PyObject_Call(
function, args, NULL);
37116 Py_DECREF(
function);
37122 #if CYTHON_COMPILING_IN_CPYTHON
37123 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg) {
37124 PyObject *
self, *result;
37126 cfunc = PyCFunction_GET_FUNCTION(func);
37127 self = PyCFunction_GET_SELF(func);
37128 if (unlikely(Py_EnterRecursiveCall((
char*)
" while calling a Python object")))
37130 result = cfunc(
self, arg);
37131 Py_LeaveRecursiveCall();
37132 if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
37135 "NULL result without error in PyObject_Call");
37142 #if CYTHON_COMPILING_IN_CPYTHON
37143 static PyObject* __Pyx__PyObject_CallOneArg(PyObject *func, PyObject *arg) {
37145 PyObject *args = PyTuple_New(1);
37146 if (unlikely(!args))
return NULL;
37148 PyTuple_SET_ITEM(args, 0, arg);
37149 result = __Pyx_PyObject_Call(func, args, NULL);
37153 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) {
37154 #if CYTHON_FAST_PYCALL
37155 if (PyFunction_Check(func)) {
37156 return __Pyx_PyFunction_FastCall(func, &arg, 1);
37159 if (likely(PyCFunction_Check(func))) {
37160 if (likely(PyCFunction_GET_FLAGS(func) & METH_O)) {
37161 return __Pyx_PyObject_CallMethO(func, arg);
37162 #if CYTHON_FAST_PYCCALL
37163 }
else if (__Pyx_PyFastCFunction_Check(func)) {
37164 return __Pyx_PyCFunction_FastCall(func, &arg, 1);
37168 return __Pyx__PyObject_CallOneArg(func, arg);
37171 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) {
37173 PyObject *args = PyTuple_Pack(1, arg);
37174 if (unlikely(!args))
return NULL;
37175 result = __Pyx_PyObject_Call(func, args, NULL);
37182 static CYTHON_INLINE
int __Pyx_TypeTest(PyObject *obj, PyTypeObject *type) {
37183 if (unlikely(!type)) {
37184 PyErr_SetString(PyExc_SystemError,
"Missing type object");
37187 if (likely(__Pyx_TypeCheck(obj, type)))
37189 PyErr_Format(PyExc_TypeError,
"Cannot convert %.200s to %.200s",
37190 Py_TYPE(obj)->tp_name, type->tp_name);
37195 #if CYTHON_FAST_THREAD_STATE
37196 static CYTHON_INLINE
void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
37197 PyObject *tmp_type, *tmp_value, *tmp_tb;
37198 tmp_type = tstate->curexc_type;
37199 tmp_value = tstate->curexc_value;
37200 tmp_tb = tstate->curexc_traceback;
37201 tstate->curexc_type = type;
37202 tstate->curexc_value = value;
37203 tstate->curexc_traceback = tb;
37204 Py_XDECREF(tmp_type);
37205 Py_XDECREF(tmp_value);
37206 Py_XDECREF(tmp_tb);
37208 static CYTHON_INLINE
void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
37209 *type = tstate->curexc_type;
37210 *value = tstate->curexc_value;
37211 *tb = tstate->curexc_traceback;
37212 tstate->curexc_type = 0;
37213 tstate->curexc_value = 0;
37214 tstate->curexc_traceback = 0;
37219 #if PY_MAJOR_VERSION < 3
37220 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb,
37221 CYTHON_UNUSED PyObject *cause) {
37222 __Pyx_PyThreadState_declare
37224 if (!value || value == Py_None)
37228 if (!tb || tb == Py_None)
37232 if (!PyTraceBack_Check(tb)) {
37233 PyErr_SetString(PyExc_TypeError,
37234 "raise: arg 3 must be a traceback or None");
37238 if (PyType_Check(type)) {
37239 #if CYTHON_COMPILING_IN_PYPY
37241 Py_INCREF(Py_None);
37245 PyErr_NormalizeException(&type, &value, &tb);
37248 PyErr_SetString(PyExc_TypeError,
37249 "instance exception may not have a separate value");
37253 type = (PyObject*) Py_TYPE(type);
37255 if (!PyType_IsSubtype((PyTypeObject *)type, (PyTypeObject *)PyExc_BaseException)) {
37256 PyErr_SetString(PyExc_TypeError,
37257 "raise: exception class must be a subclass of BaseException");
37261 __Pyx_PyThreadState_assign
37262 __Pyx_ErrRestore(type, value, tb);
37271 static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause) {
37272 PyObject* owned_instance = NULL;
37273 if (tb == Py_None) {
37275 }
else if (tb && !PyTraceBack_Check(tb)) {
37276 PyErr_SetString(PyExc_TypeError,
37277 "raise: arg 3 must be a traceback or None");
37280 if (value == Py_None)
37282 if (PyExceptionInstance_Check(type)) {
37284 PyErr_SetString(PyExc_TypeError,
37285 "instance exception may not have a separate value");
37289 type = (PyObject*) Py_TYPE(value);
37290 }
else if (PyExceptionClass_Check(type)) {
37291 PyObject *instance_class = NULL;
37292 if (value && PyExceptionInstance_Check(value)) {
37293 instance_class = (PyObject*) Py_TYPE(value);
37294 if (instance_class != type) {
37295 int is_subclass = PyObject_IsSubclass(instance_class, type);
37296 if (!is_subclass) {
37297 instance_class = NULL;
37298 }
else if (unlikely(is_subclass == -1)) {
37301 type = instance_class;
37305 if (!instance_class) {
37308 args = PyTuple_New(0);
37309 else if (PyTuple_Check(value)) {
37313 args = PyTuple_Pack(1, value);
37316 owned_instance = PyObject_Call(type, args, NULL);
37318 if (!owned_instance)
37320 value = owned_instance;
37321 if (!PyExceptionInstance_Check(value)) {
37322 PyErr_Format(PyExc_TypeError,
37323 "calling %R should have returned an instance of "
37324 "BaseException, not %R",
37325 type, Py_TYPE(value));
37330 PyErr_SetString(PyExc_TypeError,
37331 "raise: exception class must be a subclass of BaseException");
37335 PyObject *fixed_cause;
37336 if (cause == Py_None) {
37337 fixed_cause = NULL;
37338 }
else if (PyExceptionClass_Check(cause)) {
37339 fixed_cause = PyObject_CallObject(cause, NULL);
37340 if (fixed_cause == NULL)
37342 }
else if (PyExceptionInstance_Check(cause)) {
37343 fixed_cause = cause;
37344 Py_INCREF(fixed_cause);
37346 PyErr_SetString(PyExc_TypeError,
37347 "exception causes must derive from "
37351 PyException_SetCause(value, fixed_cause);
37353 PyErr_SetObject(type, value);
37355 #if CYTHON_COMPILING_IN_PYPY
37356 PyObject *tmp_type, *tmp_value, *tmp_tb;
37357 PyErr_Fetch(&tmp_type, &tmp_value, &tmp_tb);
37359 PyErr_Restore(tmp_type, tmp_value, tb);
37360 Py_XDECREF(tmp_tb);
37362 PyThreadState *tstate = __Pyx_PyThreadState_Current;
37363 PyObject* tmp_tb = tstate->curexc_traceback;
37364 if (tb != tmp_tb) {
37366 tstate->curexc_traceback = tb;
37367 Py_XDECREF(tmp_tb);
37372 Py_XDECREF(owned_instance);
37378 #if CYTHON_COMPILING_IN_CPYTHON
37379 static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func) {
37380 #if CYTHON_FAST_PYCALL
37381 if (PyFunction_Check(func)) {
37382 return __Pyx_PyFunction_FastCall(func, NULL, 0);
37385 #ifdef __Pyx_CyFunction_USED
37386 if (likely(PyCFunction_Check(func) || __Pyx_CyFunction_Check(func)))
37388 if (likely(PyCFunction_Check(func)))
37391 if (likely(PyCFunction_GET_FLAGS(func) & METH_NOARGS)) {
37392 return __Pyx_PyObject_CallMethO(func, NULL);
37395 return __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL);
37400 static void __Pyx_RaiseDoubleKeywordsError(
37401 const char* func_name,
37404 PyErr_Format(PyExc_TypeError,
37405 #
if PY_MAJOR_VERSION >= 3
37406 "%s() got multiple values for keyword argument '%U'", func_name, kw_name);
37408 "%s() got multiple values for keyword argument '%s'", func_name,
37409 PyString_AsString(kw_name));
37414 static int __Pyx_ParseOptionalKeywords(
37416 PyObject **argnames[],
37418 PyObject *values[],
37419 Py_ssize_t num_pos_args,
37420 const char* function_name)
37422 PyObject *key = 0, *value = 0;
37423 Py_ssize_t
pos = 0;
37425 PyObject*** first_kw_arg = argnames + num_pos_args;
37426 while (PyDict_Next(kwds, &
pos, &key, &value)) {
37427 name = first_kw_arg;
37428 while (*name && (**name != key)) name++;
37430 values[name-argnames] = value;
37433 name = first_kw_arg;
37434 #if PY_MAJOR_VERSION < 3
37435 if (likely(PyString_Check(key))) {
37437 if ((CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**name) == PyString_GET_SIZE(key))
37438 && _PyString_Eq(**name, key)) {
37439 values[name-argnames] = value;
37444 if (*name)
continue;
37446 PyObject*** argname = argnames;
37447 while (argname != first_kw_arg) {
37448 if ((**argname == key) || (
37449 (CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**argname) == PyString_GET_SIZE(key))
37450 && _PyString_Eq(**argname, key))) {
37451 goto arg_passed_twice;
37458 if (likely(PyUnicode_Check(key))) {
37460 int cmp = (**name == key) ? 0 :
37461 #
if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
37462 (__Pyx_PyUnicode_GET_LENGTH(**name) != __Pyx_PyUnicode_GET_LENGTH(key)) ? 1 :
37464 PyUnicode_Compare(**name, key);
37465 if (cmp < 0 && unlikely(PyErr_Occurred()))
goto bad;
37467 values[name-argnames] = value;
37472 if (*name)
continue;
37474 PyObject*** argname = argnames;
37475 while (argname != first_kw_arg) {
37476 int cmp = (**argname == key) ? 0 :
37477 #
if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
37478 (__Pyx_PyUnicode_GET_LENGTH(**argname) != __Pyx_PyUnicode_GET_LENGTH(key)) ? 1 :
37480 PyUnicode_Compare(**argname, key);
37481 if (cmp < 0 && unlikely(PyErr_Occurred()))
goto bad;
37482 if (cmp == 0)
goto arg_passed_twice;
37487 goto invalid_keyword_type;
37489 if (unlikely(PyDict_SetItem(kwds2, key, value)))
goto bad;
37491 goto invalid_keyword;
37496 __Pyx_RaiseDoubleKeywordsError(function_name, key);
37498 invalid_keyword_type:
37499 PyErr_Format(PyExc_TypeError,
37500 "%.200s() keywords must be strings", function_name);
37503 PyErr_Format(PyExc_TypeError,
37504 #
if PY_MAJOR_VERSION < 3
37505 "%.200s() got an unexpected keyword argument '%.200s'",
37506 function_name, PyString_AsString(key));
37508 "%s() got an unexpected keyword argument '%U'",
37509 function_name, key);
37516 static int __Pyx__ArgTypeTest(PyObject *obj, PyTypeObject *type,
const char *name,
int exact)
37518 if (unlikely(!type)) {
37519 PyErr_SetString(PyExc_SystemError,
"Missing type object");
37523 #if PY_MAJOR_VERSION == 2
37524 if ((type == &PyBaseString_Type) && likely(__Pyx_PyBaseString_CheckExact(obj)))
return 1;
37528 if (likely(__Pyx_TypeCheck(obj, type)))
return 1;
37530 PyErr_Format(PyExc_TypeError,
37531 "Argument '%.200s' has incorrect type (expected %.200s, got %.200s)",
37532 name, type->tp_name, Py_TYPE(obj)->tp_name);
37537 #if !CYTHON_COMPILING_IN_PYPY
37538 static PyObject* __Pyx_PyInt_SubtractObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED
long intval,
int inplace,
int zerodivision_check) {
37540 (void)zerodivision_check;
37541 #if PY_MAJOR_VERSION < 3
37542 if (likely(PyInt_CheckExact(op1))) {
37543 const long b = intval;
37545 long a = PyInt_AS_LONG(op1);
37546 x = (long)((
unsigned long)a - b);
37547 if (likely((x^a) >= 0 || (x^~b) >= 0))
37548 return PyInt_FromLong(x);
37549 return PyLong_Type.tp_as_number->nb_subtract(op1, op2);
37552 #if CYTHON_USE_PYLONG_INTERNALS
37553 if (likely(PyLong_CheckExact(op1))) {
37554 const long b = intval;
37556 #ifdef HAVE_LONG_LONG
37557 const PY_LONG_LONG llb = intval;
37558 PY_LONG_LONG lla, llx;
37560 const digit* digits = ((PyLongObject*)op1)->ob_digit;
37561 const Py_ssize_t size = Py_SIZE(op1);
37562 if (likely(__Pyx_sst_abs(size) <= 1)) {
37563 a = likely(size) ? digits[0] : 0;
37564 if (size == -1) a = -a;
37568 if (8 *
sizeof(
long) - 1 > 2 * PyLong_SHIFT) {
37569 a = -(long) (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
37571 #ifdef HAVE_LONG_LONG
37572 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) {
37573 lla = -(PY_LONG_LONG) (((((
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
37577 CYTHON_FALLTHROUGH;
37579 if (8 *
sizeof(
long) - 1 > 2 * PyLong_SHIFT) {
37580 a = (long) (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
37582 #ifdef HAVE_LONG_LONG
37583 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) {
37584 lla = (PY_LONG_LONG) (((((
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
37588 CYTHON_FALLTHROUGH;
37590 if (8 *
sizeof(
long) - 1 > 3 * PyLong_SHIFT) {
37591 a = -(long) (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
37593 #ifdef HAVE_LONG_LONG
37594 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) {
37595 lla = -(PY_LONG_LONG) (((((((
unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
37599 CYTHON_FALLTHROUGH;
37601 if (8 *
sizeof(
long) - 1 > 3 * PyLong_SHIFT) {
37602 a = (long) (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
37604 #ifdef HAVE_LONG_LONG
37605 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) {
37606 lla = (PY_LONG_LONG) (((((((
unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
37610 CYTHON_FALLTHROUGH;
37612 if (8 *
sizeof(
long) - 1 > 4 * PyLong_SHIFT) {
37613 a = -(long) (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
37615 #ifdef HAVE_LONG_LONG
37616 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) {
37617 lla = -(PY_LONG_LONG) (((((((((
unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
37621 CYTHON_FALLTHROUGH;
37623 if (8 *
sizeof(
long) - 1 > 4 * PyLong_SHIFT) {
37624 a = (long) (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
37626 #ifdef HAVE_LONG_LONG
37627 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) {
37628 lla = (PY_LONG_LONG) (((((((((
unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
37632 CYTHON_FALLTHROUGH;
37633 default:
return PyLong_Type.tp_as_number->nb_subtract(op1, op2);
37637 return PyLong_FromLong(x);
37638 #ifdef HAVE_LONG_LONG
37641 return PyLong_FromLongLong(llx);
37647 if (PyFloat_CheckExact(op1)) {
37648 const long b = intval;
37649 double a = PyFloat_AS_DOUBLE(op1);
37651 PyFPE_START_PROTECT(
"subtract",
return NULL)
37652 result = ((double)a) - (double)b;
37653 PyFPE_END_PROTECT(result)
37654 return PyFloat_FromDouble(result);
37656 return (inplace ? PyNumber_InPlaceSubtract : PyNumber_Subtract)(op1, op2);
37661 static CYTHON_INLINE PyObject* __Pyx_PyInt_EqObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED
long intval, CYTHON_UNUSED
long inplace) {
37665 #if PY_MAJOR_VERSION < 3
37666 if (likely(PyInt_CheckExact(op1))) {
37667 const long b = intval;
37668 long a = PyInt_AS_LONG(op1);
37669 if (a == b) Py_RETURN_TRUE;
else Py_RETURN_FALSE;
37672 #if CYTHON_USE_PYLONG_INTERNALS
37673 if (likely(PyLong_CheckExact(op1))) {
37675 unsigned long uintval;
37676 Py_ssize_t size = Py_SIZE(op1);
37677 const digit* digits = ((PyLongObject*)op1)->ob_digit;
37679 if (size == 0) Py_RETURN_TRUE;
else Py_RETURN_FALSE;
37680 }
else if (intval < 0) {
37689 uintval = (
unsigned long) intval;
37690 #if PyLong_SHIFT * 4 < SIZEOF_LONG*8
37691 if (uintval >> (PyLong_SHIFT * 4)) {
37692 unequal = (size != 5) || (digits[0] != (uintval & (
unsigned long) PyLong_MASK))
37693 | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK)) | (digits[3] != ((uintval >> (3 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK)) | (digits[4] != ((uintval >> (4 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK));
37696 #if PyLong_SHIFT * 3 < SIZEOF_LONG*8
37697 if (uintval >> (PyLong_SHIFT * 3)) {
37698 unequal = (size != 4) || (digits[0] != (uintval & (
unsigned long) PyLong_MASK))
37699 | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK)) | (digits[3] != ((uintval >> (3 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK));
37702 #if PyLong_SHIFT * 2 < SIZEOF_LONG*8
37703 if (uintval >> (PyLong_SHIFT * 2)) {
37704 unequal = (size != 3) || (digits[0] != (uintval & (
unsigned long) PyLong_MASK))
37705 | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK)) | (digits[2] != ((uintval >> (2 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK));
37708 #if PyLong_SHIFT * 1 < SIZEOF_LONG*8
37709 if (uintval >> (PyLong_SHIFT * 1)) {
37710 unequal = (size != 2) || (digits[0] != (uintval & (
unsigned long) PyLong_MASK))
37711 | (digits[1] != ((uintval >> (1 * PyLong_SHIFT)) & (
unsigned long) PyLong_MASK));
37714 unequal = (size != 1) || (((
unsigned long) digits[0]) != (uintval & (
unsigned long) PyLong_MASK));
37715 if (unequal == 0) Py_RETURN_TRUE;
else Py_RETURN_FALSE;
37718 if (PyFloat_CheckExact(op1)) {
37719 const long b = intval;
37720 double a = PyFloat_AS_DOUBLE(op1);
37721 if ((
double)a == (
double)b) Py_RETURN_TRUE;
else Py_RETURN_FALSE;
37724 PyObject_RichCompare(op1, op2, Py_EQ));
37728 static void __Pyx_WriteUnraisable(
const char *name, CYTHON_UNUSED
int clineno,
37729 CYTHON_UNUSED
int lineno, CYTHON_UNUSED
const char *filename,
37730 int full_traceback, CYTHON_UNUSED
int nogil) {
37731 PyObject *old_exc, *old_val, *old_tb;
37733 __Pyx_PyThreadState_declare
37735 PyGILState_STATE state;
37737 state = PyGILState_Ensure();
37739 else state = (PyGILState_STATE)-1;
37742 __Pyx_PyThreadState_assign
37743 __Pyx_ErrFetch(&old_exc, &old_val, &old_tb);
37744 if (full_traceback) {
37745 Py_XINCREF(old_exc);
37746 Py_XINCREF(old_val);
37747 Py_XINCREF(old_tb);
37748 __Pyx_ErrRestore(old_exc, old_val, old_tb);
37751 #if PY_MAJOR_VERSION < 3
37752 ctx = PyString_FromString(name);
37754 ctx = PyUnicode_FromString(name);
37756 __Pyx_ErrRestore(old_exc, old_val, old_tb);
37758 PyErr_WriteUnraisable(Py_None);
37760 PyErr_WriteUnraisable(ctx);
37765 PyGILState_Release(state);
37770 #if CYTHON_USE_EXC_INFO_STACK
37771 static _PyErr_StackItem *
37772 __Pyx_PyErr_GetTopmostException(PyThreadState *tstate)
37774 _PyErr_StackItem *exc_info = tstate->exc_info;
37775 while ((exc_info->exc_type == NULL || exc_info->exc_type == Py_None) &&
37776 exc_info->previous_item != NULL)
37778 exc_info = exc_info->previous_item;
37785 #if CYTHON_FAST_THREAD_STATE
37786 static CYTHON_INLINE
void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
37787 #if CYTHON_USE_EXC_INFO_STACK
37788 _PyErr_StackItem *exc_info = __Pyx_PyErr_GetTopmostException(tstate);
37789 *type = exc_info->exc_type;
37790 *value = exc_info->exc_value;
37791 *tb = exc_info->exc_traceback;
37793 *type = tstate->exc_type;
37794 *value = tstate->exc_value;
37795 *tb = tstate->exc_traceback;
37798 Py_XINCREF(*value);
37801 static CYTHON_INLINE
void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
37802 PyObject *tmp_type, *tmp_value, *tmp_tb;
37803 #if CYTHON_USE_EXC_INFO_STACK
37804 _PyErr_StackItem *exc_info = tstate->exc_info;
37805 tmp_type = exc_info->exc_type;
37806 tmp_value = exc_info->exc_value;
37807 tmp_tb = exc_info->exc_traceback;
37808 exc_info->exc_type = type;
37809 exc_info->exc_value = value;
37810 exc_info->exc_traceback = tb;
37812 tmp_type = tstate->exc_type;
37813 tmp_value = tstate->exc_value;
37814 tmp_tb = tstate->exc_traceback;
37815 tstate->exc_type = type;
37816 tstate->exc_value = value;
37817 tstate->exc_traceback = tb;
37819 Py_XDECREF(tmp_type);
37820 Py_XDECREF(tmp_value);
37821 Py_XDECREF(tmp_tb);
37826 #if CYTHON_FAST_THREAD_STATE
37827 static int __Pyx_PyErr_ExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
37829 n = PyTuple_GET_SIZE(tuple);
37830 #if PY_MAJOR_VERSION >= 3
37831 for (i=0; i<
n; i++) {
37832 if (exc_type == PyTuple_GET_ITEM(tuple, i))
return 1;
37835 for (i=0; i<
n; i++) {
37836 if (__Pyx_PyErr_GivenExceptionMatches(exc_type, PyTuple_GET_ITEM(tuple, i)))
return 1;
37840 static CYTHON_INLINE
int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err) {
37841 PyObject *exc_type = tstate->curexc_type;
37842 if (exc_type == err)
return 1;
37843 if (unlikely(!exc_type))
return 0;
37844 if (unlikely(PyTuple_Check(err)))
37845 return __Pyx_PyErr_ExceptionMatchesTuple(exc_type, err);
37846 return __Pyx_PyErr_GivenExceptionMatches(exc_type, err);
37851 #if CYTHON_FAST_THREAD_STATE
37852 static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb)
37854 static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb)
37857 PyObject *local_type, *local_value, *local_tb;
37858 #if CYTHON_FAST_THREAD_STATE
37859 PyObject *tmp_type, *tmp_value, *tmp_tb;
37860 local_type = tstate->curexc_type;
37861 local_value = tstate->curexc_value;
37862 local_tb = tstate->curexc_traceback;
37863 tstate->curexc_type = 0;
37864 tstate->curexc_value = 0;
37865 tstate->curexc_traceback = 0;
37867 PyErr_Fetch(&local_type, &local_value, &local_tb);
37869 PyErr_NormalizeException(&local_type, &local_value, &local_tb);
37870 #if CYTHON_FAST_THREAD_STATE
37871 if (unlikely(tstate->curexc_type))
37873 if (unlikely(PyErr_Occurred()))
37876 #if PY_MAJOR_VERSION >= 3
37878 if (unlikely(PyException_SetTraceback(local_value, local_tb) < 0))
37882 Py_XINCREF(local_tb);
37883 Py_XINCREF(local_type);
37884 Py_XINCREF(local_value);
37885 *type = local_type;
37886 *value = local_value;
37888 #if CYTHON_FAST_THREAD_STATE
37889 #if CYTHON_USE_EXC_INFO_STACK
37891 _PyErr_StackItem *exc_info = tstate->exc_info;
37892 tmp_type = exc_info->exc_type;
37893 tmp_value = exc_info->exc_value;
37894 tmp_tb = exc_info->exc_traceback;
37895 exc_info->exc_type = local_type;
37896 exc_info->exc_value = local_value;
37897 exc_info->exc_traceback = local_tb;
37900 tmp_type = tstate->exc_type;
37901 tmp_value = tstate->exc_value;
37902 tmp_tb = tstate->exc_traceback;
37903 tstate->exc_type = local_type;
37904 tstate->exc_value = local_value;
37905 tstate->exc_traceback = local_tb;
37907 Py_XDECREF(tmp_type);
37908 Py_XDECREF(tmp_value);
37909 Py_XDECREF(tmp_tb);
37911 PyErr_SetExcInfo(local_type, local_value, local_tb);
37918 Py_XDECREF(local_type);
37919 Py_XDECREF(local_value);
37920 Py_XDECREF(local_tb);
37925 static CYTHON_INLINE
int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2,
int equals) {
37926 #if CYTHON_COMPILING_IN_PYPY
37927 return PyObject_RichCompareBool(s1, s2, equals);
37930 return (equals == Py_EQ);
37931 }
else if (PyBytes_CheckExact(s1) & PyBytes_CheckExact(s2)) {
37932 const char *ps1, *ps2;
37933 Py_ssize_t length = PyBytes_GET_SIZE(s1);
37934 if (length != PyBytes_GET_SIZE(s2))
37935 return (equals == Py_NE);
37936 ps1 = PyBytes_AS_STRING(s1);
37937 ps2 = PyBytes_AS_STRING(s2);
37938 if (ps1[0] != ps2[0]) {
37939 return (equals == Py_NE);
37940 }
else if (length == 1) {
37941 return (equals == Py_EQ);
37944 #if CYTHON_USE_UNICODE_INTERNALS && (PY_VERSION_HEX < 0x030B0000)
37945 Py_hash_t hash1, hash2;
37946 hash1 = ((PyBytesObject*)s1)->ob_shash;
37947 hash2 = ((PyBytesObject*)s2)->ob_shash;
37948 if (hash1 != hash2 && hash1 != -1 && hash2 != -1) {
37949 return (equals == Py_NE);
37952 result = memcmp(ps1, ps2, (
size_t)length);
37953 return (equals == Py_EQ) ? (result == 0) : (result != 0);
37955 }
else if ((s1 == Py_None) & PyBytes_CheckExact(s2)) {
37956 return (equals == Py_NE);
37957 }
else if ((s2 == Py_None) & PyBytes_CheckExact(s1)) {
37958 return (equals == Py_NE);
37961 PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
37964 result = __Pyx_PyObject_IsTrue(py_result);
37965 Py_DECREF(py_result);
37972 static CYTHON_INLINE
int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2,
int equals) {
37973 #if CYTHON_COMPILING_IN_PYPY
37974 return PyObject_RichCompareBool(s1, s2, equals);
37976 #if PY_MAJOR_VERSION < 3
37977 PyObject* owned_ref = NULL;
37979 int s1_is_unicode, s2_is_unicode;
37983 s1_is_unicode = PyUnicode_CheckExact(s1);
37984 s2_is_unicode = PyUnicode_CheckExact(s2);
37985 #if PY_MAJOR_VERSION < 3
37986 if ((s1_is_unicode & (!s2_is_unicode)) && PyString_CheckExact(s2)) {
37987 owned_ref = PyUnicode_FromObject(s2);
37988 if (unlikely(!owned_ref))
37992 }
else if ((s2_is_unicode & (!s1_is_unicode)) && PyString_CheckExact(s1)) {
37993 owned_ref = PyUnicode_FromObject(s1);
37994 if (unlikely(!owned_ref))
37998 }
else if (((!s2_is_unicode) & (!s1_is_unicode))) {
37999 return __Pyx_PyBytes_Equals(s1, s2, equals);
38002 if (s1_is_unicode & s2_is_unicode) {
38005 void *data1, *data2;
38006 if (unlikely(__Pyx_PyUnicode_READY(s1) < 0) || unlikely(__Pyx_PyUnicode_READY(s2) < 0))
38008 length = __Pyx_PyUnicode_GET_LENGTH(s1);
38009 if (length != __Pyx_PyUnicode_GET_LENGTH(s2)) {
38012 #if CYTHON_USE_UNICODE_INTERNALS
38014 Py_hash_t hash1, hash2;
38015 #if CYTHON_PEP393_ENABLED
38016 hash1 = ((PyASCIIObject*)s1)->hash;
38017 hash2 = ((PyASCIIObject*)s2)->hash;
38019 hash1 = ((PyUnicodeObject*)s1)->hash;
38020 hash2 = ((PyUnicodeObject*)s2)->hash;
38022 if (hash1 != hash2 && hash1 != -1 && hash2 != -1) {
38027 kind = __Pyx_PyUnicode_KIND(s1);
38028 if (kind != __Pyx_PyUnicode_KIND(s2)) {
38031 data1 = __Pyx_PyUnicode_DATA(s1);
38032 data2 = __Pyx_PyUnicode_DATA(s2);
38033 if (__Pyx_PyUnicode_READ(kind, data1, 0) != __Pyx_PyUnicode_READ(kind, data2, 0)) {
38035 }
else if (length == 1) {
38038 int result = memcmp(data1, data2, (
size_t)(length * kind));
38039 #if PY_MAJOR_VERSION < 3
38040 Py_XDECREF(owned_ref);
38042 return (equals == Py_EQ) ? (result == 0) : (result != 0);
38044 }
else if ((s1 == Py_None) & s2_is_unicode) {
38046 }
else if ((s2 == Py_None) & s1_is_unicode) {
38050 PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
38051 #if PY_MAJOR_VERSION < 3
38052 Py_XDECREF(owned_ref);
38056 result = __Pyx_PyObject_IsTrue(py_result);
38057 Py_DECREF(py_result);
38061 #if PY_MAJOR_VERSION < 3
38062 Py_XDECREF(owned_ref);
38064 return (equals == Py_EQ);
38066 #if PY_MAJOR_VERSION < 3
38067 Py_XDECREF(owned_ref);
38069 return (equals == Py_NE);
38074 static CYTHON_INLINE Py_ssize_t __Pyx_div_Py_ssize_t(Py_ssize_t a, Py_ssize_t b) {
38075 Py_ssize_t
q = a / b;
38076 Py_ssize_t
r = a -
q*b;
38077 q -= ((
r != 0) & ((
r ^ b) < 0));
38082 static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *o, PyObject *
n) {
38083 #if CYTHON_USE_TYPE_SLOTS
38084 #if PY_MAJOR_VERSION >= 3
38085 if (likely(PyUnicode_Check(
n)))
38087 if (likely(PyString_Check(
n)))
38089 return __Pyx_PyObject_GetAttrStr(o,
n);
38091 return PyObject_GetAttr(o,
n);
38095 static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j) {
38097 if (!j)
return NULL;
38098 r = PyObject_GetItem(o, j);
38102 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
38103 CYTHON_NCP_UNUSED
int wraparound,
38104 CYTHON_NCP_UNUSED
int boundscheck) {
38105 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
38106 Py_ssize_t wrapped_i = i;
38107 if (wraparound & unlikely(i < 0)) {
38108 wrapped_i += PyList_GET_SIZE(o);
38110 if ((!boundscheck) || likely(__Pyx_is_valid_index(wrapped_i, PyList_GET_SIZE(o)))) {
38111 PyObject *
r = PyList_GET_ITEM(o, wrapped_i);
38115 return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
38117 return PySequence_GetItem(o, i);
38120 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
38121 CYTHON_NCP_UNUSED
int wraparound,
38122 CYTHON_NCP_UNUSED
int boundscheck) {
38123 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
38124 Py_ssize_t wrapped_i = i;
38125 if (wraparound & unlikely(i < 0)) {
38126 wrapped_i += PyTuple_GET_SIZE(o);
38128 if ((!boundscheck) || likely(__Pyx_is_valid_index(wrapped_i, PyTuple_GET_SIZE(o)))) {
38129 PyObject *
r = PyTuple_GET_ITEM(o, wrapped_i);
38133 return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
38135 return PySequence_GetItem(o, i);
38138 static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i,
int is_list,
38139 CYTHON_NCP_UNUSED
int wraparound,
38140 CYTHON_NCP_UNUSED
int boundscheck) {
38141 #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS && CYTHON_USE_TYPE_SLOTS
38142 if (is_list || PyList_CheckExact(o)) {
38143 Py_ssize_t
n = ((!wraparound) | likely(i >= 0)) ? i : i + PyList_GET_SIZE(o);
38144 if ((!boundscheck) || (likely(__Pyx_is_valid_index(
n, PyList_GET_SIZE(o))))) {
38145 PyObject *
r = PyList_GET_ITEM(o,
n);
38150 else if (PyTuple_CheckExact(o)) {
38151 Py_ssize_t
n = ((!wraparound) | likely(i >= 0)) ? i : i + PyTuple_GET_SIZE(o);
38152 if ((!boundscheck) || likely(__Pyx_is_valid_index(
n, PyTuple_GET_SIZE(o)))) {
38153 PyObject *
r = PyTuple_GET_ITEM(o,
n);
38158 PySequenceMethods *m = Py_TYPE(o)->tp_as_sequence;
38159 if (likely(m && m->sq_item)) {
38160 if (wraparound && unlikely(i < 0) && likely(m->sq_length)) {
38161 Py_ssize_t l = m->sq_length(o);
38162 if (likely(l >= 0)) {
38165 if (!PyErr_ExceptionMatches(PyExc_OverflowError))
38170 return m->sq_item(o, i);
38174 if (is_list || PySequence_Check(o)) {
38175 return PySequence_GetItem(o, i);
38178 return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
38182 #if CYTHON_USE_TYPE_SLOTS
38183 static PyObject *__Pyx_PyObject_GetIndex(PyObject *obj, PyObject* index) {
38185 Py_ssize_t key_value;
38186 PySequenceMethods *m = Py_TYPE(obj)->tp_as_sequence;
38187 if (unlikely(!(m && m->sq_item))) {
38188 PyErr_Format(PyExc_TypeError,
"'%.200s' object is not subscriptable", Py_TYPE(obj)->tp_name);
38191 key_value = __Pyx_PyIndex_AsSsize_t(index);
38192 if (likely(key_value != -1 || !(runerr = PyErr_Occurred()))) {
38193 return __Pyx_GetItemInt_Fast(obj, key_value, 0, 1, 1);
38195 if (PyErr_GivenExceptionMatches(runerr, PyExc_OverflowError)) {
38197 PyErr_Format(PyExc_IndexError,
"cannot fit '%.200s' into an index-sized integer", Py_TYPE(index)->tp_name);
38201 static PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject* key) {
38202 PyMappingMethods *m = Py_TYPE(obj)->tp_as_mapping;
38203 if (likely(m && m->mp_subscript)) {
38204 return m->mp_subscript(obj, key);
38206 return __Pyx_PyObject_GetIndex(obj, key);
38211 static CYTHON_INLINE PyObject* __Pyx_decode_c_string(
38212 const char* cstring, Py_ssize_t start, Py_ssize_t stop,
38213 const char* encoding,
const char* errors,
38214 PyObject* (*decode_func)(
const char *
s, Py_ssize_t size,
const char *errors)) {
38216 if (unlikely((start < 0) | (stop < 0))) {
38217 size_t slen = strlen(cstring);
38218 if (unlikely(slen > (
size_t) PY_SSIZE_T_MAX)) {
38219 PyErr_SetString(PyExc_OverflowError,
38220 "c-string too long to convert to Python");
38223 length = (Py_ssize_t) slen;
38232 if (unlikely(stop <= start))
38233 return __Pyx_NewRef(__pyx_empty_unicode);
38234 length = stop - start;
38237 return decode_func(cstring, length, errors);
38239 return PyUnicode_Decode(cstring, length, encoding, errors);
38244 static PyObject *__Pyx_GetAttr3Default(PyObject *d) {
38245 __Pyx_PyThreadState_declare
38246 __Pyx_PyThreadState_assign
38247 if (unlikely(!__Pyx_PyErr_ExceptionMatches(PyExc_AttributeError)))
38249 __Pyx_PyErr_Clear();
38253 static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *o, PyObject *
n, PyObject *d) {
38254 PyObject *
r = __Pyx_GetAttr(o,
n);
38255 return (likely(
r)) ?
r : __Pyx_GetAttr3Default(d);
38259 static CYTHON_INLINE
void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected) {
38260 PyErr_Format(PyExc_ValueError,
38261 "too many values to unpack (expected %" CYTHON_FORMAT_SSIZE_T
"d)", expected);
38265 static CYTHON_INLINE
void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index) {
38266 PyErr_Format(PyExc_ValueError,
38267 "need more than %" CYTHON_FORMAT_SSIZE_T
"d value%.1s to unpack",
38268 index, (index == 1) ?
"" :
"s");
38272 static CYTHON_INLINE
void __Pyx_RaiseNoneNotIterableError(
void) {
38273 PyErr_SetString(PyExc_TypeError,
"'NoneType' object is not iterable");
38277 #if CYTHON_FAST_THREAD_STATE
38278 static CYTHON_INLINE
void __Pyx__ExceptionSwap(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
38279 PyObject *tmp_type, *tmp_value, *tmp_tb;
38280 #if CYTHON_USE_EXC_INFO_STACK
38281 _PyErr_StackItem *exc_info = tstate->exc_info;
38282 tmp_type = exc_info->exc_type;
38283 tmp_value = exc_info->exc_value;
38284 tmp_tb = exc_info->exc_traceback;
38285 exc_info->exc_type = *type;
38286 exc_info->exc_value = *value;
38287 exc_info->exc_traceback = *tb;
38289 tmp_type = tstate->exc_type;
38290 tmp_value = tstate->exc_value;
38291 tmp_tb = tstate->exc_traceback;
38292 tstate->exc_type = *type;
38293 tstate->exc_value = *value;
38294 tstate->exc_traceback = *tb;
38297 *value = tmp_value;
38301 static CYTHON_INLINE
void __Pyx_ExceptionSwap(PyObject **type, PyObject **value, PyObject **tb) {
38302 PyObject *tmp_type, *tmp_value, *tmp_tb;
38303 PyErr_GetExcInfo(&tmp_type, &tmp_value, &tmp_tb);
38304 PyErr_SetExcInfo(*type, *value, *tb);
38306 *value = tmp_value;
38312 static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list,
int level) {
38313 PyObject *empty_list = 0;
38314 PyObject *module = 0;
38315 PyObject *global_dict = 0;
38316 PyObject *empty_dict = 0;
38318 #if PY_MAJOR_VERSION < 3
38319 PyObject *py_import;
38320 py_import = __Pyx_PyObject_GetAttrStr(__pyx_b, __pyx_n_s_import);
38327 empty_list = PyList_New(0);
38332 global_dict = PyModule_GetDict(__pyx_m);
38335 empty_dict = PyDict_New();
38339 #if PY_MAJOR_VERSION >= 3
38341 if ((1) && (strchr(__Pyx_MODULE_NAME,
'.'))) {
38342 module = PyImport_ImportModuleLevelObject(
38343 name, global_dict, empty_dict, list, 1);
38345 if (!PyErr_ExceptionMatches(PyExc_ImportError))
38354 #if PY_MAJOR_VERSION < 3
38355 PyObject *py_level = PyInt_FromLong(level);
38358 module = PyObject_CallFunctionObjArgs(py_import,
38359 name, global_dict, empty_dict, list, py_level, (PyObject *)NULL);
38360 Py_DECREF(py_level);
38362 module = PyImport_ImportModuleLevelObject(
38363 name, global_dict, empty_dict, list, level);
38368 #if PY_MAJOR_VERSION < 3
38369 Py_XDECREF(py_import);
38371 Py_XDECREF(empty_list);
38372 Py_XDECREF(empty_dict);
38377 #if CYTHON_COMPILING_IN_CPYTHON
38378 static int __Pyx_InBases(PyTypeObject *a, PyTypeObject *b) {
38384 return b == &PyBaseObject_Type;
38386 static CYTHON_INLINE
int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b) {
38388 if (a == b)
return 1;
38392 n = PyTuple_GET_SIZE(mro);
38393 for (i = 0; i <
n; i++) {
38394 if (PyTuple_GET_ITEM(mro, i) == (PyObject *)b)
38399 return __Pyx_InBases(a, b);
38401 #if PY_MAJOR_VERSION == 2
38402 static int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject* exc_type2) {
38403 PyObject *exception, *value, *tb;
38405 __Pyx_PyThreadState_declare
38406 __Pyx_PyThreadState_assign
38407 __Pyx_ErrFetch(&exception, &value, &tb);
38408 res = exc_type1 ? PyObject_IsSubclass(err, exc_type1) : 0;
38409 if (unlikely(res == -1)) {
38410 PyErr_WriteUnraisable(err);
38414 res = PyObject_IsSubclass(err, exc_type2);
38415 if (unlikely(res == -1)) {
38416 PyErr_WriteUnraisable(err);
38420 __Pyx_ErrRestore(exception, value, tb);
38424 static CYTHON_INLINE
int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject *exc_type2) {
38425 int res = exc_type1 ? __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type1) : 0;
38427 res = __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type2);
38432 static int __Pyx_PyErr_GivenExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
38434 assert(PyExceptionClass_Check(exc_type));
38435 n = PyTuple_GET_SIZE(tuple);
38436 #if PY_MAJOR_VERSION >= 3
38437 for (i=0; i<
n; i++) {
38438 if (exc_type == PyTuple_GET_ITEM(tuple, i))
return 1;
38441 for (i=0; i<
n; i++) {
38442 PyObject *t = PyTuple_GET_ITEM(tuple, i);
38443 #if PY_MAJOR_VERSION < 3
38444 if (likely(exc_type == t))
return 1;
38446 if (likely(PyExceptionClass_Check(t))) {
38447 if (__Pyx_inner_PyErr_GivenExceptionMatches2(exc_type, NULL, t))
return 1;
38453 static CYTHON_INLINE
int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject* exc_type) {
38454 if (likely(err == exc_type))
return 1;
38455 if (likely(PyExceptionClass_Check(err))) {
38456 if (likely(PyExceptionClass_Check(exc_type))) {
38457 return __Pyx_inner_PyErr_GivenExceptionMatches2(err, NULL, exc_type);
38458 }
else if (likely(PyTuple_Check(exc_type))) {
38459 return __Pyx_PyErr_GivenExceptionMatchesTuple(err, exc_type);
38463 return PyErr_GivenExceptionMatches(err, exc_type);
38465 static CYTHON_INLINE
int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *exc_type1, PyObject *exc_type2) {
38466 assert(PyExceptionClass_Check(exc_type1));
38467 assert(PyExceptionClass_Check(exc_type2));
38468 if (likely(err == exc_type1 || err == exc_type2))
return 1;
38469 if (likely(PyExceptionClass_Check(err))) {
38470 return __Pyx_inner_PyErr_GivenExceptionMatches2(err, exc_type1, exc_type2);
38472 return (PyErr_GivenExceptionMatches(err, exc_type1) || PyErr_GivenExceptionMatches(err, exc_type2));
38477 #if !CYTHON_COMPILING_IN_PYPY
38478 static PyObject* __Pyx_PyInt_AddObjC(PyObject *op1, PyObject *op2, CYTHON_UNUSED
long intval,
int inplace,
int zerodivision_check) {
38480 (void)zerodivision_check;
38481 #if PY_MAJOR_VERSION < 3
38482 if (likely(PyInt_CheckExact(op1))) {
38483 const long b = intval;
38485 long a = PyInt_AS_LONG(op1);
38486 x = (long)((
unsigned long)a + b);
38487 if (likely((x^a) >= 0 || (x^b) >= 0))
38488 return PyInt_FromLong(x);
38489 return PyLong_Type.tp_as_number->nb_add(op1, op2);
38492 #if CYTHON_USE_PYLONG_INTERNALS
38493 if (likely(PyLong_CheckExact(op1))) {
38494 const long b = intval;
38496 #ifdef HAVE_LONG_LONG
38497 const PY_LONG_LONG llb = intval;
38498 PY_LONG_LONG lla, llx;
38500 const digit* digits = ((PyLongObject*)op1)->ob_digit;
38501 const Py_ssize_t size = Py_SIZE(op1);
38502 if (likely(__Pyx_sst_abs(size) <= 1)) {
38503 a = likely(size) ? digits[0] : 0;
38504 if (size == -1) a = -a;
38508 if (8 *
sizeof(
long) - 1 > 2 * PyLong_SHIFT) {
38509 a = -(long) (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
38511 #ifdef HAVE_LONG_LONG
38512 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) {
38513 lla = -(PY_LONG_LONG) (((((
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
38517 CYTHON_FALLTHROUGH;
38519 if (8 *
sizeof(
long) - 1 > 2 * PyLong_SHIFT) {
38520 a = (long) (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
38522 #ifdef HAVE_LONG_LONG
38523 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 2 * PyLong_SHIFT) {
38524 lla = (PY_LONG_LONG) (((((
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
38528 CYTHON_FALLTHROUGH;
38530 if (8 *
sizeof(
long) - 1 > 3 * PyLong_SHIFT) {
38531 a = -(long) (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
38533 #ifdef HAVE_LONG_LONG
38534 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) {
38535 lla = -(PY_LONG_LONG) (((((((
unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
38539 CYTHON_FALLTHROUGH;
38541 if (8 *
sizeof(
long) - 1 > 3 * PyLong_SHIFT) {
38542 a = (long) (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
38544 #ifdef HAVE_LONG_LONG
38545 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 3 * PyLong_SHIFT) {
38546 lla = (PY_LONG_LONG) (((((((
unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
38550 CYTHON_FALLTHROUGH;
38552 if (8 *
sizeof(
long) - 1 > 4 * PyLong_SHIFT) {
38553 a = -(long) (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
38555 #ifdef HAVE_LONG_LONG
38556 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) {
38557 lla = -(PY_LONG_LONG) (((((((((
unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
38561 CYTHON_FALLTHROUGH;
38563 if (8 *
sizeof(
long) - 1 > 4 * PyLong_SHIFT) {
38564 a = (long) (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0]));
38566 #ifdef HAVE_LONG_LONG
38567 }
else if (8 *
sizeof(PY_LONG_LONG) - 1 > 4 * PyLong_SHIFT) {
38568 lla = (PY_LONG_LONG) (((((((((
unsigned PY_LONG_LONG)digits[3]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[2]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[1]) << PyLong_SHIFT) | (
unsigned PY_LONG_LONG)digits[0]));
38572 CYTHON_FALLTHROUGH;
38573 default:
return PyLong_Type.tp_as_number->nb_add(op1, op2);
38577 return PyLong_FromLong(x);
38578 #ifdef HAVE_LONG_LONG
38581 return PyLong_FromLongLong(llx);
38587 if (PyFloat_CheckExact(op1)) {
38588 const long b = intval;
38589 double a = PyFloat_AS_DOUBLE(op1);
38591 PyFPE_START_PROTECT(
"add",
return NULL)
38592 result = ((double)a) + (double)b;
38593 PyFPE_END_PROTECT(result)
38594 return PyFloat_FromDouble(result);
38596 return (inplace ? PyNumber_InPlaceAdd : PyNumber_Add)(op1, op2);
38601 static CYTHON_INLINE
void __Pyx_RaiseUnboundLocalError(
const char *varname) {
38602 PyErr_Format(PyExc_UnboundLocalError,
"local variable '%s' referenced before assignment", varname);
38606 static CYTHON_INLINE
long __Pyx_div_long(
long a,
long b) {
38609 q -= ((
r != 0) & ((
r ^ b) < 0));
38614 static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name) {
38615 PyObject* value = __Pyx_PyObject_GetAttrStr(module, name);
38616 if (unlikely(!value) && PyErr_ExceptionMatches(PyExc_AttributeError)) {
38617 PyErr_Format(PyExc_ImportError,
38618 #
if PY_MAJOR_VERSION < 3
38619 "cannot import name %.230s", PyString_AS_STRING(name));
38621 "cannot import name %S", name);
38628 static CYTHON_INLINE
int __Pyx_HasAttr(PyObject *o, PyObject *
n) {
38630 if (unlikely(!__Pyx_PyBaseString_Check(
n))) {
38631 PyErr_SetString(PyExc_TypeError,
38632 "hasattr(): attribute name must be string");
38635 r = __Pyx_GetAttr(o,
n);
38636 if (unlikely(!
r)) {
38646 #if !CYTHON_COMPILING_IN_CPYTHON
38647 static CYTHON_INLINE PyObject* __Pyx_PyBytes_Join(PyObject* sep, PyObject* values) {
38648 return PyObject_CallMethodObjArgs(sep, __pyx_n_s_join, values, NULL);
38653 #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
38654 static PyObject *__Pyx_RaiseGenericGetAttributeError(PyTypeObject *tp, PyObject *attr_name) {
38655 PyErr_Format(PyExc_AttributeError,
38656 #
if PY_MAJOR_VERSION >= 3
38657 "'%.50s' object has no attribute '%U'",
38658 tp->tp_name, attr_name);
38660 "'%.50s' object has no attribute '%.400s'",
38661 tp->tp_name, PyString_AS_STRING(attr_name));
38665 static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name) {
38667 PyTypeObject *tp = Py_TYPE(obj);
38668 if (unlikely(!PyString_Check(attr_name))) {
38669 return PyObject_GenericGetAttr(obj, attr_name);
38671 assert(!tp->tp_dictoffset);
38672 descr = _PyType_Lookup(tp, attr_name);
38673 if (unlikely(!descr)) {
38674 return __Pyx_RaiseGenericGetAttributeError(tp, attr_name);
38677 #if PY_MAJOR_VERSION < 3
38678 if (likely(PyType_HasFeature(Py_TYPE(descr), Py_TPFLAGS_HAVE_CLASS)))
38681 descrgetfunc
f = Py_TYPE(descr)->tp_descr_get;
38683 PyObject *res =
f(descr, obj, (PyObject *)tp);
38693 #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
38694 static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name) {
38695 if (unlikely(Py_TYPE(obj)->tp_dictoffset)) {
38696 return PyObject_GenericGetAttr(obj, attr_name);
38698 return __Pyx_PyObject_GenericGetAttrNoDict(obj, attr_name);
38703 static void __Pyx_PyObject_GetAttrStr_ClearAttributeError(
void) {
38704 __Pyx_PyThreadState_declare
38705 __Pyx_PyThreadState_assign
38706 if (likely(__Pyx_PyErr_ExceptionMatches(PyExc_AttributeError)))
38707 __Pyx_PyErr_Clear();
38709 static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStrNoError(PyObject* obj, PyObject* attr_name) {
38711 #if CYTHON_COMPILING_IN_CPYTHON && CYTHON_USE_TYPE_SLOTS && PY_VERSION_HEX >= 0x030700B1
38712 PyTypeObject* tp = Py_TYPE(obj);
38713 if (likely(tp->tp_getattro == PyObject_GenericGetAttr)) {
38714 return _PyObject_GenericGetAttrWithDict(obj, attr_name, NULL, 1);
38717 result = __Pyx_PyObject_GetAttrStr(obj, attr_name);
38718 if (unlikely(!result)) {
38719 __Pyx_PyObject_GetAttrStr_ClearAttributeError();
38725 static int __Pyx_setup_reduce_is_named(PyObject* meth, PyObject* name) {
38727 PyObject *name_attr;
38728 name_attr = __Pyx_PyObject_GetAttrStr(meth, __pyx_n_s_name_2);
38729 if (likely(name_attr)) {
38730 ret = PyObject_RichCompareBool(name_attr, name, Py_EQ);
38734 if (unlikely(ret < 0)) {
38738 Py_XDECREF(name_attr);
38741 static int __Pyx_setup_reduce(PyObject* type_obj) {
38743 PyObject *object_reduce = NULL;
38744 PyObject *object_getstate = NULL;
38745 PyObject *object_reduce_ex = NULL;
38746 PyObject *reduce = NULL;
38747 PyObject *reduce_ex = NULL;
38748 PyObject *reduce_cython = NULL;
38749 PyObject *setstate = NULL;
38750 PyObject *setstate_cython = NULL;
38751 PyObject *getstate = NULL;
38752 #if CYTHON_USE_PYTYPE_LOOKUP
38753 getstate = _PyType_Lookup((PyTypeObject*)type_obj, __pyx_n_s_getstate);
38755 getstate = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_getstate);
38756 if (!getstate && PyErr_Occurred()) {
38761 #if CYTHON_USE_PYTYPE_LOOKUP
38762 object_getstate = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_getstate);
38764 object_getstate = __Pyx_PyObject_GetAttrStrNoError((PyObject*)&PyBaseObject_Type, __pyx_n_s_getstate);
38765 if (!object_getstate && PyErr_Occurred()) {
38769 if (object_getstate != getstate) {
38773 #if CYTHON_USE_PYTYPE_LOOKUP
38774 object_reduce_ex = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce_ex);
if (!object_reduce_ex)
goto __PYX_BAD;
38776 object_reduce_ex = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce_ex);
if (!object_reduce_ex)
goto __PYX_BAD;
38778 reduce_ex = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce_ex);
if (unlikely(!reduce_ex))
goto __PYX_BAD;
38779 if (reduce_ex == object_reduce_ex) {
38780 #if CYTHON_USE_PYTYPE_LOOKUP
38781 object_reduce = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce);
if (!object_reduce)
goto __PYX_BAD;
38783 object_reduce = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce);
if (!object_reduce)
goto __PYX_BAD;
38785 reduce = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce);
if (unlikely(!reduce))
goto __PYX_BAD;
38786 if (reduce == object_reduce || __Pyx_setup_reduce_is_named(reduce, __pyx_n_s_reduce_cython)) {
38787 reduce_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_reduce_cython);
38788 if (likely(reduce_cython)) {
38789 ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce, reduce_cython);
if (unlikely(ret < 0))
goto __PYX_BAD;
38790 ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce_cython);
if (unlikely(ret < 0))
goto __PYX_BAD;
38791 }
else if (reduce == object_reduce || PyErr_Occurred()) {
38794 setstate = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_setstate);
38795 if (!setstate) PyErr_Clear();
38796 if (!setstate || __Pyx_setup_reduce_is_named(setstate, __pyx_n_s_setstate_cython)) {
38797 setstate_cython = __Pyx_PyObject_GetAttrStrNoError(type_obj, __pyx_n_s_setstate_cython);
38798 if (likely(setstate_cython)) {
38799 ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate, setstate_cython);
if (unlikely(ret < 0))
goto __PYX_BAD;
38800 ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate_cython);
if (unlikely(ret < 0))
goto __PYX_BAD;
38801 }
else if (!setstate || PyErr_Occurred()) {
38805 PyType_Modified((PyTypeObject*)type_obj);
38810 if (!PyErr_Occurred())
38811 PyErr_Format(PyExc_RuntimeError,
"Unable to initialize pickling for %s", ((PyTypeObject*)type_obj)->tp_name);
38814 #if !CYTHON_USE_PYTYPE_LOOKUP
38815 Py_XDECREF(object_reduce);
38816 Py_XDECREF(object_reduce_ex);
38817 Py_XDECREF(object_getstate);
38818 Py_XDECREF(getstate);
38820 Py_XDECREF(reduce);
38821 Py_XDECREF(reduce_ex);
38822 Py_XDECREF(reduce_cython);
38823 Py_XDECREF(setstate);
38824 Py_XDECREF(setstate_cython);
38829 static int __Pyx_SetVtable(PyObject *dict,
void *vtable) {
38830 #if PY_VERSION_HEX >= 0x02070000
38831 PyObject *ob = PyCapsule_New(vtable, 0, 0);
38833 PyObject *ob = PyCObject_FromVoidPtr(vtable, 0);
38837 if (PyDict_SetItem(dict, __pyx_n_s_pyx_vtable, ob) < 0)
38847 #ifndef __PYX_HAVE_RT_ImportType
38848 #define __PYX_HAVE_RT_ImportType
38849 static PyTypeObject *__Pyx_ImportType(PyObject *module,
const char *module_name,
const char *class_name,
38850 size_t size,
enum __Pyx_ImportType_CheckSize check_size)
38852 PyObject *result = 0;
38854 Py_ssize_t basicsize;
38855 #ifdef Py_LIMITED_API
38856 PyObject *py_basicsize;
38858 result = PyObject_GetAttrString(module, class_name);
38861 if (!PyType_Check(result)) {
38862 PyErr_Format(PyExc_TypeError,
38863 "%.200s.%.200s is not a type object",
38864 module_name, class_name);
38867 #ifndef Py_LIMITED_API
38868 basicsize = ((PyTypeObject *)result)->tp_basicsize;
38870 py_basicsize = PyObject_GetAttrString(result,
"__basicsize__");
38873 basicsize = PyLong_AsSsize_t(py_basicsize);
38874 Py_DECREF(py_basicsize);
38876 if (basicsize == (Py_ssize_t)-1 && PyErr_Occurred())
38879 if ((
size_t)basicsize < size) {
38880 PyErr_Format(PyExc_ValueError,
38881 "%.200s.%.200s size changed, may indicate binary incompatibility. "
38882 "Expected %zd from C header, got %zd from PyObject",
38883 module_name, class_name, size, basicsize);
38886 if (check_size == __Pyx_ImportType_CheckSize_Error && (
size_t)basicsize != size) {
38887 PyErr_Format(PyExc_ValueError,
38888 "%.200s.%.200s size changed, may indicate binary incompatibility. "
38889 "Expected %zd from C header, got %zd from PyObject",
38890 module_name, class_name, size, basicsize);
38893 else if (check_size == __Pyx_ImportType_CheckSize_Warn && (
size_t)basicsize > size) {
38894 PyOS_snprintf(warning,
sizeof(warning),
38895 "%s.%s size changed, may indicate binary incompatibility. "
38896 "Expected %zd from C header, got %zd from PyObject",
38897 module_name, class_name, size, basicsize);
38898 if (PyErr_WarnEx(NULL, warning, 0) < 0)
goto bad;
38900 return (PyTypeObject *)result;
38902 Py_XDECREF(result);
38908 #ifndef CYTHON_CLINE_IN_TRACEBACK
38909 static int __Pyx_CLineForTraceback(CYTHON_NCP_UNUSED PyThreadState *tstate,
int c_line) {
38910 PyObject *use_cline;
38911 PyObject *ptype, *pvalue, *ptraceback;
38912 #if CYTHON_COMPILING_IN_CPYTHON
38913 PyObject **cython_runtime_dict;
38915 if (unlikely(!__pyx_cython_runtime)) {
38918 __Pyx_ErrFetchInState(tstate, &ptype, &pvalue, &ptraceback);
38919 #if CYTHON_COMPILING_IN_CPYTHON
38920 cython_runtime_dict = _PyObject_GetDictPtr(__pyx_cython_runtime);
38921 if (likely(cython_runtime_dict)) {
38922 __PYX_PY_DICT_LOOKUP_IF_MODIFIED(
38923 use_cline, *cython_runtime_dict,
38924 __Pyx_PyDict_GetItemStr(*cython_runtime_dict, __pyx_n_s_cline_in_traceback))
38928 PyObject *use_cline_obj = __Pyx_PyObject_GetAttrStr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback);
38929 if (use_cline_obj) {
38930 use_cline = PyObject_Not(use_cline_obj) ? Py_False : Py_True;
38931 Py_DECREF(use_cline_obj);
38939 (void) PyObject_SetAttr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback, Py_False);
38941 else if (use_cline == Py_False || (use_cline != Py_True && PyObject_Not(use_cline) != 0)) {
38944 __Pyx_ErrRestoreInState(tstate, ptype, pvalue, ptraceback);
38950 static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries,
int count,
int code_line) {
38951 int start = 0, mid = 0, end = count - 1;
38952 if (end >= 0 && code_line > entries[end].code_line) {
38955 while (start < end) {
38956 mid = start + (end - start) / 2;
38957 if (code_line < entries[mid].code_line) {
38959 }
else if (code_line > entries[mid].code_line) {
38965 if (code_line <= entries[mid].code_line) {
38971 static PyCodeObject *__pyx_find_code_object(
int code_line) {
38972 PyCodeObject* code_object;
38974 if (unlikely(!code_line) || unlikely(!__pyx_code_cache.entries)) {
38977 pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
38978 if (unlikely(
pos >= __pyx_code_cache.count) || unlikely(__pyx_code_cache.entries[
pos].code_line != code_line)) {
38981 code_object = __pyx_code_cache.entries[
pos].code_object;
38982 Py_INCREF(code_object);
38983 return code_object;
38985 static void __pyx_insert_code_object(
int code_line, PyCodeObject* code_object) {
38987 __Pyx_CodeObjectCacheEntry* entries = __pyx_code_cache.entries;
38988 if (unlikely(!code_line)) {
38991 if (unlikely(!entries)) {
38992 entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Malloc(64*
sizeof(__Pyx_CodeObjectCacheEntry));
38993 if (likely(entries)) {
38994 __pyx_code_cache.entries = entries;
38995 __pyx_code_cache.max_count = 64;
38996 __pyx_code_cache.count = 1;
38997 entries[0].code_line = code_line;
38998 entries[0].code_object = code_object;
38999 Py_INCREF(code_object);
39003 pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
39004 if ((
pos < __pyx_code_cache.count) && unlikely(__pyx_code_cache.entries[
pos].code_line == code_line)) {
39005 PyCodeObject* tmp = entries[
pos].code_object;
39006 entries[
pos].code_object = code_object;
39010 if (__pyx_code_cache.count == __pyx_code_cache.max_count) {
39011 int new_max = __pyx_code_cache.max_count + 64;
39012 entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Realloc(
39013 __pyx_code_cache.entries, ((
size_t)new_max) *
sizeof(__Pyx_CodeObjectCacheEntry));
39014 if (unlikely(!entries)) {
39017 __pyx_code_cache.entries = entries;
39018 __pyx_code_cache.max_count = new_max;
39020 for (i=__pyx_code_cache.count; i>
pos; i--) {
39021 entries[i] = entries[i-1];
39023 entries[
pos].code_line = code_line;
39024 entries[
pos].code_object = code_object;
39025 __pyx_code_cache.count++;
39026 Py_INCREF(code_object);
39030 #include "compile.h"
39031 #include "frameobject.h"
39032 #include "traceback.h"
39033 #if PY_VERSION_HEX >= 0x030b00a6
39034 #ifndef Py_BUILD_CORE
39035 #define Py_BUILD_CORE 1
39037 #include "internal/pycore_frame.h"
39039 static PyCodeObject* __Pyx_CreateCodeObjectForTraceback(
39040 const char *funcname,
int c_line,
39041 int py_line,
const char *filename) {
39042 PyCodeObject *py_code = NULL;
39043 PyObject *py_funcname = NULL;
39044 #if PY_MAJOR_VERSION < 3
39045 PyObject *py_srcfile = NULL;
39046 py_srcfile = PyString_FromString(filename);
39047 if (!py_srcfile)
goto bad;
39050 #if PY_MAJOR_VERSION < 3
39051 py_funcname = PyString_FromFormat(
"%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
39052 if (!py_funcname)
goto bad;
39054 py_funcname = PyUnicode_FromFormat(
"%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
39055 if (!py_funcname)
goto bad;
39056 funcname = PyUnicode_AsUTF8(py_funcname);
39057 if (!funcname)
goto bad;
39061 #if PY_MAJOR_VERSION < 3
39062 py_funcname = PyString_FromString(funcname);
39063 if (!py_funcname)
goto bad;
39066 #if PY_MAJOR_VERSION < 3
39067 py_code = __Pyx_PyCode_New(
39084 Py_DECREF(py_srcfile);
39086 py_code = PyCode_NewEmpty(filename, funcname, py_line);
39088 Py_XDECREF(py_funcname);
39091 Py_XDECREF(py_funcname);
39092 #if PY_MAJOR_VERSION < 3
39093 Py_XDECREF(py_srcfile);
39097 static void __Pyx_AddTraceback(
const char *funcname,
int c_line,
39098 int py_line,
const char *filename) {
39099 PyCodeObject *py_code = 0;
39100 PyFrameObject *py_frame = 0;
39101 PyThreadState *tstate = __Pyx_PyThreadState_Current;
39102 PyObject *ptype, *pvalue, *ptraceback;
39104 c_line = __Pyx_CLineForTraceback(tstate, c_line);
39106 py_code = __pyx_find_code_object(c_line ? -c_line : py_line);
39108 __Pyx_ErrFetchInState(tstate, &ptype, &pvalue, &ptraceback);
39109 py_code = __Pyx_CreateCodeObjectForTraceback(
39110 funcname, c_line, py_line, filename);
39115 Py_XDECREF(pvalue);
39116 Py_XDECREF(ptraceback);
39119 __Pyx_ErrRestoreInState(tstate, ptype, pvalue, ptraceback);
39120 __pyx_insert_code_object(c_line ? -c_line : py_line, py_code);
39122 py_frame = PyFrame_New(
39128 if (!py_frame)
goto bad;
39129 __Pyx_PyFrame_SetLineNumber(py_frame, py_line);
39130 PyTraceBack_Here(py_frame);
39132 Py_XDECREF(py_code);
39133 Py_XDECREF(py_frame);
39137 #define __PYX_VERIFY_RETURN_INT(target_type, func_type, func_value)\
39138 __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 0)
39139 #define __PYX_VERIFY_RETURN_INT_EXC(target_type, func_type, func_value)\
39140 __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 1)
39141 #define __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, exc)\
39143 func_type value = func_value;\
39144 if (sizeof(target_type) < sizeof(func_type)) {\
39145 if (unlikely(value != (func_type) (target_type) value)) {\
39146 func_type zero = 0;\
39147 if (exc && unlikely(value == (func_type)-1 && PyErr_Occurred()))\
39148 return (target_type) -1;\
39149 if (is_unsigned && unlikely(value < zero))\
39150 goto raise_neg_overflow;\
39152 goto raise_overflow;\
39155 return (target_type) value;\
39159 static CYTHON_INLINE PyObject *__pyx_memview_get_int(
const char *itemp) {
39160 return (PyObject *) __Pyx_PyInt_From_int(*(
int *) itemp);
39162 static CYTHON_INLINE
int __pyx_memview_set_int(
const char *itemp, PyObject *obj) {
39163 int value = __Pyx_PyInt_As_int(obj);
39164 if ((value == (
int)-1) && PyErr_Occurred())
39166 *(
int *) itemp = value;
39171 static CYTHON_INLINE PyObject *__pyx_memview_get_double(
const char *itemp) {
39172 return (PyObject *) PyFloat_FromDouble(*(
double *) itemp);
39174 static CYTHON_INLINE
int __pyx_memview_set_double(
const char *itemp, PyObject *obj) {
39175 double value = __pyx_PyFloat_AsDouble(obj);
39176 if ((value == (
double)-1) && PyErr_Occurred())
39178 *(
double *) itemp = value;
39183 #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION < 3
39184 static PyObject *__Pyx_GetStdout(
void) {
39185 PyObject *
f = PySys_GetObject((
char *)
"stdout");
39187 PyErr_SetString(PyExc_RuntimeError,
"lost sys.stdout");
39191 static int __Pyx_Print(PyObject*
f, PyObject *arg_tuple,
int newline) {
39194 if (!(
f = __Pyx_GetStdout()))
39198 for (i=0; i < PyTuple_GET_SIZE(arg_tuple); i++) {
39200 if (PyFile_SoftSpace(
f, 1)) {
39201 if (PyFile_WriteString(
" ",
f) < 0)
39204 v = PyTuple_GET_ITEM(arg_tuple, i);
39205 if (PyFile_WriteObject(
v,
f, Py_PRINT_RAW) < 0)
39207 if (PyString_Check(
v)) {
39208 char *
s = PyString_AsString(
v);
39209 Py_ssize_t len = PyString_Size(
v);
39211 switch (
s[len-1]) {
39213 case '\f':
case '\r':
case '\n':
case '\t':
case '\v':
39214 PyFile_SoftSpace(
f, 0);
39222 if (PyFile_WriteString(
"\n",
f) < 0)
39224 PyFile_SoftSpace(
f, 0);
39233 static int __Pyx_Print(PyObject* stream, PyObject *arg_tuple,
int newline) {
39234 PyObject* kwargs = 0;
39235 PyObject* result = 0;
39236 PyObject* end_string;
39237 if (unlikely(!__pyx_print)) {
39238 __pyx_print = PyObject_GetAttr(__pyx_b, __pyx_n_s_print);
39243 kwargs = PyDict_New();
39244 if (unlikely(!kwargs))
39246 if (unlikely(PyDict_SetItem(kwargs, __pyx_n_s_file, stream) < 0))
39249 end_string = PyUnicode_FromStringAndSize(
" ", 1);
39250 if (unlikely(!end_string))
39252 if (PyDict_SetItem(kwargs, __pyx_n_s_end, end_string) < 0) {
39253 Py_DECREF(end_string);
39256 Py_DECREF(end_string);
39258 }
else if (!newline) {
39259 if (unlikely(!__pyx_print_kwargs)) {
39260 __pyx_print_kwargs = PyDict_New();
39261 if (unlikely(!__pyx_print_kwargs))
39263 end_string = PyUnicode_FromStringAndSize(
" ", 1);
39264 if (unlikely(!end_string))
39266 if (PyDict_SetItem(__pyx_print_kwargs, __pyx_n_s_end, end_string) < 0) {
39267 Py_DECREF(end_string);
39270 Py_DECREF(end_string);
39272 kwargs = __pyx_print_kwargs;
39274 result = PyObject_Call(__pyx_print, arg_tuple, kwargs);
39275 if (unlikely(kwargs) && (kwargs != __pyx_print_kwargs))
39282 if (kwargs != __pyx_print_kwargs)
39283 Py_XDECREF(kwargs);
39289 #if CYTHON_CCOMPLEX
39291 static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(
float x,
float y) {
39292 return ::std::complex< float >(x, y);
39295 static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(
float x,
float y) {
39296 return x + y*(__pyx_t_float_complex)_Complex_I;
39300 static CYTHON_INLINE __pyx_t_float_complex __pyx_t_float_complex_from_parts(
float x,
float y) {
39301 __pyx_t_float_complex
z;
39309 #if CYTHON_CCOMPLEX
39311 static CYTHON_INLINE
int __Pyx_c_eq_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
39312 return (a.real == b.real) && (a.imag == b.imag);
39314 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_sum_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
39315 __pyx_t_float_complex
z;
39316 z.real = a.real + b.real;
39317 z.imag = a.imag + b.imag;
39320 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_diff_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
39321 __pyx_t_float_complex
z;
39322 z.real = a.real - b.real;
39323 z.imag = a.imag - b.imag;
39326 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_prod_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
39327 __pyx_t_float_complex
z;
39328 z.real = a.real * b.real - a.imag * b.imag;
39329 z.imag = a.real * b.imag + a.imag * b.real;
39333 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
39335 return __pyx_t_float_complex_from_parts(a.real / b.real, a.imag / b.real);
39336 }
else if (fabsf(b.real) >= fabsf(b.imag)) {
39337 if (b.real == 0 && b.imag == 0) {
39338 return __pyx_t_float_complex_from_parts(a.real / b.real, a.imag / b.imag);
39340 float r = b.imag / b.real;
39341 float s = (float)(1.0) / (b.real + b.imag *
r);
39342 return __pyx_t_float_complex_from_parts(
39343 (a.real + a.imag *
r) *
s, (a.imag - a.real *
r) *
s);
39346 float r = b.real / b.imag;
39347 float s = (float)(1.0) / (b.imag + b.real *
r);
39348 return __pyx_t_float_complex_from_parts(
39349 (a.real *
r + a.imag) *
s, (a.imag *
r - a.real) *
s);
39353 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_quot_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
39355 return __pyx_t_float_complex_from_parts(a.real / b.real, a.imag / b.real);
39357 float denom = b.real * b.real + b.imag * b.imag;
39358 return __pyx_t_float_complex_from_parts(
39359 (a.real * b.real + a.imag * b.imag) / denom,
39360 (a.imag * b.real - a.real * b.imag) / denom);
39364 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_neg_float(__pyx_t_float_complex a) {
39365 __pyx_t_float_complex
z;
39370 static CYTHON_INLINE
int __Pyx_c_is_zero_float(__pyx_t_float_complex a) {
39371 return (a.real == 0) && (a.imag == 0);
39373 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_conj_float(__pyx_t_float_complex a) {
39374 __pyx_t_float_complex
z;
39380 static CYTHON_INLINE
float __Pyx_c_abs_float(__pyx_t_float_complex
z) {
39381 #if !defined(HAVE_HYPOT) || defined(_MSC_VER)
39382 return sqrtf(
z.real*
z.real +
z.imag*
z.imag);
39384 return hypotf(
z.real,
z.imag);
39387 static CYTHON_INLINE __pyx_t_float_complex __Pyx_c_pow_float(__pyx_t_float_complex a, __pyx_t_float_complex b) {
39388 __pyx_t_float_complex
z;
39389 float r, lnr, theta, z_r, z_theta;
39390 if (b.imag == 0 && b.real == (
int)b.real) {
39392 float denom = a.real * a.real + a.imag * a.imag;
39393 a.real = a.real / denom;
39394 a.imag = -a.imag / denom;
39397 switch ((
int)b.real) {
39405 return __Pyx_c_prod_float(a, a);
39407 z = __Pyx_c_prod_float(a, a);
39408 return __Pyx_c_prod_float(
z, a);
39410 z = __Pyx_c_prod_float(a, a);
39411 return __Pyx_c_prod_float(
z,
z);
39417 }
else if (b.imag == 0) {
39418 z.real = powf(a.real, b.real);
39421 }
else if (a.real > 0) {
39426 theta = atan2f(0.0, -1.0);
39429 r = __Pyx_c_abs_float(a);
39430 theta = atan2f(a.imag, a.real);
39433 z_r = expf(lnr * b.real - theta * b.imag);
39434 z_theta = theta * b.real + lnr * b.imag;
39435 z.real = z_r * cosf(z_theta);
39436 z.imag = z_r * sinf(z_theta);
39443 #if CYTHON_CCOMPLEX
39445 static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(
double x,
double y) {
39446 return ::std::complex< double >(x, y);
39449 static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(
double x,
double y) {
39450 return x + y*(__pyx_t_double_complex)_Complex_I;
39454 static CYTHON_INLINE __pyx_t_double_complex __pyx_t_double_complex_from_parts(
double x,
double y) {
39455 __pyx_t_double_complex
z;
39463 #if CYTHON_CCOMPLEX
39465 static CYTHON_INLINE
int __Pyx_c_eq_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
39466 return (a.real == b.real) && (a.imag == b.imag);
39468 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_sum_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
39469 __pyx_t_double_complex
z;
39470 z.real = a.real + b.real;
39471 z.imag = a.imag + b.imag;
39474 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_diff_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
39475 __pyx_t_double_complex
z;
39476 z.real = a.real - b.real;
39477 z.imag = a.imag - b.imag;
39480 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_prod_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
39481 __pyx_t_double_complex
z;
39482 z.real = a.real * b.real - a.imag * b.imag;
39483 z.imag = a.real * b.imag + a.imag * b.real;
39487 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
39489 return __pyx_t_double_complex_from_parts(a.real / b.real, a.imag / b.real);
39490 }
else if (fabs(b.real) >= fabs(b.imag)) {
39491 if (b.real == 0 && b.imag == 0) {
39492 return __pyx_t_double_complex_from_parts(a.real / b.real, a.imag / b.imag);
39494 double r = b.imag / b.real;
39495 double s = (double)(1.0) / (b.real + b.imag *
r);
39496 return __pyx_t_double_complex_from_parts(
39497 (a.real + a.imag *
r) *
s, (a.imag - a.real *
r) *
s);
39500 double r = b.real / b.imag;
39501 double s = (double)(1.0) / (b.imag + b.real *
r);
39502 return __pyx_t_double_complex_from_parts(
39503 (a.real *
r + a.imag) *
s, (a.imag *
r - a.real) *
s);
39507 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_quot_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
39509 return __pyx_t_double_complex_from_parts(a.real / b.real, a.imag / b.real);
39511 double denom = b.real * b.real + b.imag * b.imag;
39512 return __pyx_t_double_complex_from_parts(
39513 (a.real * b.real + a.imag * b.imag) / denom,
39514 (a.imag * b.real - a.real * b.imag) / denom);
39518 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_neg_double(__pyx_t_double_complex a) {
39519 __pyx_t_double_complex
z;
39524 static CYTHON_INLINE
int __Pyx_c_is_zero_double(__pyx_t_double_complex a) {
39525 return (a.real == 0) && (a.imag == 0);
39527 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_conj_double(__pyx_t_double_complex a) {
39528 __pyx_t_double_complex
z;
39534 static CYTHON_INLINE
double __Pyx_c_abs_double(__pyx_t_double_complex
z) {
39535 #if !defined(HAVE_HYPOT) || defined(_MSC_VER)
39536 return sqrt(
z.real*
z.real +
z.imag*
z.imag);
39538 return hypot(
z.real,
z.imag);
39541 static CYTHON_INLINE __pyx_t_double_complex __Pyx_c_pow_double(__pyx_t_double_complex a, __pyx_t_double_complex b) {
39542 __pyx_t_double_complex
z;
39543 double r, lnr, theta, z_r, z_theta;
39544 if (b.imag == 0 && b.real == (
int)b.real) {
39546 double denom = a.real * a.real + a.imag * a.imag;
39547 a.real = a.real / denom;
39548 a.imag = -a.imag / denom;
39551 switch ((
int)b.real) {
39559 return __Pyx_c_prod_double(a, a);
39561 z = __Pyx_c_prod_double(a, a);
39562 return __Pyx_c_prod_double(
z, a);
39564 z = __Pyx_c_prod_double(a, a);
39565 return __Pyx_c_prod_double(
z,
z);
39571 }
else if (b.imag == 0) {
39572 z.real = pow(a.real, b.real);
39575 }
else if (a.real > 0) {
39580 theta = atan2(0.0, -1.0);
39583 r = __Pyx_c_abs_double(a);
39584 theta = atan2(a.imag, a.real);
39587 z_r = exp(lnr * b.real - theta * b.imag);
39588 z_theta = theta * b.real + lnr * b.imag;
39589 z.real = z_r * cos(z_theta);
39590 z.imag = z_r * sin(z_theta);
39596 #if PY_MAJOR_VERSION < 3
39597 static int __Pyx_GetBuffer(PyObject *obj, Py_buffer *view,
int flags) {
39598 if (PyObject_CheckBuffer(obj))
return PyObject_GetBuffer(obj, view, flags);
39599 if (__Pyx_TypeCheck(obj, __pyx_array_type))
return __pyx_array_getbuffer(obj, view, flags);
39600 if (__Pyx_TypeCheck(obj, __pyx_memoryview_type))
return __pyx_memoryview_getbuffer(obj, view, flags);
39601 PyErr_Format(PyExc_TypeError,
"'%.200s' does not have the buffer interface", Py_TYPE(obj)->tp_name);
39604 static void __Pyx_ReleaseBuffer(Py_buffer *view) {
39605 PyObject *obj = view->obj;
39607 if (PyObject_CheckBuffer(obj)) {
39608 PyBuffer_Release(view);
39620 __pyx_memviewslice_is_contig(
const __Pyx_memviewslice mvs,
char order,
int ndim)
39622 int i, index, step, start;
39623 Py_ssize_t itemsize = mvs.memview->view.itemsize;
39624 if (order ==
'F') {
39631 for (i = 0; i < ndim; i++) {
39632 index = start + step * i;
39633 if (mvs.suboffsets[index] >= 0 || mvs.strides[index] != itemsize)
39635 itemsize *= mvs.shape[index];
39642 __pyx_get_array_memory_extents(__Pyx_memviewslice *slice,
39643 void **out_start,
void **out_end,
39644 int ndim,
size_t itemsize)
39648 start = end = slice->data;
39649 for (i = 0; i < ndim; i++) {
39650 Py_ssize_t stride = slice->strides[i];
39651 Py_ssize_t extent = slice->shape[i];
39653 *out_start = *out_end = start;
39657 end += stride * (extent - 1);
39659 start += stride * (extent - 1);
39662 *out_start = start;
39663 *out_end = end + itemsize;
39666 __pyx_slices_overlap(__Pyx_memviewslice *slice1,
39667 __Pyx_memviewslice *slice2,
39668 int ndim,
size_t itemsize)
39670 void *start1, *end1, *start2, *end2;
39671 __pyx_get_array_memory_extents(slice1, &start1, &end1, ndim, itemsize);
39672 __pyx_get_array_memory_extents(slice2, &start2, &end2, ndim, itemsize);
39673 return (start1 < end2) && (start2 < end1);
39677 static CYTHON_INLINE PyObject *
39678 __pyx_capsule_create(
void *p, CYTHON_UNUSED
const char *sig)
39681 #if PY_VERSION_HEX >= 0x02070000
39682 cobj = PyCapsule_New(p, sig, NULL);
39684 cobj = PyCObject_FromVoidPtr(p, NULL);
39690 static CYTHON_INLINE
int __Pyx_PyInt_As_int(PyObject *x) {
39691 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
39692 #pragma GCC diagnostic push
39693 #pragma GCC diagnostic ignored "-Wconversion"
39695 const int neg_one = (int) -1, const_zero = (
int) 0;
39696 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
39697 #pragma GCC diagnostic pop
39699 const int is_unsigned = neg_one > const_zero;
39700 #if PY_MAJOR_VERSION < 3
39701 if (likely(PyInt_Check(x))) {
39702 if (
sizeof(
int) <
sizeof(long)) {
39703 __PYX_VERIFY_RETURN_INT(
int,
long, PyInt_AS_LONG(x))
39705 long val = PyInt_AS_LONG(x);
39706 if (is_unsigned && unlikely(val < 0)) {
39707 goto raise_neg_overflow;
39713 if (likely(PyLong_Check(x))) {
39715 #if CYTHON_USE_PYLONG_INTERNALS
39716 const digit* digits = ((PyLongObject*)x)->ob_digit;
39717 switch (Py_SIZE(x)) {
39718 case 0:
return (
int) 0;
39719 case 1: __PYX_VERIFY_RETURN_INT(
int, digit, digits[0])
39721 if (8 *
sizeof(
int) > 1 * PyLong_SHIFT) {
39722 if (8 *
sizeof(
unsigned long) > 2 * PyLong_SHIFT) {
39723 __PYX_VERIFY_RETURN_INT(
int,
unsigned long, (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
39724 }
else if (8 *
sizeof(
int) >= 2 * PyLong_SHIFT) {
39725 return (
int) (((((int)digits[1]) << PyLong_SHIFT) | (
int)digits[0]));
39730 if (8 *
sizeof(
int) > 2 * PyLong_SHIFT) {
39731 if (8 *
sizeof(
unsigned long) > 3 * PyLong_SHIFT) {
39732 __PYX_VERIFY_RETURN_INT(
int,
unsigned long, (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
39733 }
else if (8 *
sizeof(
int) >= 3 * PyLong_SHIFT) {
39734 return (
int) (((((((int)digits[2]) << PyLong_SHIFT) | (
int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
39739 if (8 *
sizeof(
int) > 3 * PyLong_SHIFT) {
39740 if (8 *
sizeof(
unsigned long) > 4 * PyLong_SHIFT) {
39741 __PYX_VERIFY_RETURN_INT(
int,
unsigned long, (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
39742 }
else if (8 *
sizeof(
int) >= 4 * PyLong_SHIFT) {
39743 return (
int) (((((((((int)digits[3]) << PyLong_SHIFT) | (
int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (
int)digits[0]));
39749 #if CYTHON_COMPILING_IN_CPYTHON
39750 if (unlikely(Py_SIZE(x) < 0)) {
39751 goto raise_neg_overflow;
39755 int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
39756 if (unlikely(result < 0))
39758 if (unlikely(result == 1))
39759 goto raise_neg_overflow;
39762 if (
sizeof(
int) <=
sizeof(
unsigned long)) {
39763 __PYX_VERIFY_RETURN_INT_EXC(
int,
unsigned long, PyLong_AsUnsignedLong(x))
39764 #ifdef HAVE_LONG_LONG
39765 }
else if (
sizeof(
int) <=
sizeof(
unsigned PY_LONG_LONG)) {
39766 __PYX_VERIFY_RETURN_INT_EXC(
int,
unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
39770 #if CYTHON_USE_PYLONG_INTERNALS
39771 const digit* digits = ((PyLongObject*)x)->ob_digit;
39772 switch (Py_SIZE(x)) {
39773 case 0:
return (
int) 0;
39774 case -1: __PYX_VERIFY_RETURN_INT(
int, sdigit, (sdigit) (-(sdigit)digits[0]))
39775 case 1: __PYX_VERIFY_RETURN_INT(
int, digit, +digits[0])
39777 if (8 *
sizeof(
int) - 1 > 1 * PyLong_SHIFT) {
39778 if (8 *
sizeof(
unsigned long) > 2 * PyLong_SHIFT) {
39779 __PYX_VERIFY_RETURN_INT(
int,
long, -(
long) (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
39780 }
else if (8 *
sizeof(
int) - 1 > 2 * PyLong_SHIFT) {
39781 return (
int) (((int)-1)*(((((int)digits[1]) << PyLong_SHIFT) | (
int)digits[0])));
39786 if (8 *
sizeof(
int) > 1 * PyLong_SHIFT) {
39787 if (8 *
sizeof(
unsigned long) > 2 * PyLong_SHIFT) {
39788 __PYX_VERIFY_RETURN_INT(
int,
unsigned long, (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
39789 }
else if (8 *
sizeof(
int) - 1 > 2 * PyLong_SHIFT) {
39790 return (
int) ((((((int)digits[1]) << PyLong_SHIFT) | (
int)digits[0])));
39795 if (8 *
sizeof(
int) - 1 > 2 * PyLong_SHIFT) {
39796 if (8 *
sizeof(
unsigned long) > 3 * PyLong_SHIFT) {
39797 __PYX_VERIFY_RETURN_INT(
int,
long, -(
long) (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
39798 }
else if (8 *
sizeof(
int) - 1 > 3 * PyLong_SHIFT) {
39799 return (
int) (((int)-1)*(((((((int)digits[2]) << PyLong_SHIFT) | (
int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
39804 if (8 *
sizeof(
int) > 2 * PyLong_SHIFT) {
39805 if (8 *
sizeof(
unsigned long) > 3 * PyLong_SHIFT) {
39806 __PYX_VERIFY_RETURN_INT(
int,
unsigned long, (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
39807 }
else if (8 *
sizeof(
int) - 1 > 3 * PyLong_SHIFT) {
39808 return (
int) ((((((((int)digits[2]) << PyLong_SHIFT) | (
int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
39813 if (8 *
sizeof(
int) - 1 > 3 * PyLong_SHIFT) {
39814 if (8 *
sizeof(
unsigned long) > 4 * PyLong_SHIFT) {
39815 __PYX_VERIFY_RETURN_INT(
int,
long, -(
long) (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
39816 }
else if (8 *
sizeof(
int) - 1 > 4 * PyLong_SHIFT) {
39817 return (
int) (((int)-1)*(((((((((int)digits[3]) << PyLong_SHIFT) | (
int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (
int)digits[0])));
39822 if (8 *
sizeof(
int) > 3 * PyLong_SHIFT) {
39823 if (8 *
sizeof(
unsigned long) > 4 * PyLong_SHIFT) {
39824 __PYX_VERIFY_RETURN_INT(
int,
unsigned long, (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
39825 }
else if (8 *
sizeof(
int) - 1 > 4 * PyLong_SHIFT) {
39826 return (
int) ((((((((((int)digits[3]) << PyLong_SHIFT) | (
int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (
int)digits[0])));
39832 if (
sizeof(
int) <=
sizeof(long)) {
39833 __PYX_VERIFY_RETURN_INT_EXC(
int,
long, PyLong_AsLong(x))
39834 #ifdef HAVE_LONG_LONG
39835 }
else if (
sizeof(
int) <=
sizeof(PY_LONG_LONG)) {
39836 __PYX_VERIFY_RETURN_INT_EXC(
int, PY_LONG_LONG, PyLong_AsLongLong(x))
39841 #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
39842 PyErr_SetString(PyExc_RuntimeError,
39843 "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
39846 PyObject *
v = __Pyx_PyNumber_IntOrLong(x);
39847 #if PY_MAJOR_VERSION < 3
39848 if (likely(
v) && !PyLong_Check(
v)) {
39850 v = PyNumber_Long(tmp);
39855 int one = 1;
int is_little = (int)*(
unsigned char *)&one;
39856 unsigned char *bytes = (
unsigned char *)&val;
39857 int ret = _PyLong_AsByteArray((PyLongObject *)
v,
39858 bytes,
sizeof(val),
39859 is_little, !is_unsigned);
39869 PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
39870 if (!tmp)
return (
int) -1;
39871 val = __Pyx_PyInt_As_int(tmp);
39876 PyErr_SetString(PyExc_OverflowError,
39877 "value too large to convert to int");
39879 raise_neg_overflow:
39880 PyErr_SetString(PyExc_OverflowError,
39881 "can't convert negative value to int");
39886 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(
int value) {
39887 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
39888 #pragma GCC diagnostic push
39889 #pragma GCC diagnostic ignored "-Wconversion"
39891 const int neg_one = (int) -1, const_zero = (
int) 0;
39892 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
39893 #pragma GCC diagnostic pop
39895 const int is_unsigned = neg_one > const_zero;
39897 if (
sizeof(
int) <
sizeof(long)) {
39898 return PyInt_FromLong((
long) value);
39899 }
else if (
sizeof(
int) <=
sizeof(
unsigned long)) {
39900 return PyLong_FromUnsignedLong((
unsigned long) value);
39901 #ifdef HAVE_LONG_LONG
39902 }
else if (
sizeof(
int) <=
sizeof(
unsigned PY_LONG_LONG)) {
39903 return PyLong_FromUnsignedLongLong((
unsigned PY_LONG_LONG) value);
39907 if (
sizeof(
int) <=
sizeof(
long)) {
39908 return PyInt_FromLong((
long) value);
39909 #ifdef HAVE_LONG_LONG
39910 }
else if (
sizeof(
int) <=
sizeof(PY_LONG_LONG)) {
39911 return PyLong_FromLongLong((PY_LONG_LONG) value);
39916 int one = 1;
int little = (int)*(
unsigned char *)&one;
39917 unsigned char *bytes = (
unsigned char *)&value;
39918 return _PyLong_FromByteArray(bytes,
sizeof(
int),
39919 little, !is_unsigned);
39924 static struct __pyx_typeinfo_string __Pyx_TypeInfoToFormat(__Pyx_TypeInfo *type) {
39925 struct __pyx_typeinfo_string result = { {0} };
39926 char *buf = (
char *) result.string;
39927 size_t size = type->size;
39928 switch (type->typegroup) {
39935 *buf = (type->is_unsigned) ?
'B' :
'b';
39936 else if (size == 2)
39937 *buf = (type->is_unsigned) ?
'H' :
'h';
39938 else if (size == 4)
39939 *buf = (type->is_unsigned) ?
'I' :
'i';
39940 else if (size == 8)
39941 *buf = (type->is_unsigned) ?
'Q' :
'q';
39948 __Pyx_TypeInfo complex_type = *type;
39949 complex_type.typegroup =
'R';
39950 complex_type.size /= 2;
39952 *buf = __Pyx_TypeInfoToFormat(&complex_type).string[0];
39958 else if (size == 8)
39968 #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION < 3
39969 static int __Pyx_PrintOne(PyObject*
f, PyObject *o) {
39971 if (!(
f = __Pyx_GetStdout()))
39975 if (PyFile_SoftSpace(
f, 0)) {
39976 if (PyFile_WriteString(
" ",
f) < 0)
39979 if (PyFile_WriteObject(o,
f, Py_PRINT_RAW) < 0)
39981 if (PyFile_WriteString(
"\n",
f) < 0)
39990 return __Pyx_Print(
f, NULL, 0);
39993 static int __Pyx_PrintOne(PyObject* stream, PyObject *o) {
39995 PyObject* arg_tuple = PyTuple_Pack(1, o);
39996 if (unlikely(!arg_tuple))
39998 res = __Pyx_Print(stream, arg_tuple, 1);
39999 Py_DECREF(arg_tuple);
40005 static __Pyx_memviewslice
40006 __pyx_memoryview_copy_new_contig(
const __Pyx_memviewslice *from_mvs,
40007 const char *mode,
int ndim,
40008 size_t sizeof_dtype,
int contig_flag,
40009 int dtype_is_object)
40011 __Pyx_RefNannyDeclarations
40013 __Pyx_memviewslice new_mvs = { 0, 0, { 0 }, { 0 }, { 0 } };
40014 struct __pyx_memoryview_obj *from_memview = from_mvs->memview;
40015 Py_buffer *buf = &from_memview->view;
40016 PyObject *shape_tuple = NULL;
40017 PyObject *temp_int = NULL;
40018 struct __pyx_array_obj *array_obj = NULL;
40019 struct __pyx_memoryview_obj *memview_obj = NULL;
40020 __Pyx_RefNannySetupContext(
"__pyx_memoryview_copy_new_contig", 0);
40021 for (i = 0; i < ndim; i++) {
40022 if (unlikely(from_mvs->suboffsets[i] >= 0)) {
40023 PyErr_Format(PyExc_ValueError,
"Cannot copy memoryview slice with "
40024 "indirect dimensions (axis %d)", i);
40028 shape_tuple = PyTuple_New(ndim);
40029 if (unlikely(!shape_tuple)) {
40032 __Pyx_GOTREF(shape_tuple);
40033 for(i = 0; i < ndim; i++) {
40034 temp_int = PyInt_FromSsize_t(from_mvs->shape[i]);
40035 if(unlikely(!temp_int)) {
40038 PyTuple_SET_ITEM(shape_tuple, i, temp_int);
40042 array_obj = __pyx_array_new(shape_tuple, sizeof_dtype, buf->format, (
char *) mode, NULL);
40043 if (unlikely(!array_obj)) {
40046 __Pyx_GOTREF(array_obj);
40047 memview_obj = (
struct __pyx_memoryview_obj *) __pyx_memoryview_new(
40048 (PyObject *) array_obj, contig_flag,
40050 from_mvs->memview->typeinfo);
40051 if (unlikely(!memview_obj))
40053 if (unlikely(__Pyx_init_memviewslice(memview_obj, ndim, &new_mvs, 1) < 0))
40055 if (unlikely(__pyx_memoryview_copy_contents(*from_mvs, new_mvs, ndim, ndim,
40056 dtype_is_object) < 0))
40060 __Pyx_XDECREF(new_mvs.memview);
40061 new_mvs.memview = NULL;
40062 new_mvs.data = NULL;
40064 __Pyx_XDECREF(shape_tuple);
40065 __Pyx_XDECREF(temp_int);
40066 __Pyx_XDECREF(array_obj);
40067 __Pyx_RefNannyFinishContext();
40073 __Pyx_init_memviewslice(
struct __pyx_memoryview_obj *memview,
40075 __Pyx_memviewslice *memviewslice,
40076 int memview_is_new_reference)
40078 __Pyx_RefNannyDeclarations
40080 Py_buffer *buf = &memview->view;
40081 __Pyx_RefNannySetupContext(
"init_memviewslice", 0);
40082 if (unlikely(memviewslice->memview || memviewslice->data)) {
40083 PyErr_SetString(PyExc_ValueError,
40084 "memviewslice is already initialized!");
40087 if (buf->strides) {
40088 for (i = 0; i < ndim; i++) {
40089 memviewslice->strides[i] = buf->strides[i];
40092 Py_ssize_t stride = buf->itemsize;
40093 for (i = ndim - 1; i >= 0; i--) {
40094 memviewslice->strides[i] = stride;
40095 stride *= buf->shape[i];
40098 for (i = 0; i < ndim; i++) {
40099 memviewslice->shape[i] = buf->shape[i];
40100 if (buf->suboffsets) {
40101 memviewslice->suboffsets[i] = buf->suboffsets[i];
40103 memviewslice->suboffsets[i] = -1;
40106 memviewslice->memview = memview;
40107 memviewslice->data = (
char *)buf->buf;
40108 if (__pyx_add_acquisition_count(memview) == 0 && !memview_is_new_reference) {
40109 Py_INCREF(memview);
40114 memviewslice->memview = 0;
40115 memviewslice->data = 0;
40118 __Pyx_RefNannyFinishContext();
40121 #ifndef Py_NO_RETURN
40122 #define Py_NO_RETURN
40124 static void __pyx_fatalerror(
const char *fmt, ...) Py_NO_RETURN {
40127 #ifdef HAVE_STDARG_PROTOTYPES
40128 va_start(vargs, fmt);
40132 vsnprintf(msg, 200, fmt, vargs);
40134 Py_FatalError(msg);
40136 static CYTHON_INLINE
int
40137 __pyx_add_acquisition_count_locked(__pyx_atomic_int *acquisition_count,
40138 PyThread_type_lock lock)
40141 PyThread_acquire_lock(lock, 1);
40142 result = (*acquisition_count)++;
40143 PyThread_release_lock(lock);
40146 static CYTHON_INLINE
int
40147 __pyx_sub_acquisition_count_locked(__pyx_atomic_int *acquisition_count,
40148 PyThread_type_lock lock)
40151 PyThread_acquire_lock(lock, 1);
40152 result = (*acquisition_count)--;
40153 PyThread_release_lock(lock);
40156 static CYTHON_INLINE
void
40157 __Pyx_INC_MEMVIEW(__Pyx_memviewslice *memslice,
int have_gil,
int lineno)
40160 struct __pyx_memoryview_obj *memview = memslice->memview;
40161 if (unlikely(!memview || (PyObject *) memview == Py_None))
40163 if (unlikely(__pyx_get_slice_count(memview) < 0))
40164 __pyx_fatalerror(
"Acquisition count is %d (line %d)",
40165 __pyx_get_slice_count(memview), lineno);
40166 first_time = __pyx_add_acquisition_count(memview) == 0;
40167 if (unlikely(first_time)) {
40169 Py_INCREF((PyObject *) memview);
40171 PyGILState_STATE _gilstate = PyGILState_Ensure();
40172 Py_INCREF((PyObject *) memview);
40173 PyGILState_Release(_gilstate);
40177 static CYTHON_INLINE
void __Pyx_XDEC_MEMVIEW(__Pyx_memviewslice *memslice,
40178 int have_gil,
int lineno) {
40180 struct __pyx_memoryview_obj *memview = memslice->memview;
40181 if (unlikely(!memview || (PyObject *) memview == Py_None)) {
40182 memslice->memview = NULL;
40185 if (unlikely(__pyx_get_slice_count(memview) <= 0))
40186 __pyx_fatalerror(
"Acquisition count is %d (line %d)",
40187 __pyx_get_slice_count(memview), lineno);
40188 last_time = __pyx_sub_acquisition_count(memview) == 1;
40189 memslice->data = NULL;
40190 if (unlikely(last_time)) {
40192 Py_CLEAR(memslice->memview);
40194 PyGILState_STATE _gilstate = PyGILState_Ensure();
40195 Py_CLEAR(memslice->memview);
40196 PyGILState_Release(_gilstate);
40199 memslice->memview = NULL;
40204 static CYTHON_INLINE
long __Pyx_PyInt_As_long(PyObject *x) {
40205 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
40206 #pragma GCC diagnostic push
40207 #pragma GCC diagnostic ignored "-Wconversion"
40209 const long neg_one = (long) -1, const_zero = (
long) 0;
40210 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
40211 #pragma GCC diagnostic pop
40213 const int is_unsigned = neg_one > const_zero;
40214 #if PY_MAJOR_VERSION < 3
40215 if (likely(PyInt_Check(x))) {
40216 if (
sizeof(
long) <
sizeof(long)) {
40217 __PYX_VERIFY_RETURN_INT(
long,
long, PyInt_AS_LONG(x))
40219 long val = PyInt_AS_LONG(x);
40220 if (is_unsigned && unlikely(val < 0)) {
40221 goto raise_neg_overflow;
40227 if (likely(PyLong_Check(x))) {
40229 #if CYTHON_USE_PYLONG_INTERNALS
40230 const digit* digits = ((PyLongObject*)x)->ob_digit;
40231 switch (Py_SIZE(x)) {
40232 case 0:
return (
long) 0;
40233 case 1: __PYX_VERIFY_RETURN_INT(
long, digit, digits[0])
40235 if (8 *
sizeof(
long) > 1 * PyLong_SHIFT) {
40236 if (8 *
sizeof(
unsigned long) > 2 * PyLong_SHIFT) {
40237 __PYX_VERIFY_RETURN_INT(
long,
unsigned long, (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40238 }
else if (8 *
sizeof(
long) >= 2 * PyLong_SHIFT) {
40239 return (
long) (((((long)digits[1]) << PyLong_SHIFT) | (
long)digits[0]));
40244 if (8 *
sizeof(
long) > 2 * PyLong_SHIFT) {
40245 if (8 *
sizeof(
unsigned long) > 3 * PyLong_SHIFT) {
40246 __PYX_VERIFY_RETURN_INT(
long,
unsigned long, (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40247 }
else if (8 *
sizeof(
long) >= 3 * PyLong_SHIFT) {
40248 return (
long) (((((((long)digits[2]) << PyLong_SHIFT) | (
long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
40253 if (8 *
sizeof(
long) > 3 * PyLong_SHIFT) {
40254 if (8 *
sizeof(
unsigned long) > 4 * PyLong_SHIFT) {
40255 __PYX_VERIFY_RETURN_INT(
long,
unsigned long, (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40256 }
else if (8 *
sizeof(
long) >= 4 * PyLong_SHIFT) {
40257 return (
long) (((((((((long)digits[3]) << PyLong_SHIFT) | (
long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (
long)digits[0]));
40263 #if CYTHON_COMPILING_IN_CPYTHON
40264 if (unlikely(Py_SIZE(x) < 0)) {
40265 goto raise_neg_overflow;
40269 int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
40270 if (unlikely(result < 0))
40272 if (unlikely(result == 1))
40273 goto raise_neg_overflow;
40276 if (
sizeof(
long) <=
sizeof(
unsigned long)) {
40277 __PYX_VERIFY_RETURN_INT_EXC(
long,
unsigned long, PyLong_AsUnsignedLong(x))
40278 #ifdef HAVE_LONG_LONG
40279 }
else if (
sizeof(
long) <=
sizeof(
unsigned PY_LONG_LONG)) {
40280 __PYX_VERIFY_RETURN_INT_EXC(
long,
unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
40284 #if CYTHON_USE_PYLONG_INTERNALS
40285 const digit* digits = ((PyLongObject*)x)->ob_digit;
40286 switch (Py_SIZE(x)) {
40287 case 0:
return (
long) 0;
40288 case -1: __PYX_VERIFY_RETURN_INT(
long, sdigit, (sdigit) (-(sdigit)digits[0]))
40289 case 1: __PYX_VERIFY_RETURN_INT(
long, digit, +digits[0])
40291 if (8 *
sizeof(
long) - 1 > 1 * PyLong_SHIFT) {
40292 if (8 *
sizeof(
unsigned long) > 2 * PyLong_SHIFT) {
40293 __PYX_VERIFY_RETURN_INT(
long,
long, -(
long) (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40294 }
else if (8 *
sizeof(
long) - 1 > 2 * PyLong_SHIFT) {
40295 return (
long) (((long)-1)*(((((long)digits[1]) << PyLong_SHIFT) | (
long)digits[0])));
40300 if (8 *
sizeof(
long) > 1 * PyLong_SHIFT) {
40301 if (8 *
sizeof(
unsigned long) > 2 * PyLong_SHIFT) {
40302 __PYX_VERIFY_RETURN_INT(
long,
unsigned long, (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40303 }
else if (8 *
sizeof(
long) - 1 > 2 * PyLong_SHIFT) {
40304 return (
long) ((((((long)digits[1]) << PyLong_SHIFT) | (
long)digits[0])));
40309 if (8 *
sizeof(
long) - 1 > 2 * PyLong_SHIFT) {
40310 if (8 *
sizeof(
unsigned long) > 3 * PyLong_SHIFT) {
40311 __PYX_VERIFY_RETURN_INT(
long,
long, -(
long) (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40312 }
else if (8 *
sizeof(
long) - 1 > 3 * PyLong_SHIFT) {
40313 return (
long) (((long)-1)*(((((((long)digits[2]) << PyLong_SHIFT) | (
long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
40318 if (8 *
sizeof(
long) > 2 * PyLong_SHIFT) {
40319 if (8 *
sizeof(
unsigned long) > 3 * PyLong_SHIFT) {
40320 __PYX_VERIFY_RETURN_INT(
long,
unsigned long, (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40321 }
else if (8 *
sizeof(
long) - 1 > 3 * PyLong_SHIFT) {
40322 return (
long) ((((((((long)digits[2]) << PyLong_SHIFT) | (
long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
40327 if (8 *
sizeof(
long) - 1 > 3 * PyLong_SHIFT) {
40328 if (8 *
sizeof(
unsigned long) > 4 * PyLong_SHIFT) {
40329 __PYX_VERIFY_RETURN_INT(
long,
long, -(
long) (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40330 }
else if (8 *
sizeof(
long) - 1 > 4 * PyLong_SHIFT) {
40331 return (
long) (((long)-1)*(((((((((long)digits[3]) << PyLong_SHIFT) | (
long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (
long)digits[0])));
40336 if (8 *
sizeof(
long) > 3 * PyLong_SHIFT) {
40337 if (8 *
sizeof(
unsigned long) > 4 * PyLong_SHIFT) {
40338 __PYX_VERIFY_RETURN_INT(
long,
unsigned long, (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40339 }
else if (8 *
sizeof(
long) - 1 > 4 * PyLong_SHIFT) {
40340 return (
long) ((((((((((long)digits[3]) << PyLong_SHIFT) | (
long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (
long)digits[0])));
40346 if (
sizeof(
long) <=
sizeof(long)) {
40347 __PYX_VERIFY_RETURN_INT_EXC(
long,
long, PyLong_AsLong(x))
40348 #ifdef HAVE_LONG_LONG
40349 }
else if (
sizeof(
long) <=
sizeof(PY_LONG_LONG)) {
40350 __PYX_VERIFY_RETURN_INT_EXC(
long, PY_LONG_LONG, PyLong_AsLongLong(x))
40355 #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
40356 PyErr_SetString(PyExc_RuntimeError,
40357 "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
40360 PyObject *
v = __Pyx_PyNumber_IntOrLong(x);
40361 #if PY_MAJOR_VERSION < 3
40362 if (likely(
v) && !PyLong_Check(
v)) {
40364 v = PyNumber_Long(tmp);
40369 int one = 1;
int is_little = (int)*(
unsigned char *)&one;
40370 unsigned char *bytes = (
unsigned char *)&val;
40371 int ret = _PyLong_AsByteArray((PyLongObject *)
v,
40372 bytes,
sizeof(val),
40373 is_little, !is_unsigned);
40383 PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
40384 if (!tmp)
return (
long) -1;
40385 val = __Pyx_PyInt_As_long(tmp);
40390 PyErr_SetString(PyExc_OverflowError,
40391 "value too large to convert to long");
40393 raise_neg_overflow:
40394 PyErr_SetString(PyExc_OverflowError,
40395 "can't convert negative value to long");
40400 static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(
long value) {
40401 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
40402 #pragma GCC diagnostic push
40403 #pragma GCC diagnostic ignored "-Wconversion"
40405 const long neg_one = (long) -1, const_zero = (
long) 0;
40406 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
40407 #pragma GCC diagnostic pop
40409 const int is_unsigned = neg_one > const_zero;
40411 if (
sizeof(
long) <
sizeof(long)) {
40412 return PyInt_FromLong((
long) value);
40413 }
else if (
sizeof(
long) <=
sizeof(
unsigned long)) {
40414 return PyLong_FromUnsignedLong((
unsigned long) value);
40415 #ifdef HAVE_LONG_LONG
40416 }
else if (
sizeof(
long) <=
sizeof(
unsigned PY_LONG_LONG)) {
40417 return PyLong_FromUnsignedLongLong((
unsigned PY_LONG_LONG) value);
40421 if (
sizeof(
long) <=
sizeof(
long)) {
40422 return PyInt_FromLong((
long) value);
40423 #ifdef HAVE_LONG_LONG
40424 }
else if (
sizeof(
long) <=
sizeof(PY_LONG_LONG)) {
40425 return PyLong_FromLongLong((PY_LONG_LONG) value);
40430 int one = 1;
int little = (int)*(
unsigned char *)&one;
40431 unsigned char *bytes = (
unsigned char *)&value;
40432 return _PyLong_FromByteArray(bytes,
sizeof(
long),
40433 little, !is_unsigned);
40438 static CYTHON_INLINE
char __Pyx_PyInt_As_char(PyObject *x) {
40439 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
40440 #pragma GCC diagnostic push
40441 #pragma GCC diagnostic ignored "-Wconversion"
40443 const char neg_one = (char) -1, const_zero = (
char) 0;
40444 #ifdef __Pyx_HAS_GCC_DIAGNOSTIC
40445 #pragma GCC diagnostic pop
40447 const int is_unsigned = neg_one > const_zero;
40448 #if PY_MAJOR_VERSION < 3
40449 if (likely(PyInt_Check(x))) {
40450 if (
sizeof(
char) <
sizeof(long)) {
40451 __PYX_VERIFY_RETURN_INT(
char,
long, PyInt_AS_LONG(x))
40453 long val = PyInt_AS_LONG(x);
40454 if (is_unsigned && unlikely(val < 0)) {
40455 goto raise_neg_overflow;
40461 if (likely(PyLong_Check(x))) {
40463 #if CYTHON_USE_PYLONG_INTERNALS
40464 const digit* digits = ((PyLongObject*)x)->ob_digit;
40465 switch (Py_SIZE(x)) {
40466 case 0:
return (
char) 0;
40467 case 1: __PYX_VERIFY_RETURN_INT(
char, digit, digits[0])
40469 if (8 *
sizeof(
char) > 1 * PyLong_SHIFT) {
40470 if (8 *
sizeof(
unsigned long) > 2 * PyLong_SHIFT) {
40471 __PYX_VERIFY_RETURN_INT(
char,
unsigned long, (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40472 }
else if (8 *
sizeof(
char) >= 2 * PyLong_SHIFT) {
40473 return (
char) (((((char)digits[1]) << PyLong_SHIFT) | (
char)digits[0]));
40478 if (8 *
sizeof(
char) > 2 * PyLong_SHIFT) {
40479 if (8 *
sizeof(
unsigned long) > 3 * PyLong_SHIFT) {
40480 __PYX_VERIFY_RETURN_INT(
char,
unsigned long, (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40481 }
else if (8 *
sizeof(
char) >= 3 * PyLong_SHIFT) {
40482 return (
char) (((((((char)digits[2]) << PyLong_SHIFT) | (
char)digits[1]) << PyLong_SHIFT) | (char)digits[0]));
40487 if (8 *
sizeof(
char) > 3 * PyLong_SHIFT) {
40488 if (8 *
sizeof(
unsigned long) > 4 * PyLong_SHIFT) {
40489 __PYX_VERIFY_RETURN_INT(
char,
unsigned long, (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40490 }
else if (8 *
sizeof(
char) >= 4 * PyLong_SHIFT) {
40491 return (
char) (((((((((char)digits[3]) << PyLong_SHIFT) | (
char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (
char)digits[0]));
40497 #if CYTHON_COMPILING_IN_CPYTHON
40498 if (unlikely(Py_SIZE(x) < 0)) {
40499 goto raise_neg_overflow;
40503 int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
40504 if (unlikely(result < 0))
40506 if (unlikely(result == 1))
40507 goto raise_neg_overflow;
40510 if (
sizeof(
char) <=
sizeof(
unsigned long)) {
40511 __PYX_VERIFY_RETURN_INT_EXC(
char,
unsigned long, PyLong_AsUnsignedLong(x))
40512 #ifdef HAVE_LONG_LONG
40513 }
else if (
sizeof(
char) <=
sizeof(
unsigned PY_LONG_LONG)) {
40514 __PYX_VERIFY_RETURN_INT_EXC(
char,
unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
40518 #if CYTHON_USE_PYLONG_INTERNALS
40519 const digit* digits = ((PyLongObject*)x)->ob_digit;
40520 switch (Py_SIZE(x)) {
40521 case 0:
return (
char) 0;
40522 case -1: __PYX_VERIFY_RETURN_INT(
char, sdigit, (sdigit) (-(sdigit)digits[0]))
40523 case 1: __PYX_VERIFY_RETURN_INT(
char, digit, +digits[0])
40525 if (8 *
sizeof(
char) - 1 > 1 * PyLong_SHIFT) {
40526 if (8 *
sizeof(
unsigned long) > 2 * PyLong_SHIFT) {
40527 __PYX_VERIFY_RETURN_INT(
char,
long, -(
long) (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40528 }
else if (8 *
sizeof(
char) - 1 > 2 * PyLong_SHIFT) {
40529 return (
char) (((char)-1)*(((((char)digits[1]) << PyLong_SHIFT) | (
char)digits[0])));
40534 if (8 *
sizeof(
char) > 1 * PyLong_SHIFT) {
40535 if (8 *
sizeof(
unsigned long) > 2 * PyLong_SHIFT) {
40536 __PYX_VERIFY_RETURN_INT(
char,
unsigned long, (((((
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40537 }
else if (8 *
sizeof(
char) - 1 > 2 * PyLong_SHIFT) {
40538 return (
char) ((((((char)digits[1]) << PyLong_SHIFT) | (
char)digits[0])));
40543 if (8 *
sizeof(
char) - 1 > 2 * PyLong_SHIFT) {
40544 if (8 *
sizeof(
unsigned long) > 3 * PyLong_SHIFT) {
40545 __PYX_VERIFY_RETURN_INT(
char,
long, -(
long) (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40546 }
else if (8 *
sizeof(
char) - 1 > 3 * PyLong_SHIFT) {
40547 return (
char) (((char)-1)*(((((((char)digits[2]) << PyLong_SHIFT) | (
char)digits[1]) << PyLong_SHIFT) | (char)digits[0])));
40552 if (8 *
sizeof(
char) > 2 * PyLong_SHIFT) {
40553 if (8 *
sizeof(
unsigned long) > 3 * PyLong_SHIFT) {
40554 __PYX_VERIFY_RETURN_INT(
char,
unsigned long, (((((((
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40555 }
else if (8 *
sizeof(
char) - 1 > 3 * PyLong_SHIFT) {
40556 return (
char) ((((((((char)digits[2]) << PyLong_SHIFT) | (
char)digits[1]) << PyLong_SHIFT) | (char)digits[0])));
40561 if (8 *
sizeof(
char) - 1 > 3 * PyLong_SHIFT) {
40562 if (8 *
sizeof(
unsigned long) > 4 * PyLong_SHIFT) {
40563 __PYX_VERIFY_RETURN_INT(
char,
long, -(
long) (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40564 }
else if (8 *
sizeof(
char) - 1 > 4 * PyLong_SHIFT) {
40565 return (
char) (((char)-1)*(((((((((char)digits[3]) << PyLong_SHIFT) | (
char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (
char)digits[0])));
40570 if (8 *
sizeof(
char) > 3 * PyLong_SHIFT) {
40571 if (8 *
sizeof(
unsigned long) > 4 * PyLong_SHIFT) {
40572 __PYX_VERIFY_RETURN_INT(
char,
unsigned long, (((((((((
unsigned long)digits[3]) << PyLong_SHIFT) | (
unsigned long)digits[2]) << PyLong_SHIFT) | (
unsigned long)digits[1]) << PyLong_SHIFT) | (
unsigned long)digits[0])))
40573 }
else if (8 *
sizeof(
char) - 1 > 4 * PyLong_SHIFT) {
40574 return (
char) ((((((((((char)digits[3]) << PyLong_SHIFT) | (
char)digits[2]) << PyLong_SHIFT) | (char)digits[1]) << PyLong_SHIFT) | (
char)digits[0])));
40580 if (
sizeof(
char) <=
sizeof(long)) {
40581 __PYX_VERIFY_RETURN_INT_EXC(
char,
long, PyLong_AsLong(x))
40582 #ifdef HAVE_LONG_LONG
40583 }
else if (
sizeof(
char) <=
sizeof(PY_LONG_LONG)) {
40584 __PYX_VERIFY_RETURN_INT_EXC(
char, PY_LONG_LONG, PyLong_AsLongLong(x))
40589 #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
40590 PyErr_SetString(PyExc_RuntimeError,
40591 "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
40594 PyObject *
v = __Pyx_PyNumber_IntOrLong(x);
40595 #if PY_MAJOR_VERSION < 3
40596 if (likely(
v) && !PyLong_Check(
v)) {
40598 v = PyNumber_Long(tmp);
40603 int one = 1;
int is_little = (int)*(
unsigned char *)&one;
40604 unsigned char *bytes = (
unsigned char *)&val;
40605 int ret = _PyLong_AsByteArray((PyLongObject *)
v,
40606 bytes,
sizeof(val),
40607 is_little, !is_unsigned);
40617 PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
40618 if (!tmp)
return (
char) -1;
40619 val = __Pyx_PyInt_As_char(tmp);
40624 PyErr_SetString(PyExc_OverflowError,
40625 "value too large to convert to char");
40627 raise_neg_overflow:
40628 PyErr_SetString(PyExc_OverflowError,
40629 "can't convert negative value to char");
40634 static int __Pyx_check_binary_version(
void) {
40636 int same=1, i, found_dot;
40637 const char* rt_from_call = Py_GetVersion();
40638 PyOS_snprintf(ctversion, 5,
"%d.%d", PY_MAJOR_VERSION, PY_MINOR_VERSION);
40640 for (i = 0; i < 4; i++) {
40641 if (!ctversion[i]) {
40642 same = (rt_from_call[i] <
'0' || rt_from_call[i] >
'9');
40645 if (rt_from_call[i] != ctversion[i]) {
40651 char rtversion[5] = {
'\0'};
40653 for (i=0; i<4; ++i) {
40654 if (rt_from_call[i] ==
'.') {
40655 if (found_dot)
break;
40657 }
else if (rt_from_call[i] <
'0' || rt_from_call[i] >
'9') {
40660 rtversion[i] = rt_from_call[i];
40662 PyOS_snprintf(message,
sizeof(message),
40663 "compiletime version %s of module '%.100s' "
40664 "does not match runtime version %s",
40665 ctversion, __Pyx_MODULE_NAME, rtversion);
40666 return PyErr_WarnEx(NULL, message, 1);
40672 static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) {
40674 #if PY_MAJOR_VERSION < 3
40675 if (t->is_unicode) {
40676 *t->p = PyUnicode_DecodeUTF8(t->s, t->n - 1, NULL);
40677 }
else if (t->intern) {
40678 *t->p = PyString_InternFromString(t->s);
40680 *t->p = PyString_FromStringAndSize(t->s, t->n - 1);
40683 if (t->is_unicode | t->is_str) {
40685 *t->p = PyUnicode_InternFromString(t->s);
40686 }
else if (t->encoding) {
40687 *t->p = PyUnicode_Decode(t->s, t->n - 1, t->encoding, NULL);
40689 *t->p = PyUnicode_FromStringAndSize(t->s, t->n - 1);
40692 *t->p = PyBytes_FromStringAndSize(t->s, t->n - 1);
40697 if (PyObject_Hash(*t->p) == -1)
40704 static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(
const char* c_str) {
40705 return __Pyx_PyUnicode_FromStringAndSize(c_str, (Py_ssize_t)strlen(c_str));
40707 static CYTHON_INLINE
const char* __Pyx_PyObject_AsString(PyObject* o) {
40709 return __Pyx_PyObject_AsStringAndSize(o, &ignore);
40711 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
40712 #if !CYTHON_PEP393_ENABLED
40713 static const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
40715 PyObject* defenc = _PyUnicode_AsDefaultEncodedString(o, NULL);
40716 if (!defenc)
return NULL;
40717 defenc_c = PyBytes_AS_STRING(defenc);
40718 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
40720 char* end = defenc_c + PyBytes_GET_SIZE(defenc);
40722 for (
c = defenc_c;
c < end;
c++) {
40723 if ((
unsigned char) (*
c) >= 128) {
40724 PyUnicode_AsASCIIString(o);
40730 *length = PyBytes_GET_SIZE(defenc);
40734 static CYTHON_INLINE
const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
40735 if (unlikely(__Pyx_PyUnicode_READY(o) == -1))
return NULL;
40736 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
40737 if (likely(PyUnicode_IS_ASCII(o))) {
40738 *length = PyUnicode_GET_LENGTH(o);
40739 return PyUnicode_AsUTF8(o);
40741 PyUnicode_AsASCIIString(o);
40745 return PyUnicode_AsUTF8AndSize(o, length);
40750 static CYTHON_INLINE
const char* __Pyx_PyObject_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
40751 #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
40753 #
if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
40754 __Pyx_sys_getdefaultencoding_not_ascii &&
40756 PyUnicode_Check(o)) {
40757 return __Pyx_PyUnicode_AsStringAndSize(o, length);
40760 #if (!CYTHON_COMPILING_IN_PYPY) || (defined(PyByteArray_AS_STRING) && defined(PyByteArray_GET_SIZE))
40761 if (PyByteArray_Check(o)) {
40762 *length = PyByteArray_GET_SIZE(o);
40763 return PyByteArray_AS_STRING(o);
40768 int r = PyBytes_AsStringAndSize(o, &result, length);
40769 if (unlikely(
r < 0)) {
40776 static CYTHON_INLINE
int __Pyx_PyObject_IsTrue(PyObject* x) {
40777 int is_true = x == Py_True;
40778 if (is_true | (x == Py_False) | (x == Py_None))
return is_true;
40779 else return PyObject_IsTrue(x);
40781 static CYTHON_INLINE
int __Pyx_PyObject_IsTrueAndDecref(PyObject* x) {
40783 if (unlikely(!x))
return -1;
40784 retval = __Pyx_PyObject_IsTrue(x);
40788 static PyObject* __Pyx_PyNumber_IntOrLongWrongResultType(PyObject* result,
const char* type_name) {
40789 #if PY_MAJOR_VERSION >= 3
40790 if (PyLong_Check(result)) {
40791 if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1,
40792 "__int__ returned non-int (type %.200s). "
40793 "The ability to return an instance of a strict subclass of int "
40794 "is deprecated, and may be removed in a future version of Python.",
40795 Py_TYPE(result)->tp_name)) {
40802 PyErr_Format(PyExc_TypeError,
40803 "__%.4s__ returned non-%.4s (type %.200s)",
40804 type_name, type_name, Py_TYPE(result)->tp_name);
40808 static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x) {
40809 #if CYTHON_USE_TYPE_SLOTS
40810 PyNumberMethods *m;
40812 const char *name = NULL;
40813 PyObject *res = NULL;
40814 #if PY_MAJOR_VERSION < 3
40815 if (likely(PyInt_Check(x) || PyLong_Check(x)))
40817 if (likely(PyLong_Check(x)))
40819 return __Pyx_NewRef(x);
40820 #if CYTHON_USE_TYPE_SLOTS
40821 m = Py_TYPE(x)->tp_as_number;
40822 #if PY_MAJOR_VERSION < 3
40823 if (m && m->nb_int) {
40825 res = m->nb_int(x);
40827 else if (m && m->nb_long) {
40829 res = m->nb_long(x);
40832 if (likely(m && m->nb_int)) {
40834 res = m->nb_int(x);
40838 if (!PyBytes_CheckExact(x) && !PyUnicode_CheckExact(x)) {
40839 res = PyNumber_Int(x);
40843 #if PY_MAJOR_VERSION < 3
40844 if (unlikely(!PyInt_Check(res) && !PyLong_Check(res))) {
40846 if (unlikely(!PyLong_CheckExact(res))) {
40848 return __Pyx_PyNumber_IntOrLongWrongResultType(res, name);
40851 else if (!PyErr_Occurred()) {
40852 PyErr_SetString(PyExc_TypeError,
40853 "an integer is required");
40857 static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) {
40860 #if PY_MAJOR_VERSION < 3
40861 if (likely(PyInt_CheckExact(b))) {
40862 if (
sizeof(Py_ssize_t) >=
sizeof(
long))
40863 return PyInt_AS_LONG(b);
40865 return PyInt_AsSsize_t(b);
40868 if (likely(PyLong_CheckExact(b))) {
40869 #if CYTHON_USE_PYLONG_INTERNALS
40870 const digit* digits = ((PyLongObject*)b)->ob_digit;
40871 const Py_ssize_t size = Py_SIZE(b);
40872 if (likely(__Pyx_sst_abs(size) <= 1)) {
40873 ival = likely(size) ? digits[0] : 0;
40874 if (size == -1) ival = -ival;
40879 if (8 *
sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
40880 return (Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (
size_t)digits[0]));
40884 if (8 *
sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
40885 return -(Py_ssize_t) (((((
size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
40889 if (8 *
sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
40890 return (Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (
size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
40894 if (8 *
sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
40895 return -(Py_ssize_t) (((((((
size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (
size_t)digits[0]));
40899 if (8 *
sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
40900 return (Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (
size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (
size_t)digits[0]));
40904 if (8 *
sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
40905 return -(Py_ssize_t) (((((((((
size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (
size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
40911 return PyLong_AsSsize_t(b);
40913 x = PyNumber_Index(b);
40915 ival = PyInt_AsSsize_t(x);
40919 static CYTHON_INLINE Py_hash_t __Pyx_PyIndex_AsHash_t(PyObject* o) {
40920 if (
sizeof(Py_hash_t) ==
sizeof(Py_ssize_t)) {
40921 return (Py_hash_t) __Pyx_PyIndex_AsSsize_t(o);
40922 #if PY_MAJOR_VERSION < 3
40923 }
else if (likely(PyInt_CheckExact(o))) {
40924 return PyInt_AS_LONG(o);
40929 x = PyNumber_Index(o);
40931 ival = PyInt_AsLong(x);
40936 static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(
long b) {
40937 return b ? __Pyx_NewRef(Py_True) : __Pyx_NewRef(Py_False);
40939 static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(
size_t ival) {
40940 return PyInt_FromSize_t(ival);