[Yt-svn] yt-commit r1575 - in trunk/yt: . _amr_utils extensions/volume_rendering lagos
mturk at wrangler.dreamhost.com
mturk at wrangler.dreamhost.com
Thu Jan 14 00:02:14 PST 2010
Author: mturk
Date: Thu Jan 14 00:02:09 2010
New Revision: 1575
URL: http://yt.enzotools.org/changeset/1575
Log:
Updates from hg:
* Close #235 by changing fields to log interpolation, fixing int overflow in
FillRegion and using rint in the Python code.
* Grid homogenization/partitioning is now much faster and creates far fewer
bricks. This shows up in the volume rendering.
Modified:
trunk/yt/_amr_utils/VolumeIntegrator.pyx
trunk/yt/amr_utils.c
trunk/yt/extensions/volume_rendering/grid_partitioner.py
trunk/yt/lagos/BaseDataTypes.py
trunk/yt/lagos/PointCombine.c
Modified: trunk/yt/_amr_utils/VolumeIntegrator.pyx
==============================================================================
--- trunk/yt/_amr_utils/VolumeIntegrator.pyx (original)
+++ trunk/yt/_amr_utils/VolumeIntegrator.pyx Thu Jan 14 00:02:09 2010
@@ -58,6 +58,7 @@
double ceil(double x)
double fmod(double x, double y)
double log2(double x)
+ long int lrint(double x)
cdef extern from "FixedInterpolator.h":
np.float64_t fast_interpolate(int *ds, int *ci, np.float64_t *dp,
@@ -382,3 +383,113 @@
dp[i] = fclip(fmod(cp[i], self.dds[i])/self.dds[i], 0, 1.0)
dv = trilinear_interpolate(self.dims, ci, dp, self.data)
tf.eval_transfer(dt, dv, rgba)
+
+cdef class GridFace:
+ cdef int direction
+ cdef public np.float64_t coord
+ cdef np.float64_t left_edge[3]
+ cdef np.float64_t right_edge[3]
+
+ @cython.boundscheck(False)
+ @cython.wraparound(False)
+ def __init__(self, grid, int direction, int left):
+ self.direction = direction
+ if left == 1:
+ self.coord = grid.LeftEdge[direction]
+ else:
+ self.coord = grid.RightEdge[direction]
+ cdef int i
+ for i in range(3):
+ self.left_edge[i] = grid.LeftEdge[i]
+ self.right_edge[i] = grid.RightEdge[i]
+ self.left_edge[direction] = self.right_edge[direction] = self.coord
+
+ @cython.boundscheck(False)
+ @cython.wraparound(False)
+ cdef int proj_overlap(self, np.float64_t *left_edge, np.float64_t *right_edge):
+ cdef int xax, yax
+ xax = (self.direction + 1) % 3
+ yax = (self.direction + 2) % 3
+ if left_edge[xax] >= self.right_edge[xax]: return 0
+ if right_edge[xax] <= self.left_edge[xax]: return 0
+ if left_edge[yax] >= self.right_edge[yax]: return 0
+ if right_edge[yax] <= self.left_edge[yax]: return 0
+ return 1
+
+cdef class ProtoPrism:
+ cdef np.float64_t left_edge[3]
+ cdef np.float64_t right_edge[3]
+ cdef public object LeftEdge
+ cdef public object RightEdge
+ cdef public object subgrid_faces
+ def __cinit__(self, np.ndarray[np.float64_t, ndim=1] left_edge,
+ np.ndarray[np.float64_t, ndim=1] right_edge,
+ subgrid_faces):
+ cdef int i
+ self.LeftEdge = left_edge
+ self.RightEdge = right_edge
+ for i in range(3):
+ self.left_edge[i] = left_edge[i]
+ self.right_edge[i] = right_edge[i]
+ self.subgrid_faces = subgrid_faces
+
+ @cython.boundscheck(False)
+ @cython.wraparound(False)
+ def sweep(self, int direction = 0, int stack = 0):
+ cdef int i
+ cdef GridFace face
+ cdef np.float64_t proto_split[3]
+ for i in range(3): proto_split[i] = self.right_edge[i]
+ for face in self.subgrid_faces[direction]:
+ proto_split[direction] = face.coord
+ if proto_split[direction] <= self.left_edge[direction]:
+ continue
+ if proto_split[direction] == self.right_edge[direction]:
+ if stack == 2: return [self]
+ return self.sweep((direction + 1) % 3, stack + 1)
+ if face.proj_overlap(self.left_edge, proto_split) == 1:
+ left, right = self.split(proto_split, direction)
+ LC = left.sweep((direction + 1) % 3)
+ RC = right.sweep(direction)
+ return LC + RC
+ raise RuntimeError
+
+ @cython.boundscheck(False)
+ @cython.wraparound(False)
+ cdef object split(self, np.float64_t *sp, int direction):
+ cdef int i
+ cdef np.ndarray split_left = self.LeftEdge.copy()
+ cdef np.ndarray split_right = self.RightEdge.copy()
+
+ for i in range(3): split_left[i] = self.right_edge[i]
+ split_left[direction] = sp[direction]
+ left = ProtoPrism(self.LeftEdge, split_left, self.subgrid_faces)
+
+ for i in range(3): split_right[i] = self.left_edge[i]
+ split_right[direction] = sp[direction]
+ right = ProtoPrism(split_right, self.RightEdge, self.subgrid_faces)
+
+ return (left, right)
+
+ @cython.boundscheck(False)
+ @cython.wraparound(False)
+ def get_brick(self, np.ndarray[np.float64_t, ndim=1] grid_left_edge,
+ np.ndarray[np.float64_t, ndim=1] grid_dds,
+ np.ndarray[np.float64_t, ndim=3] data,
+ child_mask):
+ # We get passed in the left edge, the dds (which gives dimensions) and
+ # the data, which is already vertex-centered.
+ cdef PartitionedGrid PG
+ cdef int li[3], ri[3], idims[3], i
+ for i in range(3):
+ li[i] = lrint((self.left_edge[i] - grid_left_edge[i])/grid_dds[i])
+ ri[i] = lrint((self.right_edge[i] - grid_left_edge[i])/grid_dds[i])
+ idims[i] = ri[i] - li[i]
+ if child_mask[li[0], li[1], li[2]] == 0: return []
+ cdef np.ndarray[np.int64_t, ndim=1] dims = np.empty(3, dtype='int64')
+ for i in range(3):
+ dims[i] = idims[i]
+ cdef np.ndarray[np.float64_t, ndim=3] new_data
+ new_data = data[li[0]:ri[0]+1,li[1]:ri[1]+1,li[2]:ri[2]+1].copy()
+ PG = PartitionedGrid(new_data, self.LeftEdge, self.RightEdge, dims)
+ return [PG]
Modified: trunk/yt/amr_utils.c
==============================================================================
--- trunk/yt/amr_utils.c (original)
+++ trunk/yt/amr_utils.c Thu Jan 14 00:02:09 2010
@@ -1,4 +1,4 @@
-/* Generated by Cython 0.11.3 on Fri Nov 20 19:28:58 2009 */
+/* Generated by Cython 0.11.3 on Thu Jan 14 00:00:38 2010 */
#define PY_SSIZE_T_CLEAN
#include "Python.h"
@@ -420,6 +420,34 @@
static void __Pyx_RaiseBufferFallbackError(void); /*proto*/
#define __Pyx_BufPtrStrided3d(type, buf, i0, s0, i1, s1, i2, s2) (type)((char*)buf + i0 * s0 + i1 * s1 + i2 * s2)
+static void __Pyx_RaiseBufferIndexError(int axis); /*proto*/
+
+#define __Pyx_SetItemInt(o, i, v, size, to_py_func) ((size <= sizeof(Py_ssize_t)) ? \
+ __Pyx_SetItemInt_Fast(o, i, v, size <= sizeof(long)) : \
+ __Pyx_SetItemInt_Generic(o, to_py_func(i), v))
+
+static INLINE int __Pyx_SetItemInt_Generic(PyObject *o, PyObject *j, PyObject *v) {
+ int r;
+ if (!j) return -1;
+ r = PyObject_SetItem(o, j, v);
+ Py_DECREF(j);
+ return r;
+}
+
+static INLINE int __Pyx_SetItemInt_Fast(PyObject *o, Py_ssize_t i, PyObject *v, int fits_long) {
+ if (PyList_CheckExact(o) && ((0 <= i) & (i < PyList_GET_SIZE(o)))) {
+ Py_INCREF(v);
+ Py_DECREF(PyList_GET_ITEM(o, i));
+ PyList_SET_ITEM(o, i, v);
+ return 1;
+ }
+ else if (Py_TYPE(o)->tp_as_sequence && Py_TYPE(o)->tp_as_sequence->sq_ass_item && (likely(i >= 0)))
+ return PySequence_SetItem(o, i, v);
+ else {
+ PyObject *j = fits_long ? PyInt_FromLong(i) : PyLong_FromLongLong(i);
+ return __Pyx_SetItemInt_Generic(o, j, v);
+ }
+}
static INLINE void __Pyx_RaiseNoneNotIterableError(void);
@@ -460,6 +488,11 @@
static INLINE npy_int64 __Pyx_PyInt_from_py_npy_int64(PyObject *);
+static PyObject *__Pyx_UnpackItem(PyObject *, Py_ssize_t index); /*proto*/
+static int __Pyx_EndUnpack(PyObject *); /*proto*/
+
+static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb); /*proto*/
+
static INLINE PyObject *__Pyx_PyInt_to_py_npy_int64(npy_int64);
#if __PYX_USE_C99_COMPLEX
@@ -676,11 +709,6 @@
#endif
-static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb); /*proto*/
-
-static PyObject *__Pyx_UnpackItem(PyObject *, Py_ssize_t index); /*proto*/
-static int __Pyx_EndUnpack(PyObject *); /*proto*/
-
static INLINE unsigned char __Pyx_PyInt_AsUnsignedChar(PyObject *);
static INLINE unsigned short __Pyx_PyInt_AsUnsignedShort(PyObject *);
@@ -771,7 +799,7 @@
typedef npy_cdouble __pyx_t_5numpy_complex_t;
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":71
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":72
* cdef class VectorPlane
*
* cdef class TransferFunctionProxy: # <<<<<<<<<<<<<<
@@ -820,6 +848,24 @@
PyObject *grids;
};
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":419
+ * return 1
+ *
+ * cdef class ProtoPrism: # <<<<<<<<<<<<<<
+ * cdef np.float64_t left_edge[3]
+ * cdef np.float64_t right_edge[3]
+ */
+
+struct __pyx_obj_2yt_9amr_utils_ProtoPrism {
+ PyObject_HEAD
+ struct __pyx_vtabstruct_2yt_9amr_utils_ProtoPrism *__pyx_vtab;
+ __pyx_t_5numpy_float64_t left_edge[3];
+ __pyx_t_5numpy_float64_t right_edge[3];
+ PyObject *LeftEdge;
+ PyObject *RightEdge;
+ PyObject *subgrid_faces;
+};
+
/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/DepthFirstOctree.pyx":30
* cimport cython
*
@@ -834,7 +880,24 @@
int refined_pos;
};
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":69
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":387
+ * tf.eval_transfer(dt, dv, rgba)
+ *
+ * cdef class GridFace: # <<<<<<<<<<<<<<
+ * cdef int direction
+ * cdef public np.float64_t coord
+ */
+
+struct __pyx_obj_2yt_9amr_utils_GridFace {
+ PyObject_HEAD
+ struct __pyx_vtabstruct_2yt_9amr_utils_GridFace *__pyx_vtab;
+ int direction;
+ __pyx_t_5numpy_float64_t coord;
+ __pyx_t_5numpy_float64_t left_edge[3];
+ __pyx_t_5numpy_float64_t right_edge[3];
+};
+
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":70
* np.float64_t *data)
*
* cdef class VectorPlane # <<<<<<<<<<<<<<
@@ -863,7 +926,7 @@
__pyx_t_5numpy_float64_t *y_vec;
};
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":188
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":189
* tv[(((k*self.nv)+j)*self.nv+i)] = fv[k]
*
* cdef class PartitionedGrid: # <<<<<<<<<<<<<<
@@ -887,7 +950,21 @@
};
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":128
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":419
+ * return 1
+ *
+ * cdef class ProtoPrism: # <<<<<<<<<<<<<<
+ * cdef np.float64_t left_edge[3]
+ * cdef np.float64_t right_edge[3]
+ */
+
+struct __pyx_vtabstruct_2yt_9amr_utils_ProtoPrism {
+ PyObject *(*split)(struct __pyx_obj_2yt_9amr_utils_ProtoPrism *, __pyx_t_5numpy_float64_t *, int);
+};
+static struct __pyx_vtabstruct_2yt_9amr_utils_ProtoPrism *__pyx_vtabptr_2yt_9amr_utils_ProtoPrism;
+
+
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":129
* # dst.a = dst.a + (1 - dst.a) * src.a
*
* cdef class VectorPlane: # <<<<<<<<<<<<<<
@@ -903,7 +980,7 @@
static struct __pyx_vtabstruct_2yt_9amr_utils_VectorPlane *__pyx_vtabptr_2yt_9amr_utils_VectorPlane;
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":188
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":189
* tv[(((k*self.nv)+j)*self.nv+i)] = fv[k]
*
* cdef class PartitionedGrid: # <<<<<<<<<<<<<<
@@ -919,7 +996,21 @@
static struct __pyx_vtabstruct_2yt_9amr_utils_PartitionedGrid *__pyx_vtabptr_2yt_9amr_utils_PartitionedGrid;
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":71
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":387
+ * tf.eval_transfer(dt, dv, rgba)
+ *
+ * cdef class GridFace: # <<<<<<<<<<<<<<
+ * cdef int direction
+ * cdef public np.float64_t coord
+ */
+
+struct __pyx_vtabstruct_2yt_9amr_utils_GridFace {
+ int (*proj_overlap)(struct __pyx_obj_2yt_9amr_utils_GridFace *, __pyx_t_5numpy_float64_t *, __pyx_t_5numpy_float64_t *);
+};
+static struct __pyx_vtabstruct_2yt_9amr_utils_GridFace *__pyx_vtabptr_2yt_9amr_utils_GridFace;
+
+
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":72
* cdef class VectorPlane
*
* cdef class TransferFunctionProxy: # <<<<<<<<<<<<<<
@@ -956,6 +1047,8 @@
static PyTypeObject *__pyx_ptype_2yt_9amr_utils_VectorPlane = 0;
static PyTypeObject *__pyx_ptype_2yt_9amr_utils_TransferFunctionProxy = 0;
static PyTypeObject *__pyx_ptype_2yt_9amr_utils_PartitionedGrid = 0;
+static PyTypeObject *__pyx_ptype_2yt_9amr_utils_GridFace = 0;
+static PyTypeObject *__pyx_ptype_2yt_9amr_utils_ProtoPrism = 0;
static INLINE int __pyx_f_2yt_9amr_utils_imax(int, int); /*proto*/
static INLINE __pyx_t_5numpy_float64_t __pyx_f_2yt_9amr_utils_fmax(__pyx_t_5numpy_float64_t, __pyx_t_5numpy_float64_t); /*proto*/
static INLINE int __pyx_f_2yt_9amr_utils_imin(int, int); /*proto*/
@@ -977,6 +1070,7 @@
static PyObject *__pyx_int_1;
static PyObject *__pyx_int_3;
static PyObject *__pyx_int_4;
+static PyObject *__pyx_int_0;
static char __pyx_k___main__[] = "__main__";
static PyObject *__pyx_kp___main__;
static char __pyx_k___cinit__[] = "__cinit__";
@@ -985,6 +1079,12 @@
static PyObject *__pyx_kp___getitem__;
static char __pyx_k_cast_plane[] = "cast_plane";
static PyObject *__pyx_kp_cast_plane;
+static char __pyx_k___init__[] = "__init__";
+static PyObject *__pyx_kp___init__;
+static char __pyx_k_sweep[] = "sweep";
+static PyObject *__pyx_kp_sweep;
+static char __pyx_k_get_brick[] = "get_brick";
+static PyObject *__pyx_kp_get_brick;
static char __pyx_k_child_indices[] = "child_indices";
static PyObject *__pyx_kp_child_indices;
static char __pyx_k_fields[] = "fields";
@@ -1121,6 +1221,22 @@
static PyObject *__pyx_kp_tf;
static char __pyx_k_vp[] = "vp";
static PyObject *__pyx_kp_vp;
+static char __pyx_k_grid[] = "grid";
+static PyObject *__pyx_kp_grid;
+static char __pyx_k_direction[] = "direction";
+static PyObject *__pyx_kp_direction;
+static char __pyx_k_left[] = "left";
+static PyObject *__pyx_kp_left;
+static char __pyx_k_subgrid_faces[] = "subgrid_faces";
+static PyObject *__pyx_kp_subgrid_faces;
+static char __pyx_k_stack[] = "stack";
+static PyObject *__pyx_kp_stack;
+static char __pyx_k_grid_left_edge[] = "grid_left_edge";
+static PyObject *__pyx_kp_grid_left_edge;
+static char __pyx_k_grid_dds[] = "grid_dds";
+static PyObject *__pyx_kp_grid_dds;
+static char __pyx_k_child_mask[] = "child_mask";
+static PyObject *__pyx_kp_child_mask;
static char __pyx_k_posx[] = "posx";
static PyObject *__pyx_kp_posx;
static char __pyx_k_posy[] = "posy";
@@ -1183,8 +1299,19 @@
static PyObject *__pyx_kp_x_bounds;
static char __pyx_k_nbins[] = "nbins";
static PyObject *__pyx_kp_nbins;
+static char __pyx_k_LeftEdge[] = "LeftEdge";
+static PyObject *__pyx_kp_LeftEdge;
+static char __pyx_k_RightEdge[] = "RightEdge";
+static PyObject *__pyx_kp_RightEdge;
+static char __pyx_k_RuntimeError[] = "RuntimeError";
+static PyObject *__pyx_kp_RuntimeError;
+static char __pyx_k_copy[] = "copy";
+static PyObject *__pyx_kp_copy;
+static char __pyx_k_37[] = "int64";
+static PyObject *__pyx_kp_37;
static PyObject *__pyx_builtin_range;
static PyObject *__pyx_builtin_xrange;
+static PyObject *__pyx_builtin_RuntimeError;
static PyObject *__pyx_int_15;
static char __pyx_k___getbuffer__[] = "__getbuffer__";
static PyObject *__pyx_kp___getbuffer__;
@@ -1196,14 +1323,11 @@
static PyObject *__pyx_kp_flags;
static char __pyx_k_ValueError[] = "ValueError";
static PyObject *__pyx_kp_ValueError;
-static char __pyx_k_RuntimeError[] = "RuntimeError";
-static PyObject *__pyx_kp_RuntimeError;
static PyObject *__pyx_kp_1;
static PyObject *__pyx_kp_2;
static PyObject *__pyx_kp_5;
static PyObject *__pyx_kp_23;
static PyObject *__pyx_builtin_ValueError;
-static PyObject *__pyx_builtin_RuntimeError;
static char __pyx_k_1[] = "ndarray is not C contiguous";
static char __pyx_k_2[] = "ndarray is not Fortran contiguous";
static char __pyx_k_3[] = ">";
@@ -3583,29 +3707,29 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_vals);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, 1); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, 1); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_bins);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, 2); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, 2); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_is);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, 3); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, 3); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_output);
if (likely(values[4])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, 4); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, 4); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "UnilinearlyInterpolate") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "UnilinearlyInterpolate") < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_table = ((PyArrayObject *)values[0]);
__pyx_v_x_vals = ((PyArrayObject *)values[1]);
@@ -3623,7 +3747,7 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("UnilinearlyInterpolate", 1, 5, 5, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.UnilinearlyInterpolate");
return NULL;
@@ -3634,38 +3758,38 @@
__pyx_bstruct_x_bins.buf = NULL;
__pyx_bstruct_x_is.buf = NULL;
__pyx_bstruct_output.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_table), __pyx_ptype_5numpy_ndarray, 1, "table", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_vals), __pyx_ptype_5numpy_ndarray, 1, "x_vals", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_bins), __pyx_ptype_5numpy_ndarray, 1, "x_bins", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 33; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_is), __pyx_ptype_5numpy_ndarray, 1, "x_is", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 34; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_output), __pyx_ptype_5numpy_ndarray, 1, "output", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 35; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_table), __pyx_ptype_5numpy_ndarray, 1, "table", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_vals), __pyx_ptype_5numpy_ndarray, 1, "x_vals", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_bins), __pyx_ptype_5numpy_ndarray, 1, "x_bins", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 33; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_is), __pyx_ptype_5numpy_ndarray, 1, "x_is", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 34; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_output), __pyx_ptype_5numpy_ndarray, 1, "output", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 35; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_table, (PyObject*)__pyx_v_table, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_table, (PyObject*)__pyx_v_table, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_table = __pyx_bstruct_table.strides[0];
__pyx_bshape_0_table = __pyx_bstruct_table.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_vals, (PyObject*)__pyx_v_x_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_vals, (PyObject*)__pyx_v_x_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_vals = __pyx_bstruct_x_vals.strides[0];
__pyx_bshape_0_x_vals = __pyx_bstruct_x_vals.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_bins, (PyObject*)__pyx_v_x_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_bins, (PyObject*)__pyx_v_x_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_bins = __pyx_bstruct_x_bins.strides[0];
__pyx_bshape_0_x_bins = __pyx_bstruct_x_bins.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_is, (PyObject*)__pyx_v_x_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_is, (PyObject*)__pyx_v_x_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_is = __pyx_bstruct_x_is.strides[0];
__pyx_bshape_0_x_is = __pyx_bstruct_x_is.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_output, (PyObject*)__pyx_v_output, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_output, (PyObject*)__pyx_v_output, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_output = __pyx_bstruct_output.strides[0];
__pyx_bshape_0_output = __pyx_bstruct_output.shape[0];
@@ -3713,7 +3837,7 @@
if (__pyx_t_4 < 0) __pyx_t_4 += __pyx_bshape_0_x_bins;
__pyx_t_5 = __pyx_v_x_i;
if (__pyx_t_5 < 0) __pyx_t_5 += __pyx_bshape_0_x_bins;
- __pyx_t_6 = PyFloat_FromDouble((1.0 / ((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_x_bins.buf, __pyx_t_4, __pyx_bstride_0_x_bins)) - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_x_bins.buf, __pyx_t_5, __pyx_bstride_0_x_bins))))); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyFloat_FromDouble((1.0 / ((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_x_bins.buf, __pyx_t_4, __pyx_bstride_0_x_bins)) - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_x_bins.buf, __pyx_t_5, __pyx_bstride_0_x_bins))))); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_v_dx_inv);
__pyx_v_dx_inv = __pyx_t_6;
@@ -3728,12 +3852,12 @@
*/
__pyx_t_7 = __pyx_v_x_i;
if (__pyx_t_7 < 0) __pyx_t_7 += __pyx_bshape_0_x_bins;
- __pyx_t_6 = PyFloat_FromDouble((__pyx_v_x - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_x_bins.buf, __pyx_t_7, __pyx_bstride_0_x_bins)))); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyFloat_FromDouble((__pyx_v_x - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_x_bins.buf, __pyx_t_7, __pyx_bstride_0_x_bins)))); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
- __pyx_t_8 = PyNumber_Multiply(__pyx_t_6, __pyx_v_dx_inv); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = PyNumber_Multiply(__pyx_t_6, __pyx_v_dx_inv); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
- __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_8); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_8); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
__pyx_v_xp = __pyx_t_9;
@@ -3746,12 +3870,12 @@
*/
__pyx_t_10 = (__pyx_v_x_i + 1);
if (__pyx_t_10 < 0) __pyx_t_10 += __pyx_bshape_0_x_bins;
- __pyx_t_8 = PyFloat_FromDouble(((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_x_bins.buf, __pyx_t_10, __pyx_bstride_0_x_bins)) - __pyx_v_x)); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 43; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = PyFloat_FromDouble(((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_x_bins.buf, __pyx_t_10, __pyx_bstride_0_x_bins)) - __pyx_v_x)); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 43; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_8);
- __pyx_t_6 = PyNumber_Multiply(__pyx_t_8, __pyx_v_dx_inv); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 43; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_6 = PyNumber_Multiply(__pyx_t_8, __pyx_v_dx_inv); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 43; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_6);
__Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
- __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_6); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 43; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_9 = __pyx_PyFloat_AsDouble(__pyx_t_6); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 43; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
__pyx_v_xm = __pyx_t_9;
@@ -3921,47 +4045,47 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_vals);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 1); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 1); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_y_vals);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 2); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 2); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_bins);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 3); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 3); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_y_bins);
if (likely(values[4])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 4); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 4); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_is);
if (likely(values[5])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 5); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 5); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 6:
values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_y_is);
if (likely(values[6])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 6); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 6); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 7:
values[7] = PyDict_GetItem(__pyx_kwds, __pyx_kp_output);
if (likely(values[7])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 7); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, 7); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "BilinearlyInterpolate") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "BilinearlyInterpolate") < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_table = ((PyArrayObject *)values[0]);
__pyx_v_x_vals = ((PyArrayObject *)values[1]);
@@ -3985,7 +4109,7 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("BilinearlyInterpolate", 1, 8, 8, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.BilinearlyInterpolate");
return NULL;
@@ -3998,59 +4122,59 @@
__pyx_bstruct_x_is.buf = NULL;
__pyx_bstruct_y_is.buf = NULL;
__pyx_bstruct_output.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_table), __pyx_ptype_5numpy_ndarray, 1, "table", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_vals), __pyx_ptype_5numpy_ndarray, 1, "x_vals", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 49; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_vals), __pyx_ptype_5numpy_ndarray, 1, "y_vals", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 50; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_bins), __pyx_ptype_5numpy_ndarray, 1, "x_bins", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 51; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_bins), __pyx_ptype_5numpy_ndarray, 1, "y_bins", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 52; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_is), __pyx_ptype_5numpy_ndarray, 1, "x_is", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 53; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_is), __pyx_ptype_5numpy_ndarray, 1, "y_is", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 54; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_output), __pyx_ptype_5numpy_ndarray, 1, "output", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 55; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_table), __pyx_ptype_5numpy_ndarray, 1, "table", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_vals), __pyx_ptype_5numpy_ndarray, 1, "x_vals", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 49; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_vals), __pyx_ptype_5numpy_ndarray, 1, "y_vals", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 50; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_bins), __pyx_ptype_5numpy_ndarray, 1, "x_bins", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 51; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_bins), __pyx_ptype_5numpy_ndarray, 1, "y_bins", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 52; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_is), __pyx_ptype_5numpy_ndarray, 1, "x_is", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 53; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_is), __pyx_ptype_5numpy_ndarray, 1, "y_is", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 54; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_output), __pyx_ptype_5numpy_ndarray, 1, "output", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 55; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_table, (PyObject*)__pyx_v_table, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_table, (PyObject*)__pyx_v_table, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_table = __pyx_bstruct_table.strides[0]; __pyx_bstride_1_table = __pyx_bstruct_table.strides[1];
__pyx_bshape_0_table = __pyx_bstruct_table.shape[0]; __pyx_bshape_1_table = __pyx_bstruct_table.shape[1];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_vals, (PyObject*)__pyx_v_x_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_vals, (PyObject*)__pyx_v_x_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_vals = __pyx_bstruct_x_vals.strides[0];
__pyx_bshape_0_x_vals = __pyx_bstruct_x_vals.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_vals, (PyObject*)__pyx_v_y_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_vals, (PyObject*)__pyx_v_y_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_y_vals = __pyx_bstruct_y_vals.strides[0];
__pyx_bshape_0_y_vals = __pyx_bstruct_y_vals.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_bins, (PyObject*)__pyx_v_x_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_bins, (PyObject*)__pyx_v_x_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_bins = __pyx_bstruct_x_bins.strides[0];
__pyx_bshape_0_x_bins = __pyx_bstruct_x_bins.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_bins, (PyObject*)__pyx_v_y_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_bins, (PyObject*)__pyx_v_y_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_y_bins = __pyx_bstruct_y_bins.strides[0];
__pyx_bshape_0_y_bins = __pyx_bstruct_y_bins.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_is, (PyObject*)__pyx_v_x_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_is, (PyObject*)__pyx_v_x_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_is = __pyx_bstruct_x_is.strides[0];
__pyx_bshape_0_x_is = __pyx_bstruct_x_is.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_is, (PyObject*)__pyx_v_y_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_is, (PyObject*)__pyx_v_y_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_y_is = __pyx_bstruct_y_is.strides[0];
__pyx_bshape_0_y_is = __pyx_bstruct_y_is.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_output, (PyObject*)__pyx_v_output, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_output, (PyObject*)__pyx_v_output, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 48; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_output = __pyx_bstruct_output.strides[0];
__pyx_bshape_0_output = __pyx_bstruct_output.shape[0];
@@ -4420,65 +4544,65 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_vals);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 1); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 1); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_y_vals);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 2); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 2); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_z_vals);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 3); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 3); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_bins);
if (likely(values[4])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 4); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 4); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_y_bins);
if (likely(values[5])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 5); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 5); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 6:
values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_z_bins);
if (likely(values[6])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 6); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 6); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 7:
values[7] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_is);
if (likely(values[7])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 7); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 7); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 8:
values[8] = PyDict_GetItem(__pyx_kwds, __pyx_kp_y_is);
if (likely(values[8])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 8); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 8); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 9:
values[9] = PyDict_GetItem(__pyx_kwds, __pyx_kp_z_is);
if (likely(values[9])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 9); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 9); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 10:
values[10] = PyDict_GetItem(__pyx_kwds, __pyx_kp_output);
if (likely(values[10])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 10); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, 10); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "TrilinearlyInterpolate") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "TrilinearlyInterpolate") < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_table = ((PyArrayObject *)values[0]);
__pyx_v_x_vals = ((PyArrayObject *)values[1]);
@@ -4508,7 +4632,7 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TrilinearlyInterpolate", 1, 11, 11, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.TrilinearlyInterpolate");
return NULL;
@@ -4524,80 +4648,80 @@
__pyx_bstruct_y_is.buf = NULL;
__pyx_bstruct_z_is.buf = NULL;
__pyx_bstruct_output.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_table), __pyx_ptype_5numpy_ndarray, 1, "table", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_vals), __pyx_ptype_5numpy_ndarray, 1, "x_vals", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 78; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_vals), __pyx_ptype_5numpy_ndarray, 1, "y_vals", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 79; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_z_vals), __pyx_ptype_5numpy_ndarray, 1, "z_vals", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_bins), __pyx_ptype_5numpy_ndarray, 1, "x_bins", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 81; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_bins), __pyx_ptype_5numpy_ndarray, 1, "y_bins", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 82; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_z_bins), __pyx_ptype_5numpy_ndarray, 1, "z_bins", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 83; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_is), __pyx_ptype_5numpy_ndarray, 1, "x_is", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 84; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_is), __pyx_ptype_5numpy_ndarray, 1, "y_is", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 85; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_z_is), __pyx_ptype_5numpy_ndarray, 1, "z_is", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 86; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_output), __pyx_ptype_5numpy_ndarray, 1, "output", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 87; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_table), __pyx_ptype_5numpy_ndarray, 1, "table", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_vals), __pyx_ptype_5numpy_ndarray, 1, "x_vals", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 78; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_vals), __pyx_ptype_5numpy_ndarray, 1, "y_vals", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 79; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_z_vals), __pyx_ptype_5numpy_ndarray, 1, "z_vals", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_bins), __pyx_ptype_5numpy_ndarray, 1, "x_bins", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 81; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_bins), __pyx_ptype_5numpy_ndarray, 1, "y_bins", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 82; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_z_bins), __pyx_ptype_5numpy_ndarray, 1, "z_bins", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 83; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_is), __pyx_ptype_5numpy_ndarray, 1, "x_is", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 84; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_is), __pyx_ptype_5numpy_ndarray, 1, "y_is", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 85; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_z_is), __pyx_ptype_5numpy_ndarray, 1, "z_is", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 86; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_output), __pyx_ptype_5numpy_ndarray, 1, "output", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 87; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_table, (PyObject*)__pyx_v_table, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_table, (PyObject*)__pyx_v_table, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_table = __pyx_bstruct_table.strides[0]; __pyx_bstride_1_table = __pyx_bstruct_table.strides[1]; __pyx_bstride_2_table = __pyx_bstruct_table.strides[2];
__pyx_bshape_0_table = __pyx_bstruct_table.shape[0]; __pyx_bshape_1_table = __pyx_bstruct_table.shape[1]; __pyx_bshape_2_table = __pyx_bstruct_table.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_vals, (PyObject*)__pyx_v_x_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_vals, (PyObject*)__pyx_v_x_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_vals = __pyx_bstruct_x_vals.strides[0];
__pyx_bshape_0_x_vals = __pyx_bstruct_x_vals.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_vals, (PyObject*)__pyx_v_y_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_vals, (PyObject*)__pyx_v_y_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_y_vals = __pyx_bstruct_y_vals.strides[0];
__pyx_bshape_0_y_vals = __pyx_bstruct_y_vals.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_z_vals, (PyObject*)__pyx_v_z_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_z_vals, (PyObject*)__pyx_v_z_vals, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_z_vals = __pyx_bstruct_z_vals.strides[0];
__pyx_bshape_0_z_vals = __pyx_bstruct_z_vals.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_bins, (PyObject*)__pyx_v_x_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_bins, (PyObject*)__pyx_v_x_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_bins = __pyx_bstruct_x_bins.strides[0];
__pyx_bshape_0_x_bins = __pyx_bstruct_x_bins.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_bins, (PyObject*)__pyx_v_y_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_bins, (PyObject*)__pyx_v_y_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_y_bins = __pyx_bstruct_y_bins.strides[0];
__pyx_bshape_0_y_bins = __pyx_bstruct_y_bins.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_z_bins, (PyObject*)__pyx_v_z_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_z_bins, (PyObject*)__pyx_v_z_bins, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_z_bins = __pyx_bstruct_z_bins.strides[0];
__pyx_bshape_0_z_bins = __pyx_bstruct_z_bins.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_is, (PyObject*)__pyx_v_x_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_is, (PyObject*)__pyx_v_x_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_is = __pyx_bstruct_x_is.strides[0];
__pyx_bshape_0_x_is = __pyx_bstruct_x_is.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_is, (PyObject*)__pyx_v_y_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_is, (PyObject*)__pyx_v_y_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_y_is = __pyx_bstruct_y_is.strides[0];
__pyx_bshape_0_y_is = __pyx_bstruct_y_is.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_z_is, (PyObject*)__pyx_v_z_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_z_is, (PyObject*)__pyx_v_z_is, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_z_is = __pyx_bstruct_z_is.strides[0];
__pyx_bshape_0_z_is = __pyx_bstruct_z_is.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_output, (PyObject*)__pyx_v_output, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_output, (PyObject*)__pyx_v_output, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_output = __pyx_bstruct_output.strides[0];
__pyx_bshape_0_output = __pyx_bstruct_output.shape[0];
@@ -5652,91 +5776,91 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_o_s);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 1); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 1); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_e);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 2); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 2); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_a);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 3); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 3); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_imin);
if (likely(values[4])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 4); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 4); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_imax);
if (likely(values[5])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 5); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 5); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 6:
values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_jmin);
if (likely(values[6])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 6); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 6); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 7:
values[7] = PyDict_GetItem(__pyx_kwds, __pyx_kp_jmax);
if (likely(values[7])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 7); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 7); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 8:
values[8] = PyDict_GetItem(__pyx_kwds, __pyx_kp_kmin);
if (likely(values[8])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 8); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 8); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 9:
values[9] = PyDict_GetItem(__pyx_kwds, __pyx_kp_kmax);
if (likely(values[9])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 9); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 9); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 10:
values[10] = PyDict_GetItem(__pyx_kwds, __pyx_kp_istride);
if (likely(values[10])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 10); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 10); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 11:
values[11] = PyDict_GetItem(__pyx_kwds, __pyx_kp_jstride);
if (likely(values[11])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 11); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 11); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 12:
values[12] = PyDict_GetItem(__pyx_kwds, __pyx_kp_dx);
if (likely(values[12])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 12); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, 12); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "Transfer3D") < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "Transfer3D") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_i_s = ((PyArrayObject *)values[0]);
__pyx_v_o_s = ((PyArrayObject *)values[1]);
__pyx_v_e = ((PyArrayObject *)values[2]);
__pyx_v_a = ((PyArrayObject *)values[3]);
- __pyx_v_imin = __Pyx_PyInt_AsInt(values[4]); if (unlikely((__pyx_v_imin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_imax = __Pyx_PyInt_AsInt(values[5]); if (unlikely((__pyx_v_imax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_jmin = __Pyx_PyInt_AsInt(values[6]); if (unlikely((__pyx_v_jmin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_jmax = __Pyx_PyInt_AsInt(values[7]); if (unlikely((__pyx_v_jmax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_kmin = __Pyx_PyInt_AsInt(values[8]); if (unlikely((__pyx_v_kmin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_kmax = __Pyx_PyInt_AsInt(values[9]); if (unlikely((__pyx_v_kmax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_istride = __Pyx_PyInt_AsInt(values[10]); if (unlikely((__pyx_v_istride == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_jstride = __Pyx_PyInt_AsInt(values[11]); if (unlikely((__pyx_v_jstride == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_dx = __pyx_PyFloat_AsDouble(values[12]); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_imin = __Pyx_PyInt_AsInt(values[4]); if (unlikely((__pyx_v_imin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_imax = __Pyx_PyInt_AsInt(values[5]); if (unlikely((__pyx_v_imax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_jmin = __Pyx_PyInt_AsInt(values[6]); if (unlikely((__pyx_v_jmin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_jmax = __Pyx_PyInt_AsInt(values[7]); if (unlikely((__pyx_v_jmax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_kmin = __Pyx_PyInt_AsInt(values[8]); if (unlikely((__pyx_v_kmin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_kmax = __Pyx_PyInt_AsInt(values[9]); if (unlikely((__pyx_v_kmax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_istride = __Pyx_PyInt_AsInt(values[10]); if (unlikely((__pyx_v_istride == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_jstride = __Pyx_PyInt_AsInt(values[11]); if (unlikely((__pyx_v_jstride == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_dx = __pyx_PyFloat_AsDouble(values[12]); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else if (PyTuple_GET_SIZE(__pyx_args) != 13) {
goto __pyx_L5_argtuple_error;
} else {
@@ -5744,19 +5868,19 @@
__pyx_v_o_s = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 1));
__pyx_v_e = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 2));
__pyx_v_a = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 3));
- __pyx_v_imin = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 4)); if (unlikely((__pyx_v_imin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_imax = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 5)); if (unlikely((__pyx_v_imax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_jmin = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 6)); if (unlikely((__pyx_v_jmin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_jmax = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 7)); if (unlikely((__pyx_v_jmax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_kmin = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 8)); if (unlikely((__pyx_v_kmin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_kmax = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 9)); if (unlikely((__pyx_v_kmax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_istride = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 10)); if (unlikely((__pyx_v_istride == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_jstride = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 11)); if (unlikely((__pyx_v_jstride == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_dx = __pyx_PyFloat_AsDouble(PyTuple_GET_ITEM(__pyx_args, 12)); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_imin = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 4)); if (unlikely((__pyx_v_imin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_imax = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 5)); if (unlikely((__pyx_v_imax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_jmin = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 6)); if (unlikely((__pyx_v_jmin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_jmax = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 7)); if (unlikely((__pyx_v_jmax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 40; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_kmin = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 8)); if (unlikely((__pyx_v_kmin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_kmax = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 9)); if (unlikely((__pyx_v_kmax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_istride = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 10)); if (unlikely((__pyx_v_istride == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_jstride = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 11)); if (unlikely((__pyx_v_jstride == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 41; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_dx = __pyx_PyFloat_AsDouble(PyTuple_GET_ITEM(__pyx_args, 12)); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 42; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer3D", 1, 13, 13, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.Transfer3D");
return NULL;
@@ -5765,31 +5889,31 @@
__pyx_bstruct_o_s.buf = NULL;
__pyx_bstruct_e.buf = NULL;
__pyx_bstruct_a.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_i_s), __pyx_ptype_5numpy_ndarray, 1, "i_s", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_o_s), __pyx_ptype_5numpy_ndarray, 1, "o_s", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 37; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_e), __pyx_ptype_5numpy_ndarray, 1, "e", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 38; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 39; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_i_s), __pyx_ptype_5numpy_ndarray, 1, "i_s", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_o_s), __pyx_ptype_5numpy_ndarray, 1, "o_s", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 37; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_e), __pyx_ptype_5numpy_ndarray, 1, "e", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 38; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 39; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_i_s, (PyObject*)__pyx_v_i_s, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_i_s, (PyObject*)__pyx_v_i_s, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_i_s = __pyx_bstruct_i_s.strides[0]; __pyx_bstride_1_i_s = __pyx_bstruct_i_s.strides[1]; __pyx_bstride_2_i_s = __pyx_bstruct_i_s.strides[2];
__pyx_bshape_0_i_s = __pyx_bstruct_i_s.shape[0]; __pyx_bshape_1_i_s = __pyx_bstruct_i_s.shape[1]; __pyx_bshape_2_i_s = __pyx_bstruct_i_s.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_o_s, (PyObject*)__pyx_v_o_s, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 4, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_o_s, (PyObject*)__pyx_v_o_s, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 4, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_o_s = __pyx_bstruct_o_s.strides[0]; __pyx_bstride_1_o_s = __pyx_bstruct_o_s.strides[1]; __pyx_bstride_2_o_s = __pyx_bstruct_o_s.strides[2]; __pyx_bstride_3_o_s = __pyx_bstruct_o_s.strides[3];
__pyx_bshape_0_o_s = __pyx_bstruct_o_s.shape[0]; __pyx_bshape_1_o_s = __pyx_bstruct_o_s.shape[1]; __pyx_bshape_2_o_s = __pyx_bstruct_o_s.shape[2]; __pyx_bshape_3_o_s = __pyx_bstruct_o_s.shape[3];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_e, (PyObject*)__pyx_v_e, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 4, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_e, (PyObject*)__pyx_v_e, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 4, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_e = __pyx_bstruct_e.strides[0]; __pyx_bstride_1_e = __pyx_bstruct_e.strides[1]; __pyx_bstride_2_e = __pyx_bstruct_e.strides[2]; __pyx_bstride_3_e = __pyx_bstruct_e.strides[3];
__pyx_bshape_0_e = __pyx_bstruct_e.shape[0]; __pyx_bshape_1_e = __pyx_bstruct_e.shape[1]; __pyx_bshape_2_e = __pyx_bstruct_e.shape[2]; __pyx_bshape_3_e = __pyx_bstruct_e.shape[3];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_a, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 4, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_a, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 4, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_a = __pyx_bstruct_a.strides[0]; __pyx_bstride_1_a = __pyx_bstruct_a.strides[1]; __pyx_bstride_2_a = __pyx_bstruct_a.strides[2]; __pyx_bstride_3_a = __pyx_bstruct_a.strides[3];
__pyx_bshape_0_a = __pyx_bstruct_a.shape[0]; __pyx_bshape_1_a = __pyx_bstruct_a.shape[1]; __pyx_bshape_2_a = __pyx_bstruct_a.shape[2]; __pyx_bshape_3_a = __pyx_bstruct_a.shape[3];
@@ -6120,17 +6244,17 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_data);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TransferShells", 1, 3, 3, 1); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TransferShells", 1, 3, 3, 1); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_shells);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("TransferShells", 1, 3, 3, 2); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TransferShells", 1, 3, 3, 2); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "TransferShells") < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "TransferShells") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_i_s = ((PyArrayObject *)values[0]);
__pyx_v_data = ((PyArrayObject *)values[1]);
@@ -6144,7 +6268,7 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("TransferShells", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("TransferShells", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.TransferShells");
return NULL;
@@ -6152,24 +6276,24 @@
__pyx_bstruct_i_s.buf = NULL;
__pyx_bstruct_data.buf = NULL;
__pyx_bstruct_shells.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_i_s), __pyx_ptype_5numpy_ndarray, 1, "i_s", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_data), __pyx_ptype_5numpy_ndarray, 1, "data", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 75; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_shells), __pyx_ptype_5numpy_ndarray, 1, "shells", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 76; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_i_s), __pyx_ptype_5numpy_ndarray, 1, "i_s", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_data), __pyx_ptype_5numpy_ndarray, 1, "data", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 75; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_shells), __pyx_ptype_5numpy_ndarray, 1, "shells", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 76; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_i_s, (PyObject*)__pyx_v_i_s, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_i_s, (PyObject*)__pyx_v_i_s, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_i_s = __pyx_bstruct_i_s.strides[0]; __pyx_bstride_1_i_s = __pyx_bstruct_i_s.strides[1]; __pyx_bstride_2_i_s = __pyx_bstruct_i_s.strides[2];
__pyx_bshape_0_i_s = __pyx_bstruct_i_s.shape[0]; __pyx_bshape_1_i_s = __pyx_bstruct_i_s.shape[1]; __pyx_bshape_2_i_s = __pyx_bstruct_i_s.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_data, (PyObject*)__pyx_v_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_data, (PyObject*)__pyx_v_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_data = __pyx_bstruct_data.strides[0]; __pyx_bstride_1_data = __pyx_bstruct_data.strides[1]; __pyx_bstride_2_data = __pyx_bstruct_data.strides[2];
__pyx_bshape_0_data = __pyx_bstruct_data.shape[0]; __pyx_bshape_1_data = __pyx_bstruct_data.shape[1]; __pyx_bshape_2_data = __pyx_bstruct_data.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_shells, (PyObject*)__pyx_v_shells, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_shells, (PyObject*)__pyx_v_shells, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 74; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_shells = __pyx_bstruct_shells.strides[0]; __pyx_bstride_1_shells = __pyx_bstruct_shells.strides[1];
__pyx_bshape_0_shells = __pyx_bstruct_shells.shape[0]; __pyx_bshape_1_shells = __pyx_bstruct_shells.shape[1];
@@ -6545,63 +6669,63 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_o_s);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 1); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 1); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_e);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 2); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 2); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_a);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 3); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 3); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_dx);
if (likely(values[4])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 4); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 4); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_imin);
if (likely(values[5])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 5); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 5); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 6:
values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_imax);
if (likely(values[6])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 6); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, 6); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "Transfer1D") < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "Transfer1D") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
- __pyx_v_i_s = __pyx_PyFloat_AsDouble(values[0]); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_i_s = __pyx_PyFloat_AsDouble(values[0]); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_v_o_s = ((PyArrayObject *)values[1]);
__pyx_v_e = ((PyArrayObject *)values[2]);
__pyx_v_a = ((PyArrayObject *)values[3]);
__pyx_v_dx = ((PyArrayObject *)values[4]);
- __pyx_v_imin = __Pyx_PyInt_AsInt(values[5]); if (unlikely((__pyx_v_imin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 119; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_imax = __Pyx_PyInt_AsInt(values[6]); if (unlikely((__pyx_v_imax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 119; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_imin = __Pyx_PyInt_AsInt(values[5]); if (unlikely((__pyx_v_imin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 119; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_imax = __Pyx_PyInt_AsInt(values[6]); if (unlikely((__pyx_v_imax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 119; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
} else if (PyTuple_GET_SIZE(__pyx_args) != 7) {
goto __pyx_L5_argtuple_error;
} else {
- __pyx_v_i_s = __pyx_PyFloat_AsDouble(PyTuple_GET_ITEM(__pyx_args, 0)); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_i_s = __pyx_PyFloat_AsDouble(PyTuple_GET_ITEM(__pyx_args, 0)); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_v_o_s = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 1));
__pyx_v_e = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 2));
__pyx_v_a = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 3));
__pyx_v_dx = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 4));
- __pyx_v_imin = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 5)); if (unlikely((__pyx_v_imin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 119; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_imax = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 6)); if (unlikely((__pyx_v_imax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 119; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_imin = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 5)); if (unlikely((__pyx_v_imin == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 119; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_imax = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 6)); if (unlikely((__pyx_v_imax == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 119; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("Transfer1D", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.Transfer1D");
return NULL;
@@ -6610,31 +6734,31 @@
__pyx_bstruct_e.buf = NULL;
__pyx_bstruct_a.buf = NULL;
__pyx_bstruct_dx.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_o_s), __pyx_ptype_5numpy_ndarray, 1, "o_s", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_e), __pyx_ptype_5numpy_ndarray, 1, "e", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_o_s), __pyx_ptype_5numpy_ndarray, 1, "o_s", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 115; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_e), __pyx_ptype_5numpy_ndarray, 1, "e", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 116; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_a), __pyx_ptype_5numpy_ndarray, 1, "a", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 117; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 118; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_o_s, (PyObject*)__pyx_v_o_s, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_o_s, (PyObject*)__pyx_v_o_s, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_o_s = __pyx_bstruct_o_s.strides[0];
__pyx_bshape_0_o_s = __pyx_bstruct_o_s.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_e, (PyObject*)__pyx_v_e, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_e, (PyObject*)__pyx_v_e, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_e = __pyx_bstruct_e.strides[0];
__pyx_bshape_0_e = __pyx_bstruct_e.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_a, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_a, (PyObject*)__pyx_v_a, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_a = __pyx_bstruct_a.strides[0];
__pyx_bshape_0_a = __pyx_bstruct_a.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dx, (PyObject*)__pyx_v_dx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dx, (PyObject*)__pyx_v_dx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 114; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_dx = __pyx_bstruct_dx.strides[0];
__pyx_bshape_0_dx = __pyx_bstruct_dx.shape[0];
@@ -6686,7 +6810,7 @@
* @cython.wraparound(False)
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_7 = PyFloat_FromDouble(__pyx_v_i_s); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyFloat_FromDouble(__pyx_v_i_s); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 124; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_7);
__pyx_r = __pyx_t_7;
__pyx_t_7 = 0;
@@ -7010,47 +7134,47 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_grid_t);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 1); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 1); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_grid_dt);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 2); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 2); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_left_edge);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 3); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 3); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_right_edge);
if (likely(values[4])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 4); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 4); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_dx);
if (likely(values[5])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 5); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 5); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 6:
values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_u);
if (likely(values[6])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 6); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 6); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 7:
values[7] = PyDict_GetItem(__pyx_kwds, __pyx_kp_v);
if (likely(values[7])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 7); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, 7); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "VoxelTraversal") < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "VoxelTraversal") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_grid_mask = ((PyArrayObject *)values[0]);
__pyx_v_grid_t = ((PyArrayObject *)values[1]);
@@ -7074,7 +7198,7 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("VoxelTraversal", 1, 8, 8, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.VoxelTraversal");
return NULL;
@@ -7092,59 +7216,59 @@
__pyx_bstruct_dx.buf = NULL;
__pyx_bstruct_u.buf = NULL;
__pyx_bstruct_v.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grid_mask), __pyx_ptype_5numpy_ndarray, 1, "grid_mask", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grid_t), __pyx_ptype_5numpy_ndarray, 1, "grid_t", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grid_dt), __pyx_ptype_5numpy_ndarray, 1, "grid_dt", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 130; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_left_edge), __pyx_ptype_5numpy_ndarray, 1, "left_edge", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 131; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_right_edge), __pyx_ptype_5numpy_ndarray, 1, "right_edge", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1, "u", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 134; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v), __pyx_ptype_5numpy_ndarray, 1, "v", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grid_mask), __pyx_ptype_5numpy_ndarray, 1, "grid_mask", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grid_t), __pyx_ptype_5numpy_ndarray, 1, "grid_t", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grid_dt), __pyx_ptype_5numpy_ndarray, 1, "grid_dt", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 130; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_left_edge), __pyx_ptype_5numpy_ndarray, 1, "left_edge", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 131; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_right_edge), __pyx_ptype_5numpy_ndarray, 1, "right_edge", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 132; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 133; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1, "u", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 134; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v), __pyx_ptype_5numpy_ndarray, 1, "v", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 135; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_grid_mask, (PyObject*)__pyx_v_grid_mask, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_grid_mask, (PyObject*)__pyx_v_grid_mask, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_grid_mask = __pyx_bstruct_grid_mask.strides[0]; __pyx_bstride_1_grid_mask = __pyx_bstruct_grid_mask.strides[1]; __pyx_bstride_2_grid_mask = __pyx_bstruct_grid_mask.strides[2];
__pyx_bshape_0_grid_mask = __pyx_bstruct_grid_mask.shape[0]; __pyx_bshape_1_grid_mask = __pyx_bstruct_grid_mask.shape[1]; __pyx_bshape_2_grid_mask = __pyx_bstruct_grid_mask.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_grid_t, (PyObject*)__pyx_v_grid_t, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_grid_t, (PyObject*)__pyx_v_grid_t, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_grid_t = __pyx_bstruct_grid_t.strides[0]; __pyx_bstride_1_grid_t = __pyx_bstruct_grid_t.strides[1]; __pyx_bstride_2_grid_t = __pyx_bstruct_grid_t.strides[2];
__pyx_bshape_0_grid_t = __pyx_bstruct_grid_t.shape[0]; __pyx_bshape_1_grid_t = __pyx_bstruct_grid_t.shape[1]; __pyx_bshape_2_grid_t = __pyx_bstruct_grid_t.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_grid_dt, (PyObject*)__pyx_v_grid_dt, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_grid_dt, (PyObject*)__pyx_v_grid_dt, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_grid_dt = __pyx_bstruct_grid_dt.strides[0]; __pyx_bstride_1_grid_dt = __pyx_bstruct_grid_dt.strides[1]; __pyx_bstride_2_grid_dt = __pyx_bstruct_grid_dt.strides[2];
__pyx_bshape_0_grid_dt = __pyx_bstruct_grid_dt.shape[0]; __pyx_bshape_1_grid_dt = __pyx_bstruct_grid_dt.shape[1]; __pyx_bshape_2_grid_dt = __pyx_bstruct_grid_dt.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_left_edge, (PyObject*)__pyx_v_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_left_edge, (PyObject*)__pyx_v_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_left_edge = __pyx_bstruct_left_edge.strides[0];
__pyx_bshape_0_left_edge = __pyx_bstruct_left_edge.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_right_edge, (PyObject*)__pyx_v_right_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_right_edge, (PyObject*)__pyx_v_right_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_right_edge = __pyx_bstruct_right_edge.strides[0];
__pyx_bshape_0_right_edge = __pyx_bstruct_right_edge.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dx, (PyObject*)__pyx_v_dx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dx, (PyObject*)__pyx_v_dx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_dx = __pyx_bstruct_dx.strides[0];
__pyx_bshape_0_dx = __pyx_bstruct_dx.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_u, (PyObject*)__pyx_v_u, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_u, (PyObject*)__pyx_v_u, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_u = __pyx_bstruct_u.strides[0];
__pyx_bshape_0_u = __pyx_bstruct_u.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_v, (PyObject*)__pyx_v_v, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_v, (PyObject*)__pyx_v_v, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_v = __pyx_bstruct_v.strides[0];
__pyx_bshape_0_v = __pyx_bstruct_v.shape[0];
@@ -7156,42 +7280,42 @@
* cdef np.ndarray[np.int64_t, ndim=1] cur_ind = np.empty((3,), dtype=np.int64)
* cdef np.ndarray[np.float64_t, ndim=1] tdelta = np.empty((3,), dtype=np.float64)
*/
- __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_1);
- __pyx_t_1 = PyObject_GetAttr(__pyx_1, __pyx_kp_empty); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_1, __pyx_kp_empty); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_1); __pyx_1 = 0;
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_2));
__Pyx_INCREF(__pyx_int_3);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_int_3);
__Pyx_GIVEREF(__pyx_int_3);
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_3));
PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_t_2));
__Pyx_GIVEREF(((PyObject *)__pyx_t_2));
__pyx_t_2 = 0;
- __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_1));
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_35); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_35); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- __pyx_t_2 = PyEval_CallObjectWithKeywords(__pyx_t_1, ((PyObject *)__pyx_t_3), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyEval_CallObjectWithKeywords(__pyx_t_1, ((PyObject *)__pyx_t_3), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
__Pyx_DECREF(((PyObject *)__pyx_1)); __pyx_1 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_4 = ((PyArrayObject *)__pyx_t_2);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_step, (PyObject*)__pyx_t_4, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {
__pyx_v_step = ((PyArrayObject *)Py_None); __Pyx_INCREF(Py_None); __pyx_bstruct_step.buf = NULL;
- {__pyx_filename = __pyx_f[4]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
} else {__pyx_bstride_0_step = __pyx_bstruct_step.strides[0];
__pyx_bshape_0_step = __pyx_bstruct_step.shape[0];
}
@@ -7207,42 +7331,42 @@
* cdef np.ndarray[np.float64_t, ndim=1] tdelta = np.empty((3,), dtype=np.float64)
* cdef np.ndarray[np.float64_t, ndim=1] tmax = np.empty((3,), dtype=np.float64)
*/
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_empty); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_empty); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_3));
__Pyx_INCREF(__pyx_int_3);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_int_3);
__Pyx_GIVEREF(__pyx_int_3);
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_1));
PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_t_3));
__Pyx_GIVEREF(((PyObject *)__pyx_t_3));
__pyx_t_3 = 0;
- __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_1));
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_35); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_35); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_3 = PyEval_CallObjectWithKeywords(__pyx_t_2, ((PyObject *)__pyx_t_1), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyEval_CallObjectWithKeywords(__pyx_t_2, ((PyObject *)__pyx_t_1), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
__Pyx_DECREF(((PyObject *)__pyx_1)); __pyx_1 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_5 = ((PyArrayObject *)__pyx_t_3);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_cur_ind, (PyObject*)__pyx_t_5, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {
__pyx_v_cur_ind = ((PyArrayObject *)Py_None); __Pyx_INCREF(Py_None); __pyx_bstruct_cur_ind.buf = NULL;
- {__pyx_filename = __pyx_f[4]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
} else {__pyx_bstride_0_cur_ind = __pyx_bstruct_cur_ind.strides[0];
__pyx_bshape_0_cur_ind = __pyx_bstruct_cur_ind.shape[0];
}
@@ -7258,42 +7382,42 @@
* cdef np.ndarray[np.float64_t, ndim=1] tmax = np.empty((3,), dtype=np.float64)
* cdef np.ndarray[np.float64_t, ndim=1] intersect = np.empty((3,), dtype=np.float64)
*/
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_empty); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_empty); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_1));
__Pyx_INCREF(__pyx_int_3);
PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_int_3);
__Pyx_GIVEREF(__pyx_int_3);
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_2));
PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_t_1));
__Pyx_GIVEREF(((PyObject *)__pyx_t_1));
__pyx_t_1 = 0;
- __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_1));
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_1 = PyObject_GetAttr(__pyx_2, __pyx_kp_36); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_2, __pyx_kp_36); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_1) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- __pyx_t_1 = PyEval_CallObjectWithKeywords(__pyx_t_3, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyEval_CallObjectWithKeywords(__pyx_t_3, ((PyObject *)__pyx_t_2), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
__Pyx_DECREF(((PyObject *)__pyx_1)); __pyx_1 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_6 = ((PyArrayObject *)__pyx_t_1);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_tdelta, (PyObject*)__pyx_t_6, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {
__pyx_v_tdelta = ((PyArrayObject *)Py_None); __Pyx_INCREF(Py_None); __pyx_bstruct_tdelta.buf = NULL;
- {__pyx_filename = __pyx_f[4]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
} else {__pyx_bstride_0_tdelta = __pyx_bstruct_tdelta.strides[0];
__pyx_bshape_0_tdelta = __pyx_bstruct_tdelta.shape[0];
}
@@ -7309,42 +7433,42 @@
* cdef np.ndarray[np.float64_t, ndim=1] intersect = np.empty((3,), dtype=np.float64)
* intersect_t = 1
*/
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_1 = PyObject_GetAttr(__pyx_2, __pyx_kp_empty); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_2, __pyx_kp_empty); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_2));
__Pyx_INCREF(__pyx_int_3);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_int_3);
__Pyx_GIVEREF(__pyx_int_3);
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_3));
PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_t_2));
__Pyx_GIVEREF(((PyObject *)__pyx_t_2));
__pyx_t_2 = 0;
- __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_1));
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_36); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_36); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- __pyx_t_2 = PyEval_CallObjectWithKeywords(__pyx_t_1, ((PyObject *)__pyx_t_3), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyEval_CallObjectWithKeywords(__pyx_t_1, ((PyObject *)__pyx_t_3), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
__Pyx_DECREF(((PyObject *)__pyx_1)); __pyx_1 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_7 = ((PyArrayObject *)__pyx_t_2);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_tmax, (PyObject*)__pyx_t_7, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {
__pyx_v_tmax = ((PyArrayObject *)Py_None); __Pyx_INCREF(Py_None); __pyx_bstruct_tmax.buf = NULL;
- {__pyx_filename = __pyx_f[4]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[5]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
} else {__pyx_bstride_0_tmax = __pyx_bstruct_tmax.strides[0];
__pyx_bshape_0_tmax = __pyx_bstruct_tmax.shape[0];
}
@@ -7360,42 +7484,42 @@
* intersect_t = 1
* dt_tolerance = 1e-6
*/
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_empty); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_empty); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_3));
__Pyx_INCREF(__pyx_int_3);
PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_int_3);
__Pyx_GIVEREF(__pyx_int_3);
- __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(1); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_1));
PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_t_3));
__Pyx_GIVEREF(((PyObject *)__pyx_t_3));
__pyx_t_3 = 0;
- __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_1));
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_36); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_36); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_3) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_3 = PyEval_CallObjectWithKeywords(__pyx_t_2, ((PyObject *)__pyx_t_1), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyEval_CallObjectWithKeywords(__pyx_t_2, ((PyObject *)__pyx_t_1), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
__Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
__Pyx_DECREF(((PyObject *)__pyx_1)); __pyx_1 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_8 = ((PyArrayObject *)__pyx_t_3);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_intersect, (PyObject*)__pyx_t_8, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {
__pyx_v_intersect = ((PyArrayObject *)Py_None); __Pyx_INCREF(Py_None); __pyx_bstruct_intersect.buf = NULL;
- {__pyx_filename = __pyx_f[4]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[5]; __pyx_lineno = 145; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
} else {__pyx_bstride_0_intersect = __pyx_bstruct_intersect.strides[0];
__pyx_bshape_0_intersect = __pyx_bstruct_intersect.shape[0];
}
@@ -7739,15 +7863,15 @@
* for i in range(3):
* cur_ind[i] = np.floor((intersect[i] + 1e-8*dx[i] - left_edge[i])/dx[i])
*/
- __pyx_t_3 = PyFloat_FromDouble(__pyx_v_intersect_t); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyFloat_FromDouble(__pyx_v_intersect_t); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_1 = PyNumber_Multiply(__pyx_t_3, ((PyObject *)__pyx_v_v)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyNumber_Multiply(__pyx_t_3, ((PyObject *)__pyx_v_v)); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- __pyx_t_3 = PyNumber_Add(((PyObject *)__pyx_v_u), __pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyNumber_Add(((PyObject *)__pyx_v_u), __pyx_t_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_3, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_8 = ((PyArrayObject *)__pyx_t_3);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
@@ -7764,7 +7888,7 @@
}
__pyx_bstride_0_intersect = __pyx_bstruct_intersect.strides[0];
__pyx_bshape_0_intersect = __pyx_bstruct_intersect.shape[0];
- if (unlikely(__pyx_t_9 < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__pyx_t_9 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 173; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_t_8 = 0;
__Pyx_DECREF(((PyObject *)__pyx_v_intersect));
@@ -7788,27 +7912,27 @@
* tmax[i] = (((cur_ind[i]+step[i])*dx[i])+left_edge[i]-u[i])/v[i]
* if cur_ind[i] == grid_mask.shape[i] and step[i] < 0:
*/
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_floor); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_GetAttr(__pyx_2, __pyx_kp_floor); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
__pyx_t_52 = __pyx_v_i;
__pyx_t_53 = __pyx_v_i;
__pyx_t_54 = __pyx_v_i;
__pyx_t_55 = __pyx_v_i;
- __pyx_t_1 = PyFloat_FromDouble(((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_intersect.buf, __pyx_t_52, __pyx_bstride_0_intersect)) + (1e-08 * (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_dx.buf, __pyx_t_53, __pyx_bstride_0_dx)))) - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_left_edge.buf, __pyx_t_54, __pyx_bstride_0_left_edge))) / (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_dx.buf, __pyx_t_55, __pyx_bstride_0_dx)))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyFloat_FromDouble(((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_intersect.buf, __pyx_t_52, __pyx_bstride_0_intersect)) + (1e-08 * (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_dx.buf, __pyx_t_53, __pyx_bstride_0_dx)))) - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_left_edge.buf, __pyx_t_54, __pyx_bstride_0_left_edge))) / (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_dx.buf, __pyx_t_55, __pyx_bstride_0_dx)))); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_2));
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_1);
__Pyx_GIVEREF(__pyx_t_1);
__pyx_t_1 = 0;
- __pyx_t_1 = PyObject_Call(__pyx_t_3, ((PyObject *)__pyx_t_2), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_Call(__pyx_t_3, ((PyObject *)__pyx_t_2), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
__Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
- __pyx_t_56 = __Pyx_PyInt_from_py_npy_int64(__pyx_t_1); if (unlikely((__pyx_t_56 == (npy_int64)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_56 = __Pyx_PyInt_from_py_npy_int64(__pyx_t_1); if (unlikely((__pyx_t_56 == (npy_int64)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 175; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__pyx_t_57 = __pyx_v_i;
*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int64_t *, __pyx_bstruct_cur_ind.buf, __pyx_t_57, __pyx_bstride_0_cur_ind) = __pyx_t_56;
@@ -8547,47 +8671,47 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_right_edge);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 1); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 1); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_dx);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 2); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 2); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_ug);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 3); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 3); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_v);
if (likely(values[4])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 4); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 4); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_image);
if (likely(values[5])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 5); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 5); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 6:
values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_data);
if (likely(values[6])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 6); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 6); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 7:
values[7] = PyDict_GetItem(__pyx_kwds, __pyx_kp_shells);
if (likely(values[7])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 7); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, 7); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "PlaneVoxelIntegration") < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "PlaneVoxelIntegration") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_left_edge = ((PyArrayObject *)values[0]);
__pyx_v_right_edge = ((PyArrayObject *)values[1]);
@@ -8611,7 +8735,7 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("PlaneVoxelIntegration", 1, 8, 8, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.PlaneVoxelIntegration");
return NULL;
@@ -8627,59 +8751,59 @@
__pyx_bstruct_image.buf = NULL;
__pyx_bstruct_data.buf = NULL;
__pyx_bstruct_shells.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_left_edge), __pyx_ptype_5numpy_ndarray, 1, "left_edge", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_right_edge), __pyx_ptype_5numpy_ndarray, 1, "right_edge", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 228; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 229; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ug), __pyx_ptype_5numpy_ndarray, 1, "ug", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 230; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v), __pyx_ptype_5numpy_ndarray, 1, "v", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 231; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_image), __pyx_ptype_5numpy_ndarray, 1, "image", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 232; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_data), __pyx_ptype_5numpy_ndarray, 1, "data", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 233; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_shells), __pyx_ptype_5numpy_ndarray, 1, "shells", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_left_edge), __pyx_ptype_5numpy_ndarray, 1, "left_edge", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_right_edge), __pyx_ptype_5numpy_ndarray, 1, "right_edge", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 228; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 229; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_ug), __pyx_ptype_5numpy_ndarray, 1, "ug", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 230; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v), __pyx_ptype_5numpy_ndarray, 1, "v", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 231; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_image), __pyx_ptype_5numpy_ndarray, 1, "image", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 232; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_data), __pyx_ptype_5numpy_ndarray, 1, "data", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 233; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_shells), __pyx_ptype_5numpy_ndarray, 1, "shells", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 234; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_left_edge, (PyObject*)__pyx_v_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_left_edge, (PyObject*)__pyx_v_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_left_edge = __pyx_bstruct_left_edge.strides[0];
__pyx_bshape_0_left_edge = __pyx_bstruct_left_edge.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_right_edge, (PyObject*)__pyx_v_right_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_right_edge, (PyObject*)__pyx_v_right_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_right_edge = __pyx_bstruct_right_edge.strides[0];
__pyx_bshape_0_right_edge = __pyx_bstruct_right_edge.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dx, (PyObject*)__pyx_v_dx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dx, (PyObject*)__pyx_v_dx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_dx = __pyx_bstruct_dx.strides[0];
__pyx_bshape_0_dx = __pyx_bstruct_dx.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_ug, (PyObject*)__pyx_v_ug, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_ug, (PyObject*)__pyx_v_ug, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_ug = __pyx_bstruct_ug.strides[0]; __pyx_bstride_1_ug = __pyx_bstruct_ug.strides[1];
__pyx_bshape_0_ug = __pyx_bstruct_ug.shape[0]; __pyx_bshape_1_ug = __pyx_bstruct_ug.shape[1];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_v, (PyObject*)__pyx_v_v, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_v, (PyObject*)__pyx_v_v, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_v = __pyx_bstruct_v.strides[0];
__pyx_bshape_0_v = __pyx_bstruct_v.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_image, (PyObject*)__pyx_v_image, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_image, (PyObject*)__pyx_v_image, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_image = __pyx_bstruct_image.strides[0]; __pyx_bstride_1_image = __pyx_bstruct_image.strides[1];
__pyx_bshape_0_image = __pyx_bstruct_image.shape[0]; __pyx_bshape_1_image = __pyx_bstruct_image.shape[1];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_data, (PyObject*)__pyx_v_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_data, (PyObject*)__pyx_v_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_data = __pyx_bstruct_data.strides[0]; __pyx_bstride_1_data = __pyx_bstruct_data.strides[1]; __pyx_bstride_2_data = __pyx_bstruct_data.strides[2];
__pyx_bshape_0_data = __pyx_bstruct_data.shape[0]; __pyx_bshape_1_data = __pyx_bstruct_data.shape[1]; __pyx_bshape_2_data = __pyx_bstruct_data.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_shells, (PyObject*)__pyx_v_shells, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_shells, (PyObject*)__pyx_v_shells, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 227; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_shells = __pyx_bstruct_shells.strides[0]; __pyx_bstride_1_shells = __pyx_bstruct_shells.strides[1];
__pyx_bshape_0_shells = __pyx_bstruct_shells.shape[0]; __pyx_bshape_1_shells = __pyx_bstruct_shells.shape[1];
@@ -8702,7 +8826,7 @@
* cdef int nv = ug.shape[0]
* cdef int nshells = shells.shape[0]
*/
- __pyx_t_1 = PyFloat_FromDouble(9.9999999999999995e-07); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 240; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyFloat_FromDouble(9.9999999999999995e-07); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 240; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_v_dt_tolerance);
__pyx_v_dt_tolerance = __pyx_t_1;
@@ -8733,42 +8857,42 @@
* # Copy things into temporary location for passing between functions
* for vi in range(nv):
*/
- __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_1);
- __pyx_t_1 = PyObject_GetAttr(__pyx_1, __pyx_kp_empty); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_1, __pyx_kp_empty); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_1); __pyx_1 = 0;
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_2));
__Pyx_INCREF(__pyx_int_3);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_int_3);
__Pyx_GIVEREF(__pyx_int_3);
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_3));
PyTuple_SET_ITEM(__pyx_t_3, 0, ((PyObject *)__pyx_t_2));
__Pyx_GIVEREF(((PyObject *)__pyx_t_2));
__pyx_t_2 = 0;
- __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_1));
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
- __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_36); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_GetAttr(__pyx_2, __pyx_kp_36); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
- if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_t_2) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- __pyx_t_2 = PyEval_CallObjectWithKeywords(__pyx_t_1, ((PyObject *)__pyx_t_3), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyEval_CallObjectWithKeywords(__pyx_t_1, ((PyObject *)__pyx_t_3), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
__Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
__Pyx_DECREF(((PyObject *)__pyx_1)); __pyx_1 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_4 = ((PyArrayObject *)__pyx_t_2);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_u, (PyObject*)__pyx_t_4, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {
__pyx_v_u = ((PyArrayObject *)Py_None); __Pyx_INCREF(Py_None); __pyx_bstruct_u.buf = NULL;
- {__pyx_filename = __pyx_f[4]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {__pyx_filename = __pyx_f[5]; __pyx_lineno = 243; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
} else {__pyx_bstride_0_u = __pyx_bstruct_u.strides[0];
__pyx_bshape_0_u = __pyx_bstruct_u.shape[0];
}
@@ -8809,7 +8933,7 @@
* nshells, vi, data, shells, image)
*
*/
- __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_integrate_ray); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_2 = __Pyx_GetName(__pyx_m, __pyx_kp_integrate_ray); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_2);
/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/RayIntegrators.pyx":248
@@ -8819,11 +8943,11 @@
*
* @cython.wraparound(False)
*/
- __pyx_t_2 = PyInt_FromLong(__pyx_v_nshells); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyInt_FromLong(__pyx_v_nshells); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_3 = PyInt_FromLong(__pyx_v_vi); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyInt_FromLong(__pyx_v_vi); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 248; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
- __pyx_t_1 = PyTuple_New(10); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyTuple_New(10); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_1));
__Pyx_INCREF(((PyObject *)__pyx_v_u));
PyTuple_SET_ITEM(__pyx_t_1, 0, ((PyObject *)__pyx_v_u));
@@ -8855,7 +8979,7 @@
__Pyx_GIVEREF(((PyObject *)__pyx_v_image));
__pyx_t_2 = 0;
__pyx_t_3 = 0;
- __pyx_t_3 = PyObject_Call(__pyx_2, ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_Call(__pyx_2, ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 247; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(__pyx_2); __pyx_2 = 0;
__Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
@@ -9102,67 +9226,67 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_v);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 1); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 1); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_left_edge);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 2); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 2); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_right_edge);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 3); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 3); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_dx);
if (likely(values[4])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 4); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 4); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_nshells);
if (likely(values[5])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 5); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 5); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 6:
values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_ind);
if (likely(values[6])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 6); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 6); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 7:
values[7] = PyDict_GetItem(__pyx_kwds, __pyx_kp_data);
if (likely(values[7])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 7); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 7); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 8:
values[8] = PyDict_GetItem(__pyx_kwds, __pyx_kp_shells);
if (likely(values[8])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 8); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 8); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 9:
values[9] = PyDict_GetItem(__pyx_kwds, __pyx_kp_image);
if (likely(values[9])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 9); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, 9); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "integrate_ray") < 0)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "integrate_ray") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_u = ((PyArrayObject *)values[0]);
__pyx_v_v = ((PyArrayObject *)values[1]);
__pyx_v_left_edge = ((PyArrayObject *)values[2]);
__pyx_v_right_edge = ((PyArrayObject *)values[3]);
__pyx_v_dx = ((PyArrayObject *)values[4]);
- __pyx_v_nshells = __Pyx_PyInt_AsInt(values[5]); if (unlikely((__pyx_v_nshells == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_ind = __Pyx_PyInt_AsInt(values[6]); if (unlikely((__pyx_v_ind == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_nshells = __Pyx_PyInt_AsInt(values[5]); if (unlikely((__pyx_v_nshells == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_ind = __Pyx_PyInt_AsInt(values[6]); if (unlikely((__pyx_v_ind == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_v_data = ((PyArrayObject *)values[7]);
__pyx_v_shells = ((PyArrayObject *)values[8]);
__pyx_v_image = ((PyArrayObject *)values[9]);
@@ -9174,15 +9298,15 @@
__pyx_v_left_edge = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 2));
__pyx_v_right_edge = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 3));
__pyx_v_dx = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 4));
- __pyx_v_nshells = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 5)); if (unlikely((__pyx_v_nshells == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_ind = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 6)); if (unlikely((__pyx_v_ind == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_nshells = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 5)); if (unlikely((__pyx_v_nshells == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_ind = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 6)); if (unlikely((__pyx_v_ind == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 257; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_v_data = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 7));
__pyx_v_shells = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 8));
__pyx_v_image = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 9));
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("integrate_ray", 1, 10, 10, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.integrate_ray");
return NULL;
@@ -9195,59 +9319,59 @@
__pyx_bstruct_data.buf = NULL;
__pyx_bstruct_shells.buf = NULL;
__pyx_bstruct_image.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1, "u", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v), __pyx_ptype_5numpy_ndarray, 1, "v", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 253; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_left_edge), __pyx_ptype_5numpy_ndarray, 1, "left_edge", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 254; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_right_edge), __pyx_ptype_5numpy_ndarray, 1, "right_edge", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 255; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_data), __pyx_ptype_5numpy_ndarray, 1, "data", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 258; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_shells), __pyx_ptype_5numpy_ndarray, 1, "shells", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 259; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_image), __pyx_ptype_5numpy_ndarray, 1, "image", 0))) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 260; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_u), __pyx_ptype_5numpy_ndarray, 1, "u", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_v), __pyx_ptype_5numpy_ndarray, 1, "v", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 253; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_left_edge), __pyx_ptype_5numpy_ndarray, 1, "left_edge", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 254; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_right_edge), __pyx_ptype_5numpy_ndarray, 1, "right_edge", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 255; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dx), __pyx_ptype_5numpy_ndarray, 1, "dx", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 256; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_data), __pyx_ptype_5numpy_ndarray, 1, "data", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 258; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_shells), __pyx_ptype_5numpy_ndarray, 1, "shells", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 259; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_image), __pyx_ptype_5numpy_ndarray, 1, "image", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 260; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_u, (PyObject*)__pyx_v_u, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_u, (PyObject*)__pyx_v_u, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_u = __pyx_bstruct_u.strides[0];
__pyx_bshape_0_u = __pyx_bstruct_u.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_v, (PyObject*)__pyx_v_v, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_v, (PyObject*)__pyx_v_v, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_v = __pyx_bstruct_v.strides[0];
__pyx_bshape_0_v = __pyx_bstruct_v.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_left_edge, (PyObject*)__pyx_v_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_left_edge, (PyObject*)__pyx_v_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_left_edge = __pyx_bstruct_left_edge.strides[0];
__pyx_bshape_0_left_edge = __pyx_bstruct_left_edge.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_right_edge, (PyObject*)__pyx_v_right_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_right_edge, (PyObject*)__pyx_v_right_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_right_edge = __pyx_bstruct_right_edge.strides[0];
__pyx_bshape_0_right_edge = __pyx_bstruct_right_edge.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dx, (PyObject*)__pyx_v_dx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dx, (PyObject*)__pyx_v_dx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_dx = __pyx_bstruct_dx.strides[0];
__pyx_bshape_0_dx = __pyx_bstruct_dx.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_data, (PyObject*)__pyx_v_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_data, (PyObject*)__pyx_v_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_data = __pyx_bstruct_data.strides[0]; __pyx_bstride_1_data = __pyx_bstruct_data.strides[1]; __pyx_bstride_2_data = __pyx_bstruct_data.strides[2];
__pyx_bshape_0_data = __pyx_bstruct_data.shape[0]; __pyx_bshape_1_data = __pyx_bstruct_data.shape[1]; __pyx_bshape_2_data = __pyx_bstruct_data.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_shells, (PyObject*)__pyx_v_shells, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_shells, (PyObject*)__pyx_v_shells, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_shells = __pyx_bstruct_shells.strides[0]; __pyx_bstride_1_shells = __pyx_bstruct_shells.strides[1];
__pyx_bshape_0_shells = __pyx_bstruct_shells.shape[0]; __pyx_bshape_1_shells = __pyx_bstruct_shells.shape[1];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_image, (PyObject*)__pyx_v_image, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_image, (PyObject*)__pyx_v_image, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 2, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 252; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_image = __pyx_bstruct_image.strides[0]; __pyx_bstride_1_image = __pyx_bstruct_image.strides[1];
__pyx_bshape_0_image = __pyx_bstruct_image.shape[0]; __pyx_bshape_1_image = __pyx_bstruct_image.shape[1];
@@ -9682,26 +9806,26 @@
* tmax[i] = (((cur_ind[i]+step[i])*dx[i])+left_edge[i]-u[i])/v[i]
* if cur_ind[i] == dims[i] and step[i] < 0:
*/
- __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_1);
- __pyx_t_41 = PyObject_GetAttr(__pyx_1, __pyx_kp_floor); if (unlikely(!__pyx_t_41)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_41 = PyObject_GetAttr(__pyx_1, __pyx_kp_floor); if (unlikely(!__pyx_t_41)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_41);
__Pyx_DECREF(__pyx_1); __pyx_1 = 0;
__pyx_t_42 = __pyx_v_i;
__pyx_t_43 = __pyx_v_i;
__pyx_t_44 = __pyx_v_i;
- __pyx_t_45 = PyFloat_FromDouble(((((__pyx_v_intersect[__pyx_v_i]) + (1e-08 * (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_dx.buf, __pyx_t_42, __pyx_bstride_0_dx)))) - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_left_edge.buf, __pyx_t_43, __pyx_bstride_0_left_edge))) / (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_dx.buf, __pyx_t_44, __pyx_bstride_0_dx)))); if (unlikely(!__pyx_t_45)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_45 = PyFloat_FromDouble(((((__pyx_v_intersect[__pyx_v_i]) + (1e-08 * (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_dx.buf, __pyx_t_42, __pyx_bstride_0_dx)))) - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_left_edge.buf, __pyx_t_43, __pyx_bstride_0_left_edge))) / (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_dx.buf, __pyx_t_44, __pyx_bstride_0_dx)))); if (unlikely(!__pyx_t_45)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_45);
- __pyx_t_46 = PyTuple_New(1); if (unlikely(!__pyx_t_46)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_46 = PyTuple_New(1); if (unlikely(!__pyx_t_46)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_46));
PyTuple_SET_ITEM(__pyx_t_46, 0, __pyx_t_45);
__Pyx_GIVEREF(__pyx_t_45);
__pyx_t_45 = 0;
- __pyx_t_45 = PyObject_Call(__pyx_t_41, ((PyObject *)__pyx_t_46), NULL); if (unlikely(!__pyx_t_45)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_45 = PyObject_Call(__pyx_t_41, ((PyObject *)__pyx_t_46), NULL); if (unlikely(!__pyx_t_45)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_45);
__Pyx_DECREF(__pyx_t_41); __pyx_t_41 = 0;
__Pyx_DECREF(((PyObject *)__pyx_t_46)); __pyx_t_46 = 0;
- __pyx_t_47 = __Pyx_PyInt_from_py_npy_int64(__pyx_t_45); if (unlikely((__pyx_t_47 == (npy_int64)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_47 = __Pyx_PyInt_from_py_npy_int64(__pyx_t_45); if (unlikely((__pyx_t_47 == (npy_int64)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 307; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_45); __pyx_t_45 = 0;
(__pyx_v_cur_ind[__pyx_v_i]) = __pyx_t_47;
@@ -10609,7 +10733,7 @@
return __pyx_r;
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":77
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":78
* cdef np.float64_t dbin
* cdef public object tf_obj
* def __cinit__(self, tf_obj): # <<<<<<<<<<<<<<
@@ -10651,7 +10775,7 @@
else goto __pyx_L5_argtuple_error;
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "__cinit__") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "__cinit__") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 78; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_tf_obj = values[0];
} else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
@@ -10661,7 +10785,7 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 77; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 78; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.TransferFunctionProxy.__cinit__");
return -1;
@@ -10669,7 +10793,7 @@
__pyx_v_temp = ((PyArrayObject *)Py_None); __Pyx_INCREF(Py_None);
__pyx_bstruct_temp.buf = NULL;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":78
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":79
* cdef public object tf_obj
* def __cinit__(self, tf_obj):
* self.tf_obj = tf_obj # <<<<<<<<<<<<<<
@@ -10682,19 +10806,19 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_self)->tf_obj);
((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_self)->tf_obj = __pyx_v_tf_obj;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":80
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":81
* self.tf_obj = tf_obj
* cdef np.ndarray[np.float64_t, ndim=1] temp
* temp = tf_obj.red.y # <<<<<<<<<<<<<<
* self.vs[0] = <np.float64_t *> temp.data
* temp = tf_obj.green.y
*/
- __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_red); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_red); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 81; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = PyObject_GetAttr(__pyx_t_1, __pyx_kp_y); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_GetAttr(__pyx_t_1, __pyx_kp_y); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 81; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 81; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = ((PyArrayObject *)__pyx_t_2);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
@@ -10711,14 +10835,14 @@
}
__pyx_bstride_0_temp = __pyx_bstruct_temp.strides[0];
__pyx_bshape_0_temp = __pyx_bstruct_temp.shape[0];
- if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 81; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_t_3 = 0;
__Pyx_DECREF(((PyObject *)__pyx_v_temp));
__pyx_v_temp = ((PyArrayObject *)__pyx_t_2);
__pyx_t_2 = 0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":81
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":82
* cdef np.ndarray[np.float64_t, ndim=1] temp
* temp = tf_obj.red.y
* self.vs[0] = <np.float64_t *> temp.data # <<<<<<<<<<<<<<
@@ -10727,19 +10851,19 @@
*/
(((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_self)->vs[0]) = ((__pyx_t_5numpy_float64_t *)__pyx_v_temp->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":82
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":83
* temp = tf_obj.red.y
* self.vs[0] = <np.float64_t *> temp.data
* temp = tf_obj.green.y # <<<<<<<<<<<<<<
* self.vs[1] = <np.float64_t *> temp.data
* temp = tf_obj.blue.y
*/
- __pyx_t_2 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_green); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 82; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_green); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 83; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_1 = PyObject_GetAttr(__pyx_t_2, __pyx_kp_y); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 82; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_t_2, __pyx_kp_y); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 83; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 82; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 83; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = ((PyArrayObject *)__pyx_t_1);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
@@ -10756,14 +10880,14 @@
}
__pyx_bstride_0_temp = __pyx_bstruct_temp.strides[0];
__pyx_bshape_0_temp = __pyx_bstruct_temp.shape[0];
- if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 82; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 83; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_t_3 = 0;
__Pyx_DECREF(((PyObject *)__pyx_v_temp));
__pyx_v_temp = ((PyArrayObject *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":83
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":84
* self.vs[0] = <np.float64_t *> temp.data
* temp = tf_obj.green.y
* self.vs[1] = <np.float64_t *> temp.data # <<<<<<<<<<<<<<
@@ -10772,19 +10896,19 @@
*/
(((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_self)->vs[1]) = ((__pyx_t_5numpy_float64_t *)__pyx_v_temp->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":84
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":85
* temp = tf_obj.green.y
* self.vs[1] = <np.float64_t *> temp.data
* temp = tf_obj.blue.y # <<<<<<<<<<<<<<
* self.vs[2] = <np.float64_t *> temp.data
* temp = tf_obj.alpha.y
*/
- __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_blue); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 84; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_blue); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 85; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_2 = PyObject_GetAttr(__pyx_t_1, __pyx_kp_y); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 84; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_GetAttr(__pyx_t_1, __pyx_kp_y); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 85; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 84; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 85; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = ((PyArrayObject *)__pyx_t_2);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
@@ -10801,14 +10925,14 @@
}
__pyx_bstride_0_temp = __pyx_bstruct_temp.strides[0];
__pyx_bshape_0_temp = __pyx_bstruct_temp.shape[0];
- if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 84; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 85; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_t_3 = 0;
__Pyx_DECREF(((PyObject *)__pyx_v_temp));
__pyx_v_temp = ((PyArrayObject *)__pyx_t_2);
__pyx_t_2 = 0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":85
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":86
* self.vs[1] = <np.float64_t *> temp.data
* temp = tf_obj.blue.y
* self.vs[2] = <np.float64_t *> temp.data # <<<<<<<<<<<<<<
@@ -10817,19 +10941,19 @@
*/
(((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_self)->vs[2]) = ((__pyx_t_5numpy_float64_t *)__pyx_v_temp->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":86
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":87
* temp = tf_obj.blue.y
* self.vs[2] = <np.float64_t *> temp.data
* temp = tf_obj.alpha.y # <<<<<<<<<<<<<<
* self.vs[3] = <np.float64_t *> temp.data
* self.x_bounds[0] = tf_obj.x_bounds[0]
*/
- __pyx_t_2 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_alpha); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 86; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_alpha); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 87; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __pyx_t_1 = PyObject_GetAttr(__pyx_t_2, __pyx_kp_y); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 86; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_t_2, __pyx_kp_y); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 87; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- if (!(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 86; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (!(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 87; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_t_3 = ((PyArrayObject *)__pyx_t_1);
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
@@ -10846,14 +10970,14 @@
}
__pyx_bstride_0_temp = __pyx_bstruct_temp.strides[0];
__pyx_bshape_0_temp = __pyx_bstruct_temp.shape[0];
- if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 86; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__pyx_t_4 < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 87; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_t_3 = 0;
__Pyx_DECREF(((PyObject *)__pyx_v_temp));
__pyx_v_temp = ((PyArrayObject *)__pyx_t_1);
__pyx_t_1 = 0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":87
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":88
* self.vs[2] = <np.float64_t *> temp.data
* temp = tf_obj.alpha.y
* self.vs[3] = <np.float64_t *> temp.data # <<<<<<<<<<<<<<
@@ -10862,52 +10986,52 @@
*/
(((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_self)->vs[3]) = ((__pyx_t_5numpy_float64_t *)__pyx_v_temp->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":88
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":89
* temp = tf_obj.alpha.y
* self.vs[3] = <np.float64_t *> temp.data
* self.x_bounds[0] = tf_obj.x_bounds[0] # <<<<<<<<<<<<<<
* self.x_bounds[1] = tf_obj.x_bounds[1]
* self.nbins = tf_obj.nbins
*/
- __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_x_bounds); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 88; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_x_bounds); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 89; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_1 = __Pyx_GetItemInt(__pyx_t_1, 0, sizeof(long), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 88; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = __Pyx_GetItemInt(__pyx_t_1, 0, sizeof(long), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 89; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_1);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- __pyx_t_8 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 88; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 89; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_1); __pyx_1 = 0;
(((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_self)->x_bounds[0]) = __pyx_t_8;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":89
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":90
* self.vs[3] = <np.float64_t *> temp.data
* self.x_bounds[0] = tf_obj.x_bounds[0]
* self.x_bounds[1] = tf_obj.x_bounds[1] # <<<<<<<<<<<<<<
* self.nbins = tf_obj.nbins
* self.dbin = (self.x_bounds[1] - self.x_bounds[0])/self.nbins
*/
- __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_x_bounds); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 89; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_x_bounds); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 90; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_1 = __Pyx_GetItemInt(__pyx_t_1, 1, sizeof(long), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 89; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = __Pyx_GetItemInt(__pyx_t_1, 1, sizeof(long), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 90; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_1);
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- __pyx_t_8 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 89; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 90; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_1); __pyx_1 = 0;
(((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_self)->x_bounds[1]) = __pyx_t_8;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":90
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":91
* self.x_bounds[0] = tf_obj.x_bounds[0]
* self.x_bounds[1] = tf_obj.x_bounds[1]
* self.nbins = tf_obj.nbins # <<<<<<<<<<<<<<
* self.dbin = (self.x_bounds[1] - self.x_bounds[0])/self.nbins
*
*/
- __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_nbins); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 90; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = PyObject_GetAttr(__pyx_v_tf_obj, __pyx_kp_nbins); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 91; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_1);
- __pyx_t_4 = __Pyx_PyInt_AsInt(__pyx_t_1); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 90; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyInt_AsInt(__pyx_t_1); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 91; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_self)->nbins = __pyx_t_4;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":91
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":92
* self.x_bounds[1] = tf_obj.x_bounds[1]
* self.nbins = tf_obj.nbins
* self.dbin = (self.x_bounds[1] - self.x_bounds[0])/self.nbins # <<<<<<<<<<<<<<
@@ -10937,7 +11061,7 @@
return __pyx_r;
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":93
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":94
* self.dbin = (self.x_bounds[1] - self.x_bounds[0])/self.nbins
*
* cdef void eval_transfer(self, np.float64_t dt, np.float64_t dv, # <<<<<<<<<<<<<<
@@ -10957,7 +11081,7 @@
int __pyx_t_1;
__Pyx_SetupRefcountContext("eval_transfer");
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":98
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":99
* cdef int bin_id
* cdef np.float64_t tf, trgba[4], bv, dx, dy, dd,ta
* dx = self.dbin # <<<<<<<<<<<<<<
@@ -10966,7 +11090,7 @@
*/
__pyx_v_dx = __pyx_v_self->dbin;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":103
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":104
* # First locate our points
* bin_id = iclip(<int> floor((dv - self.x_bounds[0]) / dx),
* 0, self.nbins-2) # <<<<<<<<<<<<<<
@@ -10975,7 +11099,7 @@
*/
__pyx_v_bin_id = __pyx_f_2yt_9amr_utils_iclip(((int)floor(((__pyx_v_dv - (__pyx_v_self->x_bounds[0])) / __pyx_v_dx))), 0, (__pyx_v_self->nbins - 2));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":105
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":106
* 0, self.nbins-2)
* # Recall that linear interpolation is y0 + (x-x0) * dx/dy
* bv = self.vs[3][bin_id] # This is x0 # <<<<<<<<<<<<<<
@@ -10984,7 +11108,7 @@
*/
__pyx_v_bv = ((__pyx_v_self->vs[3])[__pyx_v_bin_id]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":106
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":107
* # Recall that linear interpolation is y0 + (x-x0) * dx/dy
* bv = self.vs[3][bin_id] # This is x0
* dy = self.vs[3][bin_id+1]-bv # dy # <<<<<<<<<<<<<<
@@ -10993,7 +11117,7 @@
*/
__pyx_v_dy = (((__pyx_v_self->vs[3])[(__pyx_v_bin_id + 1)]) - __pyx_v_bv);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":107
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":108
* bv = self.vs[3][bin_id] # This is x0
* dy = self.vs[3][bin_id+1]-bv # dy
* dd = dv-(self.x_bounds[0] + bin_id * dx) # x - x0 # <<<<<<<<<<<<<<
@@ -11002,7 +11126,7 @@
*/
__pyx_v_dd = (__pyx_v_dv - ((__pyx_v_self->x_bounds[0]) + (__pyx_v_bin_id * __pyx_v_dx)));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":109
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":110
* dd = dv-(self.x_bounds[0] + bin_id * dx) # x - x0
* # This is our final value for transfer function on the entering face
* tf = bv+dd*(dy/dx) # <<<<<<<<<<<<<<
@@ -11011,7 +11135,7 @@
*/
__pyx_v_tf = (__pyx_v_bv + (__pyx_v_dd * (__pyx_v_dy / __pyx_v_dx)));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":110
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":111
* # This is our final value for transfer function on the entering face
* tf = bv+dd*(dy/dx)
* ta = tf # Store the source alpha # <<<<<<<<<<<<<<
@@ -11020,7 +11144,7 @@
*/
__pyx_v_ta = __pyx_v_tf;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":111
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":112
* tf = bv+dd*(dy/dx)
* ta = tf # Store the source alpha
* for i in range(3): # <<<<<<<<<<<<<<
@@ -11030,7 +11154,7 @@
for (__pyx_t_1 = 0; __pyx_t_1 < 3; __pyx_t_1+=1) {
__pyx_v_i = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":113
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":114
* for i in range(3):
* # Recall that linear interpolation is y0 + (x-x0) * dx/dy
* bv = self.vs[i][bin_id] # This is x0 # <<<<<<<<<<<<<<
@@ -11039,7 +11163,7 @@
*/
__pyx_v_bv = ((__pyx_v_self->vs[__pyx_v_i])[__pyx_v_bin_id]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":114
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":115
* # Recall that linear interpolation is y0 + (x-x0) * dx/dy
* bv = self.vs[i][bin_id] # This is x0
* dy = self.vs[i][bin_id+1]-bv # dy # <<<<<<<<<<<<<<
@@ -11048,7 +11172,7 @@
*/
__pyx_v_dy = (((__pyx_v_self->vs[__pyx_v_i])[(__pyx_v_bin_id + 1)]) - __pyx_v_bv);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":115
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":116
* bv = self.vs[i][bin_id] # This is x0
* dy = self.vs[i][bin_id+1]-bv # dy
* dd = dv-(self.x_bounds[0] + bin_id * dx) # x - x0 # <<<<<<<<<<<<<<
@@ -11057,7 +11181,7 @@
*/
__pyx_v_dd = (__pyx_v_dv - ((__pyx_v_self->x_bounds[0]) + (__pyx_v_bin_id * __pyx_v_dx)));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":117
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":118
* dd = dv-(self.x_bounds[0] + bin_id * dx) # x - x0
* # This is our final value for transfer function on the entering face
* tf = bv+dd*(dy/dx) # <<<<<<<<<<<<<<
@@ -11066,7 +11190,7 @@
*/
__pyx_v_tf = (__pyx_v_bv + (__pyx_v_dd * (__pyx_v_dy / __pyx_v_dx)));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":119
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":120
* tf = bv+dd*(dy/dx)
* # alpha blending
* rgba[i] += (1. - rgba[3])*ta*tf*dt # <<<<<<<<<<<<<<
@@ -11076,7 +11200,7 @@
(__pyx_v_rgba[__pyx_v_i]) += ((((1.0 - (__pyx_v_rgba[3])) * __pyx_v_ta) * __pyx_v_tf) * __pyx_v_dt);
}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":121
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":122
* rgba[i] += (1. - rgba[3])*ta*tf*dt
* #update alpha
* rgba[3] += (1. - rgba[3])*ta*dt # <<<<<<<<<<<<<<
@@ -11088,7 +11212,7 @@
__Pyx_FinishRefcountContext();
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":136
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":137
* cdef np.float64_t *x_vec, *y_vec
*
* def __cinit__(self, # <<<<<<<<<<<<<<
@@ -11161,41 +11285,41 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_vp_dir);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 1); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 1); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_center);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 2); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 2); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_bounds);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 3); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 3); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 4:
values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_image);
if (likely(values[4])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 4); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 4); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 5:
values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_x_vec);
if (likely(values[5])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 5); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 5); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 6:
values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_y_vec);
if (likely(values[6])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 6); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, 6); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "__cinit__") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "__cinit__") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_vp_pos = ((PyArrayObject *)values[0]);
__pyx_v_vp_dir = ((PyArrayObject *)values[1]);
@@ -11217,7 +11341,7 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 7, 7, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.VectorPlane.__cinit__");
return -1;
@@ -11228,50 +11352,50 @@
__pyx_bstruct_image.buf = NULL;
__pyx_bstruct_x_vec.buf = NULL;
__pyx_bstruct_y_vec.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vp_pos), __pyx_ptype_5numpy_ndarray, 1, "vp_pos", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vp_dir), __pyx_ptype_5numpy_ndarray, 1, "vp_dir", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 138; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_center), __pyx_ptype_5numpy_ndarray, 1, "center", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 139; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_image), __pyx_ptype_5numpy_ndarray, 1, "image", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 141; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_vec), __pyx_ptype_5numpy_ndarray, 1, "x_vec", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_vec), __pyx_ptype_5numpy_ndarray, 1, "y_vec", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vp_pos), __pyx_ptype_5numpy_ndarray, 1, "vp_pos", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 138; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vp_dir), __pyx_ptype_5numpy_ndarray, 1, "vp_dir", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 139; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_center), __pyx_ptype_5numpy_ndarray, 1, "center", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 140; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_image), __pyx_ptype_5numpy_ndarray, 1, "image", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 142; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_x_vec), __pyx_ptype_5numpy_ndarray, 1, "x_vec", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 143; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_y_vec), __pyx_ptype_5numpy_ndarray, 1, "y_vec", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 144; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_vp_pos, (PyObject*)__pyx_v_vp_pos, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_vp_pos, (PyObject*)__pyx_v_vp_pos, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_vp_pos = __pyx_bstruct_vp_pos.strides[0]; __pyx_bstride_1_vp_pos = __pyx_bstruct_vp_pos.strides[1]; __pyx_bstride_2_vp_pos = __pyx_bstruct_vp_pos.strides[2];
__pyx_bshape_0_vp_pos = __pyx_bstruct_vp_pos.shape[0]; __pyx_bshape_1_vp_pos = __pyx_bstruct_vp_pos.shape[1]; __pyx_bshape_2_vp_pos = __pyx_bstruct_vp_pos.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_vp_dir, (PyObject*)__pyx_v_vp_dir, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_vp_dir, (PyObject*)__pyx_v_vp_dir, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_vp_dir = __pyx_bstruct_vp_dir.strides[0];
__pyx_bshape_0_vp_dir = __pyx_bstruct_vp_dir.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_center, (PyObject*)__pyx_v_center, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_center, (PyObject*)__pyx_v_center, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_center = __pyx_bstruct_center.strides[0];
__pyx_bshape_0_center = __pyx_bstruct_center.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_image, (PyObject*)__pyx_v_image, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_image, (PyObject*)__pyx_v_image, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_image = __pyx_bstruct_image.strides[0]; __pyx_bstride_1_image = __pyx_bstruct_image.strides[1]; __pyx_bstride_2_image = __pyx_bstruct_image.strides[2];
__pyx_bshape_0_image = __pyx_bstruct_image.shape[0]; __pyx_bshape_1_image = __pyx_bstruct_image.shape[1]; __pyx_bshape_2_image = __pyx_bstruct_image.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_vec, (PyObject*)__pyx_v_x_vec, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_x_vec, (PyObject*)__pyx_v_x_vec, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_x_vec = __pyx_bstruct_x_vec.strides[0];
__pyx_bshape_0_x_vec = __pyx_bstruct_x_vec.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_vec, (PyObject*)__pyx_v_y_vec, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 136; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_y_vec, (PyObject*)__pyx_v_y_vec, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 137; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_y_vec = __pyx_bstruct_y_vec.strides[0];
__pyx_bshape_0_y_vec = __pyx_bstruct_y_vec.shape[0];
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":145
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":146
* np.ndarray[np.float64_t, ndim=1] y_vec):
* cdef int i, j
* self.avp_pos = vp_pos # <<<<<<<<<<<<<<
@@ -11284,7 +11408,7 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->avp_pos);
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->avp_pos = ((PyObject *)__pyx_v_vp_pos);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":146
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":147
* cdef int i, j
* self.avp_pos = vp_pos
* self.avp_dir = vp_dir # <<<<<<<<<<<<<<
@@ -11297,7 +11421,7 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->avp_dir);
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->avp_dir = ((PyObject *)__pyx_v_vp_dir);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":147
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":148
* self.avp_pos = vp_pos
* self.avp_dir = vp_dir
* self.acenter = center # <<<<<<<<<<<<<<
@@ -11310,7 +11434,7 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->acenter);
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->acenter = ((PyObject *)__pyx_v_center);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":148
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":149
* self.avp_dir = vp_dir
* self.acenter = center
* self.aimage = image # <<<<<<<<<<<<<<
@@ -11323,7 +11447,7 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->aimage);
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->aimage = ((PyObject *)__pyx_v_image);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":149
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":150
* self.acenter = center
* self.aimage = image
* self.ax_vec = x_vec # <<<<<<<<<<<<<<
@@ -11336,7 +11460,7 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->ax_vec);
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->ax_vec = ((PyObject *)__pyx_v_x_vec);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":150
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":151
* self.aimage = image
* self.ax_vec = x_vec
* self.ay_vec = y_vec # <<<<<<<<<<<<<<
@@ -11349,7 +11473,7 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->ay_vec);
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->ay_vec = ((PyObject *)__pyx_v_y_vec);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":151
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":152
* self.ax_vec = x_vec
* self.ay_vec = y_vec
* self.vp_pos = <np.float64_t *> vp_pos.data # <<<<<<<<<<<<<<
@@ -11358,7 +11482,7 @@
*/
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->vp_pos = ((__pyx_t_5numpy_float64_t *)__pyx_v_vp_pos->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":152
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":153
* self.ay_vec = y_vec
* self.vp_pos = <np.float64_t *> vp_pos.data
* self.vp_dir = <np.float64_t *> vp_dir.data # <<<<<<<<<<<<<<
@@ -11367,7 +11491,7 @@
*/
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->vp_dir = ((__pyx_t_5numpy_float64_t *)__pyx_v_vp_dir->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":153
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":154
* self.vp_pos = <np.float64_t *> vp_pos.data
* self.vp_dir = <np.float64_t *> vp_dir.data
* self.center = <np.float64_t *> center.data # <<<<<<<<<<<<<<
@@ -11376,7 +11500,7 @@
*/
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->center = ((__pyx_t_5numpy_float64_t *)__pyx_v_center->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":154
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":155
* self.vp_dir = <np.float64_t *> vp_dir.data
* self.center = <np.float64_t *> center.data
* self.image = <np.float64_t *> image.data # <<<<<<<<<<<<<<
@@ -11385,7 +11509,7 @@
*/
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->image = ((__pyx_t_5numpy_float64_t *)__pyx_v_image->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":155
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":156
* self.center = <np.float64_t *> center.data
* self.image = <np.float64_t *> image.data
* self.x_vec = <np.float64_t *> x_vec.data # <<<<<<<<<<<<<<
@@ -11394,7 +11518,7 @@
*/
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->x_vec = ((__pyx_t_5numpy_float64_t *)__pyx_v_x_vec->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":156
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":157
* self.image = <np.float64_t *> image.data
* self.x_vec = <np.float64_t *> x_vec.data
* self.y_vec = <np.float64_t *> y_vec.data # <<<<<<<<<<<<<<
@@ -11403,7 +11527,7 @@
*/
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->y_vec = ((__pyx_t_5numpy_float64_t *)__pyx_v_y_vec->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":157
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":158
* self.x_vec = <np.float64_t *> x_vec.data
* self.y_vec = <np.float64_t *> y_vec.data
* self.nv = vp_pos.shape[0] # <<<<<<<<<<<<<<
@@ -11412,7 +11536,7 @@
*/
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->nv = (__pyx_v_vp_pos->dimensions[0]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":158
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":159
* self.y_vec = <np.float64_t *> y_vec.data
* self.nv = vp_pos.shape[0]
* for i in range(4): self.bounds[i] = bounds[i] # <<<<<<<<<<<<<<
@@ -11421,14 +11545,14 @@
*/
for (__pyx_t_1 = 0; __pyx_t_1 < 4; __pyx_t_1+=1) {
__pyx_v_i = __pyx_t_1;
- __pyx_1 = __Pyx_GetItemInt(__pyx_v_bounds, __pyx_v_i, sizeof(int), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 158; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = __Pyx_GetItemInt(__pyx_v_bounds, __pyx_v_i, sizeof(int), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_1);
- __pyx_t_2 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 158; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_1); __pyx_1 = 0;
(((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->bounds[__pyx_v_i]) = __pyx_t_2;
}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":159
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":160
* self.nv = vp_pos.shape[0]
* for i in range(4): self.bounds[i] = bounds[i]
* self.pdx = (self.bounds[1] - self.bounds[0])/self.nv # <<<<<<<<<<<<<<
@@ -11437,7 +11561,7 @@
*/
((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->pdx = (((((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->bounds[1]) - (((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->bounds[0])) / ((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)__pyx_v_self)->nv);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":160
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":161
* for i in range(4): self.bounds[i] = bounds[i]
* self.pdx = (self.bounds[1] - self.bounds[0])/self.nv
* self.pdy = (self.bounds[3] - self.bounds[2])/self.nv # <<<<<<<<<<<<<<
@@ -11474,7 +11598,7 @@
return __pyx_r;
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":162
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":163
* self.pdy = (self.bounds[3] - self.bounds[2])/self.nv
*
* cdef void get_start_stop(self, np.float64_t *ex, int *rv): # <<<<<<<<<<<<<<
@@ -11494,7 +11618,7 @@
__Pyx_SetupRefcountContext("get_start_stop");
__pyx_v_i = Py_None; __Pyx_INCREF(Py_None);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":165
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":166
* # Extrema need to be re-centered
* cdef np.float64_t cx, cy
* cx = cy = 0.0 # <<<<<<<<<<<<<<
@@ -11504,25 +11628,25 @@
__pyx_v_cx = 0.0;
__pyx_v_cy = 0.0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":166
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":167
* cdef np.float64_t cx, cy
* cx = cy = 0.0
* for i in range(3): # <<<<<<<<<<<<<<
* cx += self.center[i] * self.x_vec[i]
* cy += self.center[i] * self.y_vec[i]
*/
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 166; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 167; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(((PyObject *)__pyx_t_2));
__Pyx_INCREF(__pyx_int_3);
PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_int_3);
__Pyx_GIVEREF(__pyx_int_3);
- __pyx_t_3 = PyObject_Call(__pyx_builtin_range, ((PyObject *)__pyx_t_2), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 166; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyObject_Call(__pyx_builtin_range, ((PyObject *)__pyx_t_2), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 167; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
if (PyList_CheckExact(__pyx_t_3) || PyTuple_CheckExact(__pyx_t_3)) {
__pyx_t_1 = 0; __pyx_t_2 = __pyx_t_3; __Pyx_INCREF(__pyx_t_2);
} else {
- __pyx_t_1 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 166; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_1 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 167; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
}
__Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
@@ -11536,7 +11660,7 @@
} else {
__pyx_t_3 = PyIter_Next(__pyx_t_2);
if (!__pyx_t_3) {
- if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 166; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 167; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
break;
}
__Pyx_GOTREF(__pyx_t_3);
@@ -11545,31 +11669,31 @@
__pyx_v_i = __pyx_t_3;
__pyx_t_3 = 0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":167
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":168
* cx = cy = 0.0
* for i in range(3):
* cx += self.center[i] * self.x_vec[i] # <<<<<<<<<<<<<<
* cy += self.center[i] * self.y_vec[i]
* rv[0] = <int> floor((ex[0] - cx - self.bounds[0])/self.pdx)
*/
- __pyx_t_4 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i); if (unlikely((__pyx_t_4 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 167; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 167; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i); if (unlikely((__pyx_t_4 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 168; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 168; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_cx += ((__pyx_v_self->center[__pyx_t_4]) * (__pyx_v_self->x_vec[__pyx_t_5]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":168
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":169
* for i in range(3):
* cx += self.center[i] * self.x_vec[i]
* cy += self.center[i] * self.y_vec[i] # <<<<<<<<<<<<<<
* rv[0] = <int> floor((ex[0] - cx - self.bounds[0])/self.pdx)
* rv[1] = rv[0] + <int> ceil((ex[1] - ex[0])/self.pdx)
*/
- __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 168; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_t_4 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i); if (unlikely((__pyx_t_4 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 168; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i); if (unlikely((__pyx_t_5 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 169; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = __Pyx_PyIndex_AsSsize_t(__pyx_v_i); if (unlikely((__pyx_t_4 == (Py_ssize_t)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 169; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_v_cy += ((__pyx_v_self->center[__pyx_t_5]) * (__pyx_v_self->y_vec[__pyx_t_4]));
}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":169
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":170
* cx += self.center[i] * self.x_vec[i]
* cy += self.center[i] * self.y_vec[i]
* rv[0] = <int> floor((ex[0] - cx - self.bounds[0])/self.pdx) # <<<<<<<<<<<<<<
@@ -11578,7 +11702,7 @@
*/
(__pyx_v_rv[0]) = ((int)floor(((((__pyx_v_ex[0]) - __pyx_v_cx) - (__pyx_v_self->bounds[0])) / __pyx_v_self->pdx)));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":170
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":171
* cy += self.center[i] * self.y_vec[i]
* rv[0] = <int> floor((ex[0] - cx - self.bounds[0])/self.pdx)
* rv[1] = rv[0] + <int> ceil((ex[1] - ex[0])/self.pdx) # <<<<<<<<<<<<<<
@@ -11587,7 +11711,7 @@
*/
(__pyx_v_rv[1]) = ((__pyx_v_rv[0]) + ((int)ceil((((__pyx_v_ex[1]) - (__pyx_v_ex[0])) / __pyx_v_self->pdx))));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":171
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":172
* rv[0] = <int> floor((ex[0] - cx - self.bounds[0])/self.pdx)
* rv[1] = rv[0] + <int> ceil((ex[1] - ex[0])/self.pdx)
* rv[2] = <int> floor((ex[2] - cy - self.bounds[2])/self.pdy) # <<<<<<<<<<<<<<
@@ -11596,7 +11720,7 @@
*/
(__pyx_v_rv[2]) = ((int)floor(((((__pyx_v_ex[2]) - __pyx_v_cy) - (__pyx_v_self->bounds[2])) / __pyx_v_self->pdy)));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":172
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":173
* rv[1] = rv[0] + <int> ceil((ex[1] - ex[0])/self.pdx)
* rv[2] = <int> floor((ex[2] - cy - self.bounds[2])/self.pdy)
* rv[3] = rv[2] + <int> ceil((ex[3] - ex[2])/self.pdy) # <<<<<<<<<<<<<<
@@ -11615,7 +11739,7 @@
__Pyx_FinishRefcountContext();
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":174
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":175
* rv[3] = rv[2] + <int> ceil((ex[3] - ex[2])/self.pdy)
*
* cdef inline void copy_into(self, np.float64_t *fv, np.float64_t *tv, # <<<<<<<<<<<<<<
@@ -11628,7 +11752,7 @@
int __pyx_t_1;
__Pyx_SetupRefcountContext("copy_into");
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":179
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":180
* # to-vector is flat and 'ni' long
* cdef int k
* for k in range(nk): # <<<<<<<<<<<<<<
@@ -11638,7 +11762,7 @@
for (__pyx_t_1 = 0; __pyx_t_1 < __pyx_v_nk; __pyx_t_1+=1) {
__pyx_v_k = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":180
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":181
* cdef int k
* for k in range(nk):
* tv[k] = fv[(((k*self.nv)+j)*self.nv+i)] # <<<<<<<<<<<<<<
@@ -11651,7 +11775,7 @@
__Pyx_FinishRefcountContext();
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":182
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":183
* tv[k] = fv[(((k*self.nv)+j)*self.nv+i)]
*
* cdef inline void copy_back(self, np.float64_t *fv, np.float64_t *tv, # <<<<<<<<<<<<<<
@@ -11664,7 +11788,7 @@
int __pyx_t_1;
__Pyx_SetupRefcountContext("copy_back");
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":185
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":186
* int i, int j, int nk):
* cdef int k
* for k in range(nk): # <<<<<<<<<<<<<<
@@ -11674,7 +11798,7 @@
for (__pyx_t_1 = 0; __pyx_t_1 < __pyx_v_nk; __pyx_t_1+=1) {
__pyx_v_k = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":186
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":187
* cdef int k
* for k in range(nk):
* tv[(((k*self.nv)+j)*self.nv+i)] = fv[k] # <<<<<<<<<<<<<<
@@ -11687,7 +11811,7 @@
__Pyx_FinishRefcountContext();
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":202
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":203
* @cython.boundscheck(False)
* @cython.wraparound(False)
* def __cinit__(self, # <<<<<<<<<<<<<<
@@ -11746,23 +11870,23 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_left_edge);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 4, 4, 1); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 4, 4, 1); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_right_edge);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 4, 4, 2); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 4, 4, 2); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 3:
values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_dims);
if (likely(values[3])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 4, 4, 3); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 4, 4, 3); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "__cinit__") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "__cinit__") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_data = ((PyArrayObject *)values[0]);
__pyx_v_left_edge = ((PyArrayObject *)values[1]);
@@ -11778,7 +11902,7 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.PartitionedGrid.__cinit__");
return -1;
@@ -11787,36 +11911,36 @@
__pyx_bstruct_left_edge.buf = NULL;
__pyx_bstruct_right_edge.buf = NULL;
__pyx_bstruct_dims.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_data), __pyx_ptype_5numpy_ndarray, 1, "data", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_left_edge), __pyx_ptype_5numpy_ndarray, 1, "left_edge", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 204; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_right_edge), __pyx_ptype_5numpy_ndarray, 1, "right_edge", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 205; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dims), __pyx_ptype_5numpy_ndarray, 1, "dims", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 206; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_data), __pyx_ptype_5numpy_ndarray, 1, "data", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 204; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_left_edge), __pyx_ptype_5numpy_ndarray, 1, "left_edge", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 205; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_right_edge), __pyx_ptype_5numpy_ndarray, 1, "right_edge", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 206; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_dims), __pyx_ptype_5numpy_ndarray, 1, "dims", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 207; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_data, (PyObject*)__pyx_v_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_data, (PyObject*)__pyx_v_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_data = __pyx_bstruct_data.strides[0]; __pyx_bstride_1_data = __pyx_bstruct_data.strides[1]; __pyx_bstride_2_data = __pyx_bstruct_data.strides[2];
__pyx_bshape_0_data = __pyx_bstruct_data.shape[0]; __pyx_bshape_1_data = __pyx_bstruct_data.shape[1]; __pyx_bshape_2_data = __pyx_bstruct_data.shape[2];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_left_edge, (PyObject*)__pyx_v_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_left_edge, (PyObject*)__pyx_v_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_left_edge = __pyx_bstruct_left_edge.strides[0];
__pyx_bshape_0_left_edge = __pyx_bstruct_left_edge.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_right_edge, (PyObject*)__pyx_v_right_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_right_edge, (PyObject*)__pyx_v_right_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_right_edge = __pyx_bstruct_right_edge.strides[0];
__pyx_bshape_0_right_edge = __pyx_bstruct_right_edge.shape[0];
{
__Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dims, (PyObject*)__pyx_v_dims, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 202; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dims, (PyObject*)__pyx_v_dims, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 203; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
}
__pyx_bstride_0_dims = __pyx_bstruct_dims.strides[0];
__pyx_bshape_0_dims = __pyx_bstruct_dims.shape[0];
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":209
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":210
* # The data is likely brought in via a slice, so we copy it
* cdef int i, j, k, size
* self.LeftEdge = left_edge # <<<<<<<<<<<<<<
@@ -11829,7 +11953,7 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->LeftEdge);
((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->LeftEdge = ((PyObject *)__pyx_v_left_edge);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":210
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":211
* cdef int i, j, k, size
* self.LeftEdge = left_edge
* self.RightEdge = right_edge # <<<<<<<<<<<<<<
@@ -11842,7 +11966,7 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->RightEdge);
((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->RightEdge = ((PyObject *)__pyx_v_right_edge);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":211
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":212
* self.LeftEdge = left_edge
* self.RightEdge = right_edge
* for i in range(3): # <<<<<<<<<<<<<<
@@ -11852,7 +11976,7 @@
for (__pyx_t_1 = 0; __pyx_t_1 < 3; __pyx_t_1+=1) {
__pyx_v_i = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":212
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":213
* self.RightEdge = right_edge
* for i in range(3):
* self.left_edge[i] = left_edge[i] # <<<<<<<<<<<<<<
@@ -11862,7 +11986,7 @@
__pyx_t_2 = __pyx_v_i;
(((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->left_edge[__pyx_v_i]) = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_left_edge.buf, __pyx_t_2, __pyx_bstride_0_left_edge));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":213
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":214
* for i in range(3):
* self.left_edge[i] = left_edge[i]
* self.right_edge[i] = right_edge[i] # <<<<<<<<<<<<<<
@@ -11872,7 +11996,7 @@
__pyx_t_3 = __pyx_v_i;
(((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->right_edge[__pyx_v_i]) = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_right_edge.buf, __pyx_t_3, __pyx_bstride_0_right_edge));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":214
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":215
* self.left_edge[i] = left_edge[i]
* self.right_edge[i] = right_edge[i]
* self.dims[i] = dims[i] # <<<<<<<<<<<<<<
@@ -11882,7 +12006,7 @@
__pyx_t_4 = __pyx_v_i;
(((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->dims[__pyx_v_i]) = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int64_t *, __pyx_bstruct_dims.buf, __pyx_t_4, __pyx_bstride_0_dims));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":215
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":216
* self.right_edge[i] = right_edge[i]
* self.dims[i] = dims[i]
* self.dds[i] = (self.right_edge[i] - self.left_edge[i])/dims[i] # <<<<<<<<<<<<<<
@@ -11893,7 +12017,7 @@
(((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->dds[__pyx_v_i]) = (((((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->right_edge[__pyx_v_i]) - (((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->left_edge[__pyx_v_i])) / (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int64_t *, __pyx_bstruct_dims.buf, __pyx_t_5, __pyx_bstride_0_dims)));
}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":216
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":217
* self.dims[i] = dims[i]
* self.dds[i] = (self.right_edge[i] - self.left_edge[i])/dims[i]
* self.my_data = data # <<<<<<<<<<<<<<
@@ -11906,7 +12030,7 @@
__Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->my_data);
((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->my_data = ((PyObject *)__pyx_v_data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":217
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":218
* self.dds[i] = (self.right_edge[i] - self.left_edge[i])/dims[i]
* self.my_data = data
* self.data = <np.float64_t*> data.data # <<<<<<<<<<<<<<
@@ -11938,7 +12062,7 @@
return __pyx_r;
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":221
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":222
* @cython.boundscheck(False)
* @cython.wraparound(False)
* def cast_plane(self, TransferFunctionProxy tf, VectorPlane vp): # <<<<<<<<<<<<<<
@@ -11982,11 +12106,11 @@
values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_vp);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("cast_plane", 1, 2, 2, 1); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("cast_plane", 1, 2, 2, 1); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 222; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "cast_plane") < 0)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "cast_plane") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 222; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
__pyx_v_tf = ((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)values[0]);
__pyx_v_vp = ((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)values[1]);
@@ -11998,15 +12122,15 @@
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("cast_plane", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[5]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("cast_plane", 1, 2, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 222; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
__Pyx_AddTraceback("yt.amr_utils.PartitionedGrid.cast_plane");
return NULL;
__pyx_L4_argument_unpacking_done:;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_tf), __pyx_ptype_2yt_9amr_utils_TransferFunctionProxy, 1, "tf", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vp), __pyx_ptype_2yt_9amr_utils_VectorPlane, 1, "vp", 0))) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 221; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_tf), __pyx_ptype_2yt_9amr_utils_TransferFunctionProxy, 1, "tf", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 222; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_vp), __pyx_ptype_2yt_9amr_utils_VectorPlane, 1, "vp", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 222; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":226
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":227
* # like http://courses.csusm.edu/cs697exz/ray_box.htm
* cdef int vi, vj, hit, i, ni, nj, nn
* self.ns = 5 #* (1 + <int> log2(self.dds[0] / self.min_dds)) # <<<<<<<<<<<<<<
@@ -12015,7 +12139,7 @@
*/
((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->ns = 5;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":229
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":230
* cdef int iter[4]
* cdef np.float64_t v_pos[3], v_dir[3], rgba[4], extrema[4]
* self.calculate_extent(vp, extrema) # <<<<<<<<<<<<<<
@@ -12024,7 +12148,7 @@
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_PartitionedGrid *)((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->__pyx_vtab)->calculate_extent(((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self), __pyx_v_vp, __pyx_v_extrema);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":230
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":231
* cdef np.float64_t v_pos[3], v_dir[3], rgba[4], extrema[4]
* self.calculate_extent(vp, extrema)
* vp.get_start_stop(extrema, iter) # <<<<<<<<<<<<<<
@@ -12033,7 +12157,7 @@
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_VectorPlane *)__pyx_v_vp->__pyx_vtab)->get_start_stop(__pyx_v_vp, __pyx_v_extrema, __pyx_v_iter);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":231
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":232
* self.calculate_extent(vp, extrema)
* vp.get_start_stop(extrema, iter)
* for i in range(4): iter[i] = iclip(iter[i], 0, vp.nv) # <<<<<<<<<<<<<<
@@ -12045,7 +12169,7 @@
(__pyx_v_iter[__pyx_v_i]) = __pyx_f_2yt_9amr_utils_iclip((__pyx_v_iter[__pyx_v_i]), 0, __pyx_v_vp->nv);
}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":232
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":233
* vp.get_start_stop(extrema, iter)
* for i in range(4): iter[i] = iclip(iter[i], 0, vp.nv)
* hit = 0 # <<<<<<<<<<<<<<
@@ -12054,7 +12178,7 @@
*/
__pyx_v_hit = 0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":233
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":234
* for i in range(4): iter[i] = iclip(iter[i], 0, vp.nv)
* hit = 0
* for vj in range(iter[0], iter[1]): # <<<<<<<<<<<<<<
@@ -12064,7 +12188,7 @@
for (__pyx_t_1 = (__pyx_v_iter[0]); __pyx_t_1 < (__pyx_v_iter[1]); __pyx_t_1+=1) {
__pyx_v_vj = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":234
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":235
* hit = 0
* for vj in range(iter[0], iter[1]):
* for vi in range(iter[2], iter[3]): # <<<<<<<<<<<<<<
@@ -12074,7 +12198,7 @@
for (__pyx_t_2 = (__pyx_v_iter[2]); __pyx_t_2 < (__pyx_v_iter[3]); __pyx_t_2+=1) {
__pyx_v_vi = __pyx_t_2;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":235
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":236
* for vj in range(iter[0], iter[1]):
* for vi in range(iter[2], iter[3]):
* vp.copy_into(vp.vp_pos, v_pos, vi, vj, 3) # <<<<<<<<<<<<<<
@@ -12083,7 +12207,7 @@
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_VectorPlane *)__pyx_v_vp->__pyx_vtab)->copy_into(__pyx_v_vp, __pyx_v_vp->vp_pos, __pyx_v_v_pos, __pyx_v_vi, __pyx_v_vj, 3);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":236
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":237
* for vi in range(iter[2], iter[3]):
* vp.copy_into(vp.vp_pos, v_pos, vi, vj, 3)
* vp.copy_into(vp.image, rgba, vi, vj, 4) # <<<<<<<<<<<<<<
@@ -12092,7 +12216,7 @@
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_VectorPlane *)__pyx_v_vp->__pyx_vtab)->copy_into(__pyx_v_vp, __pyx_v_vp->image, __pyx_v_rgba, __pyx_v_vi, __pyx_v_vj, 4);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":237
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":238
* vp.copy_into(vp.vp_pos, v_pos, vi, vj, 3)
* vp.copy_into(vp.image, rgba, vi, vj, 4)
* self.integrate_ray(v_pos, vp.vp_dir, rgba, tf) # <<<<<<<<<<<<<<
@@ -12101,7 +12225,7 @@
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_PartitionedGrid *)((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self)->__pyx_vtab)->integrate_ray(((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self), __pyx_v_v_pos, __pyx_v_vp->vp_dir, __pyx_v_rgba, __pyx_v_tf);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":238
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":239
* vp.copy_into(vp.image, rgba, vi, vj, 4)
* self.integrate_ray(v_pos, vp.vp_dir, rgba, tf)
* vp.copy_back(rgba, vp.image, vi, vj, 4) # <<<<<<<<<<<<<<
@@ -12112,7 +12236,7 @@
}
}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":239
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":240
* self.integrate_ray(v_pos, vp.vp_dir, rgba, tf)
* vp.copy_back(rgba, vp.image, vi, vj, 4)
* return hit # <<<<<<<<<<<<<<
@@ -12120,7 +12244,7 @@
* @cython.boundscheck(False)
*/
__Pyx_XDECREF(__pyx_r);
- __pyx_t_3 = PyInt_FromLong(__pyx_v_hit); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 239; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_3 = PyInt_FromLong(__pyx_v_hit); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 240; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_3);
__pyx_r = __pyx_t_3;
__pyx_t_3 = 0;
@@ -12138,7 +12262,7 @@
return __pyx_r;
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":243
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":244
* @cython.boundscheck(False)
* @cython.wraparound(False)
* cdef void calculate_extent(self, VectorPlane vp, # <<<<<<<<<<<<<<
@@ -12159,7 +12283,7 @@
int __pyx_t_5;
__Pyx_SetupRefcountContext("calculate_extent");
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":247
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":248
* # We do this for all eight corners
* cdef np.float64_t *edges[2], temp
* edges[0] = self.left_edge # <<<<<<<<<<<<<<
@@ -12168,7 +12292,7 @@
*/
(__pyx_v_edges[0]) = __pyx_v_self->left_edge;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":248
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":249
* cdef np.float64_t *edges[2], temp
* edges[0] = self.left_edge
* edges[1] = self.right_edge # <<<<<<<<<<<<<<
@@ -12177,7 +12301,7 @@
*/
(__pyx_v_edges[1]) = __pyx_v_self->right_edge;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":249
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":250
* edges[0] = self.left_edge
* edges[1] = self.right_edge
* extrema[0] = extrema[2] = 1e300; extrema[1] = extrema[3] = -1e300 # <<<<<<<<<<<<<<
@@ -12190,7 +12314,7 @@
(__pyx_v_extrema[1]) = __pyx_t_1;
(__pyx_v_extrema[3]) = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":251
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":252
* extrema[0] = extrema[2] = 1e300; extrema[1] = extrema[3] = -1e300
* cdef int i, j, k
* for i in range(2): # <<<<<<<<<<<<<<
@@ -12200,7 +12324,7 @@
for (__pyx_t_2 = 0; __pyx_t_2 < 2; __pyx_t_2+=1) {
__pyx_v_i = __pyx_t_2;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":252
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":253
* cdef int i, j, k
* for i in range(2):
* for j in range(2): # <<<<<<<<<<<<<<
@@ -12210,7 +12334,7 @@
for (__pyx_t_3 = 0; __pyx_t_3 < 2; __pyx_t_3+=1) {
__pyx_v_j = __pyx_t_3;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":253
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":254
* for i in range(2):
* for j in range(2):
* for k in range(2): # <<<<<<<<<<<<<<
@@ -12220,7 +12344,7 @@
for (__pyx_t_4 = 0; __pyx_t_4 < 2; __pyx_t_4+=1) {
__pyx_v_k = __pyx_t_4;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":255
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":256
* for k in range(2):
* # This should rotate it into the vector plane
* temp = edges[i][0] * vp.x_vec[0] # <<<<<<<<<<<<<<
@@ -12229,7 +12353,7 @@
*/
__pyx_v_temp = (((__pyx_v_edges[__pyx_v_i])[0]) * (__pyx_v_vp->x_vec[0]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":256
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":257
* # This should rotate it into the vector plane
* temp = edges[i][0] * vp.x_vec[0]
* temp += edges[j][1] * vp.x_vec[1] # <<<<<<<<<<<<<<
@@ -12238,7 +12362,7 @@
*/
__pyx_v_temp += (((__pyx_v_edges[__pyx_v_j])[1]) * (__pyx_v_vp->x_vec[1]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":257
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":258
* temp = edges[i][0] * vp.x_vec[0]
* temp += edges[j][1] * vp.x_vec[1]
* temp += edges[k][2] * vp.x_vec[2] # <<<<<<<<<<<<<<
@@ -12247,7 +12371,7 @@
*/
__pyx_v_temp += (((__pyx_v_edges[__pyx_v_k])[2]) * (__pyx_v_vp->x_vec[2]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":258
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":259
* temp += edges[j][1] * vp.x_vec[1]
* temp += edges[k][2] * vp.x_vec[2]
* if temp < extrema[0]: extrema[0] = temp # <<<<<<<<<<<<<<
@@ -12261,7 +12385,7 @@
}
__pyx_L9:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":259
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":260
* temp += edges[k][2] * vp.x_vec[2]
* if temp < extrema[0]: extrema[0] = temp
* if temp > extrema[1]: extrema[1] = temp # <<<<<<<<<<<<<<
@@ -12275,7 +12399,7 @@
}
__pyx_L10:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":260
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":261
* if temp < extrema[0]: extrema[0] = temp
* if temp > extrema[1]: extrema[1] = temp
* temp = edges[i][0] * vp.y_vec[0] # <<<<<<<<<<<<<<
@@ -12284,7 +12408,7 @@
*/
__pyx_v_temp = (((__pyx_v_edges[__pyx_v_i])[0]) * (__pyx_v_vp->y_vec[0]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":261
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":262
* if temp > extrema[1]: extrema[1] = temp
* temp = edges[i][0] * vp.y_vec[0]
* temp += edges[j][1] * vp.y_vec[1] # <<<<<<<<<<<<<<
@@ -12293,7 +12417,7 @@
*/
__pyx_v_temp += (((__pyx_v_edges[__pyx_v_j])[1]) * (__pyx_v_vp->y_vec[1]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":262
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":263
* temp = edges[i][0] * vp.y_vec[0]
* temp += edges[j][1] * vp.y_vec[1]
* temp += edges[k][2] * vp.y_vec[2] # <<<<<<<<<<<<<<
@@ -12302,7 +12426,7 @@
*/
__pyx_v_temp += (((__pyx_v_edges[__pyx_v_k])[2]) * (__pyx_v_vp->y_vec[2]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":263
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":264
* temp += edges[j][1] * vp.y_vec[1]
* temp += edges[k][2] * vp.y_vec[2]
* if temp < extrema[2]: extrema[2] = temp # <<<<<<<<<<<<<<
@@ -12316,7 +12440,7 @@
}
__pyx_L11:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":264
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":265
* temp += edges[k][2] * vp.y_vec[2]
* if temp < extrema[2]: extrema[2] = temp
* if temp > extrema[3]: extrema[3] = temp # <<<<<<<<<<<<<<
@@ -12336,7 +12460,7 @@
__Pyx_FinishRefcountContext();
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":269
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":270
* @cython.boundscheck(False)
* @cython.wraparound(False)
* cdef int integrate_ray(self, np.float64_t v_pos[3], # <<<<<<<<<<<<<<
@@ -12370,7 +12494,7 @@
int __pyx_t_5;
__Pyx_SetupRefcountContext("integrate_ray");
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":274
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":275
* TransferFunctionProxy tf):
* cdef int cur_ind[3], step[3], x, y, i, n, flat_ind, hit, direction
* cdef np.float64_t intersect_t = 1.0 # <<<<<<<<<<<<<<
@@ -12379,7 +12503,7 @@
*/
__pyx_v_intersect_t = 1.0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":278
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":279
* cdef np.float64_t enter_t, dist, alpha, dt
* cdef np.float64_t tr, tl, temp_x, temp_y, dv
* for i in range(3): # <<<<<<<<<<<<<<
@@ -12389,7 +12513,7 @@
for (__pyx_t_1 = 0; __pyx_t_1 < 3; __pyx_t_1+=1) {
__pyx_v_i = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":279
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":280
* cdef np.float64_t tr, tl, temp_x, temp_y, dv
* for i in range(3):
* if (v_dir[i] < 0): # <<<<<<<<<<<<<<
@@ -12399,7 +12523,7 @@
__pyx_t_2 = ((__pyx_v_v_dir[__pyx_v_i]) < 0);
if (__pyx_t_2) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":280
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":281
* for i in range(3):
* if (v_dir[i] < 0):
* step[i] = -1 # <<<<<<<<<<<<<<
@@ -12411,7 +12535,7 @@
}
/*else*/ {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":282
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":283
* step[i] = -1
* else:
* step[i] = 1 # <<<<<<<<<<<<<<
@@ -12422,7 +12546,7 @@
}
__pyx_L5:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":283
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":284
* else:
* step[i] = 1
* x = (i+1) % 3 # <<<<<<<<<<<<<<
@@ -12431,7 +12555,7 @@
*/
__pyx_v_x = ((__pyx_v_i + 1) % 3);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":284
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":285
* step[i] = 1
* x = (i+1) % 3
* y = (i+2) % 3 # <<<<<<<<<<<<<<
@@ -12440,7 +12564,7 @@
*/
__pyx_v_y = ((__pyx_v_i + 2) % 3);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":285
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":286
* x = (i+1) % 3
* y = (i+2) % 3
* tl = (self.left_edge[i] - v_pos[i])/v_dir[i] # <<<<<<<<<<<<<<
@@ -12449,7 +12573,7 @@
*/
__pyx_v_tl = (((__pyx_v_self->left_edge[__pyx_v_i]) - (__pyx_v_v_pos[__pyx_v_i])) / (__pyx_v_v_dir[__pyx_v_i]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":286
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":287
* y = (i+2) % 3
* tl = (self.left_edge[i] - v_pos[i])/v_dir[i]
* tr = (self.right_edge[i] - v_pos[i])/v_dir[i] # <<<<<<<<<<<<<<
@@ -12458,7 +12582,7 @@
*/
__pyx_v_tr = (((__pyx_v_self->right_edge[__pyx_v_i]) - (__pyx_v_v_pos[__pyx_v_i])) / (__pyx_v_v_dir[__pyx_v_i]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":287
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":288
* tl = (self.left_edge[i] - v_pos[i])/v_dir[i]
* tr = (self.right_edge[i] - v_pos[i])/v_dir[i]
* temp_x = (v_pos[x] + tl*v_dir[x]) # <<<<<<<<<<<<<<
@@ -12467,7 +12591,7 @@
*/
__pyx_v_temp_x = ((__pyx_v_v_pos[__pyx_v_x]) + (__pyx_v_tl * (__pyx_v_v_dir[__pyx_v_x])));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":288
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":289
* tr = (self.right_edge[i] - v_pos[i])/v_dir[i]
* temp_x = (v_pos[x] + tl*v_dir[x])
* temp_y = (v_pos[y] + tl*v_dir[y]) # <<<<<<<<<<<<<<
@@ -12476,7 +12600,7 @@
*/
__pyx_v_temp_y = ((__pyx_v_v_pos[__pyx_v_y]) + (__pyx_v_tl * (__pyx_v_v_dir[__pyx_v_y])));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":289
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":290
* temp_x = (v_pos[x] + tl*v_dir[x])
* temp_y = (v_pos[y] + tl*v_dir[y])
* if self.left_edge[x] <= temp_x and temp_x <= self.right_edge[x] and \ # <<<<<<<<<<<<<<
@@ -12486,7 +12610,7 @@
if (((__pyx_v_self->left_edge[__pyx_v_x]) <= __pyx_v_temp_x)) {
if ((__pyx_v_temp_x <= (__pyx_v_self->right_edge[__pyx_v_x]))) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":290
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":291
* temp_y = (v_pos[y] + tl*v_dir[y])
* if self.left_edge[x] <= temp_x and temp_x <= self.right_edge[x] and \
* self.left_edge[y] <= temp_y and temp_y <= self.right_edge[y] and \ # <<<<<<<<<<<<<<
@@ -12496,7 +12620,7 @@
if (((__pyx_v_self->left_edge[__pyx_v_y]) <= __pyx_v_temp_y)) {
if ((__pyx_v_temp_y <= (__pyx_v_self->right_edge[__pyx_v_y]))) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":291
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":292
* if self.left_edge[x] <= temp_x and temp_x <= self.right_edge[x] and \
* self.left_edge[y] <= temp_y and temp_y <= self.right_edge[y] and \
* 0.0 <= tl and tl < intersect_t: # <<<<<<<<<<<<<<
@@ -12526,7 +12650,7 @@
}
if (__pyx_t_2) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":292
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":293
* self.left_edge[y] <= temp_y and temp_y <= self.right_edge[y] and \
* 0.0 <= tl and tl < intersect_t:
* direction = i # <<<<<<<<<<<<<<
@@ -12535,7 +12659,7 @@
*/
__pyx_v_direction = __pyx_v_i;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":293
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":294
* 0.0 <= tl and tl < intersect_t:
* direction = i
* intersect_t = tl # <<<<<<<<<<<<<<
@@ -12547,7 +12671,7 @@
}
__pyx_L6:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":294
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":295
* direction = i
* intersect_t = tl
* temp_x = (v_pos[x] + tr*v_dir[x]) # <<<<<<<<<<<<<<
@@ -12556,7 +12680,7 @@
*/
__pyx_v_temp_x = ((__pyx_v_v_pos[__pyx_v_x]) + (__pyx_v_tr * (__pyx_v_v_dir[__pyx_v_x])));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":295
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":296
* intersect_t = tl
* temp_x = (v_pos[x] + tr*v_dir[x])
* temp_y = (v_pos[y] + tr*v_dir[y]) # <<<<<<<<<<<<<<
@@ -12565,7 +12689,7 @@
*/
__pyx_v_temp_y = ((__pyx_v_v_pos[__pyx_v_y]) + (__pyx_v_tr * (__pyx_v_v_dir[__pyx_v_y])));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":296
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":297
* temp_x = (v_pos[x] + tr*v_dir[x])
* temp_y = (v_pos[y] + tr*v_dir[y])
* if self.left_edge[x] <= temp_x and temp_x <= self.right_edge[x] and \ # <<<<<<<<<<<<<<
@@ -12575,7 +12699,7 @@
if (((__pyx_v_self->left_edge[__pyx_v_x]) <= __pyx_v_temp_x)) {
if ((__pyx_v_temp_x <= (__pyx_v_self->right_edge[__pyx_v_x]))) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":297
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":298
* temp_y = (v_pos[y] + tr*v_dir[y])
* if self.left_edge[x] <= temp_x and temp_x <= self.right_edge[x] and \
* self.left_edge[y] <= temp_y and temp_y <= self.right_edge[y] and \ # <<<<<<<<<<<<<<
@@ -12585,7 +12709,7 @@
if (((__pyx_v_self->left_edge[__pyx_v_y]) <= __pyx_v_temp_y)) {
if ((__pyx_v_temp_y <= (__pyx_v_self->right_edge[__pyx_v_y]))) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":298
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":299
* if self.left_edge[x] <= temp_x and temp_x <= self.right_edge[x] and \
* self.left_edge[y] <= temp_y and temp_y <= self.right_edge[y] and \
* 0.0 <= tr and tr < intersect_t: # <<<<<<<<<<<<<<
@@ -12615,7 +12739,7 @@
}
if (__pyx_t_2) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":299
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":300
* self.left_edge[y] <= temp_y and temp_y <= self.right_edge[y] and \
* 0.0 <= tr and tr < intersect_t:
* direction = i # <<<<<<<<<<<<<<
@@ -12624,7 +12748,7 @@
*/
__pyx_v_direction = __pyx_v_i;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":300
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":301
* 0.0 <= tr and tr < intersect_t:
* direction = i
* intersect_t = tr # <<<<<<<<<<<<<<
@@ -12637,7 +12761,7 @@
__pyx_L7:;
}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":301
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":302
* direction = i
* intersect_t = tr
* if self.left_edge[0] <= v_pos[0] and v_pos[0] <= self.right_edge[0] and \ # <<<<<<<<<<<<<<
@@ -12647,7 +12771,7 @@
if (((__pyx_v_self->left_edge[0]) <= (__pyx_v_v_pos[0]))) {
if (((__pyx_v_v_pos[0]) <= (__pyx_v_self->right_edge[0]))) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":302
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":303
* intersect_t = tr
* if self.left_edge[0] <= v_pos[0] and v_pos[0] <= self.right_edge[0] and \
* self.left_edge[1] <= v_pos[1] and v_pos[1] <= self.right_edge[1] and \ # <<<<<<<<<<<<<<
@@ -12657,7 +12781,7 @@
if (((__pyx_v_self->left_edge[1]) <= (__pyx_v_v_pos[1]))) {
if (((__pyx_v_v_pos[1]) <= (__pyx_v_self->right_edge[1]))) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":303
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":304
* if self.left_edge[0] <= v_pos[0] and v_pos[0] <= self.right_edge[0] and \
* self.left_edge[1] <= v_pos[1] and v_pos[1] <= self.right_edge[1] and \
* self.left_edge[2] <= v_pos[2] and v_pos[2] <= self.right_edge[2]: # <<<<<<<<<<<<<<
@@ -12687,7 +12811,7 @@
}
if (__pyx_t_2) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":304
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":305
* self.left_edge[1] <= v_pos[1] and v_pos[1] <= self.right_edge[1] and \
* self.left_edge[2] <= v_pos[2] and v_pos[2] <= self.right_edge[2]:
* intersect_t = 0.0 # <<<<<<<<<<<<<<
@@ -12699,7 +12823,7 @@
}
__pyx_L8:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":305
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":306
* self.left_edge[2] <= v_pos[2] and v_pos[2] <= self.right_edge[2]:
* intersect_t = 0.0
* if not ((0.0 <= intersect_t) and (intersect_t < 1.0)): return 0 # <<<<<<<<<<<<<<
@@ -12719,7 +12843,7 @@
}
__pyx_L9:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":306
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":307
* intersect_t = 0.0
* if not ((0.0 <= intersect_t) and (intersect_t < 1.0)): return 0
* for i in range(3): # <<<<<<<<<<<<<<
@@ -12729,7 +12853,7 @@
for (__pyx_t_1 = 0; __pyx_t_1 < 3; __pyx_t_1+=1) {
__pyx_v_i = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":307
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":308
* if not ((0.0 <= intersect_t) and (intersect_t < 1.0)): return 0
* for i in range(3):
* intersect[i] = v_pos[i] + intersect_t * v_dir[i] # <<<<<<<<<<<<<<
@@ -12738,7 +12862,7 @@
*/
(__pyx_v_intersect[__pyx_v_i]) = ((__pyx_v_v_pos[__pyx_v_i]) + (__pyx_v_intersect_t * (__pyx_v_v_dir[__pyx_v_i])));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":308
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":309
* for i in range(3):
* intersect[i] = v_pos[i] + intersect_t * v_dir[i]
* cur_ind[i] = <int> floor((intersect[i] + # <<<<<<<<<<<<<<
@@ -12747,7 +12871,7 @@
*/
(__pyx_v_cur_ind[__pyx_v_i]) = ((int)floor(((((__pyx_v_intersect[__pyx_v_i]) + (((__pyx_v_step[__pyx_v_i]) * 1e-08) * (__pyx_v_self->dds[__pyx_v_i]))) - (__pyx_v_self->left_edge[__pyx_v_i])) / (__pyx_v_self->dds[__pyx_v_i]))));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":311
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":312
* step[i]*1e-8*self.dds[i] -
* self.left_edge[i])/self.dds[i])
* tmax[i] = (((cur_ind[i]+step[i])*self.dds[i])+ # <<<<<<<<<<<<<<
@@ -12756,7 +12880,7 @@
*/
(__pyx_v_tmax[__pyx_v_i]) = ((((((__pyx_v_cur_ind[__pyx_v_i]) + (__pyx_v_step[__pyx_v_i])) * (__pyx_v_self->dds[__pyx_v_i])) + (__pyx_v_self->left_edge[__pyx_v_i])) - (__pyx_v_v_pos[__pyx_v_i])) / (__pyx_v_v_dir[__pyx_v_i]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":313
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":314
* tmax[i] = (((cur_ind[i]+step[i])*self.dds[i])+
* self.left_edge[i]-v_pos[i])/v_dir[i]
* if cur_ind[i] == self.dims[i] and step[i] < 0: # <<<<<<<<<<<<<<
@@ -12770,7 +12894,7 @@
}
if (__pyx_t_3) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":314
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":315
* self.left_edge[i]-v_pos[i])/v_dir[i]
* if cur_ind[i] == self.dims[i] and step[i] < 0:
* cur_ind[i] = self.dims[i] - 1 # <<<<<<<<<<<<<<
@@ -12782,7 +12906,7 @@
}
__pyx_L12:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":315
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":316
* if cur_ind[i] == self.dims[i] and step[i] < 0:
* cur_ind[i] = self.dims[i] - 1
* if cur_ind[i] < 0 or cur_ind[i] >= self.dims[i]: return 0 # <<<<<<<<<<<<<<
@@ -12801,7 +12925,7 @@
}
__pyx_L13:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":316
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":317
* cur_ind[i] = self.dims[i] - 1
* if cur_ind[i] < 0 or cur_ind[i] >= self.dims[i]: return 0
* if step[i] > 0: # <<<<<<<<<<<<<<
@@ -12811,7 +12935,7 @@
__pyx_t_3 = ((__pyx_v_step[__pyx_v_i]) > 0);
if (__pyx_t_3) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":317
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":318
* if cur_ind[i] < 0 or cur_ind[i] >= self.dims[i]: return 0
* if step[i] > 0:
* tmax[i] = (((cur_ind[i]+1)*self.dds[i]) # <<<<<<<<<<<<<<
@@ -12823,7 +12947,7 @@
}
__pyx_L14:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":319
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":320
* tmax[i] = (((cur_ind[i]+1)*self.dds[i])
* +self.left_edge[i]-v_pos[i])/v_dir[i]
* if step[i] < 0: # <<<<<<<<<<<<<<
@@ -12833,7 +12957,7 @@
__pyx_t_3 = ((__pyx_v_step[__pyx_v_i]) < 0);
if (__pyx_t_3) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":320
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":321
* +self.left_edge[i]-v_pos[i])/v_dir[i]
* if step[i] < 0:
* tmax[i] = (((cur_ind[i]+0)*self.dds[i]) # <<<<<<<<<<<<<<
@@ -12845,7 +12969,7 @@
}
__pyx_L15:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":322
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":323
* tmax[i] = (((cur_ind[i]+0)*self.dds[i])
* +self.left_edge[i]-v_pos[i])/v_dir[i]
* tdelta[i] = (self.dds[i]/v_dir[i]) # <<<<<<<<<<<<<<
@@ -12854,7 +12978,7 @@
*/
(__pyx_v_tdelta[__pyx_v_i]) = ((__pyx_v_self->dds[__pyx_v_i]) / (__pyx_v_v_dir[__pyx_v_i]));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":323
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":324
* +self.left_edge[i]-v_pos[i])/v_dir[i]
* tdelta[i] = (self.dds[i]/v_dir[i])
* if tdelta[i] < 0: tdelta[i] *= -1 # <<<<<<<<<<<<<<
@@ -12869,7 +12993,7 @@
__pyx_L16:;
}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":325
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":326
* if tdelta[i] < 0: tdelta[i] *= -1
* # We have to jumpstart our calculation
* enter_t = intersect_t # <<<<<<<<<<<<<<
@@ -12878,7 +13002,7 @@
*/
__pyx_v_enter_t = __pyx_v_intersect_t;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":326
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":327
* # We have to jumpstart our calculation
* enter_t = intersect_t
* while 1: # <<<<<<<<<<<<<<
@@ -12889,7 +13013,7 @@
__pyx_t_3 = 1;
if (!__pyx_t_3) break;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":329
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":330
* # dims here is one less than the dimensions of the data,
* # but we are tracing on the grid, not on the data...
* if (not (0 <= cur_ind[0] < self.dims[0])) or \ # <<<<<<<<<<<<<<
@@ -12903,7 +13027,7 @@
}
if (!(!__pyx_t_3)) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":330
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":331
* # but we are tracing on the grid, not on the data...
* if (not (0 <= cur_ind[0] < self.dims[0])) or \
* (not (0 <= cur_ind[1] < self.dims[1])) or \ # <<<<<<<<<<<<<<
@@ -12917,7 +13041,7 @@
}
if (!(!__pyx_t_2)) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":331
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":332
* if (not (0 <= cur_ind[0] < self.dims[0])) or \
* (not (0 <= cur_ind[1] < self.dims[1])) or \
* (not (0 <= cur_ind[2] < self.dims[2])): # <<<<<<<<<<<<<<
@@ -12939,7 +13063,7 @@
}
if (__pyx_t_2) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":332
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":333
* (not (0 <= cur_ind[1] < self.dims[1])) or \
* (not (0 <= cur_ind[2] < self.dims[2])):
* break # <<<<<<<<<<<<<<
@@ -12951,7 +13075,7 @@
}
__pyx_L19:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":333
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":334
* (not (0 <= cur_ind[2] < self.dims[2])):
* break
* hit += 1 # <<<<<<<<<<<<<<
@@ -12960,7 +13084,7 @@
*/
__pyx_v_hit += 1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":334
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":335
* break
* hit += 1
* if tmax[0] < tmax[1]: # <<<<<<<<<<<<<<
@@ -12970,7 +13094,7 @@
__pyx_t_2 = ((__pyx_v_tmax[0]) < (__pyx_v_tmax[1]));
if (__pyx_t_2) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":335
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":336
* hit += 1
* if tmax[0] < tmax[1]:
* if tmax[0] < tmax[2]: # <<<<<<<<<<<<<<
@@ -12980,7 +13104,7 @@
__pyx_t_2 = ((__pyx_v_tmax[0]) < (__pyx_v_tmax[2]));
if (__pyx_t_2) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":337
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":338
* if tmax[0] < tmax[2]:
* self.sample_values(v_pos, v_dir, enter_t, tmax[0], cur_ind,
* rgba, tf) # <<<<<<<<<<<<<<
@@ -12989,7 +13113,7 @@
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self->__pyx_vtab)->sample_values(__pyx_v_self, __pyx_v_v_pos, __pyx_v_v_dir, __pyx_v_enter_t, (__pyx_v_tmax[0]), __pyx_v_cur_ind, __pyx_v_rgba, __pyx_v_tf);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":338
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":339
* self.sample_values(v_pos, v_dir, enter_t, tmax[0], cur_ind,
* rgba, tf)
* cur_ind[0] += step[0] # <<<<<<<<<<<<<<
@@ -12998,7 +13122,7 @@
*/
(__pyx_v_cur_ind[0]) += (__pyx_v_step[0]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":339
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":340
* rgba, tf)
* cur_ind[0] += step[0]
* dt = fmin(tmax[0], 1.0) - enter_t # <<<<<<<<<<<<<<
@@ -13007,7 +13131,7 @@
*/
__pyx_v_dt = (__pyx_f_2yt_9amr_utils_fmin((__pyx_v_tmax[0]), 1.0) - __pyx_v_enter_t);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":340
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":341
* cur_ind[0] += step[0]
* dt = fmin(tmax[0], 1.0) - enter_t
* enter_t = tmax[0] # <<<<<<<<<<<<<<
@@ -13016,7 +13140,7 @@
*/
__pyx_v_enter_t = (__pyx_v_tmax[0]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":341
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":342
* dt = fmin(tmax[0], 1.0) - enter_t
* enter_t = tmax[0]
* tmax[0] += tdelta[0] # <<<<<<<<<<<<<<
@@ -13028,7 +13152,7 @@
}
/*else*/ {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":344
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":345
* else:
* self.sample_values(v_pos, v_dir, enter_t, tmax[2], cur_ind,
* rgba, tf) # <<<<<<<<<<<<<<
@@ -13037,7 +13161,7 @@
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self->__pyx_vtab)->sample_values(__pyx_v_self, __pyx_v_v_pos, __pyx_v_v_dir, __pyx_v_enter_t, (__pyx_v_tmax[2]), __pyx_v_cur_ind, __pyx_v_rgba, __pyx_v_tf);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":345
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":346
* self.sample_values(v_pos, v_dir, enter_t, tmax[2], cur_ind,
* rgba, tf)
* cur_ind[2] += step[2] # <<<<<<<<<<<<<<
@@ -13046,7 +13170,7 @@
*/
(__pyx_v_cur_ind[2]) += (__pyx_v_step[2]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":346
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":347
* rgba, tf)
* cur_ind[2] += step[2]
* dt = fmin(tmax[2], 1.0) - enter_t # <<<<<<<<<<<<<<
@@ -13055,7 +13179,7 @@
*/
__pyx_v_dt = (__pyx_f_2yt_9amr_utils_fmin((__pyx_v_tmax[2]), 1.0) - __pyx_v_enter_t);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":347
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":348
* cur_ind[2] += step[2]
* dt = fmin(tmax[2], 1.0) - enter_t
* enter_t = tmax[2] # <<<<<<<<<<<<<<
@@ -13064,7 +13188,7 @@
*/
__pyx_v_enter_t = (__pyx_v_tmax[2]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":348
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":349
* dt = fmin(tmax[2], 1.0) - enter_t
* enter_t = tmax[2]
* tmax[2] += tdelta[2] # <<<<<<<<<<<<<<
@@ -13078,7 +13202,7 @@
}
/*else*/ {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":350
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":351
* tmax[2] += tdelta[2]
* else:
* if tmax[1] < tmax[2]: # <<<<<<<<<<<<<<
@@ -13088,7 +13212,7 @@
__pyx_t_2 = ((__pyx_v_tmax[1]) < (__pyx_v_tmax[2]));
if (__pyx_t_2) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":352
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":353
* if tmax[1] < tmax[2]:
* self.sample_values(v_pos, v_dir, enter_t, tmax[1], cur_ind,
* rgba, tf) # <<<<<<<<<<<<<<
@@ -13097,7 +13221,7 @@
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self->__pyx_vtab)->sample_values(__pyx_v_self, __pyx_v_v_pos, __pyx_v_v_dir, __pyx_v_enter_t, (__pyx_v_tmax[1]), __pyx_v_cur_ind, __pyx_v_rgba, __pyx_v_tf);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":353
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":354
* self.sample_values(v_pos, v_dir, enter_t, tmax[1], cur_ind,
* rgba, tf)
* cur_ind[1] += step[1] # <<<<<<<<<<<<<<
@@ -13106,7 +13230,7 @@
*/
(__pyx_v_cur_ind[1]) += (__pyx_v_step[1]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":354
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":355
* rgba, tf)
* cur_ind[1] += step[1]
* dt = fmin(tmax[1], 1.0) - enter_t # <<<<<<<<<<<<<<
@@ -13115,7 +13239,7 @@
*/
__pyx_v_dt = (__pyx_f_2yt_9amr_utils_fmin((__pyx_v_tmax[1]), 1.0) - __pyx_v_enter_t);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":355
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":356
* cur_ind[1] += step[1]
* dt = fmin(tmax[1], 1.0) - enter_t
* enter_t = tmax[1] # <<<<<<<<<<<<<<
@@ -13124,7 +13248,7 @@
*/
__pyx_v_enter_t = (__pyx_v_tmax[1]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":356
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":357
* dt = fmin(tmax[1], 1.0) - enter_t
* enter_t = tmax[1]
* tmax[1] += tdelta[1] # <<<<<<<<<<<<<<
@@ -13136,7 +13260,7 @@
}
/*else*/ {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":359
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":360
* else:
* self.sample_values(v_pos, v_dir, enter_t, tmax[2], cur_ind,
* rgba, tf) # <<<<<<<<<<<<<<
@@ -13145,7 +13269,7 @@
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_PartitionedGrid *)__pyx_v_self->__pyx_vtab)->sample_values(__pyx_v_self, __pyx_v_v_pos, __pyx_v_v_dir, __pyx_v_enter_t, (__pyx_v_tmax[2]), __pyx_v_cur_ind, __pyx_v_rgba, __pyx_v_tf);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":360
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":361
* self.sample_values(v_pos, v_dir, enter_t, tmax[2], cur_ind,
* rgba, tf)
* cur_ind[2] += step[2] # <<<<<<<<<<<<<<
@@ -13154,7 +13278,7 @@
*/
(__pyx_v_cur_ind[2]) += (__pyx_v_step[2]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":361
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":362
* rgba, tf)
* cur_ind[2] += step[2]
* dt = fmin(tmax[2], 1.0) - enter_t # <<<<<<<<<<<<<<
@@ -13163,7 +13287,7 @@
*/
__pyx_v_dt = (__pyx_f_2yt_9amr_utils_fmin((__pyx_v_tmax[2]), 1.0) - __pyx_v_enter_t);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":362
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":363
* cur_ind[2] += step[2]
* dt = fmin(tmax[2], 1.0) - enter_t
* enter_t = tmax[2] # <<<<<<<<<<<<<<
@@ -13172,7 +13296,7 @@
*/
__pyx_v_enter_t = (__pyx_v_tmax[2]);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":363
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":364
* dt = fmin(tmax[2], 1.0) - enter_t
* enter_t = tmax[2]
* tmax[2] += tdelta[2] # <<<<<<<<<<<<<<
@@ -13185,7 +13309,7 @@
}
__pyx_L20:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":364
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":365
* enter_t = tmax[2]
* tmax[2] += tdelta[2]
* if enter_t > 1.0: break # <<<<<<<<<<<<<<
@@ -13201,7 +13325,7 @@
}
__pyx_L18_break:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":365
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":366
* tmax[2] += tdelta[2]
* if enter_t > 1.0: break
* return hit # <<<<<<<<<<<<<<
@@ -13217,7 +13341,7 @@
return __pyx_r;
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":367
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":368
* return hit
*
* cdef void sample_values(self, # <<<<<<<<<<<<<<
@@ -13237,7 +13361,7 @@
int __pyx_t_2;
__Pyx_SetupRefcountContext("sample_values");
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":377
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":378
* cdef np.float64_t cp[3], dp[3], temp, dt, t, dv
* cdef int dti, i
* dt = (exit_t - enter_t) / (self.ns-1) # five samples, so divide by four # <<<<<<<<<<<<<<
@@ -13246,7 +13370,7 @@
*/
__pyx_v_dt = ((__pyx_v_exit_t - __pyx_v_enter_t) / (__pyx_v_self->ns - 1));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":378
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":379
* cdef int dti, i
* dt = (exit_t - enter_t) / (self.ns-1) # five samples, so divide by four
* for dti in range(self.ns - 1): # <<<<<<<<<<<<<<
@@ -13256,7 +13380,7 @@
for (__pyx_t_1 = 0; __pyx_t_1 < (__pyx_v_self->ns - 1); __pyx_t_1+=1) {
__pyx_v_dti = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":379
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":380
* dt = (exit_t - enter_t) / (self.ns-1) # five samples, so divide by four
* for dti in range(self.ns - 1):
* t = enter_t + dt * dti # <<<<<<<<<<<<<<
@@ -13265,7 +13389,7 @@
*/
__pyx_v_t = (__pyx_v_enter_t + (__pyx_v_dt * __pyx_v_dti));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":380
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":381
* for dti in range(self.ns - 1):
* t = enter_t + dt * dti
* for i in range(3): # <<<<<<<<<<<<<<
@@ -13275,7 +13399,7 @@
for (__pyx_t_2 = 0; __pyx_t_2 < 3; __pyx_t_2+=1) {
__pyx_v_i = __pyx_t_2;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":381
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":382
* t = enter_t + dt * dti
* for i in range(3):
* cp[i] = v_pos[i] + t * v_dir[i] # <<<<<<<<<<<<<<
@@ -13284,7 +13408,7 @@
*/
(__pyx_v_cp[__pyx_v_i]) = ((__pyx_v_v_pos[__pyx_v_i]) + (__pyx_v_t * (__pyx_v_v_dir[__pyx_v_i])));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":382
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":383
* for i in range(3):
* cp[i] = v_pos[i] + t * v_dir[i]
* dp[i] = fclip(fmod(cp[i], self.dds[i])/self.dds[i], 0, 1.0) # <<<<<<<<<<<<<<
@@ -13294,18 +13418,21 @@
(__pyx_v_dp[__pyx_v_i]) = __pyx_f_2yt_9amr_utils_fclip((fmod((__pyx_v_cp[__pyx_v_i]), (__pyx_v_self->dds[__pyx_v_i])) / (__pyx_v_self->dds[__pyx_v_i])), 0, 1.0);
}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":383
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":384
* cp[i] = v_pos[i] + t * v_dir[i]
* dp[i] = fclip(fmod(cp[i], self.dds[i])/self.dds[i], 0, 1.0)
* dv = trilinear_interpolate(self.dims, ci, dp, self.data) # <<<<<<<<<<<<<<
* tf.eval_transfer(dt, dv, rgba)
+ *
*/
__pyx_v_dv = trilinear_interpolate(__pyx_v_self->dims, __pyx_v_ci, __pyx_v_dp, __pyx_v_self->data);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":384
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":385
* dp[i] = fclip(fmod(cp[i], self.dds[i])/self.dds[i], 0, 1.0)
* dv = trilinear_interpolate(self.dims, ci, dp, self.data)
* tf.eval_transfer(dt, dv, rgba) # <<<<<<<<<<<<<<
+ *
+ * cdef class GridFace:
*/
((struct __pyx_vtabstruct_2yt_9amr_utils_TransferFunctionProxy *)__pyx_v_tf->__pyx_vtab)->eval_transfer(__pyx_v_tf, __pyx_v_dt, __pyx_v_dv, __pyx_v_rgba);
}
@@ -13313,126 +13440,32 @@
__Pyx_FinishRefcountContext();
}
-/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":28
- * @cython.boundscheck(False)
- * @cython.wraparound(False)
- * def CICDeposit_3(np.ndarray[np.float64_t, ndim=1] posx, # <<<<<<<<<<<<<<
- * np.ndarray[np.float64_t, ndim=1] posy,
- * np.ndarray[np.float64_t, ndim=1] posz,
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":395
+ * @cython.boundscheck(False)
+ * @cython.wraparound(False)
+ * def __init__(self, grid, int direction, int left): # <<<<<<<<<<<<<<
+ * self.direction = direction
+ * if left == 1:
*/
-static PyObject *__pyx_pf_2yt_9amr_utils_CICDeposit_3(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
-static PyObject *__pyx_pf_2yt_9amr_utils_CICDeposit_3(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
- PyArrayObject *__pyx_v_posx = 0;
- PyArrayObject *__pyx_v_posy = 0;
- PyArrayObject *__pyx_v_posz = 0;
- PyArrayObject *__pyx_v_mass = 0;
- __pyx_t_5numpy_int64_t __pyx_v_npositions;
- PyArrayObject *__pyx_v_field = 0;
- PyArrayObject *__pyx_v_leftEdge = 0;
- PyArrayObject *__pyx_v_gridDimension = 0;
- __pyx_t_5numpy_float64_t __pyx_v_cellSize;
- int __pyx_v_i1;
- int __pyx_v_j1;
- int __pyx_v_k1;
- int __pyx_v_n;
- double __pyx_v_xpos;
- double __pyx_v_ypos;
- double __pyx_v_zpos;
- double __pyx_v_fact;
- double __pyx_v_edge0;
- double __pyx_v_edge1;
- double __pyx_v_edge2;
- double __pyx_v_le0;
- double __pyx_v_le1;
- double __pyx_v_le2;
- float __pyx_v_dx;
- float __pyx_v_dy;
- float __pyx_v_dz;
- float __pyx_v_dx2;
- float __pyx_v_dy2;
- float __pyx_v_dz2;
- Py_buffer __pyx_bstruct_field;
- Py_ssize_t __pyx_bstride_0_field = 0;
- Py_ssize_t __pyx_bstride_1_field = 0;
- Py_ssize_t __pyx_bstride_2_field = 0;
- Py_ssize_t __pyx_bshape_0_field = 0;
- Py_ssize_t __pyx_bshape_1_field = 0;
- Py_ssize_t __pyx_bshape_2_field = 0;
- Py_buffer __pyx_bstruct_leftEdge;
- Py_ssize_t __pyx_bstride_0_leftEdge = 0;
- Py_ssize_t __pyx_bshape_0_leftEdge = 0;
- Py_buffer __pyx_bstruct_posz;
- Py_ssize_t __pyx_bstride_0_posz = 0;
- Py_ssize_t __pyx_bshape_0_posz = 0;
- Py_buffer __pyx_bstruct_posx;
- Py_ssize_t __pyx_bstride_0_posx = 0;
- Py_ssize_t __pyx_bshape_0_posx = 0;
- Py_buffer __pyx_bstruct_posy;
- Py_ssize_t __pyx_bstride_0_posy = 0;
- Py_ssize_t __pyx_bshape_0_posy = 0;
- Py_buffer __pyx_bstruct_gridDimension;
- Py_ssize_t __pyx_bstride_0_gridDimension = 0;
- Py_ssize_t __pyx_bshape_0_gridDimension = 0;
- Py_buffer __pyx_bstruct_mass;
- Py_ssize_t __pyx_bstride_0_mass = 0;
- Py_ssize_t __pyx_bshape_0_mass = 0;
- PyObject *__pyx_r = NULL;
- long __pyx_t_1;
- long __pyx_t_2;
- long __pyx_t_3;
- long __pyx_t_4;
- long __pyx_t_5;
- long __pyx_t_6;
- int __pyx_t_7;
- int __pyx_t_8;
- int __pyx_t_9;
- int __pyx_t_10;
- int __pyx_t_11;
- long __pyx_t_12;
- long __pyx_t_13;
- long __pyx_t_14;
- int __pyx_t_15;
- int __pyx_t_16;
- long __pyx_t_17;
- long __pyx_t_18;
- int __pyx_t_19;
- long __pyx_t_20;
- int __pyx_t_21;
- long __pyx_t_22;
- int __pyx_t_23;
- int __pyx_t_24;
- int __pyx_t_25;
- long __pyx_t_26;
- int __pyx_t_27;
- long __pyx_t_28;
- long __pyx_t_29;
- int __pyx_t_30;
- int __pyx_t_31;
- int __pyx_t_32;
- long __pyx_t_33;
- int __pyx_t_34;
- int __pyx_t_35;
- long __pyx_t_36;
- int __pyx_t_37;
- int __pyx_t_38;
- int __pyx_t_39;
- int __pyx_t_40;
- int __pyx_t_41;
- int __pyx_t_42;
- static PyObject **__pyx_pyargnames[] = {&__pyx_kp_posx,&__pyx_kp_posy,&__pyx_kp_posz,&__pyx_kp_mass,&__pyx_kp_npositions,&__pyx_kp_field,&__pyx_kp_leftEdge,&__pyx_kp_gridDimension,&__pyx_kp_cellSize,0};
- __Pyx_SetupRefcountContext("CICDeposit_3");
- __pyx_self = __pyx_self;
+static int __pyx_pf_2yt_9amr_utils_8GridFace___init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
+static int __pyx_pf_2yt_9amr_utils_8GridFace___init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
+ PyObject *__pyx_v_grid = 0;
+ int __pyx_v_direction;
+ int __pyx_v_left;
+ int __pyx_v_i;
+ int __pyx_r;
+ PyObject *__pyx_1 = 0;
+ int __pyx_t_1;
+ PyObject *__pyx_t_2 = NULL;
+ __pyx_t_5numpy_float64_t __pyx_t_3;
+ int __pyx_t_4;
+ static PyObject **__pyx_pyargnames[] = {&__pyx_kp_grid,&__pyx_kp_direction,&__pyx_kp_left,0};
+ __Pyx_SetupRefcountContext("__init__");
if (unlikely(__pyx_kwds)) {
Py_ssize_t kw_args = PyDict_Size(__pyx_kwds);
- PyObject* values[9] = {0,0,0,0,0,0,0,0,0};
+ PyObject* values[3] = {0,0,0};
switch (PyTuple_GET_SIZE(__pyx_args)) {
- case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
- case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
- case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
- case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
- case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
- case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
@@ -13441,812 +13474,2440 @@
}
switch (PyTuple_GET_SIZE(__pyx_args)) {
case 0:
- values[0] = PyDict_GetItem(__pyx_kwds, __pyx_kp_posx);
+ values[0] = PyDict_GetItem(__pyx_kwds, __pyx_kp_grid);
if (likely(values[0])) kw_args--;
else goto __pyx_L5_argtuple_error;
case 1:
- values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_posy);
+ values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_direction);
if (likely(values[1])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 1); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__init__", 1, 3, 3, 1); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 395; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
case 2:
- values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_posz);
+ values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_left);
if (likely(values[2])) kw_args--;
else {
- __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 2); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- }
- case 3:
- values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_mass);
- if (likely(values[3])) kw_args--;
- else {
- __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 3); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- }
- case 4:
- values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_npositions);
- if (likely(values[4])) kw_args--;
- else {
- __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 4); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- }
- case 5:
- values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_field);
- if (likely(values[5])) kw_args--;
- else {
- __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 5); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- }
- case 6:
- values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_leftEdge);
- if (likely(values[6])) kw_args--;
- else {
- __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 6); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- }
- case 7:
- values[7] = PyDict_GetItem(__pyx_kwds, __pyx_kp_gridDimension);
- if (likely(values[7])) kw_args--;
- else {
- __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 7); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- }
- case 8:
- values[8] = PyDict_GetItem(__pyx_kwds, __pyx_kp_cellSize);
- if (likely(values[8])) kw_args--;
- else {
- __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 8); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__init__", 1, 3, 3, 2); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 395; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
}
if (unlikely(kw_args > 0)) {
- if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "CICDeposit_3") < 0)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "__init__") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 395; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
- __pyx_v_posx = ((PyArrayObject *)values[0]);
- __pyx_v_posy = ((PyArrayObject *)values[1]);
- __pyx_v_posz = ((PyArrayObject *)values[2]);
- __pyx_v_mass = ((PyArrayObject *)values[3]);
- __pyx_v_npositions = __Pyx_PyInt_from_py_npy_int64(values[4]); if (unlikely((__pyx_v_npositions == (npy_int64)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_field = ((PyArrayObject *)values[5]);
- __pyx_v_leftEdge = ((PyArrayObject *)values[6]);
- __pyx_v_gridDimension = ((PyArrayObject *)values[7]);
- __pyx_v_cellSize = __pyx_PyFloat_AsDouble(values[8]); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- } else if (PyTuple_GET_SIZE(__pyx_args) != 9) {
+ __pyx_v_grid = values[0];
+ __pyx_v_direction = __Pyx_PyInt_AsInt(values[1]); if (unlikely((__pyx_v_direction == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 395; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_left = __Pyx_PyInt_AsInt(values[2]); if (unlikely((__pyx_v_left == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 395; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
goto __pyx_L5_argtuple_error;
} else {
- __pyx_v_posx = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 0));
- __pyx_v_posy = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 1));
- __pyx_v_posz = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 2));
- __pyx_v_mass = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 3));
- __pyx_v_npositions = __Pyx_PyInt_from_py_npy_int64(PyTuple_GET_ITEM(__pyx_args, 4)); if (unlikely((__pyx_v_npositions == (npy_int64)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
- __pyx_v_field = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 5));
- __pyx_v_leftEdge = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 6));
- __pyx_v_gridDimension = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 7));
- __pyx_v_cellSize = __pyx_PyFloat_AsDouble(PyTuple_GET_ITEM(__pyx_args, 8)); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_grid = PyTuple_GET_ITEM(__pyx_args, 0);
+ __pyx_v_direction = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 1)); if (unlikely((__pyx_v_direction == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 395; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_left = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 2)); if (unlikely((__pyx_v_left == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 395; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
}
goto __pyx_L4_argument_unpacking_done;
__pyx_L5_argtuple_error:;
- __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __Pyx_RaiseArgtupleInvalid("__init__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 395; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
__pyx_L3_error:;
- __Pyx_AddTraceback("yt.amr_utils.CICDeposit_3");
- return NULL;
+ __Pyx_AddTraceback("yt.amr_utils.GridFace.__init__");
+ return -1;
__pyx_L4_argument_unpacking_done:;
- __pyx_bstruct_posx.buf = NULL;
- __pyx_bstruct_posy.buf = NULL;
- __pyx_bstruct_posz.buf = NULL;
- __pyx_bstruct_mass.buf = NULL;
- __pyx_bstruct_field.buf = NULL;
- __pyx_bstruct_leftEdge.buf = NULL;
- __pyx_bstruct_gridDimension.buf = NULL;
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_posx), __pyx_ptype_5numpy_ndarray, 1, "posx", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_posy), __pyx_ptype_5numpy_ndarray, 1, "posy", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 29; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_posz), __pyx_ptype_5numpy_ndarray, 1, "posz", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 30; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_mass), __pyx_ptype_5numpy_ndarray, 1, "mass", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_field), __pyx_ptype_5numpy_ndarray, 1, "field", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 33; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_leftEdge), __pyx_ptype_5numpy_ndarray, 1, "leftEdge", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 34; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_gridDimension), __pyx_ptype_5numpy_ndarray, 1, "gridDimension", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 35; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- {
- __Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_posx, (PyObject*)__pyx_v_posx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- }
- __pyx_bstride_0_posx = __pyx_bstruct_posx.strides[0];
- __pyx_bshape_0_posx = __pyx_bstruct_posx.shape[0];
- {
- __Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_posy, (PyObject*)__pyx_v_posy, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- }
- __pyx_bstride_0_posy = __pyx_bstruct_posy.strides[0];
- __pyx_bshape_0_posy = __pyx_bstruct_posy.shape[0];
- {
- __Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_posz, (PyObject*)__pyx_v_posz, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- }
- __pyx_bstride_0_posz = __pyx_bstruct_posz.strides[0];
- __pyx_bshape_0_posz = __pyx_bstruct_posz.shape[0];
- {
- __Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_mass, (PyObject*)__pyx_v_mass, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- }
- __pyx_bstride_0_mass = __pyx_bstruct_mass.strides[0];
- __pyx_bshape_0_mass = __pyx_bstruct_mass.shape[0];
- {
- __Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_field, (PyObject*)__pyx_v_field, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float32_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- }
- __pyx_bstride_0_field = __pyx_bstruct_field.strides[0]; __pyx_bstride_1_field = __pyx_bstruct_field.strides[1]; __pyx_bstride_2_field = __pyx_bstruct_field.strides[2];
- __pyx_bshape_0_field = __pyx_bstruct_field.shape[0]; __pyx_bshape_1_field = __pyx_bstruct_field.shape[1]; __pyx_bshape_2_field = __pyx_bstruct_field.shape[2];
- {
- __Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_leftEdge, (PyObject*)__pyx_v_leftEdge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- }
- __pyx_bstride_0_leftEdge = __pyx_bstruct_leftEdge.strides[0];
- __pyx_bshape_0_leftEdge = __pyx_bstruct_leftEdge.shape[0];
- {
- __Pyx_BufFmt_StackElem __pyx_stack[1];
- if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_gridDimension, (PyObject*)__pyx_v_gridDimension, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- }
- __pyx_bstride_0_gridDimension = __pyx_bstruct_gridDimension.strides[0];
- __pyx_bshape_0_gridDimension = __pyx_bstruct_gridDimension.shape[0];
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":44
- * cdef float dx, dy, dz, dx2, dy2, dz2
- *
- * edge0 = (<float> gridDimension[0]) - 0.5001 # <<<<<<<<<<<<<<
- * edge1 = (<float> gridDimension[1]) - 0.5001
- * edge2 = (<float> gridDimension[2]) - 0.5001
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":396
+ * @cython.wraparound(False)
+ * def __init__(self, grid, int direction, int left):
+ * self.direction = direction # <<<<<<<<<<<<<<
+ * if left == 1:
+ * self.coord = grid.LeftEdge[direction]
+ */
+ ((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_v_self)->direction = __pyx_v_direction;
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":397
+ * def __init__(self, grid, int direction, int left):
+ * self.direction = direction
+ * if left == 1: # <<<<<<<<<<<<<<
+ * self.coord = grid.LeftEdge[direction]
+ * else:
*/
- __pyx_t_1 = 0;
- __pyx_v_edge0 = (((float)(*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int32_t *, __pyx_bstruct_gridDimension.buf, __pyx_t_1, __pyx_bstride_0_gridDimension))) - 0.50009999999999999);
-
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":45
- *
- * edge0 = (<float> gridDimension[0]) - 0.5001
- * edge1 = (<float> gridDimension[1]) - 0.5001 # <<<<<<<<<<<<<<
- * edge2 = (<float> gridDimension[2]) - 0.5001
- * fact = 1.0 / cellSize
- */
- __pyx_t_2 = 1;
- __pyx_v_edge1 = (((float)(*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int32_t *, __pyx_bstruct_gridDimension.buf, __pyx_t_2, __pyx_bstride_0_gridDimension))) - 0.50009999999999999);
-
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":46
- * edge0 = (<float> gridDimension[0]) - 0.5001
- * edge1 = (<float> gridDimension[1]) - 0.5001
- * edge2 = (<float> gridDimension[2]) - 0.5001 # <<<<<<<<<<<<<<
- * fact = 1.0 / cellSize
- *
- */
- __pyx_t_3 = 2;
- __pyx_v_edge2 = (((float)(*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int32_t *, __pyx_bstruct_gridDimension.buf, __pyx_t_3, __pyx_bstride_0_gridDimension))) - 0.50009999999999999);
-
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":47
- * edge1 = (<float> gridDimension[1]) - 0.5001
- * edge2 = (<float> gridDimension[2]) - 0.5001
- * fact = 1.0 / cellSize # <<<<<<<<<<<<<<
- *
- * le0 = leftEdge[0]
- */
- __pyx_v_fact = (1.0 / __pyx_v_cellSize);
-
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":49
- * fact = 1.0 / cellSize
- *
- * le0 = leftEdge[0] # <<<<<<<<<<<<<<
- * le1 = leftEdge[1]
- * le2 = leftEdge[2]
- */
- __pyx_t_4 = 0;
- __pyx_v_le0 = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_leftEdge.buf, __pyx_t_4, __pyx_bstride_0_leftEdge));
-
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":50
- *
- * le0 = leftEdge[0]
- * le1 = leftEdge[1] # <<<<<<<<<<<<<<
- * le2 = leftEdge[2]
- *
- */
- __pyx_t_5 = 1;
- __pyx_v_le1 = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_leftEdge.buf, __pyx_t_5, __pyx_bstride_0_leftEdge));
+ __pyx_t_1 = (__pyx_v_left == 1);
+ if (__pyx_t_1) {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":51
- * le0 = leftEdge[0]
- * le1 = leftEdge[1]
- * le2 = leftEdge[2] # <<<<<<<<<<<<<<
- *
- * for n in range(npositions):
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":398
+ * self.direction = direction
+ * if left == 1:
+ * self.coord = grid.LeftEdge[direction] # <<<<<<<<<<<<<<
+ * else:
+ * self.coord = grid.RightEdge[direction]
*/
- __pyx_t_6 = 2;
- __pyx_v_le2 = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_leftEdge.buf, __pyx_t_6, __pyx_bstride_0_leftEdge));
+ __pyx_t_2 = PyObject_GetAttr(__pyx_v_grid, __pyx_kp_LeftEdge); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_2);
+ __pyx_1 = __Pyx_GetItemInt(__pyx_t_2, __pyx_v_direction, sizeof(int), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
+ __pyx_t_3 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 398; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_1); __pyx_1 = 0;
+ ((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_v_self)->coord = __pyx_t_3;
+ goto __pyx_L6;
+ }
+ /*else*/ {
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":53
- * le2 = leftEdge[2]
- *
- * for n in range(npositions): # <<<<<<<<<<<<<<
- *
- * # Compute the position of the central cell
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":400
+ * self.coord = grid.LeftEdge[direction]
+ * else:
+ * self.coord = grid.RightEdge[direction] # <<<<<<<<<<<<<<
+ * cdef int i
+ * for i in range(3):
*/
- for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_v_npositions; __pyx_t_7+=1) {
- __pyx_v_n = __pyx_t_7;
+ __pyx_t_2 = PyObject_GetAttr(__pyx_v_grid, __pyx_kp_RightEdge); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 400; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_2);
+ __pyx_1 = __Pyx_GetItemInt(__pyx_t_2, __pyx_v_direction, sizeof(int), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 400; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
+ __pyx_t_3 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 400; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_1); __pyx_1 = 0;
+ ((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_v_self)->coord = __pyx_t_3;
+ }
+ __pyx_L6:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":56
- *
- * # Compute the position of the central cell
- * xpos = fmin(fmax((posx[n] - le0)*fact, 0.5001), edge0) # <<<<<<<<<<<<<<
- * ypos = fmin(fmax((posy[n] - le1)*fact, 0.5001), edge1)
- * zpos = fmin(fmax((posz[n] - le2)*fact, 0.5001), edge2)
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":402
+ * self.coord = grid.RightEdge[direction]
+ * cdef int i
+ * for i in range(3): # <<<<<<<<<<<<<<
+ * self.left_edge[i] = grid.LeftEdge[i]
+ * self.right_edge[i] = grid.RightEdge[i]
*/
- __pyx_t_8 = __pyx_v_n;
- __pyx_v_xpos = __pyx_f_2yt_9amr_utils_fmin(__pyx_f_2yt_9amr_utils_fmax((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_posx.buf, __pyx_t_8, __pyx_bstride_0_posx)) - __pyx_v_le0) * __pyx_v_fact), 0.50009999999999999), __pyx_v_edge0);
+ for (__pyx_t_4 = 0; __pyx_t_4 < 3; __pyx_t_4+=1) {
+ __pyx_v_i = __pyx_t_4;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":57
- * # Compute the position of the central cell
- * xpos = fmin(fmax((posx[n] - le0)*fact, 0.5001), edge0)
- * ypos = fmin(fmax((posy[n] - le1)*fact, 0.5001), edge1) # <<<<<<<<<<<<<<
- * zpos = fmin(fmax((posz[n] - le2)*fact, 0.5001), edge2)
- *
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":403
+ * cdef int i
+ * for i in range(3):
+ * self.left_edge[i] = grid.LeftEdge[i] # <<<<<<<<<<<<<<
+ * self.right_edge[i] = grid.RightEdge[i]
+ * self.left_edge[direction] = self.right_edge[direction] = self.coord
*/
- __pyx_t_9 = __pyx_v_n;
- __pyx_v_ypos = __pyx_f_2yt_9amr_utils_fmin(__pyx_f_2yt_9amr_utils_fmax((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_posy.buf, __pyx_t_9, __pyx_bstride_0_posy)) - __pyx_v_le1) * __pyx_v_fact), 0.50009999999999999), __pyx_v_edge1);
+ __pyx_t_2 = PyObject_GetAttr(__pyx_v_grid, __pyx_kp_LeftEdge); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 403; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_2);
+ __pyx_1 = __Pyx_GetItemInt(__pyx_t_2, __pyx_v_i, sizeof(int), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 403; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
+ __pyx_t_3 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 403; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_1); __pyx_1 = 0;
+ (((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_v_self)->left_edge[__pyx_v_i]) = __pyx_t_3;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":58
- * xpos = fmin(fmax((posx[n] - le0)*fact, 0.5001), edge0)
- * ypos = fmin(fmax((posy[n] - le1)*fact, 0.5001), edge1)
- * zpos = fmin(fmax((posz[n] - le2)*fact, 0.5001), edge2) # <<<<<<<<<<<<<<
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":404
+ * for i in range(3):
+ * self.left_edge[i] = grid.LeftEdge[i]
+ * self.right_edge[i] = grid.RightEdge[i] # <<<<<<<<<<<<<<
+ * self.left_edge[direction] = self.right_edge[direction] = self.coord
*
- * i1 = <int> (xpos + 0.5)
*/
- __pyx_t_10 = __pyx_v_n;
- __pyx_v_zpos = __pyx_f_2yt_9amr_utils_fmin(__pyx_f_2yt_9amr_utils_fmax((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_posz.buf, __pyx_t_10, __pyx_bstride_0_posz)) - __pyx_v_le2) * __pyx_v_fact), 0.50009999999999999), __pyx_v_edge2);
+ __pyx_t_2 = PyObject_GetAttr(__pyx_v_grid, __pyx_kp_RightEdge); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_2);
+ __pyx_1 = __Pyx_GetItemInt(__pyx_t_2, __pyx_v_i, sizeof(int), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
+ __pyx_t_3 = __pyx_PyFloat_AsDouble(__pyx_1); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 404; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_1); __pyx_1 = 0;
+ (((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_v_self)->right_edge[__pyx_v_i]) = __pyx_t_3;
+ }
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":60
- * zpos = fmin(fmax((posz[n] - le2)*fact, 0.5001), edge2)
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":405
+ * self.left_edge[i] = grid.LeftEdge[i]
+ * self.right_edge[i] = grid.RightEdge[i]
+ * self.left_edge[direction] = self.right_edge[direction] = self.coord # <<<<<<<<<<<<<<
*
- * i1 = <int> (xpos + 0.5) # <<<<<<<<<<<<<<
- * j1 = <int> (ypos + 0.5)
- * k1 = <int> (zpos + 0.5)
+ * @cython.boundscheck(False)
*/
- __pyx_v_i1 = ((int)(__pyx_v_xpos + 0.5));
+ (((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_v_self)->left_edge[__pyx_v_direction]) = ((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_v_self)->coord;
+ (((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_v_self)->right_edge[__pyx_v_direction]) = ((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_v_self)->coord;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":61
- *
- * i1 = <int> (xpos + 0.5)
- * j1 = <int> (ypos + 0.5) # <<<<<<<<<<<<<<
- * k1 = <int> (zpos + 0.5)
- *
- */
- __pyx_v_j1 = ((int)(__pyx_v_ypos + 0.5));
+ __pyx_r = 0;
+ goto __pyx_L0;
+ __pyx_L1_error:;
+ __Pyx_XDECREF(__pyx_1);
+ __Pyx_XDECREF(__pyx_t_2);
+ __Pyx_AddTraceback("yt.amr_utils.GridFace.__init__");
+ __pyx_r = -1;
+ __pyx_L0:;
+ __Pyx_FinishRefcountContext();
+ return __pyx_r;
+}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":62
- * i1 = <int> (xpos + 0.5)
- * j1 = <int> (ypos + 0.5)
- * k1 = <int> (zpos + 0.5) # <<<<<<<<<<<<<<
- *
- * # Compute the weights
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":409
+ * @cython.boundscheck(False)
+ * @cython.wraparound(False)
+ * cdef int proj_overlap(self, np.float64_t *left_edge, np.float64_t *right_edge): # <<<<<<<<<<<<<<
+ * cdef int xax, yax
+ * xax = (self.direction + 1) % 3
*/
- __pyx_v_k1 = ((int)(__pyx_v_zpos + 0.5));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":65
- *
- * # Compute the weights
- * dx = (<float> i1) + 0.5 - xpos # <<<<<<<<<<<<<<
- * dy = (<float> j1) + 0.5 - ypos
- * dz = (<float> k1) + 0.5 - zpos
- */
- __pyx_v_dx = ((((float)__pyx_v_i1) + 0.5) - __pyx_v_xpos);
+static int __pyx_f_2yt_9amr_utils_8GridFace_proj_overlap(struct __pyx_obj_2yt_9amr_utils_GridFace *__pyx_v_self, __pyx_t_5numpy_float64_t *__pyx_v_left_edge, __pyx_t_5numpy_float64_t *__pyx_v_right_edge) {
+ int __pyx_v_xax;
+ int __pyx_v_yax;
+ int __pyx_r;
+ int __pyx_t_1;
+ __Pyx_SetupRefcountContext("proj_overlap");
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":66
- * # Compute the weights
- * dx = (<float> i1) + 0.5 - xpos
- * dy = (<float> j1) + 0.5 - ypos # <<<<<<<<<<<<<<
- * dz = (<float> k1) + 0.5 - zpos
- * dx2 = 1.0 - dx
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":411
+ * cdef int proj_overlap(self, np.float64_t *left_edge, np.float64_t *right_edge):
+ * cdef int xax, yax
+ * xax = (self.direction + 1) % 3 # <<<<<<<<<<<<<<
+ * yax = (self.direction + 2) % 3
+ * if left_edge[xax] >= self.right_edge[xax]: return 0
+ */
+ __pyx_v_xax = ((__pyx_v_self->direction + 1) % 3);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":412
+ * cdef int xax, yax
+ * xax = (self.direction + 1) % 3
+ * yax = (self.direction + 2) % 3 # <<<<<<<<<<<<<<
+ * if left_edge[xax] >= self.right_edge[xax]: return 0
+ * if right_edge[xax] <= self.left_edge[xax]: return 0
+ */
+ __pyx_v_yax = ((__pyx_v_self->direction + 2) % 3);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":413
+ * xax = (self.direction + 1) % 3
+ * yax = (self.direction + 2) % 3
+ * if left_edge[xax] >= self.right_edge[xax]: return 0 # <<<<<<<<<<<<<<
+ * if right_edge[xax] <= self.left_edge[xax]: return 0
+ * if left_edge[yax] >= self.right_edge[yax]: return 0
*/
- __pyx_v_dy = ((((float)__pyx_v_j1) + 0.5) - __pyx_v_ypos);
+ __pyx_t_1 = ((__pyx_v_left_edge[__pyx_v_xax]) >= (__pyx_v_self->right_edge[__pyx_v_xax]));
+ if (__pyx_t_1) {
+ __pyx_r = 0;
+ goto __pyx_L0;
+ goto __pyx_L3;
+ }
+ __pyx_L3:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":67
- * dx = (<float> i1) + 0.5 - xpos
- * dy = (<float> j1) + 0.5 - ypos
- * dz = (<float> k1) + 0.5 - zpos # <<<<<<<<<<<<<<
- * dx2 = 1.0 - dx
- * dy2 = 1.0 - dy
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":414
+ * yax = (self.direction + 2) % 3
+ * if left_edge[xax] >= self.right_edge[xax]: return 0
+ * if right_edge[xax] <= self.left_edge[xax]: return 0 # <<<<<<<<<<<<<<
+ * if left_edge[yax] >= self.right_edge[yax]: return 0
+ * if right_edge[yax] <= self.left_edge[yax]: return 0
*/
- __pyx_v_dz = ((((float)__pyx_v_k1) + 0.5) - __pyx_v_zpos);
+ __pyx_t_1 = ((__pyx_v_right_edge[__pyx_v_xax]) <= (__pyx_v_self->left_edge[__pyx_v_xax]));
+ if (__pyx_t_1) {
+ __pyx_r = 0;
+ goto __pyx_L0;
+ goto __pyx_L4;
+ }
+ __pyx_L4:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":68
- * dy = (<float> j1) + 0.5 - ypos
- * dz = (<float> k1) + 0.5 - zpos
- * dx2 = 1.0 - dx # <<<<<<<<<<<<<<
- * dy2 = 1.0 - dy
- * dz2 = 1.0 - dz
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":415
+ * if left_edge[xax] >= self.right_edge[xax]: return 0
+ * if right_edge[xax] <= self.left_edge[xax]: return 0
+ * if left_edge[yax] >= self.right_edge[yax]: return 0 # <<<<<<<<<<<<<<
+ * if right_edge[yax] <= self.left_edge[yax]: return 0
+ * return 1
*/
- __pyx_v_dx2 = (1.0 - __pyx_v_dx);
+ __pyx_t_1 = ((__pyx_v_left_edge[__pyx_v_yax]) >= (__pyx_v_self->right_edge[__pyx_v_yax]));
+ if (__pyx_t_1) {
+ __pyx_r = 0;
+ goto __pyx_L0;
+ goto __pyx_L5;
+ }
+ __pyx_L5:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":69
- * dz = (<float> k1) + 0.5 - zpos
- * dx2 = 1.0 - dx
- * dy2 = 1.0 - dy # <<<<<<<<<<<<<<
- * dz2 = 1.0 - dz
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":416
+ * if right_edge[xax] <= self.left_edge[xax]: return 0
+ * if left_edge[yax] >= self.right_edge[yax]: return 0
+ * if right_edge[yax] <= self.left_edge[yax]: return 0 # <<<<<<<<<<<<<<
+ * return 1
*
*/
- __pyx_v_dy2 = (1.0 - __pyx_v_dy);
+ __pyx_t_1 = ((__pyx_v_right_edge[__pyx_v_yax]) <= (__pyx_v_self->left_edge[__pyx_v_yax]));
+ if (__pyx_t_1) {
+ __pyx_r = 0;
+ goto __pyx_L0;
+ goto __pyx_L6;
+ }
+ __pyx_L6:;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":70
- * dx2 = 1.0 - dx
- * dy2 = 1.0 - dy
- * dz2 = 1.0 - dz # <<<<<<<<<<<<<<
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":417
+ * if left_edge[yax] >= self.right_edge[yax]: return 0
+ * if right_edge[yax] <= self.left_edge[yax]: return 0
+ * return 1 # <<<<<<<<<<<<<<
*
- * # Interpolate from field into sumfield
+ * cdef class ProtoPrism:
*/
- __pyx_v_dz2 = (1.0 - __pyx_v_dz);
+ __pyx_r = 1;
+ goto __pyx_L0;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":73
- *
- * # Interpolate from field into sumfield
- * field[i1-1,j1-1,k1-1] += mass[n] * dx * dy * dz # <<<<<<<<<<<<<<
- * field[i1 ,j1-1,k1-1] += mass[n] * dx2 * dy * dz
- * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz
- */
- __pyx_t_11 = __pyx_v_n;
- __pyx_t_12 = (__pyx_v_i1 - 1);
- __pyx_t_13 = (__pyx_v_j1 - 1);
- __pyx_t_14 = (__pyx_v_k1 - 1);
- *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_12, __pyx_bstride_0_field, __pyx_t_13, __pyx_bstride_1_field, __pyx_t_14, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_11, __pyx_bstride_0_mass)) * __pyx_v_dx) * __pyx_v_dy) * __pyx_v_dz);
+ __pyx_r = 0;
+ __pyx_L0:;
+ __Pyx_FinishRefcountContext();
+ return __pyx_r;
+}
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":74
- * # Interpolate from field into sumfield
- * field[i1-1,j1-1,k1-1] += mass[n] * dx * dy * dz
- * field[i1 ,j1-1,k1-1] += mass[n] * dx2 * dy * dz # <<<<<<<<<<<<<<
- * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz
- * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":425
+ * cdef public object RightEdge
+ * cdef public object subgrid_faces
+ * def __cinit__(self, np.ndarray[np.float64_t, ndim=1] left_edge, # <<<<<<<<<<<<<<
+ * np.ndarray[np.float64_t, ndim=1] right_edge,
+ * subgrid_faces):
*/
- __pyx_t_15 = __pyx_v_n;
- __pyx_t_16 = __pyx_v_i1;
- __pyx_t_17 = (__pyx_v_j1 - 1);
- __pyx_t_18 = (__pyx_v_k1 - 1);
- *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_16, __pyx_bstride_0_field, __pyx_t_17, __pyx_bstride_1_field, __pyx_t_18, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_15, __pyx_bstride_0_mass)) * __pyx_v_dx2) * __pyx_v_dy) * __pyx_v_dz);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":75
- * field[i1-1,j1-1,k1-1] += mass[n] * dx * dy * dz
- * field[i1 ,j1-1,k1-1] += mass[n] * dx2 * dy * dz
- * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz # <<<<<<<<<<<<<<
- * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz
- * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2
- */
- __pyx_t_19 = __pyx_v_n;
- __pyx_t_20 = (__pyx_v_i1 - 1);
- __pyx_t_21 = __pyx_v_j1;
- __pyx_t_22 = (__pyx_v_k1 - 1);
- *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_20, __pyx_bstride_0_field, __pyx_t_21, __pyx_bstride_1_field, __pyx_t_22, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_19, __pyx_bstride_0_mass)) * __pyx_v_dx) * __pyx_v_dy2) * __pyx_v_dz);
+static int __pyx_pf_2yt_9amr_utils_10ProtoPrism___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
+static int __pyx_pf_2yt_9amr_utils_10ProtoPrism___cinit__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
+ PyArrayObject *__pyx_v_left_edge = 0;
+ PyArrayObject *__pyx_v_right_edge = 0;
+ PyObject *__pyx_v_subgrid_faces = 0;
+ int __pyx_v_i;
+ Py_buffer __pyx_bstruct_left_edge;
+ Py_ssize_t __pyx_bstride_0_left_edge = 0;
+ Py_ssize_t __pyx_bshape_0_left_edge = 0;
+ Py_buffer __pyx_bstruct_right_edge;
+ Py_ssize_t __pyx_bstride_0_right_edge = 0;
+ Py_ssize_t __pyx_bshape_0_right_edge = 0;
+ int __pyx_r;
+ int __pyx_t_1;
+ int __pyx_t_2;
+ int __pyx_t_3;
+ int __pyx_t_4;
+ static PyObject **__pyx_pyargnames[] = {&__pyx_kp_left_edge,&__pyx_kp_right_edge,&__pyx_kp_subgrid_faces,0};
+ __Pyx_SetupRefcountContext("__cinit__");
+ if (unlikely(__pyx_kwds)) {
+ Py_ssize_t kw_args = PyDict_Size(__pyx_kwds);
+ PyObject* values[3] = {0,0,0};
+ switch (PyTuple_GET_SIZE(__pyx_args)) {
+ case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
+ case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
+ case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
+ case 0: break;
+ default: goto __pyx_L5_argtuple_error;
+ }
+ switch (PyTuple_GET_SIZE(__pyx_args)) {
+ case 0:
+ values[0] = PyDict_GetItem(__pyx_kwds, __pyx_kp_left_edge);
+ if (likely(values[0])) kw_args--;
+ else goto __pyx_L5_argtuple_error;
+ case 1:
+ values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_right_edge);
+ if (likely(values[1])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 3, 3, 1); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 425; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 2:
+ values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_subgrid_faces);
+ if (likely(values[2])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 3, 3, 2); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 425; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ }
+ if (unlikely(kw_args > 0)) {
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "__cinit__") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 425; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ __pyx_v_left_edge = ((PyArrayObject *)values[0]);
+ __pyx_v_right_edge = ((PyArrayObject *)values[1]);
+ __pyx_v_subgrid_faces = values[2];
+ } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
+ goto __pyx_L5_argtuple_error;
+ } else {
+ __pyx_v_left_edge = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 0));
+ __pyx_v_right_edge = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 1));
+ __pyx_v_subgrid_faces = PyTuple_GET_ITEM(__pyx_args, 2);
+ }
+ goto __pyx_L4_argument_unpacking_done;
+ __pyx_L5_argtuple_error:;
+ __Pyx_RaiseArgtupleInvalid("__cinit__", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 425; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_L3_error:;
+ __Pyx_AddTraceback("yt.amr_utils.ProtoPrism.__cinit__");
+ return -1;
+ __pyx_L4_argument_unpacking_done:;
+ __pyx_bstruct_left_edge.buf = NULL;
+ __pyx_bstruct_right_edge.buf = NULL;
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_left_edge), __pyx_ptype_5numpy_ndarray, 1, "left_edge", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 425; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_right_edge), __pyx_ptype_5numpy_ndarray, 1, "right_edge", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 426; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_left_edge, (PyObject*)__pyx_v_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 425; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_left_edge = __pyx_bstruct_left_edge.strides[0];
+ __pyx_bshape_0_left_edge = __pyx_bstruct_left_edge.shape[0];
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_right_edge, (PyObject*)__pyx_v_right_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 425; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_right_edge = __pyx_bstruct_right_edge.strides[0];
+ __pyx_bshape_0_right_edge = __pyx_bstruct_right_edge.shape[0];
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":76
- * field[i1 ,j1-1,k1-1] += mass[n] * dx2 * dy * dz
- * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz
- * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz # <<<<<<<<<<<<<<
- * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2
- * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":429
+ * subgrid_faces):
+ * cdef int i
+ * self.LeftEdge = left_edge # <<<<<<<<<<<<<<
+ * self.RightEdge = right_edge
+ * for i in range(3):
*/
- __pyx_t_23 = __pyx_v_n;
- __pyx_t_24 = __pyx_v_i1;
- __pyx_t_25 = __pyx_v_j1;
- __pyx_t_26 = (__pyx_v_k1 - 1);
- *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_24, __pyx_bstride_0_field, __pyx_t_25, __pyx_bstride_1_field, __pyx_t_26, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_23, __pyx_bstride_0_mass)) * __pyx_v_dx2) * __pyx_v_dy2) * __pyx_v_dz);
+ __Pyx_INCREF(((PyObject *)__pyx_v_left_edge));
+ __Pyx_GIVEREF(((PyObject *)__pyx_v_left_edge));
+ __Pyx_GOTREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->LeftEdge);
+ __Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->LeftEdge);
+ ((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->LeftEdge = ((PyObject *)__pyx_v_left_edge);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":77
- * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz
- * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz
- * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2 # <<<<<<<<<<<<<<
- * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2
- * field[i1-1,j1 ,k1 ] += mass[n] * dx * dy2 * dz2
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":430
+ * cdef int i
+ * self.LeftEdge = left_edge
+ * self.RightEdge = right_edge # <<<<<<<<<<<<<<
+ * for i in range(3):
+ * self.left_edge[i] = left_edge[i]
*/
- __pyx_t_27 = __pyx_v_n;
- __pyx_t_28 = (__pyx_v_i1 - 1);
- __pyx_t_29 = (__pyx_v_j1 - 1);
- __pyx_t_30 = __pyx_v_k1;
- *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_28, __pyx_bstride_0_field, __pyx_t_29, __pyx_bstride_1_field, __pyx_t_30, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_27, __pyx_bstride_0_mass)) * __pyx_v_dx) * __pyx_v_dy) * __pyx_v_dz2);
+ __Pyx_INCREF(((PyObject *)__pyx_v_right_edge));
+ __Pyx_GIVEREF(((PyObject *)__pyx_v_right_edge));
+ __Pyx_GOTREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->RightEdge);
+ __Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->RightEdge);
+ ((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->RightEdge = ((PyObject *)__pyx_v_right_edge);
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":78
- * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz
- * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2
- * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2 # <<<<<<<<<<<<<<
- * field[i1-1,j1 ,k1 ] += mass[n] * dx * dy2 * dz2
- * field[i1 ,j1 ,k1 ] += mass[n] * dx2 * dy2 * dz2
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":431
+ * self.LeftEdge = left_edge
+ * self.RightEdge = right_edge
+ * for i in range(3): # <<<<<<<<<<<<<<
+ * self.left_edge[i] = left_edge[i]
+ * self.right_edge[i] = right_edge[i]
*/
- __pyx_t_31 = __pyx_v_n;
- __pyx_t_32 = __pyx_v_i1;
- __pyx_t_33 = (__pyx_v_j1 - 1);
- __pyx_t_34 = __pyx_v_k1;
- *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_32, __pyx_bstride_0_field, __pyx_t_33, __pyx_bstride_1_field, __pyx_t_34, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_31, __pyx_bstride_0_mass)) * __pyx_v_dx2) * __pyx_v_dy) * __pyx_v_dz2);
+ for (__pyx_t_1 = 0; __pyx_t_1 < 3; __pyx_t_1+=1) {
+ __pyx_v_i = __pyx_t_1;
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":79
- * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2
- * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2
- * field[i1-1,j1 ,k1 ] += mass[n] * dx * dy2 * dz2 # <<<<<<<<<<<<<<
- * field[i1 ,j1 ,k1 ] += mass[n] * dx2 * dy2 * dz2
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":432
+ * self.RightEdge = right_edge
+ * for i in range(3):
+ * self.left_edge[i] = left_edge[i] # <<<<<<<<<<<<<<
+ * self.right_edge[i] = right_edge[i]
+ * self.subgrid_faces = subgrid_faces
*/
- __pyx_t_35 = __pyx_v_n;
- __pyx_t_36 = (__pyx_v_i1 - 1);
- __pyx_t_37 = __pyx_v_j1;
- __pyx_t_38 = __pyx_v_k1;
- *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_36, __pyx_bstride_0_field, __pyx_t_37, __pyx_bstride_1_field, __pyx_t_38, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_35, __pyx_bstride_0_mass)) * __pyx_v_dx) * __pyx_v_dy2) * __pyx_v_dz2);
+ __pyx_t_2 = __pyx_v_i;
+ __pyx_t_3 = -1;
+ if (__pyx_t_2 < 0) {
+ __pyx_t_2 += __pyx_bshape_0_left_edge;
+ if (unlikely(__pyx_t_2 < 0)) __pyx_t_3 = 0;
+ } else if (unlikely(__pyx_t_2 >= __pyx_bshape_0_left_edge)) __pyx_t_3 = 0;
+ if (unlikely(__pyx_t_3 != -1)) {
+ __Pyx_RaiseBufferIndexError(__pyx_t_3);
+ {__pyx_filename = __pyx_f[3]; __pyx_lineno = 432; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ (((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->left_edge[__pyx_v_i]) = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_left_edge.buf, __pyx_t_2, __pyx_bstride_0_left_edge));
- /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":80
- * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2
- * field[i1-1,j1 ,k1 ] += mass[n] * dx * dy2 * dz2
- * field[i1 ,j1 ,k1 ] += mass[n] * dx2 * dy2 * dz2 # <<<<<<<<<<<<<<
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":433
+ * for i in range(3):
+ * self.left_edge[i] = left_edge[i]
+ * self.right_edge[i] = right_edge[i] # <<<<<<<<<<<<<<
+ * self.subgrid_faces = subgrid_faces
+ *
*/
- __pyx_t_39 = __pyx_v_n;
- __pyx_t_40 = __pyx_v_i1;
- __pyx_t_41 = __pyx_v_j1;
- __pyx_t_42 = __pyx_v_k1;
- *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_40, __pyx_bstride_0_field, __pyx_t_41, __pyx_bstride_1_field, __pyx_t_42, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_39, __pyx_bstride_0_mass)) * __pyx_v_dx2) * __pyx_v_dy2) * __pyx_v_dz2);
+ __pyx_t_3 = __pyx_v_i;
+ __pyx_t_4 = -1;
+ if (__pyx_t_3 < 0) {
+ __pyx_t_3 += __pyx_bshape_0_right_edge;
+ if (unlikely(__pyx_t_3 < 0)) __pyx_t_4 = 0;
+ } else if (unlikely(__pyx_t_3 >= __pyx_bshape_0_right_edge)) __pyx_t_4 = 0;
+ if (unlikely(__pyx_t_4 != -1)) {
+ __Pyx_RaiseBufferIndexError(__pyx_t_4);
+ {__pyx_filename = __pyx_f[3]; __pyx_lineno = 433; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ (((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->right_edge[__pyx_v_i]) = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_right_edge.buf, __pyx_t_3, __pyx_bstride_0_right_edge));
}
- __pyx_r = Py_None; __Pyx_INCREF(Py_None);
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":434
+ * self.left_edge[i] = left_edge[i]
+ * self.right_edge[i] = right_edge[i]
+ * self.subgrid_faces = subgrid_faces # <<<<<<<<<<<<<<
+ *
+ * @cython.boundscheck(False)
+ */
+ __Pyx_INCREF(__pyx_v_subgrid_faces);
+ __Pyx_GIVEREF(__pyx_v_subgrid_faces);
+ __Pyx_GOTREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->subgrid_faces);
+ __Pyx_DECREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->subgrid_faces);
+ ((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->subgrid_faces = __pyx_v_subgrid_faces;
+
+ __pyx_r = 0;
goto __pyx_L0;
__pyx_L1_error:;
{ PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
__Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_field);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_leftEdge);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posz);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posx);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posy);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_gridDimension);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_mass);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_left_edge);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_right_edge);
__Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
- __Pyx_AddTraceback("yt.amr_utils.CICDeposit_3");
- __pyx_r = NULL;
+ __Pyx_AddTraceback("yt.amr_utils.ProtoPrism.__cinit__");
+ __pyx_r = -1;
goto __pyx_L2;
__pyx_L0:;
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_field);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_leftEdge);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posz);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posx);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posy);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_gridDimension);
- __Pyx_SafeReleaseBuffer(&__pyx_bstruct_mass);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_left_edge);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_right_edge);
__pyx_L2:;
- __Pyx_XGIVEREF(__pyx_r);
__Pyx_FinishRefcountContext();
return __pyx_r;
}
-/* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":152
- * # experimental exception made for __getbuffer__ and __releasebuffer__
- * # -- the details of this may change.
- * def __getbuffer__(ndarray self, Py_buffer* info, int flags): # <<<<<<<<<<<<<<
- * # This implementation of getbuffer is geared towards Cython
- * # requirements, and does not yet fullfill the PEP.
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":438
+ * @cython.boundscheck(False)
+ * @cython.wraparound(False)
+ * def sweep(self, int direction = 0, int stack = 0): # <<<<<<<<<<<<<<
+ * cdef int i
+ * cdef GridFace face
*/
-static int __pyx_pf_5numpy_7ndarray___getbuffer__(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags); /*proto*/
-static int __pyx_pf_5numpy_7ndarray___getbuffer__(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags) {
- int __pyx_v_copy_shape;
+static PyObject *__pyx_pf_2yt_9amr_utils_10ProtoPrism_sweep(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
+static PyObject *__pyx_pf_2yt_9amr_utils_10ProtoPrism_sweep(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
+ int __pyx_v_direction;
+ int __pyx_v_stack;
int __pyx_v_i;
- int __pyx_v_ndim;
- int __pyx_v_endian_detector;
- int __pyx_v_little_endian;
- int __pyx_v_t;
- char *__pyx_v_f;
- PyArray_Descr *__pyx_v_descr = 0;
- int __pyx_v_offset;
- int __pyx_v_hasfields;
- int __pyx_r;
+ struct __pyx_obj_2yt_9amr_utils_GridFace *__pyx_v_face;
+ __pyx_t_5numpy_float64_t __pyx_v_proto_split[3];
+ PyObject *__pyx_v_left;
+ PyObject *__pyx_v_right;
+ PyObject *__pyx_v_LC;
+ PyObject *__pyx_v_RC;
+ PyObject *__pyx_r = NULL;
+ PyObject *__pyx_1 = 0;
+ PyObject *__pyx_2 = 0;
+ PyObject *__pyx_3 = 0;
int __pyx_t_1;
- PyObject *__pyx_t_2 = NULL;
+ Py_ssize_t __pyx_t_2;
PyObject *__pyx_t_3 = NULL;
- int __pyx_t_4;
+ PyObject *__pyx_t_4 = NULL;
int __pyx_t_5;
- int __pyx_t_6;
- char *__pyx_t_7;
- __Pyx_SetupRefcountContext("__getbuffer__");
- if (__pyx_v_info == NULL) return 0;
- __pyx_v_info->obj = Py_None; __Pyx_INCREF(Py_None);
- __Pyx_GIVEREF(__pyx_v_info->obj);
-
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":158
- * # of flags
- * cdef int copy_shape, i, ndim
- * cdef int endian_detector = 1 # <<<<<<<<<<<<<<
- * cdef bint little_endian = ((<char*>&endian_detector)[0] != 0)
- *
- */
- __pyx_v_endian_detector = 1;
-
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":159
- * cdef int copy_shape, i, ndim
- * cdef int endian_detector = 1
- * cdef bint little_endian = ((<char*>&endian_detector)[0] != 0) # <<<<<<<<<<<<<<
- *
- * ndim = PyArray_NDIM(self)
- */
- __pyx_v_little_endian = ((((char *)(&__pyx_v_endian_detector))[0]) != 0);
-
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":161
- * cdef bint little_endian = ((<char*>&endian_detector)[0] != 0)
- *
- * ndim = PyArray_NDIM(self) # <<<<<<<<<<<<<<
- *
- * if sizeof(npy_intp) != sizeof(Py_ssize_t):
- */
- __pyx_v_ndim = PyArray_NDIM(((PyArrayObject *)__pyx_v_self));
-
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":163
- * ndim = PyArray_NDIM(self)
- *
- * if sizeof(npy_intp) != sizeof(Py_ssize_t): # <<<<<<<<<<<<<<
- * copy_shape = 1
- * else:
- */
- __pyx_t_1 = ((sizeof(npy_intp)) != (sizeof(Py_ssize_t)));
- if (__pyx_t_1) {
+ PyObject *__pyx_t_6 = NULL;
+ PyObject *__pyx_t_7 = NULL;
+ PyObject *__pyx_t_8 = NULL;
+ static PyObject **__pyx_pyargnames[] = {&__pyx_kp_direction,&__pyx_kp_stack,0};
+ __Pyx_SetupRefcountContext("sweep");
+ if (unlikely(__pyx_kwds)) {
+ Py_ssize_t kw_args = PyDict_Size(__pyx_kwds);
+ PyObject* values[2] = {0,0};
+ switch (PyTuple_GET_SIZE(__pyx_args)) {
+ case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
+ case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
+ case 0: break;
+ default: goto __pyx_L5_argtuple_error;
+ }
+ switch (PyTuple_GET_SIZE(__pyx_args)) {
+ case 0:
+ if (kw_args > 1) {
+ PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_kp_direction);
+ if (unlikely(value)) { values[0] = value; kw_args--; }
+ }
+ case 1:
+ if (kw_args > 1) {
+ PyObject* value = PyDict_GetItem(__pyx_kwds, __pyx_kp_stack);
+ if (unlikely(value)) { values[1] = value; kw_args--; }
+ }
+ }
+ if (unlikely(kw_args > 0)) {
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "sweep") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 438; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ if (values[0]) {
+ __pyx_v_direction = __Pyx_PyInt_AsInt(values[0]); if (unlikely((__pyx_v_direction == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 438; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ } else {
+ __pyx_v_direction = 0;
+ }
+ if (values[1]) {
+ __pyx_v_stack = __Pyx_PyInt_AsInt(values[1]); if (unlikely((__pyx_v_stack == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 438; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ } else {
+ __pyx_v_stack = 0;
+ }
+ } else {
+ __pyx_v_direction = 0;
+ __pyx_v_stack = 0;
+ switch (PyTuple_GET_SIZE(__pyx_args)) {
+ case 2: __pyx_v_stack = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 1)); if (unlikely((__pyx_v_stack == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 438; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ case 1: __pyx_v_direction = __Pyx_PyInt_AsInt(PyTuple_GET_ITEM(__pyx_args, 0)); if (unlikely((__pyx_v_direction == (int)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 438; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ case 0: break;
+ default: goto __pyx_L5_argtuple_error;
+ }
+ }
+ goto __pyx_L4_argument_unpacking_done;
+ __pyx_L5_argtuple_error:;
+ __Pyx_RaiseArgtupleInvalid("sweep", 0, 0, 2, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 438; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_L3_error:;
+ __Pyx_AddTraceback("yt.amr_utils.ProtoPrism.sweep");
+ return NULL;
+ __pyx_L4_argument_unpacking_done:;
+ __pyx_v_face = ((struct __pyx_obj_2yt_9amr_utils_GridFace *)Py_None); __Pyx_INCREF(Py_None);
+ __pyx_v_left = Py_None; __Pyx_INCREF(Py_None);
+ __pyx_v_right = Py_None; __Pyx_INCREF(Py_None);
+ __pyx_v_LC = Py_None; __Pyx_INCREF(Py_None);
+ __pyx_v_RC = Py_None; __Pyx_INCREF(Py_None);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":442
+ * cdef GridFace face
+ * cdef np.float64_t proto_split[3]
+ * for i in range(3): proto_split[i] = self.right_edge[i] # <<<<<<<<<<<<<<
+ * for face in self.subgrid_faces[direction]:
+ * proto_split[direction] = face.coord
+ */
+ for (__pyx_t_1 = 0; __pyx_t_1 < 3; __pyx_t_1+=1) {
+ __pyx_v_i = __pyx_t_1;
+ (__pyx_v_proto_split[__pyx_v_i]) = (((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->right_edge[__pyx_v_i]);
+ }
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":164
- *
- * if sizeof(npy_intp) != sizeof(Py_ssize_t):
- * copy_shape = 1 # <<<<<<<<<<<<<<
- * else:
- * copy_shape = 0
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":443
+ * cdef np.float64_t proto_split[3]
+ * for i in range(3): proto_split[i] = self.right_edge[i]
+ * for face in self.subgrid_faces[direction]: # <<<<<<<<<<<<<<
+ * proto_split[direction] = face.coord
+ * if proto_split[direction] <= self.left_edge[direction]:
*/
- __pyx_v_copy_shape = 1;
- goto __pyx_L5;
+ __pyx_1 = __Pyx_GetItemInt(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->subgrid_faces, __pyx_v_direction, sizeof(int), PyInt_FromLong); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 443; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ if (PyList_CheckExact(__pyx_1) || PyTuple_CheckExact(__pyx_1)) {
+ __pyx_t_2 = 0; __pyx_t_3 = __pyx_1; __Pyx_INCREF(__pyx_t_3);
+ } else {
+ __pyx_t_2 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 443; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_3);
}
- /*else*/ {
+ __Pyx_DECREF(__pyx_1); __pyx_1 = 0;
+ for (;;) {
+ if (likely(PyList_CheckExact(__pyx_t_3))) {
+ if (__pyx_t_2 >= PyList_GET_SIZE(__pyx_t_3)) break;
+ __pyx_t_4 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_2); __Pyx_INCREF(__pyx_t_4); __pyx_t_2++;
+ } else if (likely(PyTuple_CheckExact(__pyx_t_3))) {
+ if (__pyx_t_2 >= PyTuple_GET_SIZE(__pyx_t_3)) break;
+ __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_2); __Pyx_INCREF(__pyx_t_4); __pyx_t_2++;
+ } else {
+ __pyx_t_4 = PyIter_Next(__pyx_t_3);
+ if (!__pyx_t_4) {
+ if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 443; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ break;
+ }
+ __Pyx_GOTREF(__pyx_t_4);
+ }
+ if (!(__Pyx_TypeTest(__pyx_t_4, __pyx_ptype_2yt_9amr_utils_GridFace))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 443; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(((PyObject *)__pyx_v_face));
+ __pyx_v_face = ((struct __pyx_obj_2yt_9amr_utils_GridFace *)__pyx_t_4);
+ __pyx_t_4 = 0;
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":444
+ * for i in range(3): proto_split[i] = self.right_edge[i]
+ * for face in self.subgrid_faces[direction]:
+ * proto_split[direction] = face.coord # <<<<<<<<<<<<<<
+ * if proto_split[direction] <= self.left_edge[direction]:
+ * continue
+ */
+ (__pyx_v_proto_split[__pyx_v_direction]) = __pyx_v_face->coord;
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":445
+ * for face in self.subgrid_faces[direction]:
+ * proto_split[direction] = face.coord
+ * if proto_split[direction] <= self.left_edge[direction]: # <<<<<<<<<<<<<<
+ * continue
+ * if proto_split[direction] == self.right_edge[direction]:
+ */
+ __pyx_t_5 = ((__pyx_v_proto_split[__pyx_v_direction]) <= (((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->left_edge[__pyx_v_direction]));
+ if (__pyx_t_5) {
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":446
+ * proto_split[direction] = face.coord
+ * if proto_split[direction] <= self.left_edge[direction]:
+ * continue # <<<<<<<<<<<<<<
+ * if proto_split[direction] == self.right_edge[direction]:
+ * if stack == 2: return [self]
+ */
+ goto __pyx_L8_continue;
+ goto __pyx_L10;
+ }
+ __pyx_L10:;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":166
- * copy_shape = 1
- * else:
- * copy_shape = 0 # <<<<<<<<<<<<<<
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":447
+ * if proto_split[direction] <= self.left_edge[direction]:
+ * continue
+ * if proto_split[direction] == self.right_edge[direction]: # <<<<<<<<<<<<<<
+ * if stack == 2: return [self]
+ * return self.sweep((direction + 1) % 3, stack + 1)
+ */
+ __pyx_t_5 = ((__pyx_v_proto_split[__pyx_v_direction]) == (((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->right_edge[__pyx_v_direction]));
+ if (__pyx_t_5) {
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":448
+ * continue
+ * if proto_split[direction] == self.right_edge[direction]:
+ * if stack == 2: return [self] # <<<<<<<<<<<<<<
+ * return self.sweep((direction + 1) % 3, stack + 1)
+ * if face.proj_overlap(self.left_edge, proto_split) == 1:
+ */
+ __pyx_t_5 = (__pyx_v_stack == 2);
+ if (__pyx_t_5) {
+ __Pyx_XDECREF(__pyx_r);
+ __pyx_t_4 = PyList_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 448; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_4));
+ __Pyx_INCREF(__pyx_v_self);
+ PyList_SET_ITEM(__pyx_t_4, 0, __pyx_v_self);
+ __Pyx_GIVEREF(__pyx_v_self);
+ __pyx_r = ((PyObject *)__pyx_t_4);
+ __pyx_t_4 = 0;
+ __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
+ goto __pyx_L0;
+ goto __pyx_L12;
+ }
+ __pyx_L12:;
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":449
+ * if proto_split[direction] == self.right_edge[direction]:
+ * if stack == 2: return [self]
+ * return self.sweep((direction + 1) % 3, stack + 1) # <<<<<<<<<<<<<<
+ * if face.proj_overlap(self.left_edge, proto_split) == 1:
+ * left, right = self.split(proto_split, direction)
+ */
+ __Pyx_XDECREF(__pyx_r);
+ __pyx_t_4 = PyObject_GetAttr(__pyx_v_self, __pyx_kp_sweep); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __pyx_t_6 = PyInt_FromLong(((__pyx_v_direction + 1) % 3)); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_6);
+ __pyx_t_7 = PyInt_FromLong((__pyx_v_stack + 1)); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ __pyx_t_8 = PyTuple_New(2); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_8));
+ PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_6);
+ __Pyx_GIVEREF(__pyx_t_6);
+ PyTuple_SET_ITEM(__pyx_t_8, 1, __pyx_t_7);
+ __Pyx_GIVEREF(__pyx_t_7);
+ __pyx_t_6 = 0;
+ __pyx_t_7 = 0;
+ __pyx_t_7 = PyObject_Call(__pyx_t_4, ((PyObject *)__pyx_t_8), NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 449; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ __Pyx_DECREF(((PyObject *)__pyx_t_8)); __pyx_t_8 = 0;
+ __pyx_r = __pyx_t_7;
+ __pyx_t_7 = 0;
+ __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
+ goto __pyx_L0;
+ goto __pyx_L11;
+ }
+ __pyx_L11:;
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":450
+ * if stack == 2: return [self]
+ * return self.sweep((direction + 1) % 3, stack + 1)
+ * if face.proj_overlap(self.left_edge, proto_split) == 1: # <<<<<<<<<<<<<<
+ * left, right = self.split(proto_split, direction)
+ * LC = left.sweep((direction + 1) % 3)
+ */
+ __pyx_t_5 = (((struct __pyx_vtabstruct_2yt_9amr_utils_GridFace *)__pyx_v_face->__pyx_vtab)->proj_overlap(__pyx_v_face, ((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->left_edge, __pyx_v_proto_split) == 1);
+ if (__pyx_t_5) {
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":451
+ * return self.sweep((direction + 1) % 3, stack + 1)
+ * if face.proj_overlap(self.left_edge, proto_split) == 1:
+ * left, right = self.split(proto_split, direction) # <<<<<<<<<<<<<<
+ * LC = left.sweep((direction + 1) % 3)
+ * RC = right.sweep(direction)
+ */
+ __pyx_t_7 = ((struct __pyx_vtabstruct_2yt_9amr_utils_ProtoPrism *)((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->__pyx_vtab)->split(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self), __pyx_v_proto_split, __pyx_v_direction); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ if (PyTuple_CheckExact(__pyx_t_7) && likely(PyTuple_GET_SIZE(__pyx_t_7) == 2)) {
+ PyObject* tuple = __pyx_t_7;
+ __pyx_2 = PyTuple_GET_ITEM(tuple, 0); __Pyx_INCREF(__pyx_2);
+ __pyx_3 = PyTuple_GET_ITEM(tuple, 1); __Pyx_INCREF(__pyx_3);
+ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
+ __Pyx_DECREF(__pyx_v_left);
+ __pyx_v_left = __pyx_2;
+ __pyx_2 = 0;
+ __Pyx_DECREF(__pyx_v_right);
+ __pyx_v_right = __pyx_3;
+ __pyx_3 = 0;
+ } else {
+ __pyx_1 = PyObject_GetIter(__pyx_t_7); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
+ __pyx_2 = __Pyx_UnpackItem(__pyx_1, 0); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_2);
+ __pyx_3 = __Pyx_UnpackItem(__pyx_1, 1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_3);
+ if (__Pyx_EndUnpack(__pyx_1) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 451; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_1); __pyx_1 = 0;
+ __Pyx_DECREF(__pyx_v_left);
+ __pyx_v_left = __pyx_2;
+ __pyx_2 = 0;
+ __Pyx_DECREF(__pyx_v_right);
+ __pyx_v_right = __pyx_3;
+ __pyx_3 = 0;
+ }
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":452
+ * if face.proj_overlap(self.left_edge, proto_split) == 1:
+ * left, right = self.split(proto_split, direction)
+ * LC = left.sweep((direction + 1) % 3) # <<<<<<<<<<<<<<
+ * RC = right.sweep(direction)
+ * return LC + RC
+ */
+ __pyx_t_7 = PyObject_GetAttr(__pyx_v_left, __pyx_kp_sweep); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 452; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ __pyx_t_8 = PyInt_FromLong(((__pyx_v_direction + 1) % 3)); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 452; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 452; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_4));
+ PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_8);
+ __Pyx_GIVEREF(__pyx_t_8);
+ __pyx_t_8 = 0;
+ __pyx_t_8 = PyObject_Call(__pyx_t_7, ((PyObject *)__pyx_t_4), NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 452; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
+ __Pyx_DECREF(((PyObject *)__pyx_t_4)); __pyx_t_4 = 0;
+ __Pyx_DECREF(__pyx_v_LC);
+ __pyx_v_LC = __pyx_t_8;
+ __pyx_t_8 = 0;
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":453
+ * left, right = self.split(proto_split, direction)
+ * LC = left.sweep((direction + 1) % 3)
+ * RC = right.sweep(direction) # <<<<<<<<<<<<<<
+ * return LC + RC
+ * raise RuntimeError
+ */
+ __pyx_t_8 = PyObject_GetAttr(__pyx_v_right, __pyx_kp_sweep); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 453; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __pyx_t_4 = PyInt_FromLong(__pyx_v_direction); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 453; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __pyx_t_7 = PyTuple_New(1); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 453; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_7));
+ PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4);
+ __Pyx_GIVEREF(__pyx_t_4);
+ __pyx_t_4 = 0;
+ __pyx_t_4 = PyObject_Call(__pyx_t_8, ((PyObject *)__pyx_t_7), NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 453; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
+ __Pyx_DECREF(((PyObject *)__pyx_t_7)); __pyx_t_7 = 0;
+ __Pyx_DECREF(__pyx_v_RC);
+ __pyx_v_RC = __pyx_t_4;
+ __pyx_t_4 = 0;
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":454
+ * LC = left.sweep((direction + 1) % 3)
+ * RC = right.sweep(direction)
+ * return LC + RC # <<<<<<<<<<<<<<
+ * raise RuntimeError
*
- * if ((flags & pybuf.PyBUF_C_CONTIGUOUS == pybuf.PyBUF_C_CONTIGUOUS)
*/
- __pyx_v_copy_shape = 0;
+ __Pyx_XDECREF(__pyx_r);
+ __pyx_t_4 = PyNumber_Add(__pyx_v_LC, __pyx_v_RC); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 454; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __pyx_r = __pyx_t_4;
+ __pyx_t_4 = 0;
+ __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
+ goto __pyx_L0;
+ goto __pyx_L13;
+ }
+ __pyx_L13:;
+ __pyx_L8_continue:;
}
- __pyx_L5:;
+ __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":168
- * copy_shape = 0
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":455
+ * RC = right.sweep(direction)
+ * return LC + RC
+ * raise RuntimeError # <<<<<<<<<<<<<<
*
- * if ((flags & pybuf.PyBUF_C_CONTIGUOUS == pybuf.PyBUF_C_CONTIGUOUS) # <<<<<<<<<<<<<<
- * and not PyArray_CHKFLAGS(self, NPY_C_CONTIGUOUS)):
- * raise ValueError("ndarray is not C contiguous")
+ * @cython.boundscheck(False)
*/
- if (((__pyx_v_flags & PyBUF_C_CONTIGUOUS) == PyBUF_C_CONTIGUOUS)) {
+ __Pyx_Raise(__pyx_builtin_RuntimeError, 0, 0);
+ {__pyx_filename = __pyx_f[3]; __pyx_lineno = 455; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":169
+ __pyx_r = Py_None; __Pyx_INCREF(Py_None);
+ goto __pyx_L0;
+ __pyx_L1_error:;
+ __Pyx_XDECREF(__pyx_1);
+ __Pyx_XDECREF(__pyx_2);
+ __Pyx_XDECREF(__pyx_3);
+ __Pyx_XDECREF(__pyx_t_3);
+ __Pyx_XDECREF(__pyx_t_4);
+ __Pyx_XDECREF(__pyx_t_6);
+ __Pyx_XDECREF(__pyx_t_7);
+ __Pyx_XDECREF(__pyx_t_8);
+ __Pyx_AddTraceback("yt.amr_utils.ProtoPrism.sweep");
+ __pyx_r = NULL;
+ __pyx_L0:;
+ __Pyx_DECREF((PyObject *)__pyx_v_face);
+ __Pyx_DECREF(__pyx_v_left);
+ __Pyx_DECREF(__pyx_v_right);
+ __Pyx_DECREF(__pyx_v_LC);
+ __Pyx_DECREF(__pyx_v_RC);
+ __Pyx_XGIVEREF(__pyx_r);
+ __Pyx_FinishRefcountContext();
+ return __pyx_r;
+}
+
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":459
+ * @cython.boundscheck(False)
+ * @cython.wraparound(False)
+ * cdef object split(self, np.float64_t *sp, int direction): # <<<<<<<<<<<<<<
+ * cdef int i
+ * cdef np.ndarray split_left = self.LeftEdge.copy()
+ */
+
+static PyObject *__pyx_f_2yt_9amr_utils_10ProtoPrism_split(struct __pyx_obj_2yt_9amr_utils_ProtoPrism *__pyx_v_self, __pyx_t_5numpy_float64_t *__pyx_v_sp, int __pyx_v_direction) {
+ int __pyx_v_i;
+ PyArrayObject *__pyx_v_split_left = 0;
+ PyArrayObject *__pyx_v_split_right = 0;
+ PyObject *__pyx_v_left;
+ PyObject *__pyx_v_right;
+ PyObject *__pyx_r = NULL;
+ PyObject *__pyx_t_1 = NULL;
+ PyObject *__pyx_t_2 = NULL;
+ int __pyx_t_3;
+ __Pyx_SetupRefcountContext("split");
+ __pyx_v_left = Py_None; __Pyx_INCREF(Py_None);
+ __pyx_v_right = Py_None; __Pyx_INCREF(Py_None);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":461
+ * cdef object split(self, np.float64_t *sp, int direction):
+ * cdef int i
+ * cdef np.ndarray split_left = self.LeftEdge.copy() # <<<<<<<<<<<<<<
+ * cdef np.ndarray split_right = self.RightEdge.copy()
*
- * if ((flags & pybuf.PyBUF_C_CONTIGUOUS == pybuf.PyBUF_C_CONTIGUOUS)
- * and not PyArray_CHKFLAGS(self, NPY_C_CONTIGUOUS)): # <<<<<<<<<<<<<<
- * raise ValueError("ndarray is not C contiguous")
+ */
+ __pyx_t_1 = PyObject_GetAttr(__pyx_v_self->LeftEdge, __pyx_kp_copy); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 461; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_1);
+ __pyx_t_2 = PyObject_Call(__pyx_t_1, ((PyObject *)__pyx_empty_tuple), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 461; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_2);
+ __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
+ if (!(__Pyx_TypeTest(__pyx_t_2, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 461; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_v_split_left = ((PyArrayObject *)__pyx_t_2);
+ __pyx_t_2 = 0;
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":462
+ * cdef int i
+ * cdef np.ndarray split_left = self.LeftEdge.copy()
+ * cdef np.ndarray split_right = self.RightEdge.copy() # <<<<<<<<<<<<<<
*
+ * for i in range(3): split_left[i] = self.right_edge[i]
*/
- __pyx_t_1 = (!PyArray_CHKFLAGS(((PyArrayObject *)__pyx_v_self), NPY_C_CONTIGUOUS));
- } else {
- __pyx_t_1 = ((__pyx_v_flags & PyBUF_C_CONTIGUOUS) == PyBUF_C_CONTIGUOUS);
- }
- if (__pyx_t_1) {
+ __pyx_t_2 = PyObject_GetAttr(__pyx_v_self->RightEdge, __pyx_kp_copy); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 462; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_2);
+ __pyx_t_1 = PyObject_Call(__pyx_t_2, ((PyObject *)__pyx_empty_tuple), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 462; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_1);
+ __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
+ if (!(__Pyx_TypeTest(__pyx_t_1, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 462; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_v_split_right = ((PyArrayObject *)__pyx_t_1);
+ __pyx_t_1 = 0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":170
- * if ((flags & pybuf.PyBUF_C_CONTIGUOUS == pybuf.PyBUF_C_CONTIGUOUS)
- * and not PyArray_CHKFLAGS(self, NPY_C_CONTIGUOUS)):
- * raise ValueError("ndarray is not C contiguous") # <<<<<<<<<<<<<<
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":464
+ * cdef np.ndarray split_right = self.RightEdge.copy()
*
- * if ((flags & pybuf.PyBUF_F_CONTIGUOUS == pybuf.PyBUF_F_CONTIGUOUS)
+ * for i in range(3): split_left[i] = self.right_edge[i] # <<<<<<<<<<<<<<
+ * split_left[direction] = sp[direction]
+ * left = ProtoPrism(self.LeftEdge, split_left, self.subgrid_faces)
*/
- __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 170; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(((PyObject *)__pyx_t_2));
- __Pyx_INCREF(__pyx_kp_1);
- PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_kp_1);
- __Pyx_GIVEREF(__pyx_kp_1);
- __pyx_t_3 = PyObject_Call(__pyx_builtin_ValueError, ((PyObject *)__pyx_t_2), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 170; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_3);
- __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
- __Pyx_Raise(__pyx_t_3, 0, 0);
- __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 170; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- goto __pyx_L6;
+ for (__pyx_t_3 = 0; __pyx_t_3 < 3; __pyx_t_3+=1) {
+ __pyx_v_i = __pyx_t_3;
+ __pyx_t_1 = PyFloat_FromDouble((__pyx_v_self->right_edge[__pyx_v_i])); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_1);
+ if (__Pyx_SetItemInt(((PyObject *)__pyx_v_split_left), __pyx_v_i, __pyx_t_1, sizeof(int), PyInt_FromLong) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 464; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
}
- __pyx_L6:;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":172
- * raise ValueError("ndarray is not C contiguous")
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":465
+ *
+ * for i in range(3): split_left[i] = self.right_edge[i]
+ * split_left[direction] = sp[direction] # <<<<<<<<<<<<<<
+ * left = ProtoPrism(self.LeftEdge, split_left, self.subgrid_faces)
*
- * if ((flags & pybuf.PyBUF_F_CONTIGUOUS == pybuf.PyBUF_F_CONTIGUOUS) # <<<<<<<<<<<<<<
- * and not PyArray_CHKFLAGS(self, NPY_F_CONTIGUOUS)):
- * raise ValueError("ndarray is not Fortran contiguous")
*/
- if (((__pyx_v_flags & PyBUF_F_CONTIGUOUS) == PyBUF_F_CONTIGUOUS)) {
+ __pyx_t_1 = PyFloat_FromDouble((__pyx_v_sp[__pyx_v_direction])); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 465; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_1);
+ if (__Pyx_SetItemInt(((PyObject *)__pyx_v_split_left), __pyx_v_direction, __pyx_t_1, sizeof(int), PyInt_FromLong) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 465; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":173
- *
- * if ((flags & pybuf.PyBUF_F_CONTIGUOUS == pybuf.PyBUF_F_CONTIGUOUS)
- * and not PyArray_CHKFLAGS(self, NPY_F_CONTIGUOUS)): # <<<<<<<<<<<<<<
- * raise ValueError("ndarray is not Fortran contiguous")
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":466
+ * for i in range(3): split_left[i] = self.right_edge[i]
+ * split_left[direction] = sp[direction]
+ * left = ProtoPrism(self.LeftEdge, split_left, self.subgrid_faces) # <<<<<<<<<<<<<<
*
+ * for i in range(3): split_right[i] = self.left_edge[i]
*/
- __pyx_t_1 = (!PyArray_CHKFLAGS(((PyArrayObject *)__pyx_v_self), NPY_F_CONTIGUOUS));
- } else {
- __pyx_t_1 = ((__pyx_v_flags & PyBUF_F_CONTIGUOUS) == PyBUF_F_CONTIGUOUS);
- }
- if (__pyx_t_1) {
+ __pyx_t_1 = PyTuple_New(3); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 466; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_1));
+ __Pyx_INCREF(__pyx_v_self->LeftEdge);
+ PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->LeftEdge);
+ __Pyx_GIVEREF(__pyx_v_self->LeftEdge);
+ __Pyx_INCREF(((PyObject *)__pyx_v_split_left));
+ PyTuple_SET_ITEM(__pyx_t_1, 1, ((PyObject *)__pyx_v_split_left));
+ __Pyx_GIVEREF(((PyObject *)__pyx_v_split_left));
+ __Pyx_INCREF(__pyx_v_self->subgrid_faces);
+ PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_v_self->subgrid_faces);
+ __Pyx_GIVEREF(__pyx_v_self->subgrid_faces);
+ __pyx_t_2 = PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_2yt_9amr_utils_ProtoPrism)), ((PyObject *)__pyx_t_1), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 466; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_2);
+ __Pyx_DECREF(((PyObject *)__pyx_t_1)); __pyx_t_1 = 0;
+ __Pyx_DECREF(__pyx_v_left);
+ __pyx_v_left = __pyx_t_2;
+ __pyx_t_2 = 0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":174
- * if ((flags & pybuf.PyBUF_F_CONTIGUOUS == pybuf.PyBUF_F_CONTIGUOUS)
- * and not PyArray_CHKFLAGS(self, NPY_F_CONTIGUOUS)):
- * raise ValueError("ndarray is not Fortran contiguous") # <<<<<<<<<<<<<<
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":468
+ * left = ProtoPrism(self.LeftEdge, split_left, self.subgrid_faces)
*
- * info.buf = PyArray_DATA(self)
+ * for i in range(3): split_right[i] = self.left_edge[i] # <<<<<<<<<<<<<<
+ * split_right[direction] = sp[direction]
+ * right = ProtoPrism(split_right, self.RightEdge, self.subgrid_faces)
*/
- __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(((PyObject *)__pyx_t_3));
- __Pyx_INCREF(__pyx_kp_2);
- PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_kp_2);
- __Pyx_GIVEREF(__pyx_kp_2);
- __pyx_t_2 = PyObject_Call(__pyx_builtin_ValueError, ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ for (__pyx_t_3 = 0; __pyx_t_3 < 3; __pyx_t_3+=1) {
+ __pyx_v_i = __pyx_t_3;
+ __pyx_t_2 = PyFloat_FromDouble((__pyx_v_self->left_edge[__pyx_v_i])); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_2);
- __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
- __Pyx_Raise(__pyx_t_2, 0, 0);
+ if (__Pyx_SetItemInt(((PyObject *)__pyx_v_split_right), __pyx_v_i, __pyx_t_2, sizeof(int), PyInt_FromLong) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 468; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- goto __pyx_L7;
}
- __pyx_L7:;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":176
- * raise ValueError("ndarray is not Fortran contiguous")
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":469
+ *
+ * for i in range(3): split_right[i] = self.left_edge[i]
+ * split_right[direction] = sp[direction] # <<<<<<<<<<<<<<
+ * right = ProtoPrism(split_right, self.RightEdge, self.subgrid_faces)
*
- * info.buf = PyArray_DATA(self) # <<<<<<<<<<<<<<
- * info.ndim = ndim
- * if copy_shape:
*/
- __pyx_v_info->buf = PyArray_DATA(((PyArrayObject *)__pyx_v_self));
+ __pyx_t_2 = PyFloat_FromDouble((__pyx_v_sp[__pyx_v_direction])); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 469; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_2);
+ if (__Pyx_SetItemInt(((PyObject *)__pyx_v_split_right), __pyx_v_direction, __pyx_t_2, sizeof(int), PyInt_FromLong) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 469; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":177
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":470
+ * for i in range(3): split_right[i] = self.left_edge[i]
+ * split_right[direction] = sp[direction]
+ * right = ProtoPrism(split_right, self.RightEdge, self.subgrid_faces) # <<<<<<<<<<<<<<
*
- * info.buf = PyArray_DATA(self)
- * info.ndim = ndim # <<<<<<<<<<<<<<
- * if copy_shape:
- * # Allocate new buffer for strides and shape info. This is allocated
+ * return (left, right)
*/
- __pyx_v_info->ndim = __pyx_v_ndim;
+ __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 470; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_2));
+ __Pyx_INCREF(((PyObject *)__pyx_v_split_right));
+ PyTuple_SET_ITEM(__pyx_t_2, 0, ((PyObject *)__pyx_v_split_right));
+ __Pyx_GIVEREF(((PyObject *)__pyx_v_split_right));
+ __Pyx_INCREF(__pyx_v_self->RightEdge);
+ PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_v_self->RightEdge);
+ __Pyx_GIVEREF(__pyx_v_self->RightEdge);
+ __Pyx_INCREF(__pyx_v_self->subgrid_faces);
+ PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_self->subgrid_faces);
+ __Pyx_GIVEREF(__pyx_v_self->subgrid_faces);
+ __pyx_t_1 = PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_2yt_9amr_utils_ProtoPrism)), ((PyObject *)__pyx_t_2), NULL); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 470; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_1);
+ __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
+ __Pyx_DECREF(__pyx_v_right);
+ __pyx_v_right = __pyx_t_1;
+ __pyx_t_1 = 0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":178
- * info.buf = PyArray_DATA(self)
- * info.ndim = ndim
- * if copy_shape: # <<<<<<<<<<<<<<
- * # Allocate new buffer for strides and shape info. This is allocated
- * # as one block, strides first.
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":472
+ * right = ProtoPrism(split_right, self.RightEdge, self.subgrid_faces)
+ *
+ * return (left, right) # <<<<<<<<<<<<<<
+ *
+ * @cython.boundscheck(False)
*/
- __pyx_t_4 = __pyx_v_copy_shape;
- if (__pyx_t_4) {
+ __Pyx_XDECREF(__pyx_r);
+ __pyx_t_1 = PyTuple_New(2); if (unlikely(!__pyx_t_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 472; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_1));
+ __Pyx_INCREF(__pyx_v_left);
+ PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_left);
+ __Pyx_GIVEREF(__pyx_v_left);
+ __Pyx_INCREF(__pyx_v_right);
+ PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_v_right);
+ __Pyx_GIVEREF(__pyx_v_right);
+ __pyx_r = ((PyObject *)__pyx_t_1);
+ __pyx_t_1 = 0;
+ goto __pyx_L0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":181
- * # Allocate new buffer for strides and shape info. This is allocated
- * # as one block, strides first.
- * info.strides = <Py_ssize_t*>stdlib.malloc(sizeof(Py_ssize_t) * ndim * 2) # <<<<<<<<<<<<<<
- * info.shape = info.strides + ndim
- * for i in range(ndim):
- */
- __pyx_v_info->strides = ((Py_ssize_t *)malloc((((sizeof(Py_ssize_t)) * __pyx_v_ndim) * 2)));
+ __pyx_r = Py_None; __Pyx_INCREF(Py_None);
+ goto __pyx_L0;
+ __pyx_L1_error:;
+ __Pyx_XDECREF(__pyx_t_1);
+ __Pyx_XDECREF(__pyx_t_2);
+ __Pyx_AddTraceback("yt.amr_utils.ProtoPrism.split");
+ __pyx_r = 0;
+ __pyx_L0:;
+ __Pyx_XDECREF((PyObject *)__pyx_v_split_left);
+ __Pyx_XDECREF((PyObject *)__pyx_v_split_right);
+ __Pyx_DECREF(__pyx_v_left);
+ __Pyx_DECREF(__pyx_v_right);
+ __Pyx_XGIVEREF(__pyx_r);
+ __Pyx_FinishRefcountContext();
+ return __pyx_r;
+}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":182
- * # as one block, strides first.
- * info.strides = <Py_ssize_t*>stdlib.malloc(sizeof(Py_ssize_t) * ndim * 2)
- * info.shape = info.strides + ndim # <<<<<<<<<<<<<<
- * for i in range(ndim):
- * info.strides[i] = PyArray_STRIDES(self)[i]
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":476
+ * @cython.boundscheck(False)
+ * @cython.wraparound(False)
+ * def get_brick(self, np.ndarray[np.float64_t, ndim=1] grid_left_edge, # <<<<<<<<<<<<<<
+ * np.ndarray[np.float64_t, ndim=1] grid_dds,
+ * np.ndarray[np.float64_t, ndim=3] data,
*/
- __pyx_v_info->shape = (__pyx_v_info->strides + __pyx_v_ndim);
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":183
- * info.strides = <Py_ssize_t*>stdlib.malloc(sizeof(Py_ssize_t) * ndim * 2)
- * info.shape = info.strides + ndim
- * for i in range(ndim): # <<<<<<<<<<<<<<
- * info.strides[i] = PyArray_STRIDES(self)[i]
- * info.shape[i] = PyArray_DIMS(self)[i]
- */
- for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_v_ndim; __pyx_t_4+=1) {
- __pyx_v_i = __pyx_t_4;
+static PyObject *__pyx_pf_2yt_9amr_utils_10ProtoPrism_get_brick(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
+static PyObject *__pyx_pf_2yt_9amr_utils_10ProtoPrism_get_brick(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
+ PyArrayObject *__pyx_v_grid_left_edge = 0;
+ PyArrayObject *__pyx_v_grid_dds = 0;
+ PyArrayObject *__pyx_v_data = 0;
+ PyObject *__pyx_v_child_mask = 0;
+ struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *__pyx_v_PG;
+ int __pyx_v_li[3];
+ int __pyx_v_ri[3];
+ int __pyx_v_idims[3];
+ int __pyx_v_i;
+ PyArrayObject *__pyx_v_dims = 0;
+ PyArrayObject *__pyx_v_new_data;
+ Py_buffer __pyx_bstruct_new_data;
+ Py_ssize_t __pyx_bstride_0_new_data = 0;
+ Py_ssize_t __pyx_bstride_1_new_data = 0;
+ Py_ssize_t __pyx_bstride_2_new_data = 0;
+ Py_ssize_t __pyx_bshape_0_new_data = 0;
+ Py_ssize_t __pyx_bshape_1_new_data = 0;
+ Py_ssize_t __pyx_bshape_2_new_data = 0;
+ Py_buffer __pyx_bstruct_grid_dds;
+ Py_ssize_t __pyx_bstride_0_grid_dds = 0;
+ Py_ssize_t __pyx_bshape_0_grid_dds = 0;
+ Py_buffer __pyx_bstruct_dims;
+ Py_ssize_t __pyx_bstride_0_dims = 0;
+ Py_ssize_t __pyx_bshape_0_dims = 0;
+ Py_buffer __pyx_bstruct_grid_left_edge;
+ Py_ssize_t __pyx_bstride_0_grid_left_edge = 0;
+ Py_ssize_t __pyx_bshape_0_grid_left_edge = 0;
+ Py_buffer __pyx_bstruct_data;
+ Py_ssize_t __pyx_bstride_0_data = 0;
+ Py_ssize_t __pyx_bstride_1_data = 0;
+ Py_ssize_t __pyx_bstride_2_data = 0;
+ Py_ssize_t __pyx_bshape_0_data = 0;
+ Py_ssize_t __pyx_bshape_1_data = 0;
+ Py_ssize_t __pyx_bshape_2_data = 0;
+ PyObject *__pyx_r = NULL;
+ PyObject *__pyx_1 = 0;
+ PyObject *__pyx_2 = 0;
+ PyObject *__pyx_3 = 0;
+ int __pyx_t_1;
+ int __pyx_t_2;
+ int __pyx_t_3;
+ int __pyx_t_4;
+ int __pyx_t_5;
+ PyObject *__pyx_t_6 = NULL;
+ PyObject *__pyx_t_7 = NULL;
+ PyObject *__pyx_t_8 = NULL;
+ PyObject *__pyx_t_9 = NULL;
+ int __pyx_t_10;
+ PyArrayObject *__pyx_t_11 = NULL;
+ int __pyx_t_12;
+ PyArrayObject *__pyx_t_13 = NULL;
+ PyObject *__pyx_t_14 = NULL;
+ PyObject *__pyx_t_15 = NULL;
+ PyObject *__pyx_t_16 = NULL;
+ static PyObject **__pyx_pyargnames[] = {&__pyx_kp_grid_left_edge,&__pyx_kp_grid_dds,&__pyx_kp_data,&__pyx_kp_child_mask,0};
+ __Pyx_SetupRefcountContext("get_brick");
+ if (unlikely(__pyx_kwds)) {
+ Py_ssize_t kw_args = PyDict_Size(__pyx_kwds);
+ PyObject* values[4] = {0,0,0,0};
+ switch (PyTuple_GET_SIZE(__pyx_args)) {
+ case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
+ case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
+ case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
+ case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
+ case 0: break;
+ default: goto __pyx_L5_argtuple_error;
+ }
+ switch (PyTuple_GET_SIZE(__pyx_args)) {
+ case 0:
+ values[0] = PyDict_GetItem(__pyx_kwds, __pyx_kp_grid_left_edge);
+ if (likely(values[0])) kw_args--;
+ else goto __pyx_L5_argtuple_error;
+ case 1:
+ values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_grid_dds);
+ if (likely(values[1])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("get_brick", 1, 4, 4, 1); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 476; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 2:
+ values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_data);
+ if (likely(values[2])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("get_brick", 1, 4, 4, 2); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 476; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 3:
+ values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_child_mask);
+ if (likely(values[3])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("get_brick", 1, 4, 4, 3); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 476; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ }
+ if (unlikely(kw_args > 0)) {
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "get_brick") < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 476; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ __pyx_v_grid_left_edge = ((PyArrayObject *)values[0]);
+ __pyx_v_grid_dds = ((PyArrayObject *)values[1]);
+ __pyx_v_data = ((PyArrayObject *)values[2]);
+ __pyx_v_child_mask = values[3];
+ } else if (PyTuple_GET_SIZE(__pyx_args) != 4) {
+ goto __pyx_L5_argtuple_error;
+ } else {
+ __pyx_v_grid_left_edge = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 0));
+ __pyx_v_grid_dds = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 1));
+ __pyx_v_data = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 2));
+ __pyx_v_child_mask = PyTuple_GET_ITEM(__pyx_args, 3);
+ }
+ goto __pyx_L4_argument_unpacking_done;
+ __pyx_L5_argtuple_error:;
+ __Pyx_RaiseArgtupleInvalid("get_brick", 1, 4, 4, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[3]; __pyx_lineno = 476; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_L3_error:;
+ __Pyx_AddTraceback("yt.amr_utils.ProtoPrism.get_brick");
+ return NULL;
+ __pyx_L4_argument_unpacking_done:;
+ __pyx_v_PG = ((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)Py_None); __Pyx_INCREF(Py_None);
+ __pyx_v_new_data = ((PyArrayObject *)Py_None); __Pyx_INCREF(Py_None);
+ __pyx_bstruct_dims.buf = NULL;
+ __pyx_bstruct_new_data.buf = NULL;
+ __pyx_bstruct_grid_left_edge.buf = NULL;
+ __pyx_bstruct_grid_dds.buf = NULL;
+ __pyx_bstruct_data.buf = NULL;
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grid_left_edge), __pyx_ptype_5numpy_ndarray, 1, "grid_left_edge", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 476; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_grid_dds), __pyx_ptype_5numpy_ndarray, 1, "grid_dds", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 477; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_data), __pyx_ptype_5numpy_ndarray, 1, "data", 0))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 478; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_grid_left_edge, (PyObject*)__pyx_v_grid_left_edge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 476; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_grid_left_edge = __pyx_bstruct_grid_left_edge.strides[0];
+ __pyx_bshape_0_grid_left_edge = __pyx_bstruct_grid_left_edge.shape[0];
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_grid_dds, (PyObject*)__pyx_v_grid_dds, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 476; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_grid_dds = __pyx_bstruct_grid_dds.strides[0];
+ __pyx_bshape_0_grid_dds = __pyx_bstruct_grid_dds.shape[0];
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_data, (PyObject*)__pyx_v_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 476; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_data = __pyx_bstruct_data.strides[0]; __pyx_bstride_1_data = __pyx_bstruct_data.strides[1]; __pyx_bstride_2_data = __pyx_bstruct_data.strides[2];
+ __pyx_bshape_0_data = __pyx_bstruct_data.shape[0]; __pyx_bshape_1_data = __pyx_bstruct_data.shape[1]; __pyx_bshape_2_data = __pyx_bstruct_data.shape[2];
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":184
- * info.shape = info.strides + ndim
- * for i in range(ndim):
- * info.strides[i] = PyArray_STRIDES(self)[i] # <<<<<<<<<<<<<<
- * info.shape[i] = PyArray_DIMS(self)[i]
- * else:
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":484
+ * cdef PartitionedGrid PG
+ * cdef int li[3], ri[3], idims[3], i
+ * for i in range(3): # <<<<<<<<<<<<<<
+ * li[i] = lrint((self.left_edge[i] - grid_left_edge[i])/grid_dds[i])
+ * ri[i] = lrint((self.right_edge[i] - grid_left_edge[i])/grid_dds[i])
*/
- (__pyx_v_info->strides[__pyx_v_i]) = (PyArray_STRIDES(((PyArrayObject *)__pyx_v_self))[__pyx_v_i]);
+ for (__pyx_t_1 = 0; __pyx_t_1 < 3; __pyx_t_1+=1) {
+ __pyx_v_i = __pyx_t_1;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":185
- * for i in range(ndim):
- * info.strides[i] = PyArray_STRIDES(self)[i]
- * info.shape[i] = PyArray_DIMS(self)[i] # <<<<<<<<<<<<<<
- * else:
- * info.strides = <Py_ssize_t*>PyArray_STRIDES(self)
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":485
+ * cdef int li[3], ri[3], idims[3], i
+ * for i in range(3):
+ * li[i] = lrint((self.left_edge[i] - grid_left_edge[i])/grid_dds[i]) # <<<<<<<<<<<<<<
+ * ri[i] = lrint((self.right_edge[i] - grid_left_edge[i])/grid_dds[i])
+ * idims[i] = ri[i] - li[i]
*/
- (__pyx_v_info->shape[__pyx_v_i]) = (PyArray_DIMS(((PyArrayObject *)__pyx_v_self))[__pyx_v_i]);
- }
- goto __pyx_L8;
- }
- /*else*/ {
+ __pyx_t_2 = __pyx_v_i;
+ __pyx_t_3 = __pyx_v_i;
+ (__pyx_v_li[__pyx_v_i]) = lrint((((((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->left_edge[__pyx_v_i]) - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_grid_left_edge.buf, __pyx_t_2, __pyx_bstride_0_grid_left_edge))) / (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_grid_dds.buf, __pyx_t_3, __pyx_bstride_0_grid_dds))));
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":187
- * info.shape[i] = PyArray_DIMS(self)[i]
- * else:
- * info.strides = <Py_ssize_t*>PyArray_STRIDES(self) # <<<<<<<<<<<<<<
- * info.shape = <Py_ssize_t*>PyArray_DIMS(self)
- * info.suboffsets = NULL
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":486
+ * for i in range(3):
+ * li[i] = lrint((self.left_edge[i] - grid_left_edge[i])/grid_dds[i])
+ * ri[i] = lrint((self.right_edge[i] - grid_left_edge[i])/grid_dds[i]) # <<<<<<<<<<<<<<
+ * idims[i] = ri[i] - li[i]
+ * if child_mask[li[0], li[1], li[2]] == 0: return []
*/
- __pyx_v_info->strides = ((Py_ssize_t *)PyArray_STRIDES(((PyArrayObject *)__pyx_v_self)));
+ __pyx_t_4 = __pyx_v_i;
+ __pyx_t_5 = __pyx_v_i;
+ (__pyx_v_ri[__pyx_v_i]) = lrint((((((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->right_edge[__pyx_v_i]) - (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_grid_left_edge.buf, __pyx_t_4, __pyx_bstride_0_grid_left_edge))) / (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_grid_dds.buf, __pyx_t_5, __pyx_bstride_0_grid_dds))));
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":188
- * else:
- * info.strides = <Py_ssize_t*>PyArray_STRIDES(self)
- * info.shape = <Py_ssize_t*>PyArray_DIMS(self) # <<<<<<<<<<<<<<
- * info.suboffsets = NULL
- * info.itemsize = PyArray_ITEMSIZE(self)
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":487
+ * li[i] = lrint((self.left_edge[i] - grid_left_edge[i])/grid_dds[i])
+ * ri[i] = lrint((self.right_edge[i] - grid_left_edge[i])/grid_dds[i])
+ * idims[i] = ri[i] - li[i] # <<<<<<<<<<<<<<
+ * if child_mask[li[0], li[1], li[2]] == 0: return []
+ * cdef np.ndarray[np.int64_t, ndim=1] dims = np.empty(3, dtype='int64')
+ */
+ (__pyx_v_idims[__pyx_v_i]) = ((__pyx_v_ri[__pyx_v_i]) - (__pyx_v_li[__pyx_v_i]));
+ }
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":488
+ * ri[i] = lrint((self.right_edge[i] - grid_left_edge[i])/grid_dds[i])
+ * idims[i] = ri[i] - li[i]
+ * if child_mask[li[0], li[1], li[2]] == 0: return [] # <<<<<<<<<<<<<<
+ * cdef np.ndarray[np.int64_t, ndim=1] dims = np.empty(3, dtype='int64')
+ * for i in range(3):
*/
- __pyx_v_info->shape = ((Py_ssize_t *)PyArray_DIMS(((PyArrayObject *)__pyx_v_self)));
+ __pyx_t_6 = PyInt_FromLong((__pyx_v_li[0])); if (unlikely(!__pyx_t_6)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 488; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_6);
+ __pyx_t_7 = PyInt_FromLong((__pyx_v_li[1])); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 488; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ __pyx_t_8 = PyInt_FromLong((__pyx_v_li[2])); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 488; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __pyx_t_9 = PyTuple_New(3); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 488; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_9));
+ PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_6);
+ __Pyx_GIVEREF(__pyx_t_6);
+ PyTuple_SET_ITEM(__pyx_t_9, 1, __pyx_t_7);
+ __Pyx_GIVEREF(__pyx_t_7);
+ PyTuple_SET_ITEM(__pyx_t_9, 2, __pyx_t_8);
+ __Pyx_GIVEREF(__pyx_t_8);
+ __pyx_t_6 = 0;
+ __pyx_t_7 = 0;
+ __pyx_t_8 = 0;
+ __pyx_1 = PyObject_GetItem(__pyx_v_child_mask, ((PyObject *)__pyx_t_9)); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 488; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ __Pyx_DECREF(((PyObject *)__pyx_t_9)); __pyx_t_9 = 0;
+ __pyx_t_9 = PyObject_RichCompare(__pyx_1, __pyx_int_0, Py_EQ); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 488; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_9);
+ __Pyx_DECREF(__pyx_1); __pyx_1 = 0;
+ __pyx_t_10 = __Pyx_PyObject_IsTrue(__pyx_t_9); if (unlikely(__pyx_t_10 < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 488; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
+ if (__pyx_t_10) {
+ __Pyx_XDECREF(__pyx_r);
+ __pyx_t_9 = PyList_New(0); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 488; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_9));
+ __pyx_r = ((PyObject *)__pyx_t_9);
+ __pyx_t_9 = 0;
+ goto __pyx_L0;
+ goto __pyx_L8;
}
__pyx_L8:;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":189
- * info.strides = <Py_ssize_t*>PyArray_STRIDES(self)
- * info.shape = <Py_ssize_t*>PyArray_DIMS(self)
- * info.suboffsets = NULL # <<<<<<<<<<<<<<
- * info.itemsize = PyArray_ITEMSIZE(self)
- * info.readonly = not PyArray_ISWRITEABLE(self)
- */
- __pyx_v_info->suboffsets = NULL;
-
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":190
- * info.shape = <Py_ssize_t*>PyArray_DIMS(self)
- * info.suboffsets = NULL
- * info.itemsize = PyArray_ITEMSIZE(self) # <<<<<<<<<<<<<<
- * info.readonly = not PyArray_ISWRITEABLE(self)
- *
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":489
+ * idims[i] = ri[i] - li[i]
+ * if child_mask[li[0], li[1], li[2]] == 0: return []
+ * cdef np.ndarray[np.int64_t, ndim=1] dims = np.empty(3, dtype='int64') # <<<<<<<<<<<<<<
+ * for i in range(3):
+ * dims[i] = idims[i]
*/
- __pyx_v_info->itemsize = PyArray_ITEMSIZE(((PyArrayObject *)__pyx_v_self));
+ __pyx_1 = __Pyx_GetName(__pyx_m, __pyx_kp_np); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 489; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ __pyx_t_9 = PyObject_GetAttr(__pyx_1, __pyx_kp_empty); if (unlikely(!__pyx_t_9)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 489; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_9);
+ __Pyx_DECREF(__pyx_1); __pyx_1 = 0;
+ __pyx_t_8 = PyTuple_New(1); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 489; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_8));
+ __Pyx_INCREF(__pyx_int_3);
+ PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_int_3);
+ __Pyx_GIVEREF(__pyx_int_3);
+ __pyx_1 = PyDict_New(); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 489; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_1));
+ if (PyDict_SetItem(__pyx_1, __pyx_kp_dtype, __pyx_kp_37) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 489; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_7 = PyEval_CallObjectWithKeywords(__pyx_t_9, ((PyObject *)__pyx_t_8), ((PyObject *)__pyx_1)); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 489; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
+ __Pyx_DECREF(((PyObject *)__pyx_t_8)); __pyx_t_8 = 0;
+ __Pyx_DECREF(((PyObject *)__pyx_1)); __pyx_1 = 0;
+ if (!(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 489; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_11 = ((PyArrayObject *)__pyx_t_7);
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_dims, (PyObject*)__pyx_t_11, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int64_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 1, 0, __pyx_stack) == -1)) {
+ __pyx_v_dims = ((PyArrayObject *)Py_None); __Pyx_INCREF(Py_None); __pyx_bstruct_dims.buf = NULL;
+ {__pyx_filename = __pyx_f[3]; __pyx_lineno = 489; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ } else {__pyx_bstride_0_dims = __pyx_bstruct_dims.strides[0];
+ __pyx_bshape_0_dims = __pyx_bstruct_dims.shape[0];
+ }
+ }
+ __pyx_t_11 = 0;
+ __pyx_v_dims = ((PyArrayObject *)__pyx_t_7);
+ __pyx_t_7 = 0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":191
- * info.suboffsets = NULL
- * info.itemsize = PyArray_ITEMSIZE(self)
- * info.readonly = not PyArray_ISWRITEABLE(self) # <<<<<<<<<<<<<<
- *
- * cdef int t
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":490
+ * if child_mask[li[0], li[1], li[2]] == 0: return []
+ * cdef np.ndarray[np.int64_t, ndim=1] dims = np.empty(3, dtype='int64')
+ * for i in range(3): # <<<<<<<<<<<<<<
+ * dims[i] = idims[i]
+ * cdef np.ndarray[np.float64_t, ndim=3] new_data
*/
- __pyx_v_info->readonly = (!PyArray_ISWRITEABLE(((PyArrayObject *)__pyx_v_self)));
+ for (__pyx_t_1 = 0; __pyx_t_1 < 3; __pyx_t_1+=1) {
+ __pyx_v_i = __pyx_t_1;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":194
- *
- * cdef int t
- * cdef char* f = NULL # <<<<<<<<<<<<<<
- * cdef dtype descr = self.descr
- * cdef list stack
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":491
+ * cdef np.ndarray[np.int64_t, ndim=1] dims = np.empty(3, dtype='int64')
+ * for i in range(3):
+ * dims[i] = idims[i] # <<<<<<<<<<<<<<
+ * cdef np.ndarray[np.float64_t, ndim=3] new_data
+ * new_data = data[li[0]:ri[0]+1,li[1]:ri[1]+1,li[2]:ri[2]+1].copy()
+ */
+ __pyx_t_12 = __pyx_v_i;
+ *__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int64_t *, __pyx_bstruct_dims.buf, __pyx_t_12, __pyx_bstride_0_dims) = (__pyx_v_idims[__pyx_v_i]);
+ }
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":493
+ * dims[i] = idims[i]
+ * cdef np.ndarray[np.float64_t, ndim=3] new_data
+ * new_data = data[li[0]:ri[0]+1,li[1]:ri[1]+1,li[2]:ri[2]+1].copy() # <<<<<<<<<<<<<<
+ * PG = PartitionedGrid(new_data, self.LeftEdge, self.RightEdge, dims)
+ * return [PG]
*/
- __pyx_v_f = NULL;
+ __pyx_t_7 = PyInt_FromLong((__pyx_v_li[0])); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ __pyx_t_8 = PyInt_FromLong(((__pyx_v_ri[0]) + 1)); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __pyx_1 = PySlice_New(__pyx_t_7, __pyx_t_8, Py_None); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
+ __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
+ __pyx_t_8 = PyInt_FromLong((__pyx_v_li[1])); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __pyx_t_7 = PyInt_FromLong(((__pyx_v_ri[1]) + 1)); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ __pyx_2 = PySlice_New(__pyx_t_8, __pyx_t_7, Py_None); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_2);
+ __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
+ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
+ __pyx_t_7 = PyInt_FromLong((__pyx_v_li[2])); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ __pyx_t_8 = PyInt_FromLong(((__pyx_v_ri[2]) + 1)); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __pyx_3 = PySlice_New(__pyx_t_7, __pyx_t_8, Py_None); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_3);
+ __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
+ __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
+ __pyx_t_8 = PyTuple_New(3); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_8));
+ PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_1);
+ __Pyx_GIVEREF(__pyx_1);
+ PyTuple_SET_ITEM(__pyx_t_8, 1, __pyx_2);
+ __Pyx_GIVEREF(__pyx_2);
+ PyTuple_SET_ITEM(__pyx_t_8, 2, __pyx_3);
+ __Pyx_GIVEREF(__pyx_3);
+ __pyx_1 = 0;
+ __pyx_2 = 0;
+ __pyx_3 = 0;
+ __pyx_1 = PyObject_GetItem(((PyObject *)__pyx_v_data), ((PyObject *)__pyx_t_8)); if (!__pyx_1) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_1);
+ __Pyx_DECREF(((PyObject *)__pyx_t_8)); __pyx_t_8 = 0;
+ __pyx_t_8 = PyObject_GetAttr(__pyx_1, __pyx_kp_copy); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __Pyx_DECREF(__pyx_1); __pyx_1 = 0;
+ __pyx_t_7 = PyObject_Call(__pyx_t_8, ((PyObject *)__pyx_empty_tuple), NULL); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_7);
+ __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
+ if (!(__Pyx_TypeTest(__pyx_t_7, __pyx_ptype_5numpy_ndarray))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_13 = ((PyArrayObject *)__pyx_t_7);
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_new_data);
+ __pyx_t_1 = __Pyx_GetBufferAndValidate(&__pyx_bstruct_new_data, (PyObject*)__pyx_t_13, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack);
+ if (unlikely(__pyx_t_1 < 0)) {
+ PyErr_Fetch(&__pyx_t_14, &__pyx_t_15, &__pyx_t_16);
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_new_data, (PyObject*)__pyx_v_new_data, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 3, 0, __pyx_stack) == -1)) {
+ Py_XDECREF(__pyx_t_14); Py_XDECREF(__pyx_t_15); Py_XDECREF(__pyx_t_16);
+ __Pyx_RaiseBufferFallbackError();
+ } else {
+ PyErr_Restore(__pyx_t_14, __pyx_t_15, __pyx_t_16);
+ }
+ }
+ __pyx_bstride_0_new_data = __pyx_bstruct_new_data.strides[0]; __pyx_bstride_1_new_data = __pyx_bstruct_new_data.strides[1]; __pyx_bstride_2_new_data = __pyx_bstruct_new_data.strides[2];
+ __pyx_bshape_0_new_data = __pyx_bstruct_new_data.shape[0]; __pyx_bshape_1_new_data = __pyx_bstruct_new_data.shape[1]; __pyx_bshape_2_new_data = __pyx_bstruct_new_data.shape[2];
+ if (unlikely(__pyx_t_1 < 0)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 493; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_t_13 = 0;
+ __Pyx_DECREF(((PyObject *)__pyx_v_new_data));
+ __pyx_v_new_data = ((PyArrayObject *)__pyx_t_7);
+ __pyx_t_7 = 0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":195
- * cdef int t
- * cdef char* f = NULL
- * cdef dtype descr = self.descr # <<<<<<<<<<<<<<
- * cdef list stack
- * cdef int offset
- */
- __Pyx_INCREF(((PyObject *)((PyArrayObject *)__pyx_v_self)->descr));
- __pyx_v_descr = ((PyArrayObject *)__pyx_v_self)->descr;
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":494
+ * cdef np.ndarray[np.float64_t, ndim=3] new_data
+ * new_data = data[li[0]:ri[0]+1,li[1]:ri[1]+1,li[2]:ri[2]+1].copy()
+ * PG = PartitionedGrid(new_data, self.LeftEdge, self.RightEdge, dims) # <<<<<<<<<<<<<<
+ * return [PG]
+ */
+ __pyx_t_7 = PyTuple_New(4); if (unlikely(!__pyx_t_7)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 494; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_7));
+ __Pyx_INCREF(((PyObject *)__pyx_v_new_data));
+ PyTuple_SET_ITEM(__pyx_t_7, 0, ((PyObject *)__pyx_v_new_data));
+ __Pyx_GIVEREF(((PyObject *)__pyx_v_new_data));
+ __Pyx_INCREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->LeftEdge);
+ PyTuple_SET_ITEM(__pyx_t_7, 1, ((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->LeftEdge);
+ __Pyx_GIVEREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->LeftEdge);
+ __Pyx_INCREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->RightEdge);
+ PyTuple_SET_ITEM(__pyx_t_7, 2, ((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->RightEdge);
+ __Pyx_GIVEREF(((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)__pyx_v_self)->RightEdge);
+ __Pyx_INCREF(((PyObject *)__pyx_v_dims));
+ PyTuple_SET_ITEM(__pyx_t_7, 3, ((PyObject *)__pyx_v_dims));
+ __Pyx_GIVEREF(((PyObject *)__pyx_v_dims));
+ __pyx_t_8 = PyObject_Call(((PyObject *)((PyObject*)__pyx_ptype_2yt_9amr_utils_PartitionedGrid)), ((PyObject *)__pyx_t_7), NULL); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 494; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_8);
+ __Pyx_DECREF(((PyObject *)__pyx_t_7)); __pyx_t_7 = 0;
+ if (!(__Pyx_TypeTest(__pyx_t_8, __pyx_ptype_2yt_9amr_utils_PartitionedGrid))) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 494; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(((PyObject *)__pyx_v_PG));
+ __pyx_v_PG = ((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)__pyx_t_8);
+ __pyx_t_8 = 0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":199
- * cdef int offset
- *
- * cdef bint hasfields = PyDataType_HASFIELDS(descr) # <<<<<<<<<<<<<<
- *
- * if not hasfields and not copy_shape:
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":495
+ * new_data = data[li[0]:ri[0]+1,li[1]:ri[1]+1,li[2]:ri[2]+1].copy()
+ * PG = PartitionedGrid(new_data, self.LeftEdge, self.RightEdge, dims)
+ * return [PG] # <<<<<<<<<<<<<<
*/
- __pyx_v_hasfields = PyDataType_HASFIELDS(__pyx_v_descr);
+ __Pyx_XDECREF(__pyx_r);
+ __pyx_t_8 = PyList_New(1); if (unlikely(!__pyx_t_8)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 495; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_8));
+ __Pyx_INCREF(((PyObject *)__pyx_v_PG));
+ PyList_SET_ITEM(__pyx_t_8, 0, ((PyObject *)__pyx_v_PG));
+ __Pyx_GIVEREF(((PyObject *)__pyx_v_PG));
+ __pyx_r = ((PyObject *)__pyx_t_8);
+ __pyx_t_8 = 0;
+ goto __pyx_L0;
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":201
- * cdef bint hasfields = PyDataType_HASFIELDS(descr)
- *
- * if not hasfields and not copy_shape: # <<<<<<<<<<<<<<
- * # do not call releasebuffer
- * info.obj = None
- */
- if ((!__pyx_v_hasfields)) {
- __pyx_t_1 = (!__pyx_v_copy_shape);
+ __pyx_r = Py_None; __Pyx_INCREF(Py_None);
+ goto __pyx_L0;
+ __pyx_L1_error:;
+ __Pyx_XDECREF(__pyx_1);
+ __Pyx_XDECREF(__pyx_2);
+ __Pyx_XDECREF(__pyx_3);
+ __Pyx_XDECREF(__pyx_t_6);
+ __Pyx_XDECREF(__pyx_t_7);
+ __Pyx_XDECREF(__pyx_t_8);
+ __Pyx_XDECREF(__pyx_t_9);
+ { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
+ __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_new_data);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_grid_dds);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_dims);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_grid_left_edge);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_data);
+ __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
+ __Pyx_AddTraceback("yt.amr_utils.ProtoPrism.get_brick");
+ __pyx_r = NULL;
+ goto __pyx_L2;
+ __pyx_L0:;
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_new_data);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_grid_dds);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_dims);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_grid_left_edge);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_data);
+ __pyx_L2:;
+ __Pyx_DECREF((PyObject *)__pyx_v_PG);
+ __Pyx_XDECREF((PyObject *)__pyx_v_dims);
+ __Pyx_DECREF((PyObject *)__pyx_v_new_data);
+ __Pyx_XGIVEREF(__pyx_r);
+ __Pyx_FinishRefcountContext();
+ return __pyx_r;
+}
+
+/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":28
+ * @cython.boundscheck(False)
+ * @cython.wraparound(False)
+ * def CICDeposit_3(np.ndarray[np.float64_t, ndim=1] posx, # <<<<<<<<<<<<<<
+ * np.ndarray[np.float64_t, ndim=1] posy,
+ * np.ndarray[np.float64_t, ndim=1] posz,
+ */
+
+static PyObject *__pyx_pf_2yt_9amr_utils_CICDeposit_3(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
+static PyObject *__pyx_pf_2yt_9amr_utils_CICDeposit_3(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
+ PyArrayObject *__pyx_v_posx = 0;
+ PyArrayObject *__pyx_v_posy = 0;
+ PyArrayObject *__pyx_v_posz = 0;
+ PyArrayObject *__pyx_v_mass = 0;
+ __pyx_t_5numpy_int64_t __pyx_v_npositions;
+ PyArrayObject *__pyx_v_field = 0;
+ PyArrayObject *__pyx_v_leftEdge = 0;
+ PyArrayObject *__pyx_v_gridDimension = 0;
+ __pyx_t_5numpy_float64_t __pyx_v_cellSize;
+ int __pyx_v_i1;
+ int __pyx_v_j1;
+ int __pyx_v_k1;
+ int __pyx_v_n;
+ double __pyx_v_xpos;
+ double __pyx_v_ypos;
+ double __pyx_v_zpos;
+ double __pyx_v_fact;
+ double __pyx_v_edge0;
+ double __pyx_v_edge1;
+ double __pyx_v_edge2;
+ double __pyx_v_le0;
+ double __pyx_v_le1;
+ double __pyx_v_le2;
+ float __pyx_v_dx;
+ float __pyx_v_dy;
+ float __pyx_v_dz;
+ float __pyx_v_dx2;
+ float __pyx_v_dy2;
+ float __pyx_v_dz2;
+ Py_buffer __pyx_bstruct_field;
+ Py_ssize_t __pyx_bstride_0_field = 0;
+ Py_ssize_t __pyx_bstride_1_field = 0;
+ Py_ssize_t __pyx_bstride_2_field = 0;
+ Py_ssize_t __pyx_bshape_0_field = 0;
+ Py_ssize_t __pyx_bshape_1_field = 0;
+ Py_ssize_t __pyx_bshape_2_field = 0;
+ Py_buffer __pyx_bstruct_leftEdge;
+ Py_ssize_t __pyx_bstride_0_leftEdge = 0;
+ Py_ssize_t __pyx_bshape_0_leftEdge = 0;
+ Py_buffer __pyx_bstruct_posz;
+ Py_ssize_t __pyx_bstride_0_posz = 0;
+ Py_ssize_t __pyx_bshape_0_posz = 0;
+ Py_buffer __pyx_bstruct_posx;
+ Py_ssize_t __pyx_bstride_0_posx = 0;
+ Py_ssize_t __pyx_bshape_0_posx = 0;
+ Py_buffer __pyx_bstruct_posy;
+ Py_ssize_t __pyx_bstride_0_posy = 0;
+ Py_ssize_t __pyx_bshape_0_posy = 0;
+ Py_buffer __pyx_bstruct_gridDimension;
+ Py_ssize_t __pyx_bstride_0_gridDimension = 0;
+ Py_ssize_t __pyx_bshape_0_gridDimension = 0;
+ Py_buffer __pyx_bstruct_mass;
+ Py_ssize_t __pyx_bstride_0_mass = 0;
+ Py_ssize_t __pyx_bshape_0_mass = 0;
+ PyObject *__pyx_r = NULL;
+ long __pyx_t_1;
+ long __pyx_t_2;
+ long __pyx_t_3;
+ long __pyx_t_4;
+ long __pyx_t_5;
+ long __pyx_t_6;
+ int __pyx_t_7;
+ int __pyx_t_8;
+ int __pyx_t_9;
+ int __pyx_t_10;
+ int __pyx_t_11;
+ long __pyx_t_12;
+ long __pyx_t_13;
+ long __pyx_t_14;
+ int __pyx_t_15;
+ int __pyx_t_16;
+ long __pyx_t_17;
+ long __pyx_t_18;
+ int __pyx_t_19;
+ long __pyx_t_20;
+ int __pyx_t_21;
+ long __pyx_t_22;
+ int __pyx_t_23;
+ int __pyx_t_24;
+ int __pyx_t_25;
+ long __pyx_t_26;
+ int __pyx_t_27;
+ long __pyx_t_28;
+ long __pyx_t_29;
+ int __pyx_t_30;
+ int __pyx_t_31;
+ int __pyx_t_32;
+ long __pyx_t_33;
+ int __pyx_t_34;
+ int __pyx_t_35;
+ long __pyx_t_36;
+ int __pyx_t_37;
+ int __pyx_t_38;
+ int __pyx_t_39;
+ int __pyx_t_40;
+ int __pyx_t_41;
+ int __pyx_t_42;
+ static PyObject **__pyx_pyargnames[] = {&__pyx_kp_posx,&__pyx_kp_posy,&__pyx_kp_posz,&__pyx_kp_mass,&__pyx_kp_npositions,&__pyx_kp_field,&__pyx_kp_leftEdge,&__pyx_kp_gridDimension,&__pyx_kp_cellSize,0};
+ __Pyx_SetupRefcountContext("CICDeposit_3");
+ __pyx_self = __pyx_self;
+ if (unlikely(__pyx_kwds)) {
+ Py_ssize_t kw_args = PyDict_Size(__pyx_kwds);
+ PyObject* values[9] = {0,0,0,0,0,0,0,0,0};
+ switch (PyTuple_GET_SIZE(__pyx_args)) {
+ case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
+ case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
+ case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
+ case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
+ case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
+ case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
+ case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
+ case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
+ case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
+ case 0: break;
+ default: goto __pyx_L5_argtuple_error;
+ }
+ switch (PyTuple_GET_SIZE(__pyx_args)) {
+ case 0:
+ values[0] = PyDict_GetItem(__pyx_kwds, __pyx_kp_posx);
+ if (likely(values[0])) kw_args--;
+ else goto __pyx_L5_argtuple_error;
+ case 1:
+ values[1] = PyDict_GetItem(__pyx_kwds, __pyx_kp_posy);
+ if (likely(values[1])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 1); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 2:
+ values[2] = PyDict_GetItem(__pyx_kwds, __pyx_kp_posz);
+ if (likely(values[2])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 2); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 3:
+ values[3] = PyDict_GetItem(__pyx_kwds, __pyx_kp_mass);
+ if (likely(values[3])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 3); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 4:
+ values[4] = PyDict_GetItem(__pyx_kwds, __pyx_kp_npositions);
+ if (likely(values[4])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 4); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 5:
+ values[5] = PyDict_GetItem(__pyx_kwds, __pyx_kp_field);
+ if (likely(values[5])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 5); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 6:
+ values[6] = PyDict_GetItem(__pyx_kwds, __pyx_kp_leftEdge);
+ if (likely(values[6])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 6); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 7:
+ values[7] = PyDict_GetItem(__pyx_kwds, __pyx_kp_gridDimension);
+ if (likely(values[7])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 7); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ case 8:
+ values[8] = PyDict_GetItem(__pyx_kwds, __pyx_kp_cellSize);
+ if (likely(values[8])) kw_args--;
+ else {
+ __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, 8); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ }
+ if (unlikely(kw_args > 0)) {
+ if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, PyTuple_GET_SIZE(__pyx_args), "CICDeposit_3") < 0)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ __pyx_v_posx = ((PyArrayObject *)values[0]);
+ __pyx_v_posy = ((PyArrayObject *)values[1]);
+ __pyx_v_posz = ((PyArrayObject *)values[2]);
+ __pyx_v_mass = ((PyArrayObject *)values[3]);
+ __pyx_v_npositions = __Pyx_PyInt_from_py_npy_int64(values[4]); if (unlikely((__pyx_v_npositions == (npy_int64)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_field = ((PyArrayObject *)values[5]);
+ __pyx_v_leftEdge = ((PyArrayObject *)values[6]);
+ __pyx_v_gridDimension = ((PyArrayObject *)values[7]);
+ __pyx_v_cellSize = __pyx_PyFloat_AsDouble(values[8]); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ } else if (PyTuple_GET_SIZE(__pyx_args) != 9) {
+ goto __pyx_L5_argtuple_error;
+ } else {
+ __pyx_v_posx = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 0));
+ __pyx_v_posy = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 1));
+ __pyx_v_posz = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 2));
+ __pyx_v_mass = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 3));
+ __pyx_v_npositions = __Pyx_PyInt_from_py_npy_int64(PyTuple_GET_ITEM(__pyx_args, 4)); if (unlikely((__pyx_v_npositions == (npy_int64)-1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 32; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_v_field = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 5));
+ __pyx_v_leftEdge = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 6));
+ __pyx_v_gridDimension = ((PyArrayObject *)PyTuple_GET_ITEM(__pyx_args, 7));
+ __pyx_v_cellSize = __pyx_PyFloat_AsDouble(PyTuple_GET_ITEM(__pyx_args, 8)); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 36; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ }
+ goto __pyx_L4_argument_unpacking_done;
+ __pyx_L5_argtuple_error:;
+ __Pyx_RaiseArgtupleInvalid("CICDeposit_3", 1, 9, 9, PyTuple_GET_SIZE(__pyx_args)); {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L3_error;}
+ __pyx_L3_error:;
+ __Pyx_AddTraceback("yt.amr_utils.CICDeposit_3");
+ return NULL;
+ __pyx_L4_argument_unpacking_done:;
+ __pyx_bstruct_posx.buf = NULL;
+ __pyx_bstruct_posy.buf = NULL;
+ __pyx_bstruct_posz.buf = NULL;
+ __pyx_bstruct_mass.buf = NULL;
+ __pyx_bstruct_field.buf = NULL;
+ __pyx_bstruct_leftEdge.buf = NULL;
+ __pyx_bstruct_gridDimension.buf = NULL;
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_posx), __pyx_ptype_5numpy_ndarray, 1, "posx", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_posy), __pyx_ptype_5numpy_ndarray, 1, "posy", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 29; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_posz), __pyx_ptype_5numpy_ndarray, 1, "posz", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 30; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_mass), __pyx_ptype_5numpy_ndarray, 1, "mass", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 31; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_field), __pyx_ptype_5numpy_ndarray, 1, "field", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 33; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_leftEdge), __pyx_ptype_5numpy_ndarray, 1, "leftEdge", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 34; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (unlikely(!__Pyx_ArgTypeTest(((PyObject *)__pyx_v_gridDimension), __pyx_ptype_5numpy_ndarray, 1, "gridDimension", 0))) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 35; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_posx, (PyObject*)__pyx_v_posx, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_posx = __pyx_bstruct_posx.strides[0];
+ __pyx_bshape_0_posx = __pyx_bstruct_posx.shape[0];
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_posy, (PyObject*)__pyx_v_posy, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_posy = __pyx_bstruct_posy.strides[0];
+ __pyx_bshape_0_posy = __pyx_bstruct_posy.shape[0];
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_posz, (PyObject*)__pyx_v_posz, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_posz = __pyx_bstruct_posz.strides[0];
+ __pyx_bshape_0_posz = __pyx_bstruct_posz.shape[0];
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_mass, (PyObject*)__pyx_v_mass, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_mass = __pyx_bstruct_mass.strides[0];
+ __pyx_bshape_0_mass = __pyx_bstruct_mass.shape[0];
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_field, (PyObject*)__pyx_v_field, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float32_t, PyBUF_FORMAT| PyBUF_STRIDES| PyBUF_WRITABLE, 3, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_field = __pyx_bstruct_field.strides[0]; __pyx_bstride_1_field = __pyx_bstruct_field.strides[1]; __pyx_bstride_2_field = __pyx_bstruct_field.strides[2];
+ __pyx_bshape_0_field = __pyx_bstruct_field.shape[0]; __pyx_bshape_1_field = __pyx_bstruct_field.shape[1]; __pyx_bshape_2_field = __pyx_bstruct_field.shape[2];
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_leftEdge, (PyObject*)__pyx_v_leftEdge, &__Pyx_TypeInfo_nn___pyx_t_5numpy_float64_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_leftEdge = __pyx_bstruct_leftEdge.strides[0];
+ __pyx_bshape_0_leftEdge = __pyx_bstruct_leftEdge.shape[0];
+ {
+ __Pyx_BufFmt_StackElem __pyx_stack[1];
+ if (unlikely(__Pyx_GetBufferAndValidate(&__pyx_bstruct_gridDimension, (PyObject*)__pyx_v_gridDimension, &__Pyx_TypeInfo_nn___pyx_t_5numpy_int32_t, PyBUF_FORMAT| PyBUF_STRIDES, 1, 0, __pyx_stack) == -1)) {__pyx_filename = __pyx_f[6]; __pyx_lineno = 28; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_bstride_0_gridDimension = __pyx_bstruct_gridDimension.strides[0];
+ __pyx_bshape_0_gridDimension = __pyx_bstruct_gridDimension.shape[0];
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":44
+ * cdef float dx, dy, dz, dx2, dy2, dz2
+ *
+ * edge0 = (<float> gridDimension[0]) - 0.5001 # <<<<<<<<<<<<<<
+ * edge1 = (<float> gridDimension[1]) - 0.5001
+ * edge2 = (<float> gridDimension[2]) - 0.5001
+ */
+ __pyx_t_1 = 0;
+ __pyx_v_edge0 = (((float)(*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int32_t *, __pyx_bstruct_gridDimension.buf, __pyx_t_1, __pyx_bstride_0_gridDimension))) - 0.50009999999999999);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":45
+ *
+ * edge0 = (<float> gridDimension[0]) - 0.5001
+ * edge1 = (<float> gridDimension[1]) - 0.5001 # <<<<<<<<<<<<<<
+ * edge2 = (<float> gridDimension[2]) - 0.5001
+ * fact = 1.0 / cellSize
+ */
+ __pyx_t_2 = 1;
+ __pyx_v_edge1 = (((float)(*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int32_t *, __pyx_bstruct_gridDimension.buf, __pyx_t_2, __pyx_bstride_0_gridDimension))) - 0.50009999999999999);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":46
+ * edge0 = (<float> gridDimension[0]) - 0.5001
+ * edge1 = (<float> gridDimension[1]) - 0.5001
+ * edge2 = (<float> gridDimension[2]) - 0.5001 # <<<<<<<<<<<<<<
+ * fact = 1.0 / cellSize
+ *
+ */
+ __pyx_t_3 = 2;
+ __pyx_v_edge2 = (((float)(*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_int32_t *, __pyx_bstruct_gridDimension.buf, __pyx_t_3, __pyx_bstride_0_gridDimension))) - 0.50009999999999999);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":47
+ * edge1 = (<float> gridDimension[1]) - 0.5001
+ * edge2 = (<float> gridDimension[2]) - 0.5001
+ * fact = 1.0 / cellSize # <<<<<<<<<<<<<<
+ *
+ * le0 = leftEdge[0]
+ */
+ __pyx_v_fact = (1.0 / __pyx_v_cellSize);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":49
+ * fact = 1.0 / cellSize
+ *
+ * le0 = leftEdge[0] # <<<<<<<<<<<<<<
+ * le1 = leftEdge[1]
+ * le2 = leftEdge[2]
+ */
+ __pyx_t_4 = 0;
+ __pyx_v_le0 = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_leftEdge.buf, __pyx_t_4, __pyx_bstride_0_leftEdge));
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":50
+ *
+ * le0 = leftEdge[0]
+ * le1 = leftEdge[1] # <<<<<<<<<<<<<<
+ * le2 = leftEdge[2]
+ *
+ */
+ __pyx_t_5 = 1;
+ __pyx_v_le1 = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_leftEdge.buf, __pyx_t_5, __pyx_bstride_0_leftEdge));
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":51
+ * le0 = leftEdge[0]
+ * le1 = leftEdge[1]
+ * le2 = leftEdge[2] # <<<<<<<<<<<<<<
+ *
+ * for n in range(npositions):
+ */
+ __pyx_t_6 = 2;
+ __pyx_v_le2 = (*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_leftEdge.buf, __pyx_t_6, __pyx_bstride_0_leftEdge));
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":53
+ * le2 = leftEdge[2]
+ *
+ * for n in range(npositions): # <<<<<<<<<<<<<<
+ *
+ * # Compute the position of the central cell
+ */
+ for (__pyx_t_7 = 0; __pyx_t_7 < __pyx_v_npositions; __pyx_t_7+=1) {
+ __pyx_v_n = __pyx_t_7;
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":56
+ *
+ * # Compute the position of the central cell
+ * xpos = fmin(fmax((posx[n] - le0)*fact, 0.5001), edge0) # <<<<<<<<<<<<<<
+ * ypos = fmin(fmax((posy[n] - le1)*fact, 0.5001), edge1)
+ * zpos = fmin(fmax((posz[n] - le2)*fact, 0.5001), edge2)
+ */
+ __pyx_t_8 = __pyx_v_n;
+ __pyx_v_xpos = __pyx_f_2yt_9amr_utils_fmin(__pyx_f_2yt_9amr_utils_fmax((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_posx.buf, __pyx_t_8, __pyx_bstride_0_posx)) - __pyx_v_le0) * __pyx_v_fact), 0.50009999999999999), __pyx_v_edge0);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":57
+ * # Compute the position of the central cell
+ * xpos = fmin(fmax((posx[n] - le0)*fact, 0.5001), edge0)
+ * ypos = fmin(fmax((posy[n] - le1)*fact, 0.5001), edge1) # <<<<<<<<<<<<<<
+ * zpos = fmin(fmax((posz[n] - le2)*fact, 0.5001), edge2)
+ *
+ */
+ __pyx_t_9 = __pyx_v_n;
+ __pyx_v_ypos = __pyx_f_2yt_9amr_utils_fmin(__pyx_f_2yt_9amr_utils_fmax((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_posy.buf, __pyx_t_9, __pyx_bstride_0_posy)) - __pyx_v_le1) * __pyx_v_fact), 0.50009999999999999), __pyx_v_edge1);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":58
+ * xpos = fmin(fmax((posx[n] - le0)*fact, 0.5001), edge0)
+ * ypos = fmin(fmax((posy[n] - le1)*fact, 0.5001), edge1)
+ * zpos = fmin(fmax((posz[n] - le2)*fact, 0.5001), edge2) # <<<<<<<<<<<<<<
+ *
+ * i1 = <int> (xpos + 0.5)
+ */
+ __pyx_t_10 = __pyx_v_n;
+ __pyx_v_zpos = __pyx_f_2yt_9amr_utils_fmin(__pyx_f_2yt_9amr_utils_fmax((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float64_t *, __pyx_bstruct_posz.buf, __pyx_t_10, __pyx_bstride_0_posz)) - __pyx_v_le2) * __pyx_v_fact), 0.50009999999999999), __pyx_v_edge2);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":60
+ * zpos = fmin(fmax((posz[n] - le2)*fact, 0.5001), edge2)
+ *
+ * i1 = <int> (xpos + 0.5) # <<<<<<<<<<<<<<
+ * j1 = <int> (ypos + 0.5)
+ * k1 = <int> (zpos + 0.5)
+ */
+ __pyx_v_i1 = ((int)(__pyx_v_xpos + 0.5));
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":61
+ *
+ * i1 = <int> (xpos + 0.5)
+ * j1 = <int> (ypos + 0.5) # <<<<<<<<<<<<<<
+ * k1 = <int> (zpos + 0.5)
+ *
+ */
+ __pyx_v_j1 = ((int)(__pyx_v_ypos + 0.5));
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":62
+ * i1 = <int> (xpos + 0.5)
+ * j1 = <int> (ypos + 0.5)
+ * k1 = <int> (zpos + 0.5) # <<<<<<<<<<<<<<
+ *
+ * # Compute the weights
+ */
+ __pyx_v_k1 = ((int)(__pyx_v_zpos + 0.5));
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":65
+ *
+ * # Compute the weights
+ * dx = (<float> i1) + 0.5 - xpos # <<<<<<<<<<<<<<
+ * dy = (<float> j1) + 0.5 - ypos
+ * dz = (<float> k1) + 0.5 - zpos
+ */
+ __pyx_v_dx = ((((float)__pyx_v_i1) + 0.5) - __pyx_v_xpos);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":66
+ * # Compute the weights
+ * dx = (<float> i1) + 0.5 - xpos
+ * dy = (<float> j1) + 0.5 - ypos # <<<<<<<<<<<<<<
+ * dz = (<float> k1) + 0.5 - zpos
+ * dx2 = 1.0 - dx
+ */
+ __pyx_v_dy = ((((float)__pyx_v_j1) + 0.5) - __pyx_v_ypos);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":67
+ * dx = (<float> i1) + 0.5 - xpos
+ * dy = (<float> j1) + 0.5 - ypos
+ * dz = (<float> k1) + 0.5 - zpos # <<<<<<<<<<<<<<
+ * dx2 = 1.0 - dx
+ * dy2 = 1.0 - dy
+ */
+ __pyx_v_dz = ((((float)__pyx_v_k1) + 0.5) - __pyx_v_zpos);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":68
+ * dy = (<float> j1) + 0.5 - ypos
+ * dz = (<float> k1) + 0.5 - zpos
+ * dx2 = 1.0 - dx # <<<<<<<<<<<<<<
+ * dy2 = 1.0 - dy
+ * dz2 = 1.0 - dz
+ */
+ __pyx_v_dx2 = (1.0 - __pyx_v_dx);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":69
+ * dz = (<float> k1) + 0.5 - zpos
+ * dx2 = 1.0 - dx
+ * dy2 = 1.0 - dy # <<<<<<<<<<<<<<
+ * dz2 = 1.0 - dz
+ *
+ */
+ __pyx_v_dy2 = (1.0 - __pyx_v_dy);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":70
+ * dx2 = 1.0 - dx
+ * dy2 = 1.0 - dy
+ * dz2 = 1.0 - dz # <<<<<<<<<<<<<<
+ *
+ * # Interpolate from field into sumfield
+ */
+ __pyx_v_dz2 = (1.0 - __pyx_v_dz);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":73
+ *
+ * # Interpolate from field into sumfield
+ * field[i1-1,j1-1,k1-1] += mass[n] * dx * dy * dz # <<<<<<<<<<<<<<
+ * field[i1 ,j1-1,k1-1] += mass[n] * dx2 * dy * dz
+ * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz
+ */
+ __pyx_t_11 = __pyx_v_n;
+ __pyx_t_12 = (__pyx_v_i1 - 1);
+ __pyx_t_13 = (__pyx_v_j1 - 1);
+ __pyx_t_14 = (__pyx_v_k1 - 1);
+ *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_12, __pyx_bstride_0_field, __pyx_t_13, __pyx_bstride_1_field, __pyx_t_14, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_11, __pyx_bstride_0_mass)) * __pyx_v_dx) * __pyx_v_dy) * __pyx_v_dz);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":74
+ * # Interpolate from field into sumfield
+ * field[i1-1,j1-1,k1-1] += mass[n] * dx * dy * dz
+ * field[i1 ,j1-1,k1-1] += mass[n] * dx2 * dy * dz # <<<<<<<<<<<<<<
+ * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz
+ * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz
+ */
+ __pyx_t_15 = __pyx_v_n;
+ __pyx_t_16 = __pyx_v_i1;
+ __pyx_t_17 = (__pyx_v_j1 - 1);
+ __pyx_t_18 = (__pyx_v_k1 - 1);
+ *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_16, __pyx_bstride_0_field, __pyx_t_17, __pyx_bstride_1_field, __pyx_t_18, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_15, __pyx_bstride_0_mass)) * __pyx_v_dx2) * __pyx_v_dy) * __pyx_v_dz);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":75
+ * field[i1-1,j1-1,k1-1] += mass[n] * dx * dy * dz
+ * field[i1 ,j1-1,k1-1] += mass[n] * dx2 * dy * dz
+ * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz # <<<<<<<<<<<<<<
+ * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz
+ * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2
+ */
+ __pyx_t_19 = __pyx_v_n;
+ __pyx_t_20 = (__pyx_v_i1 - 1);
+ __pyx_t_21 = __pyx_v_j1;
+ __pyx_t_22 = (__pyx_v_k1 - 1);
+ *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_20, __pyx_bstride_0_field, __pyx_t_21, __pyx_bstride_1_field, __pyx_t_22, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_19, __pyx_bstride_0_mass)) * __pyx_v_dx) * __pyx_v_dy2) * __pyx_v_dz);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":76
+ * field[i1 ,j1-1,k1-1] += mass[n] * dx2 * dy * dz
+ * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz
+ * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz # <<<<<<<<<<<<<<
+ * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2
+ * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2
+ */
+ __pyx_t_23 = __pyx_v_n;
+ __pyx_t_24 = __pyx_v_i1;
+ __pyx_t_25 = __pyx_v_j1;
+ __pyx_t_26 = (__pyx_v_k1 - 1);
+ *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_24, __pyx_bstride_0_field, __pyx_t_25, __pyx_bstride_1_field, __pyx_t_26, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_23, __pyx_bstride_0_mass)) * __pyx_v_dx2) * __pyx_v_dy2) * __pyx_v_dz);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":77
+ * field[i1-1,j1 ,k1-1] += mass[n] * dx * dy2 * dz
+ * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz
+ * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2 # <<<<<<<<<<<<<<
+ * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2
+ * field[i1-1,j1 ,k1 ] += mass[n] * dx * dy2 * dz2
+ */
+ __pyx_t_27 = __pyx_v_n;
+ __pyx_t_28 = (__pyx_v_i1 - 1);
+ __pyx_t_29 = (__pyx_v_j1 - 1);
+ __pyx_t_30 = __pyx_v_k1;
+ *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_28, __pyx_bstride_0_field, __pyx_t_29, __pyx_bstride_1_field, __pyx_t_30, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_27, __pyx_bstride_0_mass)) * __pyx_v_dx) * __pyx_v_dy) * __pyx_v_dz2);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":78
+ * field[i1 ,j1 ,k1-1] += mass[n] * dx2 * dy2 * dz
+ * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2
+ * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2 # <<<<<<<<<<<<<<
+ * field[i1-1,j1 ,k1 ] += mass[n] * dx * dy2 * dz2
+ * field[i1 ,j1 ,k1 ] += mass[n] * dx2 * dy2 * dz2
+ */
+ __pyx_t_31 = __pyx_v_n;
+ __pyx_t_32 = __pyx_v_i1;
+ __pyx_t_33 = (__pyx_v_j1 - 1);
+ __pyx_t_34 = __pyx_v_k1;
+ *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_32, __pyx_bstride_0_field, __pyx_t_33, __pyx_bstride_1_field, __pyx_t_34, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_31, __pyx_bstride_0_mass)) * __pyx_v_dx2) * __pyx_v_dy) * __pyx_v_dz2);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":79
+ * field[i1-1,j1-1,k1 ] += mass[n] * dx * dy * dz2
+ * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2
+ * field[i1-1,j1 ,k1 ] += mass[n] * dx * dy2 * dz2 # <<<<<<<<<<<<<<
+ * field[i1 ,j1 ,k1 ] += mass[n] * dx2 * dy2 * dz2
+ */
+ __pyx_t_35 = __pyx_v_n;
+ __pyx_t_36 = (__pyx_v_i1 - 1);
+ __pyx_t_37 = __pyx_v_j1;
+ __pyx_t_38 = __pyx_v_k1;
+ *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_36, __pyx_bstride_0_field, __pyx_t_37, __pyx_bstride_1_field, __pyx_t_38, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_35, __pyx_bstride_0_mass)) * __pyx_v_dx) * __pyx_v_dy2) * __pyx_v_dz2);
+
+ /* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/CICDeposit.pyx":80
+ * field[i1 ,j1-1,k1 ] += mass[n] * dx2 * dy * dz2
+ * field[i1-1,j1 ,k1 ] += mass[n] * dx * dy2 * dz2
+ * field[i1 ,j1 ,k1 ] += mass[n] * dx2 * dy2 * dz2 # <<<<<<<<<<<<<<
+ */
+ __pyx_t_39 = __pyx_v_n;
+ __pyx_t_40 = __pyx_v_i1;
+ __pyx_t_41 = __pyx_v_j1;
+ __pyx_t_42 = __pyx_v_k1;
+ *__Pyx_BufPtrStrided3d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_field.buf, __pyx_t_40, __pyx_bstride_0_field, __pyx_t_41, __pyx_bstride_1_field, __pyx_t_42, __pyx_bstride_2_field) += ((((*__Pyx_BufPtrStrided1d(__pyx_t_5numpy_float32_t *, __pyx_bstruct_mass.buf, __pyx_t_39, __pyx_bstride_0_mass)) * __pyx_v_dx2) * __pyx_v_dy2) * __pyx_v_dz2);
+ }
+
+ __pyx_r = Py_None; __Pyx_INCREF(Py_None);
+ goto __pyx_L0;
+ __pyx_L1_error:;
+ { PyObject *__pyx_type, *__pyx_value, *__pyx_tb;
+ __Pyx_ErrFetch(&__pyx_type, &__pyx_value, &__pyx_tb);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_field);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_leftEdge);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posz);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posx);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posy);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_gridDimension);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_mass);
+ __Pyx_ErrRestore(__pyx_type, __pyx_value, __pyx_tb);}
+ __Pyx_AddTraceback("yt.amr_utils.CICDeposit_3");
+ __pyx_r = NULL;
+ goto __pyx_L2;
+ __pyx_L0:;
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_field);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_leftEdge);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posz);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posx);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_posy);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_gridDimension);
+ __Pyx_SafeReleaseBuffer(&__pyx_bstruct_mass);
+ __pyx_L2:;
+ __Pyx_XGIVEREF(__pyx_r);
+ __Pyx_FinishRefcountContext();
+ return __pyx_r;
+}
+
+/* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":152
+ * # experimental exception made for __getbuffer__ and __releasebuffer__
+ * # -- the details of this may change.
+ * def __getbuffer__(ndarray self, Py_buffer* info, int flags): # <<<<<<<<<<<<<<
+ * # This implementation of getbuffer is geared towards Cython
+ * # requirements, and does not yet fullfill the PEP.
+ */
+
+static int __pyx_pf_5numpy_7ndarray___getbuffer__(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags); /*proto*/
+static int __pyx_pf_5numpy_7ndarray___getbuffer__(PyObject *__pyx_v_self, Py_buffer *__pyx_v_info, int __pyx_v_flags) {
+ int __pyx_v_copy_shape;
+ int __pyx_v_i;
+ int __pyx_v_ndim;
+ int __pyx_v_endian_detector;
+ int __pyx_v_little_endian;
+ int __pyx_v_t;
+ char *__pyx_v_f;
+ PyArray_Descr *__pyx_v_descr = 0;
+ int __pyx_v_offset;
+ int __pyx_v_hasfields;
+ int __pyx_r;
+ int __pyx_t_1;
+ PyObject *__pyx_t_2 = NULL;
+ PyObject *__pyx_t_3 = NULL;
+ int __pyx_t_4;
+ int __pyx_t_5;
+ int __pyx_t_6;
+ char *__pyx_t_7;
+ __Pyx_SetupRefcountContext("__getbuffer__");
+ if (__pyx_v_info == NULL) return 0;
+ __pyx_v_info->obj = Py_None; __Pyx_INCREF(Py_None);
+ __Pyx_GIVEREF(__pyx_v_info->obj);
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":158
+ * # of flags
+ * cdef int copy_shape, i, ndim
+ * cdef int endian_detector = 1 # <<<<<<<<<<<<<<
+ * cdef bint little_endian = ((<char*>&endian_detector)[0] != 0)
+ *
+ */
+ __pyx_v_endian_detector = 1;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":159
+ * cdef int copy_shape, i, ndim
+ * cdef int endian_detector = 1
+ * cdef bint little_endian = ((<char*>&endian_detector)[0] != 0) # <<<<<<<<<<<<<<
+ *
+ * ndim = PyArray_NDIM(self)
+ */
+ __pyx_v_little_endian = ((((char *)(&__pyx_v_endian_detector))[0]) != 0);
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":161
+ * cdef bint little_endian = ((<char*>&endian_detector)[0] != 0)
+ *
+ * ndim = PyArray_NDIM(self) # <<<<<<<<<<<<<<
+ *
+ * if sizeof(npy_intp) != sizeof(Py_ssize_t):
+ */
+ __pyx_v_ndim = PyArray_NDIM(((PyArrayObject *)__pyx_v_self));
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":163
+ * ndim = PyArray_NDIM(self)
+ *
+ * if sizeof(npy_intp) != sizeof(Py_ssize_t): # <<<<<<<<<<<<<<
+ * copy_shape = 1
+ * else:
+ */
+ __pyx_t_1 = ((sizeof(npy_intp)) != (sizeof(Py_ssize_t)));
+ if (__pyx_t_1) {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":164
+ *
+ * if sizeof(npy_intp) != sizeof(Py_ssize_t):
+ * copy_shape = 1 # <<<<<<<<<<<<<<
+ * else:
+ * copy_shape = 0
+ */
+ __pyx_v_copy_shape = 1;
+ goto __pyx_L5;
+ }
+ /*else*/ {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":166
+ * copy_shape = 1
+ * else:
+ * copy_shape = 0 # <<<<<<<<<<<<<<
+ *
+ * if ((flags & pybuf.PyBUF_C_CONTIGUOUS == pybuf.PyBUF_C_CONTIGUOUS)
+ */
+ __pyx_v_copy_shape = 0;
+ }
+ __pyx_L5:;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":168
+ * copy_shape = 0
+ *
+ * if ((flags & pybuf.PyBUF_C_CONTIGUOUS == pybuf.PyBUF_C_CONTIGUOUS) # <<<<<<<<<<<<<<
+ * and not PyArray_CHKFLAGS(self, NPY_C_CONTIGUOUS)):
+ * raise ValueError("ndarray is not C contiguous")
+ */
+ if (((__pyx_v_flags & PyBUF_C_CONTIGUOUS) == PyBUF_C_CONTIGUOUS)) {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":169
+ *
+ * if ((flags & pybuf.PyBUF_C_CONTIGUOUS == pybuf.PyBUF_C_CONTIGUOUS)
+ * and not PyArray_CHKFLAGS(self, NPY_C_CONTIGUOUS)): # <<<<<<<<<<<<<<
+ * raise ValueError("ndarray is not C contiguous")
+ *
+ */
+ __pyx_t_1 = (!PyArray_CHKFLAGS(((PyArrayObject *)__pyx_v_self), NPY_C_CONTIGUOUS));
+ } else {
+ __pyx_t_1 = ((__pyx_v_flags & PyBUF_C_CONTIGUOUS) == PyBUF_C_CONTIGUOUS);
+ }
+ if (__pyx_t_1) {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":170
+ * if ((flags & pybuf.PyBUF_C_CONTIGUOUS == pybuf.PyBUF_C_CONTIGUOUS)
+ * and not PyArray_CHKFLAGS(self, NPY_C_CONTIGUOUS)):
+ * raise ValueError("ndarray is not C contiguous") # <<<<<<<<<<<<<<
+ *
+ * if ((flags & pybuf.PyBUF_F_CONTIGUOUS == pybuf.PyBUF_F_CONTIGUOUS)
+ */
+ __pyx_t_2 = PyTuple_New(1); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 170; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_2));
+ __Pyx_INCREF(__pyx_kp_1);
+ PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_kp_1);
+ __Pyx_GIVEREF(__pyx_kp_1);
+ __pyx_t_3 = PyObject_Call(__pyx_builtin_ValueError, ((PyObject *)__pyx_t_2), NULL); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 170; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_3);
+ __Pyx_DECREF(((PyObject *)__pyx_t_2)); __pyx_t_2 = 0;
+ __Pyx_Raise(__pyx_t_3, 0, 0);
+ __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 170; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ goto __pyx_L6;
+ }
+ __pyx_L6:;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":172
+ * raise ValueError("ndarray is not C contiguous")
+ *
+ * if ((flags & pybuf.PyBUF_F_CONTIGUOUS == pybuf.PyBUF_F_CONTIGUOUS) # <<<<<<<<<<<<<<
+ * and not PyArray_CHKFLAGS(self, NPY_F_CONTIGUOUS)):
+ * raise ValueError("ndarray is not Fortran contiguous")
+ */
+ if (((__pyx_v_flags & PyBUF_F_CONTIGUOUS) == PyBUF_F_CONTIGUOUS)) {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":173
+ *
+ * if ((flags & pybuf.PyBUF_F_CONTIGUOUS == pybuf.PyBUF_F_CONTIGUOUS)
+ * and not PyArray_CHKFLAGS(self, NPY_F_CONTIGUOUS)): # <<<<<<<<<<<<<<
+ * raise ValueError("ndarray is not Fortran contiguous")
+ *
+ */
+ __pyx_t_1 = (!PyArray_CHKFLAGS(((PyArrayObject *)__pyx_v_self), NPY_F_CONTIGUOUS));
+ } else {
+ __pyx_t_1 = ((__pyx_v_flags & PyBUF_F_CONTIGUOUS) == PyBUF_F_CONTIGUOUS);
+ }
+ if (__pyx_t_1) {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":174
+ * if ((flags & pybuf.PyBUF_F_CONTIGUOUS == pybuf.PyBUF_F_CONTIGUOUS)
+ * and not PyArray_CHKFLAGS(self, NPY_F_CONTIGUOUS)):
+ * raise ValueError("ndarray is not Fortran contiguous") # <<<<<<<<<<<<<<
+ *
+ * info.buf = PyArray_DATA(self)
+ */
+ __pyx_t_3 = PyTuple_New(1); if (unlikely(!__pyx_t_3)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_3));
+ __Pyx_INCREF(__pyx_kp_2);
+ PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_kp_2);
+ __Pyx_GIVEREF(__pyx_kp_2);
+ __pyx_t_2 = PyObject_Call(__pyx_builtin_ValueError, ((PyObject *)__pyx_t_3), NULL); if (unlikely(!__pyx_t_2)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_2);
+ __Pyx_DECREF(((PyObject *)__pyx_t_3)); __pyx_t_3 = 0;
+ __Pyx_Raise(__pyx_t_2, 0, 0);
+ __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 174; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ goto __pyx_L7;
+ }
+ __pyx_L7:;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":176
+ * raise ValueError("ndarray is not Fortran contiguous")
+ *
+ * info.buf = PyArray_DATA(self) # <<<<<<<<<<<<<<
+ * info.ndim = ndim
+ * if copy_shape:
+ */
+ __pyx_v_info->buf = PyArray_DATA(((PyArrayObject *)__pyx_v_self));
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":177
+ *
+ * info.buf = PyArray_DATA(self)
+ * info.ndim = ndim # <<<<<<<<<<<<<<
+ * if copy_shape:
+ * # Allocate new buffer for strides and shape info. This is allocated
+ */
+ __pyx_v_info->ndim = __pyx_v_ndim;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":178
+ * info.buf = PyArray_DATA(self)
+ * info.ndim = ndim
+ * if copy_shape: # <<<<<<<<<<<<<<
+ * # Allocate new buffer for strides and shape info. This is allocated
+ * # as one block, strides first.
+ */
+ __pyx_t_4 = __pyx_v_copy_shape;
+ if (__pyx_t_4) {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":181
+ * # Allocate new buffer for strides and shape info. This is allocated
+ * # as one block, strides first.
+ * info.strides = <Py_ssize_t*>stdlib.malloc(sizeof(Py_ssize_t) * ndim * 2) # <<<<<<<<<<<<<<
+ * info.shape = info.strides + ndim
+ * for i in range(ndim):
+ */
+ __pyx_v_info->strides = ((Py_ssize_t *)malloc((((sizeof(Py_ssize_t)) * __pyx_v_ndim) * 2)));
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":182
+ * # as one block, strides first.
+ * info.strides = <Py_ssize_t*>stdlib.malloc(sizeof(Py_ssize_t) * ndim * 2)
+ * info.shape = info.strides + ndim # <<<<<<<<<<<<<<
+ * for i in range(ndim):
+ * info.strides[i] = PyArray_STRIDES(self)[i]
+ */
+ __pyx_v_info->shape = (__pyx_v_info->strides + __pyx_v_ndim);
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":183
+ * info.strides = <Py_ssize_t*>stdlib.malloc(sizeof(Py_ssize_t) * ndim * 2)
+ * info.shape = info.strides + ndim
+ * for i in range(ndim): # <<<<<<<<<<<<<<
+ * info.strides[i] = PyArray_STRIDES(self)[i]
+ * info.shape[i] = PyArray_DIMS(self)[i]
+ */
+ for (__pyx_t_4 = 0; __pyx_t_4 < __pyx_v_ndim; __pyx_t_4+=1) {
+ __pyx_v_i = __pyx_t_4;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":184
+ * info.shape = info.strides + ndim
+ * for i in range(ndim):
+ * info.strides[i] = PyArray_STRIDES(self)[i] # <<<<<<<<<<<<<<
+ * info.shape[i] = PyArray_DIMS(self)[i]
+ * else:
+ */
+ (__pyx_v_info->strides[__pyx_v_i]) = (PyArray_STRIDES(((PyArrayObject *)__pyx_v_self))[__pyx_v_i]);
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":185
+ * for i in range(ndim):
+ * info.strides[i] = PyArray_STRIDES(self)[i]
+ * info.shape[i] = PyArray_DIMS(self)[i] # <<<<<<<<<<<<<<
+ * else:
+ * info.strides = <Py_ssize_t*>PyArray_STRIDES(self)
+ */
+ (__pyx_v_info->shape[__pyx_v_i]) = (PyArray_DIMS(((PyArrayObject *)__pyx_v_self))[__pyx_v_i]);
+ }
+ goto __pyx_L8;
+ }
+ /*else*/ {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":187
+ * info.shape[i] = PyArray_DIMS(self)[i]
+ * else:
+ * info.strides = <Py_ssize_t*>PyArray_STRIDES(self) # <<<<<<<<<<<<<<
+ * info.shape = <Py_ssize_t*>PyArray_DIMS(self)
+ * info.suboffsets = NULL
+ */
+ __pyx_v_info->strides = ((Py_ssize_t *)PyArray_STRIDES(((PyArrayObject *)__pyx_v_self)));
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":188
+ * else:
+ * info.strides = <Py_ssize_t*>PyArray_STRIDES(self)
+ * info.shape = <Py_ssize_t*>PyArray_DIMS(self) # <<<<<<<<<<<<<<
+ * info.suboffsets = NULL
+ * info.itemsize = PyArray_ITEMSIZE(self)
+ */
+ __pyx_v_info->shape = ((Py_ssize_t *)PyArray_DIMS(((PyArrayObject *)__pyx_v_self)));
+ }
+ __pyx_L8:;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":189
+ * info.strides = <Py_ssize_t*>PyArray_STRIDES(self)
+ * info.shape = <Py_ssize_t*>PyArray_DIMS(self)
+ * info.suboffsets = NULL # <<<<<<<<<<<<<<
+ * info.itemsize = PyArray_ITEMSIZE(self)
+ * info.readonly = not PyArray_ISWRITEABLE(self)
+ */
+ __pyx_v_info->suboffsets = NULL;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":190
+ * info.shape = <Py_ssize_t*>PyArray_DIMS(self)
+ * info.suboffsets = NULL
+ * info.itemsize = PyArray_ITEMSIZE(self) # <<<<<<<<<<<<<<
+ * info.readonly = not PyArray_ISWRITEABLE(self)
+ *
+ */
+ __pyx_v_info->itemsize = PyArray_ITEMSIZE(((PyArrayObject *)__pyx_v_self));
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":191
+ * info.suboffsets = NULL
+ * info.itemsize = PyArray_ITEMSIZE(self)
+ * info.readonly = not PyArray_ISWRITEABLE(self) # <<<<<<<<<<<<<<
+ *
+ * cdef int t
+ */
+ __pyx_v_info->readonly = (!PyArray_ISWRITEABLE(((PyArrayObject *)__pyx_v_self)));
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":194
+ *
+ * cdef int t
+ * cdef char* f = NULL # <<<<<<<<<<<<<<
+ * cdef dtype descr = self.descr
+ * cdef list stack
+ */
+ __pyx_v_f = NULL;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":195
+ * cdef int t
+ * cdef char* f = NULL
+ * cdef dtype descr = self.descr # <<<<<<<<<<<<<<
+ * cdef list stack
+ * cdef int offset
+ */
+ __Pyx_INCREF(((PyObject *)((PyArrayObject *)__pyx_v_self)->descr));
+ __pyx_v_descr = ((PyArrayObject *)__pyx_v_self)->descr;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":199
+ * cdef int offset
+ *
+ * cdef bint hasfields = PyDataType_HASFIELDS(descr) # <<<<<<<<<<<<<<
+ *
+ * if not hasfields and not copy_shape:
+ */
+ __pyx_v_hasfields = PyDataType_HASFIELDS(__pyx_v_descr);
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":201
+ * cdef bint hasfields = PyDataType_HASFIELDS(descr)
+ *
+ * if not hasfields and not copy_shape: # <<<<<<<<<<<<<<
+ * # do not call releasebuffer
+ * info.obj = None
+ */
+ if ((!__pyx_v_hasfields)) {
+ __pyx_t_1 = (!__pyx_v_copy_shape);
} else {
__pyx_t_1 = (!__pyx_v_hasfields);
}
@@ -15073,442 +16734,869 @@
{__pyx_filename = __pyx_f[7]; __pyx_lineno = 730; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
goto __pyx_L10;
}
- __pyx_L10:;
+ __pyx_L10:;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":733
+ *
+ * # Until ticket #99 is fixed, use integers to avoid warnings
+ * if t == NPY_BYTE: f[0] = 98 #"b" # <<<<<<<<<<<<<<
+ * elif t == NPY_UBYTE: f[0] = 66 #"B"
+ * elif t == NPY_SHORT: f[0] = 104 #"h"
+ */
+ __pyx_t_5 = PyInt_FromLong(NPY_BYTE); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 98;
+ goto __pyx_L11;
+ }
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":734
+ * # Until ticket #99 is fixed, use integers to avoid warnings
+ * if t == NPY_BYTE: f[0] = 98 #"b"
+ * elif t == NPY_UBYTE: f[0] = 66 #"B" # <<<<<<<<<<<<<<
+ * elif t == NPY_SHORT: f[0] = 104 #"h"
+ * elif t == NPY_USHORT: f[0] = 72 #"H"
+ */
+ __pyx_t_4 = PyInt_FromLong(NPY_UBYTE); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 66;
+ goto __pyx_L11;
+ }
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":735
+ * if t == NPY_BYTE: f[0] = 98 #"b"
+ * elif t == NPY_UBYTE: f[0] = 66 #"B"
+ * elif t == NPY_SHORT: f[0] = 104 #"h" # <<<<<<<<<<<<<<
+ * elif t == NPY_USHORT: f[0] = 72 #"H"
+ * elif t == NPY_INT: f[0] = 105 #"i"
+ */
+ __pyx_t_5 = PyInt_FromLong(NPY_SHORT); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 104;
+ goto __pyx_L11;
+ }
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":736
+ * elif t == NPY_UBYTE: f[0] = 66 #"B"
+ * elif t == NPY_SHORT: f[0] = 104 #"h"
+ * elif t == NPY_USHORT: f[0] = 72 #"H" # <<<<<<<<<<<<<<
+ * elif t == NPY_INT: f[0] = 105 #"i"
+ * elif t == NPY_UINT: f[0] = 73 #"I"
+ */
+ __pyx_t_4 = PyInt_FromLong(NPY_USHORT); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 72;
+ goto __pyx_L11;
+ }
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":737
+ * elif t == NPY_SHORT: f[0] = 104 #"h"
+ * elif t == NPY_USHORT: f[0] = 72 #"H"
+ * elif t == NPY_INT: f[0] = 105 #"i" # <<<<<<<<<<<<<<
+ * elif t == NPY_UINT: f[0] = 73 #"I"
+ * elif t == NPY_LONG: f[0] = 108 #"l"
+ */
+ __pyx_t_5 = PyInt_FromLong(NPY_INT); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 105;
+ goto __pyx_L11;
+ }
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":738
+ * elif t == NPY_USHORT: f[0] = 72 #"H"
+ * elif t == NPY_INT: f[0] = 105 #"i"
+ * elif t == NPY_UINT: f[0] = 73 #"I" # <<<<<<<<<<<<<<
+ * elif t == NPY_LONG: f[0] = 108 #"l"
+ * elif t == NPY_ULONG: f[0] = 76 #"L"
+ */
+ __pyx_t_4 = PyInt_FromLong(NPY_UINT); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 738; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 738; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 738; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 73;
+ goto __pyx_L11;
+ }
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":739
+ * elif t == NPY_INT: f[0] = 105 #"i"
+ * elif t == NPY_UINT: f[0] = 73 #"I"
+ * elif t == NPY_LONG: f[0] = 108 #"l" # <<<<<<<<<<<<<<
+ * elif t == NPY_ULONG: f[0] = 76 #"L"
+ * elif t == NPY_LONGLONG: f[0] = 113 #"q"
+ */
+ __pyx_t_5 = PyInt_FromLong(NPY_LONG); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 739; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 739; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 739; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 108;
+ goto __pyx_L11;
+ }
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":740
+ * elif t == NPY_UINT: f[0] = 73 #"I"
+ * elif t == NPY_LONG: f[0] = 108 #"l"
+ * elif t == NPY_ULONG: f[0] = 76 #"L" # <<<<<<<<<<<<<<
+ * elif t == NPY_LONGLONG: f[0] = 113 #"q"
+ * elif t == NPY_ULONGLONG: f[0] = 81 #"Q"
+ */
+ __pyx_t_4 = PyInt_FromLong(NPY_ULONG); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 76;
+ goto __pyx_L11;
+ }
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":741
+ * elif t == NPY_LONG: f[0] = 108 #"l"
+ * elif t == NPY_ULONG: f[0] = 76 #"L"
+ * elif t == NPY_LONGLONG: f[0] = 113 #"q" # <<<<<<<<<<<<<<
+ * elif t == NPY_ULONGLONG: f[0] = 81 #"Q"
+ * elif t == NPY_FLOAT: f[0] = 102 #"f"
+ */
+ __pyx_t_5 = PyInt_FromLong(NPY_LONGLONG); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 113;
+ goto __pyx_L11;
+ }
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":733
- *
- * # Until ticket #99 is fixed, use integers to avoid warnings
- * if t == NPY_BYTE: f[0] = 98 #"b" # <<<<<<<<<<<<<<
- * elif t == NPY_UBYTE: f[0] = 66 #"B"
- * elif t == NPY_SHORT: f[0] = 104 #"h"
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":742
+ * elif t == NPY_ULONG: f[0] = 76 #"L"
+ * elif t == NPY_LONGLONG: f[0] = 113 #"q"
+ * elif t == NPY_ULONGLONG: f[0] = 81 #"Q" # <<<<<<<<<<<<<<
+ * elif t == NPY_FLOAT: f[0] = 102 #"f"
+ * elif t == NPY_DOUBLE: f[0] = 100 #"d"
*/
- __pyx_t_5 = PyInt_FromLong(NPY_BYTE); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyInt_FromLong(NPY_ULONGLONG); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
+ if (__pyx_t_8) {
+ (__pyx_v_f[0]) = 81;
+ goto __pyx_L11;
+ }
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":743
+ * elif t == NPY_LONGLONG: f[0] = 113 #"q"
+ * elif t == NPY_ULONGLONG: f[0] = 81 #"Q"
+ * elif t == NPY_FLOAT: f[0] = 102 #"f" # <<<<<<<<<<<<<<
+ * elif t == NPY_DOUBLE: f[0] = 100 #"d"
+ * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g"
+ */
+ __pyx_t_5 = PyInt_FromLong(NPY_FLOAT); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_5);
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 733; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (__pyx_t_8) {
- (__pyx_v_f[0]) = 98;
+ (__pyx_v_f[0]) = 102;
goto __pyx_L11;
}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":734
- * # Until ticket #99 is fixed, use integers to avoid warnings
- * if t == NPY_BYTE: f[0] = 98 #"b"
- * elif t == NPY_UBYTE: f[0] = 66 #"B" # <<<<<<<<<<<<<<
- * elif t == NPY_SHORT: f[0] = 104 #"h"
- * elif t == NPY_USHORT: f[0] = 72 #"H"
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":744
+ * elif t == NPY_ULONGLONG: f[0] = 81 #"Q"
+ * elif t == NPY_FLOAT: f[0] = 102 #"f"
+ * elif t == NPY_DOUBLE: f[0] = 100 #"d" # <<<<<<<<<<<<<<
+ * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g"
+ * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf
*/
- __pyx_t_4 = PyInt_FromLong(NPY_UBYTE); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyInt_FromLong(NPY_DOUBLE); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 734; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
if (__pyx_t_8) {
- (__pyx_v_f[0]) = 66;
+ (__pyx_v_f[0]) = 100;
goto __pyx_L11;
}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":735
- * if t == NPY_BYTE: f[0] = 98 #"b"
- * elif t == NPY_UBYTE: f[0] = 66 #"B"
- * elif t == NPY_SHORT: f[0] = 104 #"h" # <<<<<<<<<<<<<<
- * elif t == NPY_USHORT: f[0] = 72 #"H"
- * elif t == NPY_INT: f[0] = 105 #"i"
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":745
+ * elif t == NPY_FLOAT: f[0] = 102 #"f"
+ * elif t == NPY_DOUBLE: f[0] = 100 #"d"
+ * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g" # <<<<<<<<<<<<<<
+ * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf
+ * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd
*/
- __pyx_t_5 = PyInt_FromLong(NPY_SHORT); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyInt_FromLong(NPY_LONGDOUBLE); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 735; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (__pyx_t_8) {
- (__pyx_v_f[0]) = 104;
+ (__pyx_v_f[0]) = 103;
goto __pyx_L11;
}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":736
- * elif t == NPY_UBYTE: f[0] = 66 #"B"
- * elif t == NPY_SHORT: f[0] = 104 #"h"
- * elif t == NPY_USHORT: f[0] = 72 #"H" # <<<<<<<<<<<<<<
- * elif t == NPY_INT: f[0] = 105 #"i"
- * elif t == NPY_UINT: f[0] = 73 #"I"
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":746
+ * elif t == NPY_DOUBLE: f[0] = 100 #"d"
+ * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g"
+ * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf # <<<<<<<<<<<<<<
+ * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd
+ * elif t == NPY_CLONGDOUBLE: f[0] = 90; f[1] = 103; f += 1 # Zg
*/
- __pyx_t_4 = PyInt_FromLong(NPY_USHORT); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyInt_FromLong(NPY_CFLOAT); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 736; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
if (__pyx_t_8) {
- (__pyx_v_f[0]) = 72;
+ (__pyx_v_f[0]) = 90;
+ (__pyx_v_f[1]) = 102;
+ __pyx_v_f += 1;
goto __pyx_L11;
}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":737
- * elif t == NPY_SHORT: f[0] = 104 #"h"
- * elif t == NPY_USHORT: f[0] = 72 #"H"
- * elif t == NPY_INT: f[0] = 105 #"i" # <<<<<<<<<<<<<<
- * elif t == NPY_UINT: f[0] = 73 #"I"
- * elif t == NPY_LONG: f[0] = 108 #"l"
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":747
+ * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g"
+ * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf
+ * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd # <<<<<<<<<<<<<<
+ * elif t == NPY_CLONGDOUBLE: f[0] = 90; f[1] = 103; f += 1 # Zg
+ * elif t == NPY_OBJECT: f[0] = 79 #"O"
*/
- __pyx_t_5 = PyInt_FromLong(NPY_INT); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyInt_FromLong(NPY_CDOUBLE); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 747; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 747; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 737; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 747; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (__pyx_t_8) {
- (__pyx_v_f[0]) = 105;
+ (__pyx_v_f[0]) = 90;
+ (__pyx_v_f[1]) = 100;
+ __pyx_v_f += 1;
goto __pyx_L11;
}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":738
- * elif t == NPY_USHORT: f[0] = 72 #"H"
- * elif t == NPY_INT: f[0] = 105 #"i"
- * elif t == NPY_UINT: f[0] = 73 #"I" # <<<<<<<<<<<<<<
- * elif t == NPY_LONG: f[0] = 108 #"l"
- * elif t == NPY_ULONG: f[0] = 76 #"L"
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":748
+ * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf
+ * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd
+ * elif t == NPY_CLONGDOUBLE: f[0] = 90; f[1] = 103; f += 1 # Zg # <<<<<<<<<<<<<<
+ * elif t == NPY_OBJECT: f[0] = 79 #"O"
+ * else:
*/
- __pyx_t_4 = PyInt_FromLong(NPY_UINT); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 738; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyInt_FromLong(NPY_CLONGDOUBLE); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 738; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 738; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
if (__pyx_t_8) {
- (__pyx_v_f[0]) = 73;
+ (__pyx_v_f[0]) = 90;
+ (__pyx_v_f[1]) = 103;
+ __pyx_v_f += 1;
goto __pyx_L11;
}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":739
- * elif t == NPY_INT: f[0] = 105 #"i"
- * elif t == NPY_UINT: f[0] = 73 #"I"
- * elif t == NPY_LONG: f[0] = 108 #"l" # <<<<<<<<<<<<<<
- * elif t == NPY_ULONG: f[0] = 76 #"L"
- * elif t == NPY_LONGLONG: f[0] = 113 #"q"
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":749
+ * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd
+ * elif t == NPY_CLONGDOUBLE: f[0] = 90; f[1] = 103; f += 1 # Zg
+ * elif t == NPY_OBJECT: f[0] = 79 #"O" # <<<<<<<<<<<<<<
+ * else:
+ * raise ValueError("unknown dtype code in numpy.pxd (%d)" % t)
*/
- __pyx_t_5 = PyInt_FromLong(NPY_LONG); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 739; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_5 = PyInt_FromLong(NPY_OBJECT); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 749; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_5);
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 739; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 749; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_t_4);
__Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 739; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 749; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
if (__pyx_t_8) {
- (__pyx_v_f[0]) = 108;
+ (__pyx_v_f[0]) = 79;
goto __pyx_L11;
}
+ /*else*/ {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":751
+ * elif t == NPY_OBJECT: f[0] = 79 #"O"
+ * else:
+ * raise ValueError("unknown dtype code in numpy.pxd (%d)" % t) # <<<<<<<<<<<<<<
+ * f += 1
+ * else:
+ */
+ __pyx_t_4 = PyNumber_Remainder(__pyx_kp_30, __pyx_v_t); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __pyx_t_5 = PyTuple_New(1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(((PyObject *)__pyx_t_5));
+ PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4);
+ __Pyx_GIVEREF(__pyx_t_4);
+ __pyx_t_4 = 0;
+ __pyx_t_4 = PyObject_Call(__pyx_builtin_ValueError, ((PyObject *)__pyx_t_5), NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __Pyx_GOTREF(__pyx_t_4);
+ __Pyx_DECREF(((PyObject *)__pyx_t_5)); __pyx_t_5 = 0;
+ __Pyx_Raise(__pyx_t_4, 0, 0);
+ __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
+ {__pyx_filename = __pyx_f[7]; __pyx_lineno = 751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ }
+ __pyx_L11:;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":752
+ * else:
+ * raise ValueError("unknown dtype code in numpy.pxd (%d)" % t)
+ * f += 1 # <<<<<<<<<<<<<<
+ * else:
+ * # Cython ignores struct boundary information ("T{...}"),
+ */
+ __pyx_v_f += 1;
+ goto __pyx_L9;
+ }
+ /*else*/ {
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":756
+ * # Cython ignores struct boundary information ("T{...}"),
+ * # so don't output it
+ * f = _util_dtypestring(child, f, end, offset) # <<<<<<<<<<<<<<
+ * return f
+ *
+ */
+ __pyx_t_9 = __pyx_f_5numpy__util_dtypestring(__pyx_v_child, __pyx_v_f, __pyx_v_end, __pyx_v_offset); if (unlikely(__pyx_t_9 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 756; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_v_f = __pyx_t_9;
+ }
+ __pyx_L9:;
+ }
+ __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
+
+ /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":757
+ * # so don't output it
+ * f = _util_dtypestring(child, f, end, offset)
+ * return f # <<<<<<<<<<<<<<
+ *
+ */
+ __pyx_r = __pyx_v_f;
+ goto __pyx_L0;
+
+ __pyx_r = 0;
+ goto __pyx_L0;
+ __pyx_L1_error:;
+ __Pyx_XDECREF(__pyx_1);
+ __Pyx_XDECREF(__pyx_2);
+ __Pyx_XDECREF(__pyx_3);
+ __Pyx_XDECREF(__pyx_t_2);
+ __Pyx_XDECREF(__pyx_t_3);
+ __Pyx_XDECREF(__pyx_t_4);
+ __Pyx_XDECREF(__pyx_t_5);
+ __Pyx_AddTraceback("numpy._util_dtypestring");
+ __pyx_r = NULL;
+ __pyx_L0:;
+ __Pyx_DECREF((PyObject *)__pyx_v_child);
+ __Pyx_DECREF(__pyx_v_fields);
+ __Pyx_DECREF(__pyx_v_childname);
+ __Pyx_DECREF(__pyx_v_new_offset);
+ __Pyx_DECREF(__pyx_v_t);
+ __Pyx_FinishRefcountContext();
+ return __pyx_r;
+}
+
+static PyObject *__pyx_tp_new_2yt_9amr_utils_position(PyTypeObject *t, PyObject *a, PyObject *k) {
+ PyObject *o = (*t->tp_alloc)(t, 0);
+ if (!o) return 0;
+ if (__pyx_pf_2yt_9amr_utils_8position___cinit__(o, __pyx_empty_tuple, NULL) < 0) {
+ Py_DECREF(o); o = 0;
+ }
+ return o;
+}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":740
- * elif t == NPY_UINT: f[0] = 73 #"I"
- * elif t == NPY_LONG: f[0] = 108 #"l"
- * elif t == NPY_ULONG: f[0] = 76 #"L" # <<<<<<<<<<<<<<
- * elif t == NPY_LONGLONG: f[0] = 113 #"q"
- * elif t == NPY_ULONGLONG: f[0] = 81 #"Q"
- */
- __pyx_t_4 = PyInt_FromLong(NPY_ULONG); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 740; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 76;
- goto __pyx_L11;
- }
+static void __pyx_tp_dealloc_2yt_9amr_utils_position(PyObject *o) {
+ (*Py_TYPE(o)->tp_free)(o);
+}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":741
- * elif t == NPY_LONG: f[0] = 108 #"l"
- * elif t == NPY_ULONG: f[0] = 76 #"L"
- * elif t == NPY_LONGLONG: f[0] = 113 #"q" # <<<<<<<<<<<<<<
- * elif t == NPY_ULONGLONG: f[0] = 81 #"Q"
- * elif t == NPY_FLOAT: f[0] = 102 #"f"
- */
- __pyx_t_5 = PyInt_FromLong(NPY_LONGLONG); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 741; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 113;
- goto __pyx_L11;
- }
+static struct PyMethodDef __pyx_methods_2yt_9amr_utils_position[] = {
+ {0, 0, 0, 0}
+};
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":742
- * elif t == NPY_ULONG: f[0] = 76 #"L"
- * elif t == NPY_LONGLONG: f[0] = 113 #"q"
- * elif t == NPY_ULONGLONG: f[0] = 81 #"Q" # <<<<<<<<<<<<<<
- * elif t == NPY_FLOAT: f[0] = 102 #"f"
- * elif t == NPY_DOUBLE: f[0] = 100 #"d"
- */
- __pyx_t_4 = PyInt_FromLong(NPY_ULONGLONG); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 742; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 81;
- goto __pyx_L11;
- }
+static struct PyMemberDef __pyx_members_2yt_9amr_utils_position[] = {
+ {(char *)"output_pos", T_INT, offsetof(struct __pyx_obj_2yt_9amr_utils_position, output_pos), 0, 0},
+ {(char *)"refined_pos", T_INT, offsetof(struct __pyx_obj_2yt_9amr_utils_position, refined_pos), 0, 0},
+ {0, 0, 0, 0, 0}
+};
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":743
- * elif t == NPY_LONGLONG: f[0] = 113 #"q"
- * elif t == NPY_ULONGLONG: f[0] = 81 #"Q"
- * elif t == NPY_FLOAT: f[0] = 102 #"f" # <<<<<<<<<<<<<<
- * elif t == NPY_DOUBLE: f[0] = 100 #"d"
- * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g"
- */
- __pyx_t_5 = PyInt_FromLong(NPY_FLOAT); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 743; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 102;
- goto __pyx_L11;
- }
+static PyNumberMethods __pyx_tp_as_number_position = {
+ 0, /*nb_add*/
+ 0, /*nb_subtract*/
+ 0, /*nb_multiply*/
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_divide*/
+ #endif
+ 0, /*nb_remainder*/
+ 0, /*nb_divmod*/
+ 0, /*nb_power*/
+ 0, /*nb_negative*/
+ 0, /*nb_positive*/
+ 0, /*nb_absolute*/
+ 0, /*nb_nonzero*/
+ 0, /*nb_invert*/
+ 0, /*nb_lshift*/
+ 0, /*nb_rshift*/
+ 0, /*nb_and*/
+ 0, /*nb_xor*/
+ 0, /*nb_or*/
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_coerce*/
+ #endif
+ 0, /*nb_int*/
+ #if PY_MAJOR_VERSION >= 3
+ 0, /*reserved*/
+ #else
+ 0, /*nb_long*/
+ #endif
+ 0, /*nb_float*/
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_oct*/
+ #endif
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_hex*/
+ #endif
+ 0, /*nb_inplace_add*/
+ 0, /*nb_inplace_subtract*/
+ 0, /*nb_inplace_multiply*/
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_inplace_divide*/
+ #endif
+ 0, /*nb_inplace_remainder*/
+ 0, /*nb_inplace_power*/
+ 0, /*nb_inplace_lshift*/
+ 0, /*nb_inplace_rshift*/
+ 0, /*nb_inplace_and*/
+ 0, /*nb_inplace_xor*/
+ 0, /*nb_inplace_or*/
+ 0, /*nb_floor_divide*/
+ 0, /*nb_true_divide*/
+ 0, /*nb_inplace_floor_divide*/
+ 0, /*nb_inplace_true_divide*/
+ #if (PY_MAJOR_VERSION >= 3) || (Py_TPFLAGS_DEFAULT & Py_TPFLAGS_HAVE_INDEX)
+ 0, /*nb_index*/
+ #endif
+};
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":744
- * elif t == NPY_ULONGLONG: f[0] = 81 #"Q"
- * elif t == NPY_FLOAT: f[0] = 102 #"f"
- * elif t == NPY_DOUBLE: f[0] = 100 #"d" # <<<<<<<<<<<<<<
- * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g"
- * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf
- */
- __pyx_t_4 = PyInt_FromLong(NPY_DOUBLE); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 744; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 100;
- goto __pyx_L11;
- }
+static PySequenceMethods __pyx_tp_as_sequence_position = {
+ 0, /*sq_length*/
+ 0, /*sq_concat*/
+ 0, /*sq_repeat*/
+ 0, /*sq_item*/
+ 0, /*sq_slice*/
+ 0, /*sq_ass_item*/
+ 0, /*sq_ass_slice*/
+ 0, /*sq_contains*/
+ 0, /*sq_inplace_concat*/
+ 0, /*sq_inplace_repeat*/
+};
+
+static PyMappingMethods __pyx_tp_as_mapping_position = {
+ 0, /*mp_length*/
+ 0, /*mp_subscript*/
+ 0, /*mp_ass_subscript*/
+};
+
+static PyBufferProcs __pyx_tp_as_buffer_position = {
+ #if PY_MAJOR_VERSION < 3
+ 0, /*bf_getreadbuffer*/
+ #endif
+ #if PY_MAJOR_VERSION < 3
+ 0, /*bf_getwritebuffer*/
+ #endif
+ #if PY_MAJOR_VERSION < 3
+ 0, /*bf_getsegcount*/
+ #endif
+ #if PY_MAJOR_VERSION < 3
+ 0, /*bf_getcharbuffer*/
+ #endif
+ #if PY_VERSION_HEX >= 0x02060000
+ 0, /*bf_getbuffer*/
+ #endif
+ #if PY_VERSION_HEX >= 0x02060000
+ 0, /*bf_releasebuffer*/
+ #endif
+};
+
+PyTypeObject __pyx_type_2yt_9amr_utils_position = {
+ PyVarObject_HEAD_INIT(0, 0)
+ __Pyx_NAMESTR("yt.amr_utils.position"), /*tp_name*/
+ sizeof(struct __pyx_obj_2yt_9amr_utils_position), /*tp_basicsize*/
+ 0, /*tp_itemsize*/
+ __pyx_tp_dealloc_2yt_9amr_utils_position, /*tp_dealloc*/
+ 0, /*tp_print*/
+ 0, /*tp_getattr*/
+ 0, /*tp_setattr*/
+ 0, /*tp_compare*/
+ 0, /*tp_repr*/
+ &__pyx_tp_as_number_position, /*tp_as_number*/
+ &__pyx_tp_as_sequence_position, /*tp_as_sequence*/
+ &__pyx_tp_as_mapping_position, /*tp_as_mapping*/
+ 0, /*tp_hash*/
+ 0, /*tp_call*/
+ 0, /*tp_str*/
+ 0, /*tp_getattro*/
+ 0, /*tp_setattro*/
+ &__pyx_tp_as_buffer_position, /*tp_as_buffer*/
+ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER, /*tp_flags*/
+ 0, /*tp_doc*/
+ 0, /*tp_traverse*/
+ 0, /*tp_clear*/
+ 0, /*tp_richcompare*/
+ 0, /*tp_weaklistoffset*/
+ 0, /*tp_iter*/
+ 0, /*tp_iternext*/
+ __pyx_methods_2yt_9amr_utils_position, /*tp_methods*/
+ __pyx_members_2yt_9amr_utils_position, /*tp_members*/
+ 0, /*tp_getset*/
+ 0, /*tp_base*/
+ 0, /*tp_dict*/
+ 0, /*tp_descr_get*/
+ 0, /*tp_descr_set*/
+ 0, /*tp_dictoffset*/
+ 0, /*tp_init*/
+ 0, /*tp_alloc*/
+ __pyx_tp_new_2yt_9amr_utils_position, /*tp_new*/
+ 0, /*tp_free*/
+ 0, /*tp_is_gc*/
+ 0, /*tp_bases*/
+ 0, /*tp_mro*/
+ 0, /*tp_cache*/
+ 0, /*tp_subclasses*/
+ 0, /*tp_weaklist*/
+};
+
+static PyObject *__pyx_tp_new_2yt_9amr_utils_OctreeGrid(PyTypeObject *t, PyObject *a, PyObject *k) {
+ struct __pyx_obj_2yt_9amr_utils_OctreeGrid *p;
+ PyObject *o = (*t->tp_alloc)(t, 0);
+ if (!o) return 0;
+ p = ((struct __pyx_obj_2yt_9amr_utils_OctreeGrid *)o);
+ p->child_indices = Py_None; Py_INCREF(Py_None);
+ p->fields = Py_None; Py_INCREF(Py_None);
+ p->left_edges = Py_None; Py_INCREF(Py_None);
+ p->dimensions = Py_None; Py_INCREF(Py_None);
+ p->dx = Py_None; Py_INCREF(Py_None);
+ if (__pyx_pf_2yt_9amr_utils_10OctreeGrid___cinit__(o, a, k) < 0) {
+ Py_DECREF(o); o = 0;
+ }
+ return o;
+}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":745
- * elif t == NPY_FLOAT: f[0] = 102 #"f"
- * elif t == NPY_DOUBLE: f[0] = 100 #"d"
- * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g" # <<<<<<<<<<<<<<
- * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf
- * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd
- */
- __pyx_t_5 = PyInt_FromLong(NPY_LONGDOUBLE); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 745; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 103;
- goto __pyx_L11;
- }
+static void __pyx_tp_dealloc_2yt_9amr_utils_OctreeGrid(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_OctreeGrid *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGrid *)o;
+ Py_XDECREF(p->child_indices);
+ Py_XDECREF(p->fields);
+ Py_XDECREF(p->left_edges);
+ Py_XDECREF(p->dimensions);
+ Py_XDECREF(p->dx);
+ (*Py_TYPE(o)->tp_free)(o);
+}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":746
- * elif t == NPY_DOUBLE: f[0] = 100 #"d"
- * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g"
- * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf # <<<<<<<<<<<<<<
- * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd
- * elif t == NPY_CLONGDOUBLE: f[0] = 90; f[1] = 103; f += 1 # Zg
- */
- __pyx_t_4 = PyInt_FromLong(NPY_CFLOAT); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 746; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 90;
- (__pyx_v_f[1]) = 102;
- __pyx_v_f += 1;
- goto __pyx_L11;
- }
+static int __pyx_tp_traverse_2yt_9amr_utils_OctreeGrid(PyObject *o, visitproc v, void *a) {
+ int e;
+ struct __pyx_obj_2yt_9amr_utils_OctreeGrid *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGrid *)o;
+ if (p->child_indices) {
+ e = (*v)(p->child_indices, a); if (e) return e;
+ }
+ if (p->fields) {
+ e = (*v)(p->fields, a); if (e) return e;
+ }
+ if (p->left_edges) {
+ e = (*v)(p->left_edges, a); if (e) return e;
+ }
+ if (p->dimensions) {
+ e = (*v)(p->dimensions, a); if (e) return e;
+ }
+ if (p->dx) {
+ e = (*v)(p->dx, a); if (e) return e;
+ }
+ return 0;
+}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":747
- * elif t == NPY_LONGDOUBLE: f[0] = 103 #"g"
- * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf
- * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd # <<<<<<<<<<<<<<
- * elif t == NPY_CLONGDOUBLE: f[0] = 90; f[1] = 103; f += 1 # Zg
- * elif t == NPY_OBJECT: f[0] = 79 #"O"
- */
- __pyx_t_5 = PyInt_FromLong(NPY_CDOUBLE); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 747; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 747; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 747; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 90;
- (__pyx_v_f[1]) = 100;
- __pyx_v_f += 1;
- goto __pyx_L11;
- }
+static int __pyx_tp_clear_2yt_9amr_utils_OctreeGrid(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_OctreeGrid *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGrid *)o;
+ PyObject* tmp;
+ tmp = ((PyObject*)p->child_indices);
+ p->child_indices = Py_None; Py_INCREF(Py_None);
+ Py_XDECREF(tmp);
+ tmp = ((PyObject*)p->fields);
+ p->fields = Py_None; Py_INCREF(Py_None);
+ Py_XDECREF(tmp);
+ tmp = ((PyObject*)p->left_edges);
+ p->left_edges = Py_None; Py_INCREF(Py_None);
+ Py_XDECREF(tmp);
+ tmp = ((PyObject*)p->dimensions);
+ p->dimensions = Py_None; Py_INCREF(Py_None);
+ Py_XDECREF(tmp);
+ tmp = ((PyObject*)p->dx);
+ p->dx = Py_None; Py_INCREF(Py_None);
+ Py_XDECREF(tmp);
+ return 0;
+}
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":748
- * elif t == NPY_CFLOAT: f[0] = 90; f[1] = 102; f += 1 # Zf
- * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd
- * elif t == NPY_CLONGDOUBLE: f[0] = 90; f[1] = 103; f += 1 # Zg # <<<<<<<<<<<<<<
- * elif t == NPY_OBJECT: f[0] = 79 #"O"
- * else:
- */
- __pyx_t_4 = PyInt_FromLong(NPY_CLONGDOUBLE); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyObject_RichCompare(__pyx_v_t, __pyx_t_4, Py_EQ); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 748; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 90;
- (__pyx_v_f[1]) = 103;
- __pyx_v_f += 1;
- goto __pyx_L11;
- }
+static struct PyMethodDef __pyx_methods_2yt_9amr_utils_OctreeGrid[] = {
+ {0, 0, 0, 0}
+};
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":749
- * elif t == NPY_CDOUBLE: f[0] = 90; f[1] = 100; f += 1 # Zd
- * elif t == NPY_CLONGDOUBLE: f[0] = 90; f[1] = 103; f += 1 # Zg
- * elif t == NPY_OBJECT: f[0] = 79 #"O" # <<<<<<<<<<<<<<
- * else:
- * raise ValueError("unknown dtype code in numpy.pxd (%d)" % t)
- */
- __pyx_t_5 = PyInt_FromLong(NPY_OBJECT); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 749; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_5);
- __pyx_t_4 = PyObject_RichCompare(__pyx_v_t, __pyx_t_5, Py_EQ); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 749; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
- __pyx_t_8 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_8 < 0)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 749; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- if (__pyx_t_8) {
- (__pyx_v_f[0]) = 79;
- goto __pyx_L11;
- }
- /*else*/ {
+static struct PyMemberDef __pyx_members_2yt_9amr_utils_OctreeGrid[] = {
+ {(char *)"child_indices", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, child_indices), 0, 0},
+ {(char *)"fields", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, fields), 0, 0},
+ {(char *)"left_edges", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, left_edges), 0, 0},
+ {(char *)"dimensions", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, dimensions), 0, 0},
+ {(char *)"dx", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, dx), 0, 0},
+ {(char *)"level", T_INT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, level), 0, 0},
+ {0, 0, 0, 0, 0}
+};
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":751
- * elif t == NPY_OBJECT: f[0] = 79 #"O"
- * else:
- * raise ValueError("unknown dtype code in numpy.pxd (%d)" % t) # <<<<<<<<<<<<<<
- * f += 1
- * else:
- */
- __pyx_t_4 = PyNumber_Remainder(__pyx_kp_30, __pyx_v_t); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __pyx_t_5 = PyTuple_New(1); if (unlikely(!__pyx_t_5)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(((PyObject *)__pyx_t_5));
- PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_4);
- __Pyx_GIVEREF(__pyx_t_4);
- __pyx_t_4 = 0;
- __pyx_t_4 = PyObject_Call(__pyx_builtin_ValueError, ((PyObject *)__pyx_t_5), NULL); if (unlikely(!__pyx_t_4)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __Pyx_GOTREF(__pyx_t_4);
- __Pyx_DECREF(((PyObject *)__pyx_t_5)); __pyx_t_5 = 0;
- __Pyx_Raise(__pyx_t_4, 0, 0);
- __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
- {__pyx_filename = __pyx_f[7]; __pyx_lineno = 751; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- }
- __pyx_L11:;
+static PyNumberMethods __pyx_tp_as_number_OctreeGrid = {
+ 0, /*nb_add*/
+ 0, /*nb_subtract*/
+ 0, /*nb_multiply*/
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_divide*/
+ #endif
+ 0, /*nb_remainder*/
+ 0, /*nb_divmod*/
+ 0, /*nb_power*/
+ 0, /*nb_negative*/
+ 0, /*nb_positive*/
+ 0, /*nb_absolute*/
+ 0, /*nb_nonzero*/
+ 0, /*nb_invert*/
+ 0, /*nb_lshift*/
+ 0, /*nb_rshift*/
+ 0, /*nb_and*/
+ 0, /*nb_xor*/
+ 0, /*nb_or*/
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_coerce*/
+ #endif
+ 0, /*nb_int*/
+ #if PY_MAJOR_VERSION >= 3
+ 0, /*reserved*/
+ #else
+ 0, /*nb_long*/
+ #endif
+ 0, /*nb_float*/
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_oct*/
+ #endif
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_hex*/
+ #endif
+ 0, /*nb_inplace_add*/
+ 0, /*nb_inplace_subtract*/
+ 0, /*nb_inplace_multiply*/
+ #if PY_MAJOR_VERSION < 3
+ 0, /*nb_inplace_divide*/
+ #endif
+ 0, /*nb_inplace_remainder*/
+ 0, /*nb_inplace_power*/
+ 0, /*nb_inplace_lshift*/
+ 0, /*nb_inplace_rshift*/
+ 0, /*nb_inplace_and*/
+ 0, /*nb_inplace_xor*/
+ 0, /*nb_inplace_or*/
+ 0, /*nb_floor_divide*/
+ 0, /*nb_true_divide*/
+ 0, /*nb_inplace_floor_divide*/
+ 0, /*nb_inplace_true_divide*/
+ #if (PY_MAJOR_VERSION >= 3) || (Py_TPFLAGS_DEFAULT & Py_TPFLAGS_HAVE_INDEX)
+ 0, /*nb_index*/
+ #endif
+};
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":752
- * else:
- * raise ValueError("unknown dtype code in numpy.pxd (%d)" % t)
- * f += 1 # <<<<<<<<<<<<<<
- * else:
- * # Cython ignores struct boundary information ("T{...}"),
- */
- __pyx_v_f += 1;
- goto __pyx_L9;
- }
- /*else*/ {
+static PySequenceMethods __pyx_tp_as_sequence_OctreeGrid = {
+ 0, /*sq_length*/
+ 0, /*sq_concat*/
+ 0, /*sq_repeat*/
+ 0, /*sq_item*/
+ 0, /*sq_slice*/
+ 0, /*sq_ass_item*/
+ 0, /*sq_ass_slice*/
+ 0, /*sq_contains*/
+ 0, /*sq_inplace_concat*/
+ 0, /*sq_inplace_repeat*/
+};
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":756
- * # Cython ignores struct boundary information ("T{...}"),
- * # so don't output it
- * f = _util_dtypestring(child, f, end, offset) # <<<<<<<<<<<<<<
- * return f
- *
- */
- __pyx_t_9 = __pyx_f_5numpy__util_dtypestring(__pyx_v_child, __pyx_v_f, __pyx_v_end, __pyx_v_offset); if (unlikely(__pyx_t_9 == NULL)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 756; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_v_f = __pyx_t_9;
- }
- __pyx_L9:;
- }
- __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
+static PyMappingMethods __pyx_tp_as_mapping_OctreeGrid = {
+ 0, /*mp_length*/
+ 0, /*mp_subscript*/
+ 0, /*mp_ass_subscript*/
+};
- /* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/numpy.pxd":757
- * # so don't output it
- * f = _util_dtypestring(child, f, end, offset)
- * return f # <<<<<<<<<<<<<<
- *
- */
- __pyx_r = __pyx_v_f;
- goto __pyx_L0;
+static PyBufferProcs __pyx_tp_as_buffer_OctreeGrid = {
+ #if PY_MAJOR_VERSION < 3
+ 0, /*bf_getreadbuffer*/
+ #endif
+ #if PY_MAJOR_VERSION < 3
+ 0, /*bf_getwritebuffer*/
+ #endif
+ #if PY_MAJOR_VERSION < 3
+ 0, /*bf_getsegcount*/
+ #endif
+ #if PY_MAJOR_VERSION < 3
+ 0, /*bf_getcharbuffer*/
+ #endif
+ #if PY_VERSION_HEX >= 0x02060000
+ 0, /*bf_getbuffer*/
+ #endif
+ #if PY_VERSION_HEX >= 0x02060000
+ 0, /*bf_releasebuffer*/
+ #endif
+};
- __pyx_r = 0;
- goto __pyx_L0;
- __pyx_L1_error:;
- __Pyx_XDECREF(__pyx_1);
- __Pyx_XDECREF(__pyx_2);
- __Pyx_XDECREF(__pyx_3);
- __Pyx_XDECREF(__pyx_t_2);
- __Pyx_XDECREF(__pyx_t_3);
- __Pyx_XDECREF(__pyx_t_4);
- __Pyx_XDECREF(__pyx_t_5);
- __Pyx_AddTraceback("numpy._util_dtypestring");
- __pyx_r = NULL;
- __pyx_L0:;
- __Pyx_DECREF((PyObject *)__pyx_v_child);
- __Pyx_DECREF(__pyx_v_fields);
- __Pyx_DECREF(__pyx_v_childname);
- __Pyx_DECREF(__pyx_v_new_offset);
- __Pyx_DECREF(__pyx_v_t);
- __Pyx_FinishRefcountContext();
- return __pyx_r;
-}
+PyTypeObject __pyx_type_2yt_9amr_utils_OctreeGrid = {
+ PyVarObject_HEAD_INIT(0, 0)
+ __Pyx_NAMESTR("yt.amr_utils.OctreeGrid"), /*tp_name*/
+ sizeof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid), /*tp_basicsize*/
+ 0, /*tp_itemsize*/
+ __pyx_tp_dealloc_2yt_9amr_utils_OctreeGrid, /*tp_dealloc*/
+ 0, /*tp_print*/
+ 0, /*tp_getattr*/
+ 0, /*tp_setattr*/
+ 0, /*tp_compare*/
+ 0, /*tp_repr*/
+ &__pyx_tp_as_number_OctreeGrid, /*tp_as_number*/
+ &__pyx_tp_as_sequence_OctreeGrid, /*tp_as_sequence*/
+ &__pyx_tp_as_mapping_OctreeGrid, /*tp_as_mapping*/
+ 0, /*tp_hash*/
+ 0, /*tp_call*/
+ 0, /*tp_str*/
+ 0, /*tp_getattro*/
+ 0, /*tp_setattro*/
+ &__pyx_tp_as_buffer_OctreeGrid, /*tp_as_buffer*/
+ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
+ 0, /*tp_doc*/
+ __pyx_tp_traverse_2yt_9amr_utils_OctreeGrid, /*tp_traverse*/
+ __pyx_tp_clear_2yt_9amr_utils_OctreeGrid, /*tp_clear*/
+ 0, /*tp_richcompare*/
+ 0, /*tp_weaklistoffset*/
+ 0, /*tp_iter*/
+ 0, /*tp_iternext*/
+ __pyx_methods_2yt_9amr_utils_OctreeGrid, /*tp_methods*/
+ __pyx_members_2yt_9amr_utils_OctreeGrid, /*tp_members*/
+ 0, /*tp_getset*/
+ 0, /*tp_base*/
+ 0, /*tp_dict*/
+ 0, /*tp_descr_get*/
+ 0, /*tp_descr_set*/
+ 0, /*tp_dictoffset*/
+ 0, /*tp_init*/
+ 0, /*tp_alloc*/
+ __pyx_tp_new_2yt_9amr_utils_OctreeGrid, /*tp_new*/
+ 0, /*tp_free*/
+ 0, /*tp_is_gc*/
+ 0, /*tp_bases*/
+ 0, /*tp_mro*/
+ 0, /*tp_cache*/
+ 0, /*tp_subclasses*/
+ 0, /*tp_weaklist*/
+};
-static PyObject *__pyx_tp_new_2yt_9amr_utils_position(PyTypeObject *t, PyObject *a, PyObject *k) {
+static PyObject *__pyx_tp_new_2yt_9amr_utils_OctreeGridList(PyTypeObject *t, PyObject *a, PyObject *k) {
+ struct __pyx_obj_2yt_9amr_utils_OctreeGridList *p;
PyObject *o = (*t->tp_alloc)(t, 0);
if (!o) return 0;
- if (__pyx_pf_2yt_9amr_utils_8position___cinit__(o, __pyx_empty_tuple, NULL) < 0) {
+ p = ((struct __pyx_obj_2yt_9amr_utils_OctreeGridList *)o);
+ p->grids = Py_None; Py_INCREF(Py_None);
+ if (__pyx_pf_2yt_9amr_utils_14OctreeGridList___cinit__(o, a, k) < 0) {
Py_DECREF(o); o = 0;
}
return o;
}
-static void __pyx_tp_dealloc_2yt_9amr_utils_position(PyObject *o) {
+static void __pyx_tp_dealloc_2yt_9amr_utils_OctreeGridList(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_OctreeGridList *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGridList *)o;
+ Py_XDECREF(p->grids);
(*Py_TYPE(o)->tp_free)(o);
}
-static struct PyMethodDef __pyx_methods_2yt_9amr_utils_position[] = {
+static int __pyx_tp_traverse_2yt_9amr_utils_OctreeGridList(PyObject *o, visitproc v, void *a) {
+ int e;
+ struct __pyx_obj_2yt_9amr_utils_OctreeGridList *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGridList *)o;
+ if (p->grids) {
+ e = (*v)(p->grids, a); if (e) return e;
+ }
+ return 0;
+}
+
+static int __pyx_tp_clear_2yt_9amr_utils_OctreeGridList(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_OctreeGridList *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGridList *)o;
+ PyObject* tmp;
+ tmp = ((PyObject*)p->grids);
+ p->grids = Py_None; Py_INCREF(Py_None);
+ Py_XDECREF(tmp);
+ return 0;
+}
+static PyObject *__pyx_sq_item_2yt_9amr_utils_OctreeGridList(PyObject *o, Py_ssize_t i) {
+ PyObject *r;
+ PyObject *x = PyInt_FromSsize_t(i); if(!x) return 0;
+ r = Py_TYPE(o)->tp_as_mapping->mp_subscript(o, x);
+ Py_DECREF(x);
+ return r;
+}
+
+static struct PyMethodDef __pyx_methods_2yt_9amr_utils_OctreeGridList[] = {
+ {__Pyx_NAMESTR("__getitem__"), (PyCFunction)__pyx_pf_2yt_9amr_utils_14OctreeGridList___getitem__, METH_O|METH_COEXIST, __Pyx_DOCSTR(0)},
{0, 0, 0, 0}
};
-static struct PyMemberDef __pyx_members_2yt_9amr_utils_position[] = {
- {(char *)"output_pos", T_INT, offsetof(struct __pyx_obj_2yt_9amr_utils_position, output_pos), 0, 0},
- {(char *)"refined_pos", T_INT, offsetof(struct __pyx_obj_2yt_9amr_utils_position, refined_pos), 0, 0},
+static struct PyMemberDef __pyx_members_2yt_9amr_utils_OctreeGridList[] = {
+ {(char *)"grids", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGridList, grids), 0, 0},
{0, 0, 0, 0, 0}
};
-static PyNumberMethods __pyx_tp_as_number_position = {
+static PyNumberMethods __pyx_tp_as_number_OctreeGridList = {
0, /*nb_add*/
0, /*nb_subtract*/
0, /*nb_multiply*/
@@ -15566,11 +17654,11 @@
#endif
};
-static PySequenceMethods __pyx_tp_as_sequence_position = {
+static PySequenceMethods __pyx_tp_as_sequence_OctreeGridList = {
0, /*sq_length*/
0, /*sq_concat*/
0, /*sq_repeat*/
- 0, /*sq_item*/
+ __pyx_sq_item_2yt_9amr_utils_OctreeGridList, /*sq_item*/
0, /*sq_slice*/
0, /*sq_ass_item*/
0, /*sq_ass_slice*/
@@ -15579,13 +17667,13 @@
0, /*sq_inplace_repeat*/
};
-static PyMappingMethods __pyx_tp_as_mapping_position = {
+static PyMappingMethods __pyx_tp_as_mapping_OctreeGridList = {
0, /*mp_length*/
- 0, /*mp_subscript*/
+ __pyx_pf_2yt_9amr_utils_14OctreeGridList___getitem__, /*mp_subscript*/
0, /*mp_ass_subscript*/
};
-static PyBufferProcs __pyx_tp_as_buffer_position = {
+static PyBufferProcs __pyx_tp_as_buffer_OctreeGridList = {
#if PY_MAJOR_VERSION < 3
0, /*bf_getreadbuffer*/
#endif
@@ -15606,36 +17694,36 @@
#endif
};
-PyTypeObject __pyx_type_2yt_9amr_utils_position = {
+PyTypeObject __pyx_type_2yt_9amr_utils_OctreeGridList = {
PyVarObject_HEAD_INIT(0, 0)
- __Pyx_NAMESTR("yt.amr_utils.position"), /*tp_name*/
- sizeof(struct __pyx_obj_2yt_9amr_utils_position), /*tp_basicsize*/
+ __Pyx_NAMESTR("yt.amr_utils.OctreeGridList"), /*tp_name*/
+ sizeof(struct __pyx_obj_2yt_9amr_utils_OctreeGridList), /*tp_basicsize*/
0, /*tp_itemsize*/
- __pyx_tp_dealloc_2yt_9amr_utils_position, /*tp_dealloc*/
+ __pyx_tp_dealloc_2yt_9amr_utils_OctreeGridList, /*tp_dealloc*/
0, /*tp_print*/
0, /*tp_getattr*/
0, /*tp_setattr*/
0, /*tp_compare*/
0, /*tp_repr*/
- &__pyx_tp_as_number_position, /*tp_as_number*/
- &__pyx_tp_as_sequence_position, /*tp_as_sequence*/
- &__pyx_tp_as_mapping_position, /*tp_as_mapping*/
+ &__pyx_tp_as_number_OctreeGridList, /*tp_as_number*/
+ &__pyx_tp_as_sequence_OctreeGridList, /*tp_as_sequence*/
+ &__pyx_tp_as_mapping_OctreeGridList, /*tp_as_mapping*/
0, /*tp_hash*/
0, /*tp_call*/
0, /*tp_str*/
0, /*tp_getattro*/
0, /*tp_setattro*/
- &__pyx_tp_as_buffer_position, /*tp_as_buffer*/
- Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER, /*tp_flags*/
+ &__pyx_tp_as_buffer_OctreeGridList, /*tp_as_buffer*/
+ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
0, /*tp_doc*/
- 0, /*tp_traverse*/
- 0, /*tp_clear*/
+ __pyx_tp_traverse_2yt_9amr_utils_OctreeGridList, /*tp_traverse*/
+ __pyx_tp_clear_2yt_9amr_utils_OctreeGridList, /*tp_clear*/
0, /*tp_richcompare*/
0, /*tp_weaklistoffset*/
0, /*tp_iter*/
0, /*tp_iternext*/
- __pyx_methods_2yt_9amr_utils_position, /*tp_methods*/
- __pyx_members_2yt_9amr_utils_position, /*tp_members*/
+ __pyx_methods_2yt_9amr_utils_OctreeGridList, /*tp_methods*/
+ __pyx_members_2yt_9amr_utils_OctreeGridList, /*tp_members*/
0, /*tp_getset*/
0, /*tp_base*/
0, /*tp_dict*/
@@ -15644,7 +17732,7 @@
0, /*tp_dictoffset*/
0, /*tp_init*/
0, /*tp_alloc*/
- __pyx_tp_new_2yt_9amr_utils_position, /*tp_new*/
+ __pyx_tp_new_2yt_9amr_utils_OctreeGridList, /*tp_new*/
0, /*tp_free*/
0, /*tp_is_gc*/
0, /*tp_bases*/
@@ -15653,90 +17741,100 @@
0, /*tp_subclasses*/
0, /*tp_weaklist*/
};
+static struct __pyx_vtabstruct_2yt_9amr_utils_VectorPlane __pyx_vtable_2yt_9amr_utils_VectorPlane;
-static PyObject *__pyx_tp_new_2yt_9amr_utils_OctreeGrid(PyTypeObject *t, PyObject *a, PyObject *k) {
- struct __pyx_obj_2yt_9amr_utils_OctreeGrid *p;
+static PyObject *__pyx_tp_new_2yt_9amr_utils_VectorPlane(PyTypeObject *t, PyObject *a, PyObject *k) {
+ struct __pyx_obj_2yt_9amr_utils_VectorPlane *p;
PyObject *o = (*t->tp_alloc)(t, 0);
if (!o) return 0;
- p = ((struct __pyx_obj_2yt_9amr_utils_OctreeGrid *)o);
- p->child_indices = Py_None; Py_INCREF(Py_None);
- p->fields = Py_None; Py_INCREF(Py_None);
- p->left_edges = Py_None; Py_INCREF(Py_None);
- p->dimensions = Py_None; Py_INCREF(Py_None);
- p->dx = Py_None; Py_INCREF(Py_None);
- if (__pyx_pf_2yt_9amr_utils_10OctreeGrid___cinit__(o, a, k) < 0) {
+ p = ((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)o);
+ p->__pyx_vtab = __pyx_vtabptr_2yt_9amr_utils_VectorPlane;
+ p->avp_pos = Py_None; Py_INCREF(Py_None);
+ p->avp_dir = Py_None; Py_INCREF(Py_None);
+ p->acenter = Py_None; Py_INCREF(Py_None);
+ p->aimage = Py_None; Py_INCREF(Py_None);
+ p->ax_vec = Py_None; Py_INCREF(Py_None);
+ p->ay_vec = Py_None; Py_INCREF(Py_None);
+ if (__pyx_pf_2yt_9amr_utils_11VectorPlane___cinit__(o, a, k) < 0) {
Py_DECREF(o); o = 0;
}
return o;
}
-static void __pyx_tp_dealloc_2yt_9amr_utils_OctreeGrid(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_OctreeGrid *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGrid *)o;
- Py_XDECREF(p->child_indices);
- Py_XDECREF(p->fields);
- Py_XDECREF(p->left_edges);
- Py_XDECREF(p->dimensions);
- Py_XDECREF(p->dx);
+static void __pyx_tp_dealloc_2yt_9amr_utils_VectorPlane(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_VectorPlane *p = (struct __pyx_obj_2yt_9amr_utils_VectorPlane *)o;
+ Py_XDECREF(p->avp_pos);
+ Py_XDECREF(p->avp_dir);
+ Py_XDECREF(p->acenter);
+ Py_XDECREF(p->aimage);
+ Py_XDECREF(p->ax_vec);
+ Py_XDECREF(p->ay_vec);
(*Py_TYPE(o)->tp_free)(o);
}
-static int __pyx_tp_traverse_2yt_9amr_utils_OctreeGrid(PyObject *o, visitproc v, void *a) {
+static int __pyx_tp_traverse_2yt_9amr_utils_VectorPlane(PyObject *o, visitproc v, void *a) {
int e;
- struct __pyx_obj_2yt_9amr_utils_OctreeGrid *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGrid *)o;
- if (p->child_indices) {
- e = (*v)(p->child_indices, a); if (e) return e;
+ struct __pyx_obj_2yt_9amr_utils_VectorPlane *p = (struct __pyx_obj_2yt_9amr_utils_VectorPlane *)o;
+ if (p->avp_pos) {
+ e = (*v)(p->avp_pos, a); if (e) return e;
+ }
+ if (p->avp_dir) {
+ e = (*v)(p->avp_dir, a); if (e) return e;
}
- if (p->fields) {
- e = (*v)(p->fields, a); if (e) return e;
+ if (p->acenter) {
+ e = (*v)(p->acenter, a); if (e) return e;
}
- if (p->left_edges) {
- e = (*v)(p->left_edges, a); if (e) return e;
+ if (p->aimage) {
+ e = (*v)(p->aimage, a); if (e) return e;
}
- if (p->dimensions) {
- e = (*v)(p->dimensions, a); if (e) return e;
+ if (p->ax_vec) {
+ e = (*v)(p->ax_vec, a); if (e) return e;
}
- if (p->dx) {
- e = (*v)(p->dx, a); if (e) return e;
+ if (p->ay_vec) {
+ e = (*v)(p->ay_vec, a); if (e) return e;
}
return 0;
}
-static int __pyx_tp_clear_2yt_9amr_utils_OctreeGrid(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_OctreeGrid *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGrid *)o;
+static int __pyx_tp_clear_2yt_9amr_utils_VectorPlane(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_VectorPlane *p = (struct __pyx_obj_2yt_9amr_utils_VectorPlane *)o;
PyObject* tmp;
- tmp = ((PyObject*)p->child_indices);
- p->child_indices = Py_None; Py_INCREF(Py_None);
+ tmp = ((PyObject*)p->avp_pos);
+ p->avp_pos = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
- tmp = ((PyObject*)p->fields);
- p->fields = Py_None; Py_INCREF(Py_None);
+ tmp = ((PyObject*)p->avp_dir);
+ p->avp_dir = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
- tmp = ((PyObject*)p->left_edges);
- p->left_edges = Py_None; Py_INCREF(Py_None);
+ tmp = ((PyObject*)p->acenter);
+ p->acenter = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
- tmp = ((PyObject*)p->dimensions);
- p->dimensions = Py_None; Py_INCREF(Py_None);
+ tmp = ((PyObject*)p->aimage);
+ p->aimage = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
- tmp = ((PyObject*)p->dx);
- p->dx = Py_None; Py_INCREF(Py_None);
+ tmp = ((PyObject*)p->ax_vec);
+ p->ax_vec = Py_None; Py_INCREF(Py_None);
+ Py_XDECREF(tmp);
+ tmp = ((PyObject*)p->ay_vec);
+ p->ay_vec = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
return 0;
}
-static struct PyMethodDef __pyx_methods_2yt_9amr_utils_OctreeGrid[] = {
+static struct PyMethodDef __pyx_methods_2yt_9amr_utils_VectorPlane[] = {
{0, 0, 0, 0}
};
-static struct PyMemberDef __pyx_members_2yt_9amr_utils_OctreeGrid[] = {
- {(char *)"child_indices", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, child_indices), 0, 0},
- {(char *)"fields", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, fields), 0, 0},
- {(char *)"left_edges", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, left_edges), 0, 0},
- {(char *)"dimensions", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, dimensions), 0, 0},
- {(char *)"dx", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, dx), 0, 0},
- {(char *)"level", T_INT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid, level), 0, 0},
+static struct PyMemberDef __pyx_members_2yt_9amr_utils_VectorPlane[] = {
+ {(char *)"avp_pos", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, avp_pos), 0, 0},
+ {(char *)"avp_dir", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, avp_dir), 0, 0},
+ {(char *)"acenter", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, acenter), 0, 0},
+ {(char *)"aimage", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, aimage), 0, 0},
+ {(char *)"ax_vec", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, ax_vec), 0, 0},
+ {(char *)"ay_vec", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, ay_vec), 0, 0},
{0, 0, 0, 0, 0}
};
-static PyNumberMethods __pyx_tp_as_number_OctreeGrid = {
+static PyNumberMethods __pyx_tp_as_number_VectorPlane = {
0, /*nb_add*/
0, /*nb_subtract*/
0, /*nb_multiply*/
@@ -15794,7 +17892,7 @@
#endif
};
-static PySequenceMethods __pyx_tp_as_sequence_OctreeGrid = {
+static PySequenceMethods __pyx_tp_as_sequence_VectorPlane = {
0, /*sq_length*/
0, /*sq_concat*/
0, /*sq_repeat*/
@@ -15807,13 +17905,13 @@
0, /*sq_inplace_repeat*/
};
-static PyMappingMethods __pyx_tp_as_mapping_OctreeGrid = {
+static PyMappingMethods __pyx_tp_as_mapping_VectorPlane = {
0, /*mp_length*/
0, /*mp_subscript*/
0, /*mp_ass_subscript*/
};
-static PyBufferProcs __pyx_tp_as_buffer_OctreeGrid = {
+static PyBufferProcs __pyx_tp_as_buffer_VectorPlane = {
#if PY_MAJOR_VERSION < 3
0, /*bf_getreadbuffer*/
#endif
@@ -15834,36 +17932,36 @@
#endif
};
-PyTypeObject __pyx_type_2yt_9amr_utils_OctreeGrid = {
+PyTypeObject __pyx_type_2yt_9amr_utils_VectorPlane = {
PyVarObject_HEAD_INIT(0, 0)
- __Pyx_NAMESTR("yt.amr_utils.OctreeGrid"), /*tp_name*/
- sizeof(struct __pyx_obj_2yt_9amr_utils_OctreeGrid), /*tp_basicsize*/
+ __Pyx_NAMESTR("yt.amr_utils.VectorPlane"), /*tp_name*/
+ sizeof(struct __pyx_obj_2yt_9amr_utils_VectorPlane), /*tp_basicsize*/
0, /*tp_itemsize*/
- __pyx_tp_dealloc_2yt_9amr_utils_OctreeGrid, /*tp_dealloc*/
+ __pyx_tp_dealloc_2yt_9amr_utils_VectorPlane, /*tp_dealloc*/
0, /*tp_print*/
0, /*tp_getattr*/
0, /*tp_setattr*/
0, /*tp_compare*/
0, /*tp_repr*/
- &__pyx_tp_as_number_OctreeGrid, /*tp_as_number*/
- &__pyx_tp_as_sequence_OctreeGrid, /*tp_as_sequence*/
- &__pyx_tp_as_mapping_OctreeGrid, /*tp_as_mapping*/
+ &__pyx_tp_as_number_VectorPlane, /*tp_as_number*/
+ &__pyx_tp_as_sequence_VectorPlane, /*tp_as_sequence*/
+ &__pyx_tp_as_mapping_VectorPlane, /*tp_as_mapping*/
0, /*tp_hash*/
0, /*tp_call*/
0, /*tp_str*/
0, /*tp_getattro*/
0, /*tp_setattro*/
- &__pyx_tp_as_buffer_OctreeGrid, /*tp_as_buffer*/
+ &__pyx_tp_as_buffer_VectorPlane, /*tp_as_buffer*/
Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
0, /*tp_doc*/
- __pyx_tp_traverse_2yt_9amr_utils_OctreeGrid, /*tp_traverse*/
- __pyx_tp_clear_2yt_9amr_utils_OctreeGrid, /*tp_clear*/
+ __pyx_tp_traverse_2yt_9amr_utils_VectorPlane, /*tp_traverse*/
+ __pyx_tp_clear_2yt_9amr_utils_VectorPlane, /*tp_clear*/
0, /*tp_richcompare*/
0, /*tp_weaklistoffset*/
0, /*tp_iter*/
0, /*tp_iternext*/
- __pyx_methods_2yt_9amr_utils_OctreeGrid, /*tp_methods*/
- __pyx_members_2yt_9amr_utils_OctreeGrid, /*tp_members*/
+ __pyx_methods_2yt_9amr_utils_VectorPlane, /*tp_methods*/
+ __pyx_members_2yt_9amr_utils_VectorPlane, /*tp_members*/
0, /*tp_getset*/
0, /*tp_base*/
0, /*tp_dict*/
@@ -15872,7 +17970,7 @@
0, /*tp_dictoffset*/
0, /*tp_init*/
0, /*tp_alloc*/
- __pyx_tp_new_2yt_9amr_utils_OctreeGrid, /*tp_new*/
+ __pyx_tp_new_2yt_9amr_utils_VectorPlane, /*tp_new*/
0, /*tp_free*/
0, /*tp_is_gc*/
0, /*tp_bases*/
@@ -15881,61 +17979,55 @@
0, /*tp_subclasses*/
0, /*tp_weaklist*/
};
+static struct __pyx_vtabstruct_2yt_9amr_utils_TransferFunctionProxy __pyx_vtable_2yt_9amr_utils_TransferFunctionProxy;
-static PyObject *__pyx_tp_new_2yt_9amr_utils_OctreeGridList(PyTypeObject *t, PyObject *a, PyObject *k) {
- struct __pyx_obj_2yt_9amr_utils_OctreeGridList *p;
+static PyObject *__pyx_tp_new_2yt_9amr_utils_TransferFunctionProxy(PyTypeObject *t, PyObject *a, PyObject *k) {
+ struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *p;
PyObject *o = (*t->tp_alloc)(t, 0);
if (!o) return 0;
- p = ((struct __pyx_obj_2yt_9amr_utils_OctreeGridList *)o);
- p->grids = Py_None; Py_INCREF(Py_None);
- if (__pyx_pf_2yt_9amr_utils_14OctreeGridList___cinit__(o, a, k) < 0) {
+ p = ((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)o);
+ p->__pyx_vtab = __pyx_vtabptr_2yt_9amr_utils_TransferFunctionProxy;
+ p->tf_obj = Py_None; Py_INCREF(Py_None);
+ if (__pyx_pf_2yt_9amr_utils_21TransferFunctionProxy___cinit__(o, a, k) < 0) {
Py_DECREF(o); o = 0;
}
return o;
}
-static void __pyx_tp_dealloc_2yt_9amr_utils_OctreeGridList(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_OctreeGridList *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGridList *)o;
- Py_XDECREF(p->grids);
+static void __pyx_tp_dealloc_2yt_9amr_utils_TransferFunctionProxy(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *p = (struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)o;
+ Py_XDECREF(p->tf_obj);
(*Py_TYPE(o)->tp_free)(o);
}
-static int __pyx_tp_traverse_2yt_9amr_utils_OctreeGridList(PyObject *o, visitproc v, void *a) {
+static int __pyx_tp_traverse_2yt_9amr_utils_TransferFunctionProxy(PyObject *o, visitproc v, void *a) {
int e;
- struct __pyx_obj_2yt_9amr_utils_OctreeGridList *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGridList *)o;
- if (p->grids) {
- e = (*v)(p->grids, a); if (e) return e;
+ struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *p = (struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)o;
+ if (p->tf_obj) {
+ e = (*v)(p->tf_obj, a); if (e) return e;
}
return 0;
}
-static int __pyx_tp_clear_2yt_9amr_utils_OctreeGridList(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_OctreeGridList *p = (struct __pyx_obj_2yt_9amr_utils_OctreeGridList *)o;
+static int __pyx_tp_clear_2yt_9amr_utils_TransferFunctionProxy(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *p = (struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)o;
PyObject* tmp;
- tmp = ((PyObject*)p->grids);
- p->grids = Py_None; Py_INCREF(Py_None);
+ tmp = ((PyObject*)p->tf_obj);
+ p->tf_obj = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
return 0;
}
-static PyObject *__pyx_sq_item_2yt_9amr_utils_OctreeGridList(PyObject *o, Py_ssize_t i) {
- PyObject *r;
- PyObject *x = PyInt_FromSsize_t(i); if(!x) return 0;
- r = Py_TYPE(o)->tp_as_mapping->mp_subscript(o, x);
- Py_DECREF(x);
- return r;
-}
-static struct PyMethodDef __pyx_methods_2yt_9amr_utils_OctreeGridList[] = {
- {__Pyx_NAMESTR("__getitem__"), (PyCFunction)__pyx_pf_2yt_9amr_utils_14OctreeGridList___getitem__, METH_O|METH_COEXIST, __Pyx_DOCSTR(0)},
+static struct PyMethodDef __pyx_methods_2yt_9amr_utils_TransferFunctionProxy[] = {
{0, 0, 0, 0}
};
-static struct PyMemberDef __pyx_members_2yt_9amr_utils_OctreeGridList[] = {
- {(char *)"grids", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_OctreeGridList, grids), 0, 0},
+static struct PyMemberDef __pyx_members_2yt_9amr_utils_TransferFunctionProxy[] = {
+ {(char *)"tf_obj", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy, tf_obj), 0, 0},
{0, 0, 0, 0, 0}
};
-static PyNumberMethods __pyx_tp_as_number_OctreeGridList = {
+static PyNumberMethods __pyx_tp_as_number_TransferFunctionProxy = {
0, /*nb_add*/
0, /*nb_subtract*/
0, /*nb_multiply*/
@@ -15993,11 +18085,11 @@
#endif
};
-static PySequenceMethods __pyx_tp_as_sequence_OctreeGridList = {
+static PySequenceMethods __pyx_tp_as_sequence_TransferFunctionProxy = {
0, /*sq_length*/
0, /*sq_concat*/
0, /*sq_repeat*/
- __pyx_sq_item_2yt_9amr_utils_OctreeGridList, /*sq_item*/
+ 0, /*sq_item*/
0, /*sq_slice*/
0, /*sq_ass_item*/
0, /*sq_ass_slice*/
@@ -16006,13 +18098,13 @@
0, /*sq_inplace_repeat*/
};
-static PyMappingMethods __pyx_tp_as_mapping_OctreeGridList = {
+static PyMappingMethods __pyx_tp_as_mapping_TransferFunctionProxy = {
0, /*mp_length*/
- __pyx_pf_2yt_9amr_utils_14OctreeGridList___getitem__, /*mp_subscript*/
+ 0, /*mp_subscript*/
0, /*mp_ass_subscript*/
};
-static PyBufferProcs __pyx_tp_as_buffer_OctreeGridList = {
+static PyBufferProcs __pyx_tp_as_buffer_TransferFunctionProxy = {
#if PY_MAJOR_VERSION < 3
0, /*bf_getreadbuffer*/
#endif
@@ -16033,36 +18125,36 @@
#endif
};
-PyTypeObject __pyx_type_2yt_9amr_utils_OctreeGridList = {
+PyTypeObject __pyx_type_2yt_9amr_utils_TransferFunctionProxy = {
PyVarObject_HEAD_INIT(0, 0)
- __Pyx_NAMESTR("yt.amr_utils.OctreeGridList"), /*tp_name*/
- sizeof(struct __pyx_obj_2yt_9amr_utils_OctreeGridList), /*tp_basicsize*/
+ __Pyx_NAMESTR("yt.amr_utils.TransferFunctionProxy"), /*tp_name*/
+ sizeof(struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy), /*tp_basicsize*/
0, /*tp_itemsize*/
- __pyx_tp_dealloc_2yt_9amr_utils_OctreeGridList, /*tp_dealloc*/
+ __pyx_tp_dealloc_2yt_9amr_utils_TransferFunctionProxy, /*tp_dealloc*/
0, /*tp_print*/
0, /*tp_getattr*/
0, /*tp_setattr*/
0, /*tp_compare*/
0, /*tp_repr*/
- &__pyx_tp_as_number_OctreeGridList, /*tp_as_number*/
- &__pyx_tp_as_sequence_OctreeGridList, /*tp_as_sequence*/
- &__pyx_tp_as_mapping_OctreeGridList, /*tp_as_mapping*/
+ &__pyx_tp_as_number_TransferFunctionProxy, /*tp_as_number*/
+ &__pyx_tp_as_sequence_TransferFunctionProxy, /*tp_as_sequence*/
+ &__pyx_tp_as_mapping_TransferFunctionProxy, /*tp_as_mapping*/
0, /*tp_hash*/
0, /*tp_call*/
0, /*tp_str*/
0, /*tp_getattro*/
0, /*tp_setattro*/
- &__pyx_tp_as_buffer_OctreeGridList, /*tp_as_buffer*/
+ &__pyx_tp_as_buffer_TransferFunctionProxy, /*tp_as_buffer*/
Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
0, /*tp_doc*/
- __pyx_tp_traverse_2yt_9amr_utils_OctreeGridList, /*tp_traverse*/
- __pyx_tp_clear_2yt_9amr_utils_OctreeGridList, /*tp_clear*/
+ __pyx_tp_traverse_2yt_9amr_utils_TransferFunctionProxy, /*tp_traverse*/
+ __pyx_tp_clear_2yt_9amr_utils_TransferFunctionProxy, /*tp_clear*/
0, /*tp_richcompare*/
0, /*tp_weaklistoffset*/
0, /*tp_iter*/
0, /*tp_iternext*/
- __pyx_methods_2yt_9amr_utils_OctreeGridList, /*tp_methods*/
- __pyx_members_2yt_9amr_utils_OctreeGridList, /*tp_members*/
+ __pyx_methods_2yt_9amr_utils_TransferFunctionProxy, /*tp_methods*/
+ __pyx_members_2yt_9amr_utils_TransferFunctionProxy, /*tp_members*/
0, /*tp_getset*/
0, /*tp_base*/
0, /*tp_dict*/
@@ -16071,7 +18163,7 @@
0, /*tp_dictoffset*/
0, /*tp_init*/
0, /*tp_alloc*/
- __pyx_tp_new_2yt_9amr_utils_OctreeGridList, /*tp_new*/
+ __pyx_tp_new_2yt_9amr_utils_TransferFunctionProxy, /*tp_new*/
0, /*tp_free*/
0, /*tp_is_gc*/
0, /*tp_bases*/
@@ -16080,100 +18172,75 @@
0, /*tp_subclasses*/
0, /*tp_weaklist*/
};
-static struct __pyx_vtabstruct_2yt_9amr_utils_VectorPlane __pyx_vtable_2yt_9amr_utils_VectorPlane;
+static struct __pyx_vtabstruct_2yt_9amr_utils_PartitionedGrid __pyx_vtable_2yt_9amr_utils_PartitionedGrid;
-static PyObject *__pyx_tp_new_2yt_9amr_utils_VectorPlane(PyTypeObject *t, PyObject *a, PyObject *k) {
- struct __pyx_obj_2yt_9amr_utils_VectorPlane *p;
+static PyObject *__pyx_tp_new_2yt_9amr_utils_PartitionedGrid(PyTypeObject *t, PyObject *a, PyObject *k) {
+ struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *p;
PyObject *o = (*t->tp_alloc)(t, 0);
if (!o) return 0;
- p = ((struct __pyx_obj_2yt_9amr_utils_VectorPlane *)o);
- p->__pyx_vtab = __pyx_vtabptr_2yt_9amr_utils_VectorPlane;
- p->avp_pos = Py_None; Py_INCREF(Py_None);
- p->avp_dir = Py_None; Py_INCREF(Py_None);
- p->acenter = Py_None; Py_INCREF(Py_None);
- p->aimage = Py_None; Py_INCREF(Py_None);
- p->ax_vec = Py_None; Py_INCREF(Py_None);
- p->ay_vec = Py_None; Py_INCREF(Py_None);
- if (__pyx_pf_2yt_9amr_utils_11VectorPlane___cinit__(o, a, k) < 0) {
+ p = ((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)o);
+ p->__pyx_vtab = __pyx_vtabptr_2yt_9amr_utils_PartitionedGrid;
+ p->my_data = Py_None; Py_INCREF(Py_None);
+ p->LeftEdge = Py_None; Py_INCREF(Py_None);
+ p->RightEdge = Py_None; Py_INCREF(Py_None);
+ if (__pyx_pf_2yt_9amr_utils_15PartitionedGrid___cinit__(o, a, k) < 0) {
Py_DECREF(o); o = 0;
}
return o;
}
-static void __pyx_tp_dealloc_2yt_9amr_utils_VectorPlane(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_VectorPlane *p = (struct __pyx_obj_2yt_9amr_utils_VectorPlane *)o;
- Py_XDECREF(p->avp_pos);
- Py_XDECREF(p->avp_dir);
- Py_XDECREF(p->acenter);
- Py_XDECREF(p->aimage);
- Py_XDECREF(p->ax_vec);
- Py_XDECREF(p->ay_vec);
+static void __pyx_tp_dealloc_2yt_9amr_utils_PartitionedGrid(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *p = (struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)o;
+ Py_XDECREF(p->my_data);
+ Py_XDECREF(p->LeftEdge);
+ Py_XDECREF(p->RightEdge);
(*Py_TYPE(o)->tp_free)(o);
}
-static int __pyx_tp_traverse_2yt_9amr_utils_VectorPlane(PyObject *o, visitproc v, void *a) {
+static int __pyx_tp_traverse_2yt_9amr_utils_PartitionedGrid(PyObject *o, visitproc v, void *a) {
int e;
- struct __pyx_obj_2yt_9amr_utils_VectorPlane *p = (struct __pyx_obj_2yt_9amr_utils_VectorPlane *)o;
- if (p->avp_pos) {
- e = (*v)(p->avp_pos, a); if (e) return e;
- }
- if (p->avp_dir) {
- e = (*v)(p->avp_dir, a); if (e) return e;
- }
- if (p->acenter) {
- e = (*v)(p->acenter, a); if (e) return e;
- }
- if (p->aimage) {
- e = (*v)(p->aimage, a); if (e) return e;
- }
- if (p->ax_vec) {
- e = (*v)(p->ax_vec, a); if (e) return e;
+ struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *p = (struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)o;
+ if (p->my_data) {
+ e = (*v)(p->my_data, a); if (e) return e;
}
- if (p->ay_vec) {
- e = (*v)(p->ay_vec, a); if (e) return e;
+ if (p->LeftEdge) {
+ e = (*v)(p->LeftEdge, a); if (e) return e;
}
- return 0;
-}
-
-static int __pyx_tp_clear_2yt_9amr_utils_VectorPlane(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_VectorPlane *p = (struct __pyx_obj_2yt_9amr_utils_VectorPlane *)o;
- PyObject* tmp;
- tmp = ((PyObject*)p->avp_pos);
- p->avp_pos = Py_None; Py_INCREF(Py_None);
- Py_XDECREF(tmp);
- tmp = ((PyObject*)p->avp_dir);
- p->avp_dir = Py_None; Py_INCREF(Py_None);
- Py_XDECREF(tmp);
- tmp = ((PyObject*)p->acenter);
- p->acenter = Py_None; Py_INCREF(Py_None);
- Py_XDECREF(tmp);
- tmp = ((PyObject*)p->aimage);
- p->aimage = Py_None; Py_INCREF(Py_None);
+ if (p->RightEdge) {
+ e = (*v)(p->RightEdge, a); if (e) return e;
+ }
+ return 0;
+}
+
+static int __pyx_tp_clear_2yt_9amr_utils_PartitionedGrid(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *p = (struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)o;
+ PyObject* tmp;
+ tmp = ((PyObject*)p->my_data);
+ p->my_data = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
- tmp = ((PyObject*)p->ax_vec);
- p->ax_vec = Py_None; Py_INCREF(Py_None);
+ tmp = ((PyObject*)p->LeftEdge);
+ p->LeftEdge = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
- tmp = ((PyObject*)p->ay_vec);
- p->ay_vec = Py_None; Py_INCREF(Py_None);
+ tmp = ((PyObject*)p->RightEdge);
+ p->RightEdge = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
return 0;
}
-static struct PyMethodDef __pyx_methods_2yt_9amr_utils_VectorPlane[] = {
+static struct PyMethodDef __pyx_methods_2yt_9amr_utils_PartitionedGrid[] = {
+ {__Pyx_NAMESTR("cast_plane"), (PyCFunction)__pyx_pf_2yt_9amr_utils_15PartitionedGrid_cast_plane, METH_VARARGS|METH_KEYWORDS, __Pyx_DOCSTR(0)},
{0, 0, 0, 0}
};
-static struct PyMemberDef __pyx_members_2yt_9amr_utils_VectorPlane[] = {
- {(char *)"avp_pos", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, avp_pos), 0, 0},
- {(char *)"avp_dir", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, avp_dir), 0, 0},
- {(char *)"acenter", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, acenter), 0, 0},
- {(char *)"aimage", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, aimage), 0, 0},
- {(char *)"ax_vec", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, ax_vec), 0, 0},
- {(char *)"ay_vec", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_VectorPlane, ay_vec), 0, 0},
+static struct PyMemberDef __pyx_members_2yt_9amr_utils_PartitionedGrid[] = {
+ {(char *)"my_data", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid, my_data), 0, 0},
+ {(char *)"LeftEdge", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid, LeftEdge), 0, 0},
+ {(char *)"RightEdge", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid, RightEdge), 0, 0},
+ {(char *)"min_dds", __Pyx_T_FLOATING(npy_float64), offsetof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid, min_dds), 0, 0},
{0, 0, 0, 0, 0}
};
-static PyNumberMethods __pyx_tp_as_number_VectorPlane = {
+static PyNumberMethods __pyx_tp_as_number_PartitionedGrid = {
0, /*nb_add*/
0, /*nb_subtract*/
0, /*nb_multiply*/
@@ -16231,7 +18298,7 @@
#endif
};
-static PySequenceMethods __pyx_tp_as_sequence_VectorPlane = {
+static PySequenceMethods __pyx_tp_as_sequence_PartitionedGrid = {
0, /*sq_length*/
0, /*sq_concat*/
0, /*sq_repeat*/
@@ -16244,13 +18311,13 @@
0, /*sq_inplace_repeat*/
};
-static PyMappingMethods __pyx_tp_as_mapping_VectorPlane = {
+static PyMappingMethods __pyx_tp_as_mapping_PartitionedGrid = {
0, /*mp_length*/
0, /*mp_subscript*/
0, /*mp_ass_subscript*/
};
-static PyBufferProcs __pyx_tp_as_buffer_VectorPlane = {
+static PyBufferProcs __pyx_tp_as_buffer_PartitionedGrid = {
#if PY_MAJOR_VERSION < 3
0, /*bf_getreadbuffer*/
#endif
@@ -16271,36 +18338,36 @@
#endif
};
-PyTypeObject __pyx_type_2yt_9amr_utils_VectorPlane = {
+PyTypeObject __pyx_type_2yt_9amr_utils_PartitionedGrid = {
PyVarObject_HEAD_INIT(0, 0)
- __Pyx_NAMESTR("yt.amr_utils.VectorPlane"), /*tp_name*/
- sizeof(struct __pyx_obj_2yt_9amr_utils_VectorPlane), /*tp_basicsize*/
+ __Pyx_NAMESTR("yt.amr_utils.PartitionedGrid"), /*tp_name*/
+ sizeof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid), /*tp_basicsize*/
0, /*tp_itemsize*/
- __pyx_tp_dealloc_2yt_9amr_utils_VectorPlane, /*tp_dealloc*/
+ __pyx_tp_dealloc_2yt_9amr_utils_PartitionedGrid, /*tp_dealloc*/
0, /*tp_print*/
0, /*tp_getattr*/
0, /*tp_setattr*/
0, /*tp_compare*/
0, /*tp_repr*/
- &__pyx_tp_as_number_VectorPlane, /*tp_as_number*/
- &__pyx_tp_as_sequence_VectorPlane, /*tp_as_sequence*/
- &__pyx_tp_as_mapping_VectorPlane, /*tp_as_mapping*/
+ &__pyx_tp_as_number_PartitionedGrid, /*tp_as_number*/
+ &__pyx_tp_as_sequence_PartitionedGrid, /*tp_as_sequence*/
+ &__pyx_tp_as_mapping_PartitionedGrid, /*tp_as_mapping*/
0, /*tp_hash*/
0, /*tp_call*/
0, /*tp_str*/
0, /*tp_getattro*/
0, /*tp_setattro*/
- &__pyx_tp_as_buffer_VectorPlane, /*tp_as_buffer*/
+ &__pyx_tp_as_buffer_PartitionedGrid, /*tp_as_buffer*/
Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
0, /*tp_doc*/
- __pyx_tp_traverse_2yt_9amr_utils_VectorPlane, /*tp_traverse*/
- __pyx_tp_clear_2yt_9amr_utils_VectorPlane, /*tp_clear*/
+ __pyx_tp_traverse_2yt_9amr_utils_PartitionedGrid, /*tp_traverse*/
+ __pyx_tp_clear_2yt_9amr_utils_PartitionedGrid, /*tp_clear*/
0, /*tp_richcompare*/
0, /*tp_weaklistoffset*/
0, /*tp_iter*/
0, /*tp_iternext*/
- __pyx_methods_2yt_9amr_utils_VectorPlane, /*tp_methods*/
- __pyx_members_2yt_9amr_utils_VectorPlane, /*tp_members*/
+ __pyx_methods_2yt_9amr_utils_PartitionedGrid, /*tp_methods*/
+ __pyx_members_2yt_9amr_utils_PartitionedGrid, /*tp_members*/
0, /*tp_getset*/
0, /*tp_base*/
0, /*tp_dict*/
@@ -16309,7 +18376,7 @@
0, /*tp_dictoffset*/
0, /*tp_init*/
0, /*tp_alloc*/
- __pyx_tp_new_2yt_9amr_utils_VectorPlane, /*tp_new*/
+ __pyx_tp_new_2yt_9amr_utils_PartitionedGrid, /*tp_new*/
0, /*tp_free*/
0, /*tp_is_gc*/
0, /*tp_bases*/
@@ -16318,55 +18385,31 @@
0, /*tp_subclasses*/
0, /*tp_weaklist*/
};
-static struct __pyx_vtabstruct_2yt_9amr_utils_TransferFunctionProxy __pyx_vtable_2yt_9amr_utils_TransferFunctionProxy;
+static struct __pyx_vtabstruct_2yt_9amr_utils_GridFace __pyx_vtable_2yt_9amr_utils_GridFace;
-static PyObject *__pyx_tp_new_2yt_9amr_utils_TransferFunctionProxy(PyTypeObject *t, PyObject *a, PyObject *k) {
- struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *p;
+static PyObject *__pyx_tp_new_2yt_9amr_utils_GridFace(PyTypeObject *t, PyObject *a, PyObject *k) {
+ struct __pyx_obj_2yt_9amr_utils_GridFace *p;
PyObject *o = (*t->tp_alloc)(t, 0);
if (!o) return 0;
- p = ((struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)o);
- p->__pyx_vtab = __pyx_vtabptr_2yt_9amr_utils_TransferFunctionProxy;
- p->tf_obj = Py_None; Py_INCREF(Py_None);
- if (__pyx_pf_2yt_9amr_utils_21TransferFunctionProxy___cinit__(o, a, k) < 0) {
- Py_DECREF(o); o = 0;
- }
+ p = ((struct __pyx_obj_2yt_9amr_utils_GridFace *)o);
+ p->__pyx_vtab = __pyx_vtabptr_2yt_9amr_utils_GridFace;
return o;
}
-static void __pyx_tp_dealloc_2yt_9amr_utils_TransferFunctionProxy(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *p = (struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)o;
- Py_XDECREF(p->tf_obj);
+static void __pyx_tp_dealloc_2yt_9amr_utils_GridFace(PyObject *o) {
(*Py_TYPE(o)->tp_free)(o);
}
-static int __pyx_tp_traverse_2yt_9amr_utils_TransferFunctionProxy(PyObject *o, visitproc v, void *a) {
- int e;
- struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *p = (struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)o;
- if (p->tf_obj) {
- e = (*v)(p->tf_obj, a); if (e) return e;
- }
- return 0;
-}
-
-static int __pyx_tp_clear_2yt_9amr_utils_TransferFunctionProxy(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *p = (struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy *)o;
- PyObject* tmp;
- tmp = ((PyObject*)p->tf_obj);
- p->tf_obj = Py_None; Py_INCREF(Py_None);
- Py_XDECREF(tmp);
- return 0;
-}
-
-static struct PyMethodDef __pyx_methods_2yt_9amr_utils_TransferFunctionProxy[] = {
+static struct PyMethodDef __pyx_methods_2yt_9amr_utils_GridFace[] = {
{0, 0, 0, 0}
};
-static struct PyMemberDef __pyx_members_2yt_9amr_utils_TransferFunctionProxy[] = {
- {(char *)"tf_obj", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy, tf_obj), 0, 0},
+static struct PyMemberDef __pyx_members_2yt_9amr_utils_GridFace[] = {
+ {(char *)"coord", __Pyx_T_FLOATING(npy_float64), offsetof(struct __pyx_obj_2yt_9amr_utils_GridFace, coord), 0, 0},
{0, 0, 0, 0, 0}
};
-static PyNumberMethods __pyx_tp_as_number_TransferFunctionProxy = {
+static PyNumberMethods __pyx_tp_as_number_GridFace = {
0, /*nb_add*/
0, /*nb_subtract*/
0, /*nb_multiply*/
@@ -16424,7 +18467,7 @@
#endif
};
-static PySequenceMethods __pyx_tp_as_sequence_TransferFunctionProxy = {
+static PySequenceMethods __pyx_tp_as_sequence_GridFace = {
0, /*sq_length*/
0, /*sq_concat*/
0, /*sq_repeat*/
@@ -16437,13 +18480,13 @@
0, /*sq_inplace_repeat*/
};
-static PyMappingMethods __pyx_tp_as_mapping_TransferFunctionProxy = {
+static PyMappingMethods __pyx_tp_as_mapping_GridFace = {
0, /*mp_length*/
0, /*mp_subscript*/
0, /*mp_ass_subscript*/
};
-static PyBufferProcs __pyx_tp_as_buffer_TransferFunctionProxy = {
+static PyBufferProcs __pyx_tp_as_buffer_GridFace = {
#if PY_MAJOR_VERSION < 3
0, /*bf_getreadbuffer*/
#endif
@@ -16464,45 +18507,45 @@
#endif
};
-PyTypeObject __pyx_type_2yt_9amr_utils_TransferFunctionProxy = {
+PyTypeObject __pyx_type_2yt_9amr_utils_GridFace = {
PyVarObject_HEAD_INIT(0, 0)
- __Pyx_NAMESTR("yt.amr_utils.TransferFunctionProxy"), /*tp_name*/
- sizeof(struct __pyx_obj_2yt_9amr_utils_TransferFunctionProxy), /*tp_basicsize*/
+ __Pyx_NAMESTR("yt.amr_utils.GridFace"), /*tp_name*/
+ sizeof(struct __pyx_obj_2yt_9amr_utils_GridFace), /*tp_basicsize*/
0, /*tp_itemsize*/
- __pyx_tp_dealloc_2yt_9amr_utils_TransferFunctionProxy, /*tp_dealloc*/
+ __pyx_tp_dealloc_2yt_9amr_utils_GridFace, /*tp_dealloc*/
0, /*tp_print*/
0, /*tp_getattr*/
0, /*tp_setattr*/
0, /*tp_compare*/
0, /*tp_repr*/
- &__pyx_tp_as_number_TransferFunctionProxy, /*tp_as_number*/
- &__pyx_tp_as_sequence_TransferFunctionProxy, /*tp_as_sequence*/
- &__pyx_tp_as_mapping_TransferFunctionProxy, /*tp_as_mapping*/
+ &__pyx_tp_as_number_GridFace, /*tp_as_number*/
+ &__pyx_tp_as_sequence_GridFace, /*tp_as_sequence*/
+ &__pyx_tp_as_mapping_GridFace, /*tp_as_mapping*/
0, /*tp_hash*/
0, /*tp_call*/
0, /*tp_str*/
0, /*tp_getattro*/
0, /*tp_setattro*/
- &__pyx_tp_as_buffer_TransferFunctionProxy, /*tp_as_buffer*/
- Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
+ &__pyx_tp_as_buffer_GridFace, /*tp_as_buffer*/
+ Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER, /*tp_flags*/
0, /*tp_doc*/
- __pyx_tp_traverse_2yt_9amr_utils_TransferFunctionProxy, /*tp_traverse*/
- __pyx_tp_clear_2yt_9amr_utils_TransferFunctionProxy, /*tp_clear*/
+ 0, /*tp_traverse*/
+ 0, /*tp_clear*/
0, /*tp_richcompare*/
0, /*tp_weaklistoffset*/
0, /*tp_iter*/
0, /*tp_iternext*/
- __pyx_methods_2yt_9amr_utils_TransferFunctionProxy, /*tp_methods*/
- __pyx_members_2yt_9amr_utils_TransferFunctionProxy, /*tp_members*/
+ __pyx_methods_2yt_9amr_utils_GridFace, /*tp_methods*/
+ __pyx_members_2yt_9amr_utils_GridFace, /*tp_members*/
0, /*tp_getset*/
0, /*tp_base*/
0, /*tp_dict*/
0, /*tp_descr_get*/
0, /*tp_descr_set*/
0, /*tp_dictoffset*/
- 0, /*tp_init*/
+ __pyx_pf_2yt_9amr_utils_8GridFace___init__, /*tp_init*/
0, /*tp_alloc*/
- __pyx_tp_new_2yt_9amr_utils_TransferFunctionProxy, /*tp_new*/
+ __pyx_tp_new_2yt_9amr_utils_GridFace, /*tp_new*/
0, /*tp_free*/
0, /*tp_is_gc*/
0, /*tp_bases*/
@@ -16511,75 +18554,75 @@
0, /*tp_subclasses*/
0, /*tp_weaklist*/
};
-static struct __pyx_vtabstruct_2yt_9amr_utils_PartitionedGrid __pyx_vtable_2yt_9amr_utils_PartitionedGrid;
+static struct __pyx_vtabstruct_2yt_9amr_utils_ProtoPrism __pyx_vtable_2yt_9amr_utils_ProtoPrism;
-static PyObject *__pyx_tp_new_2yt_9amr_utils_PartitionedGrid(PyTypeObject *t, PyObject *a, PyObject *k) {
- struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *p;
+static PyObject *__pyx_tp_new_2yt_9amr_utils_ProtoPrism(PyTypeObject *t, PyObject *a, PyObject *k) {
+ struct __pyx_obj_2yt_9amr_utils_ProtoPrism *p;
PyObject *o = (*t->tp_alloc)(t, 0);
if (!o) return 0;
- p = ((struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)o);
- p->__pyx_vtab = __pyx_vtabptr_2yt_9amr_utils_PartitionedGrid;
- p->my_data = Py_None; Py_INCREF(Py_None);
+ p = ((struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)o);
+ p->__pyx_vtab = __pyx_vtabptr_2yt_9amr_utils_ProtoPrism;
p->LeftEdge = Py_None; Py_INCREF(Py_None);
p->RightEdge = Py_None; Py_INCREF(Py_None);
- if (__pyx_pf_2yt_9amr_utils_15PartitionedGrid___cinit__(o, a, k) < 0) {
+ p->subgrid_faces = Py_None; Py_INCREF(Py_None);
+ if (__pyx_pf_2yt_9amr_utils_10ProtoPrism___cinit__(o, a, k) < 0) {
Py_DECREF(o); o = 0;
}
return o;
}
-static void __pyx_tp_dealloc_2yt_9amr_utils_PartitionedGrid(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *p = (struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)o;
- Py_XDECREF(p->my_data);
+static void __pyx_tp_dealloc_2yt_9amr_utils_ProtoPrism(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_ProtoPrism *p = (struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)o;
Py_XDECREF(p->LeftEdge);
Py_XDECREF(p->RightEdge);
+ Py_XDECREF(p->subgrid_faces);
(*Py_TYPE(o)->tp_free)(o);
}
-static int __pyx_tp_traverse_2yt_9amr_utils_PartitionedGrid(PyObject *o, visitproc v, void *a) {
+static int __pyx_tp_traverse_2yt_9amr_utils_ProtoPrism(PyObject *o, visitproc v, void *a) {
int e;
- struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *p = (struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)o;
- if (p->my_data) {
- e = (*v)(p->my_data, a); if (e) return e;
- }
+ struct __pyx_obj_2yt_9amr_utils_ProtoPrism *p = (struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)o;
if (p->LeftEdge) {
e = (*v)(p->LeftEdge, a); if (e) return e;
}
if (p->RightEdge) {
e = (*v)(p->RightEdge, a); if (e) return e;
}
+ if (p->subgrid_faces) {
+ e = (*v)(p->subgrid_faces, a); if (e) return e;
+ }
return 0;
}
-static int __pyx_tp_clear_2yt_9amr_utils_PartitionedGrid(PyObject *o) {
- struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *p = (struct __pyx_obj_2yt_9amr_utils_PartitionedGrid *)o;
+static int __pyx_tp_clear_2yt_9amr_utils_ProtoPrism(PyObject *o) {
+ struct __pyx_obj_2yt_9amr_utils_ProtoPrism *p = (struct __pyx_obj_2yt_9amr_utils_ProtoPrism *)o;
PyObject* tmp;
- tmp = ((PyObject*)p->my_data);
- p->my_data = Py_None; Py_INCREF(Py_None);
- Py_XDECREF(tmp);
tmp = ((PyObject*)p->LeftEdge);
p->LeftEdge = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
tmp = ((PyObject*)p->RightEdge);
p->RightEdge = Py_None; Py_INCREF(Py_None);
Py_XDECREF(tmp);
+ tmp = ((PyObject*)p->subgrid_faces);
+ p->subgrid_faces = Py_None; Py_INCREF(Py_None);
+ Py_XDECREF(tmp);
return 0;
}
-static struct PyMethodDef __pyx_methods_2yt_9amr_utils_PartitionedGrid[] = {
- {__Pyx_NAMESTR("cast_plane"), (PyCFunction)__pyx_pf_2yt_9amr_utils_15PartitionedGrid_cast_plane, METH_VARARGS|METH_KEYWORDS, __Pyx_DOCSTR(0)},
+static struct PyMethodDef __pyx_methods_2yt_9amr_utils_ProtoPrism[] = {
+ {__Pyx_NAMESTR("sweep"), (PyCFunction)__pyx_pf_2yt_9amr_utils_10ProtoPrism_sweep, METH_VARARGS|METH_KEYWORDS, __Pyx_DOCSTR(0)},
+ {__Pyx_NAMESTR("get_brick"), (PyCFunction)__pyx_pf_2yt_9amr_utils_10ProtoPrism_get_brick, METH_VARARGS|METH_KEYWORDS, __Pyx_DOCSTR(0)},
{0, 0, 0, 0}
};
-static struct PyMemberDef __pyx_members_2yt_9amr_utils_PartitionedGrid[] = {
- {(char *)"my_data", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid, my_data), 0, 0},
- {(char *)"LeftEdge", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid, LeftEdge), 0, 0},
- {(char *)"RightEdge", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid, RightEdge), 0, 0},
- {(char *)"min_dds", __Pyx_T_FLOATING(npy_float64), offsetof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid, min_dds), 0, 0},
+static struct PyMemberDef __pyx_members_2yt_9amr_utils_ProtoPrism[] = {
+ {(char *)"LeftEdge", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_ProtoPrism, LeftEdge), 0, 0},
+ {(char *)"RightEdge", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_ProtoPrism, RightEdge), 0, 0},
+ {(char *)"subgrid_faces", T_OBJECT, offsetof(struct __pyx_obj_2yt_9amr_utils_ProtoPrism, subgrid_faces), 0, 0},
{0, 0, 0, 0, 0}
};
-static PyNumberMethods __pyx_tp_as_number_PartitionedGrid = {
+static PyNumberMethods __pyx_tp_as_number_ProtoPrism = {
0, /*nb_add*/
0, /*nb_subtract*/
0, /*nb_multiply*/
@@ -16637,7 +18680,7 @@
#endif
};
-static PySequenceMethods __pyx_tp_as_sequence_PartitionedGrid = {
+static PySequenceMethods __pyx_tp_as_sequence_ProtoPrism = {
0, /*sq_length*/
0, /*sq_concat*/
0, /*sq_repeat*/
@@ -16650,13 +18693,13 @@
0, /*sq_inplace_repeat*/
};
-static PyMappingMethods __pyx_tp_as_mapping_PartitionedGrid = {
+static PyMappingMethods __pyx_tp_as_mapping_ProtoPrism = {
0, /*mp_length*/
0, /*mp_subscript*/
0, /*mp_ass_subscript*/
};
-static PyBufferProcs __pyx_tp_as_buffer_PartitionedGrid = {
+static PyBufferProcs __pyx_tp_as_buffer_ProtoPrism = {
#if PY_MAJOR_VERSION < 3
0, /*bf_getreadbuffer*/
#endif
@@ -16677,36 +18720,36 @@
#endif
};
-PyTypeObject __pyx_type_2yt_9amr_utils_PartitionedGrid = {
+PyTypeObject __pyx_type_2yt_9amr_utils_ProtoPrism = {
PyVarObject_HEAD_INIT(0, 0)
- __Pyx_NAMESTR("yt.amr_utils.PartitionedGrid"), /*tp_name*/
- sizeof(struct __pyx_obj_2yt_9amr_utils_PartitionedGrid), /*tp_basicsize*/
+ __Pyx_NAMESTR("yt.amr_utils.ProtoPrism"), /*tp_name*/
+ sizeof(struct __pyx_obj_2yt_9amr_utils_ProtoPrism), /*tp_basicsize*/
0, /*tp_itemsize*/
- __pyx_tp_dealloc_2yt_9amr_utils_PartitionedGrid, /*tp_dealloc*/
+ __pyx_tp_dealloc_2yt_9amr_utils_ProtoPrism, /*tp_dealloc*/
0, /*tp_print*/
0, /*tp_getattr*/
0, /*tp_setattr*/
0, /*tp_compare*/
0, /*tp_repr*/
- &__pyx_tp_as_number_PartitionedGrid, /*tp_as_number*/
- &__pyx_tp_as_sequence_PartitionedGrid, /*tp_as_sequence*/
- &__pyx_tp_as_mapping_PartitionedGrid, /*tp_as_mapping*/
+ &__pyx_tp_as_number_ProtoPrism, /*tp_as_number*/
+ &__pyx_tp_as_sequence_ProtoPrism, /*tp_as_sequence*/
+ &__pyx_tp_as_mapping_ProtoPrism, /*tp_as_mapping*/
0, /*tp_hash*/
0, /*tp_call*/
0, /*tp_str*/
0, /*tp_getattro*/
0, /*tp_setattro*/
- &__pyx_tp_as_buffer_PartitionedGrid, /*tp_as_buffer*/
+ &__pyx_tp_as_buffer_ProtoPrism, /*tp_as_buffer*/
Py_TPFLAGS_DEFAULT|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
0, /*tp_doc*/
- __pyx_tp_traverse_2yt_9amr_utils_PartitionedGrid, /*tp_traverse*/
- __pyx_tp_clear_2yt_9amr_utils_PartitionedGrid, /*tp_clear*/
+ __pyx_tp_traverse_2yt_9amr_utils_ProtoPrism, /*tp_traverse*/
+ __pyx_tp_clear_2yt_9amr_utils_ProtoPrism, /*tp_clear*/
0, /*tp_richcompare*/
0, /*tp_weaklistoffset*/
0, /*tp_iter*/
0, /*tp_iternext*/
- __pyx_methods_2yt_9amr_utils_PartitionedGrid, /*tp_methods*/
- __pyx_members_2yt_9amr_utils_PartitionedGrid, /*tp_members*/
+ __pyx_methods_2yt_9amr_utils_ProtoPrism, /*tp_methods*/
+ __pyx_members_2yt_9amr_utils_ProtoPrism, /*tp_members*/
0, /*tp_getset*/
0, /*tp_base*/
0, /*tp_dict*/
@@ -16715,7 +18758,7 @@
0, /*tp_dictoffset*/
0, /*tp_init*/
0, /*tp_alloc*/
- __pyx_tp_new_2yt_9amr_utils_PartitionedGrid, /*tp_new*/
+ __pyx_tp_new_2yt_9amr_utils_ProtoPrism, /*tp_new*/
0, /*tp_free*/
0, /*tp_is_gc*/
0, /*tp_bases*/
@@ -16763,6 +18806,9 @@
{&__pyx_kp___cinit__, __pyx_k___cinit__, sizeof(__pyx_k___cinit__), 1, 1, 1},
{&__pyx_kp___getitem__, __pyx_k___getitem__, sizeof(__pyx_k___getitem__), 1, 1, 1},
{&__pyx_kp_cast_plane, __pyx_k_cast_plane, sizeof(__pyx_k_cast_plane), 1, 1, 1},
+ {&__pyx_kp___init__, __pyx_k___init__, sizeof(__pyx_k___init__), 1, 1, 1},
+ {&__pyx_kp_sweep, __pyx_k_sweep, sizeof(__pyx_k_sweep), 1, 1, 1},
+ {&__pyx_kp_get_brick, __pyx_k_get_brick, sizeof(__pyx_k_get_brick), 1, 1, 1},
{&__pyx_kp_child_indices, __pyx_k_child_indices, sizeof(__pyx_k_child_indices), 1, 1, 1},
{&__pyx_kp_fields, __pyx_k_fields, sizeof(__pyx_k_fields), 1, 1, 1},
{&__pyx_kp_left_edges, __pyx_k_left_edges, sizeof(__pyx_k_left_edges), 1, 1, 1},
@@ -16831,6 +18877,14 @@
{&__pyx_kp_dims, __pyx_k_dims, sizeof(__pyx_k_dims), 1, 1, 1},
{&__pyx_kp_tf, __pyx_k_tf, sizeof(__pyx_k_tf), 1, 1, 1},
{&__pyx_kp_vp, __pyx_k_vp, sizeof(__pyx_k_vp), 1, 1, 1},
+ {&__pyx_kp_grid, __pyx_k_grid, sizeof(__pyx_k_grid), 1, 1, 1},
+ {&__pyx_kp_direction, __pyx_k_direction, sizeof(__pyx_k_direction), 1, 1, 1},
+ {&__pyx_kp_left, __pyx_k_left, sizeof(__pyx_k_left), 1, 1, 1},
+ {&__pyx_kp_subgrid_faces, __pyx_k_subgrid_faces, sizeof(__pyx_k_subgrid_faces), 1, 1, 1},
+ {&__pyx_kp_stack, __pyx_k_stack, sizeof(__pyx_k_stack), 1, 1, 1},
+ {&__pyx_kp_grid_left_edge, __pyx_k_grid_left_edge, sizeof(__pyx_k_grid_left_edge), 1, 1, 1},
+ {&__pyx_kp_grid_dds, __pyx_k_grid_dds, sizeof(__pyx_k_grid_dds), 1, 1, 1},
+ {&__pyx_kp_child_mask, __pyx_k_child_mask, sizeof(__pyx_k_child_mask), 1, 1, 1},
{&__pyx_kp_posx, __pyx_k_posx, sizeof(__pyx_k_posx), 1, 1, 1},
{&__pyx_kp_posy, __pyx_k_posy, sizeof(__pyx_k_posy), 1, 1, 1},
{&__pyx_kp_posz, __pyx_k_posz, sizeof(__pyx_k_posz), 1, 1, 1},
@@ -16862,12 +18916,16 @@
{&__pyx_kp_alpha, __pyx_k_alpha, sizeof(__pyx_k_alpha), 1, 1, 1},
{&__pyx_kp_x_bounds, __pyx_k_x_bounds, sizeof(__pyx_k_x_bounds), 1, 1, 1},
{&__pyx_kp_nbins, __pyx_k_nbins, sizeof(__pyx_k_nbins), 1, 1, 1},
+ {&__pyx_kp_LeftEdge, __pyx_k_LeftEdge, sizeof(__pyx_k_LeftEdge), 1, 1, 1},
+ {&__pyx_kp_RightEdge, __pyx_k_RightEdge, sizeof(__pyx_k_RightEdge), 1, 1, 1},
+ {&__pyx_kp_RuntimeError, __pyx_k_RuntimeError, sizeof(__pyx_k_RuntimeError), 1, 1, 1},
+ {&__pyx_kp_copy, __pyx_k_copy, sizeof(__pyx_k_copy), 1, 1, 1},
+ {&__pyx_kp_37, __pyx_k_37, sizeof(__pyx_k_37), 0, 1, 0},
{&__pyx_kp___getbuffer__, __pyx_k___getbuffer__, sizeof(__pyx_k___getbuffer__), 1, 1, 1},
{&__pyx_kp___releasebuffer__, __pyx_k___releasebuffer__, sizeof(__pyx_k___releasebuffer__), 1, 1, 1},
{&__pyx_kp_info, __pyx_k_info, sizeof(__pyx_k_info), 1, 1, 1},
{&__pyx_kp_flags, __pyx_k_flags, sizeof(__pyx_k_flags), 1, 1, 1},
{&__pyx_kp_ValueError, __pyx_k_ValueError, sizeof(__pyx_k_ValueError), 1, 1, 1},
- {&__pyx_kp_RuntimeError, __pyx_k_RuntimeError, sizeof(__pyx_k_RuntimeError), 1, 1, 1},
{&__pyx_kp_1, __pyx_k_1, sizeof(__pyx_k_1), 0, 0, 0},
{&__pyx_kp_2, __pyx_k_2, sizeof(__pyx_k_2), 0, 0, 0},
{&__pyx_kp_5, __pyx_k_5, sizeof(__pyx_k_5), 0, 0, 0},
@@ -16881,8 +18939,8 @@
static int __Pyx_InitCachedBuiltins(void) {
__pyx_builtin_range = __Pyx_GetName(__pyx_b, __pyx_kp_range); if (!__pyx_builtin_range) {__pyx_filename = __pyx_f[1]; __pyx_lineno = 80; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_builtin_xrange = __Pyx_GetName(__pyx_b, __pyx_kp_xrange); if (!__pyx_builtin_xrange) {__pyx_filename = __pyx_f[2]; __pyx_lineno = 47; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_builtin_RuntimeError = __Pyx_GetName(__pyx_b, __pyx_kp_RuntimeError); if (!__pyx_builtin_RuntimeError) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 455; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_builtin_ValueError = __Pyx_GetName(__pyx_b, __pyx_kp_ValueError); if (!__pyx_builtin_ValueError) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 170; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- __pyx_builtin_RuntimeError = __Pyx_GetName(__pyx_b, __pyx_kp_RuntimeError); if (!__pyx_builtin_RuntimeError) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 706; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
return 0;
__pyx_L1_error:;
return -1;
@@ -16893,6 +18951,7 @@
__pyx_int_1 = PyInt_FromLong(1); if (unlikely(!__pyx_int_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__pyx_int_3 = PyInt_FromLong(3); if (unlikely(!__pyx_int_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__pyx_int_4 = PyInt_FromLong(4); if (unlikely(!__pyx_int_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
+ __pyx_int_0 = PyInt_FromLong(0); if (unlikely(!__pyx_int_0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
__pyx_int_15 = PyInt_FromLong(15); if (unlikely(!__pyx_int_15)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
if (__Pyx_InitStrings(__pyx_string_tab) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 1; __pyx_clineno = __LINE__; goto __pyx_L1_error;};
return 0;
@@ -16977,9 +19036,9 @@
*(void(**)(void))&__pyx_vtable_2yt_9amr_utils_VectorPlane.copy_into = (void(*)(void))__pyx_f_2yt_9amr_utils_11VectorPlane_copy_into;
*(void(**)(void))&__pyx_vtable_2yt_9amr_utils_VectorPlane.copy_back = (void(*)(void))__pyx_f_2yt_9amr_utils_11VectorPlane_copy_back;
#endif
- if (PyType_Ready(&__pyx_type_2yt_9amr_utils_VectorPlane) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (__Pyx_SetVtable(__pyx_type_2yt_9amr_utils_VectorPlane.tp_dict, __pyx_vtabptr_2yt_9amr_utils_VectorPlane) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (__Pyx_SetAttrString(__pyx_m, "VectorPlane", (PyObject *)&__pyx_type_2yt_9amr_utils_VectorPlane) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_2yt_9amr_utils_VectorPlane) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_2yt_9amr_utils_VectorPlane.tp_dict, __pyx_vtabptr_2yt_9amr_utils_VectorPlane) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetAttrString(__pyx_m, "VectorPlane", (PyObject *)&__pyx_type_2yt_9amr_utils_VectorPlane) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_2yt_9amr_utils_VectorPlane = &__pyx_type_2yt_9amr_utils_VectorPlane;
__pyx_vtabptr_2yt_9amr_utils_TransferFunctionProxy = &__pyx_vtable_2yt_9amr_utils_TransferFunctionProxy;
#if PY_MAJOR_VERSION >= 3
@@ -16987,9 +19046,9 @@
#else
*(void(**)(void))&__pyx_vtable_2yt_9amr_utils_TransferFunctionProxy.eval_transfer = (void(*)(void))__pyx_f_2yt_9amr_utils_21TransferFunctionProxy_eval_transfer;
#endif
- if (PyType_Ready(&__pyx_type_2yt_9amr_utils_TransferFunctionProxy) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 71; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (__Pyx_SetVtable(__pyx_type_2yt_9amr_utils_TransferFunctionProxy.tp_dict, __pyx_vtabptr_2yt_9amr_utils_TransferFunctionProxy) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 71; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (__Pyx_SetAttrString(__pyx_m, "TransferFunctionProxy", (PyObject *)&__pyx_type_2yt_9amr_utils_TransferFunctionProxy) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 71; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_2yt_9amr_utils_TransferFunctionProxy) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 72; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_2yt_9amr_utils_TransferFunctionProxy.tp_dict, __pyx_vtabptr_2yt_9amr_utils_TransferFunctionProxy) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 72; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetAttrString(__pyx_m, "TransferFunctionProxy", (PyObject *)&__pyx_type_2yt_9amr_utils_TransferFunctionProxy) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 72; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_2yt_9amr_utils_TransferFunctionProxy = &__pyx_type_2yt_9amr_utils_TransferFunctionProxy;
__pyx_vtabptr_2yt_9amr_utils_PartitionedGrid = &__pyx_vtable_2yt_9amr_utils_PartitionedGrid;
#if PY_MAJOR_VERSION >= 3
@@ -17001,10 +19060,30 @@
*(void(**)(void))&__pyx_vtable_2yt_9amr_utils_PartitionedGrid.integrate_ray = (void(*)(void))__pyx_f_2yt_9amr_utils_15PartitionedGrid_integrate_ray;
*(void(**)(void))&__pyx_vtable_2yt_9amr_utils_PartitionedGrid.sample_values = (void(*)(void))__pyx_f_2yt_9amr_utils_15PartitionedGrid_sample_values;
#endif
- if (PyType_Ready(&__pyx_type_2yt_9amr_utils_PartitionedGrid) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 188; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (__Pyx_SetVtable(__pyx_type_2yt_9amr_utils_PartitionedGrid.tp_dict, __pyx_vtabptr_2yt_9amr_utils_PartitionedGrid) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 188; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
- if (__Pyx_SetAttrString(__pyx_m, "PartitionedGrid", (PyObject *)&__pyx_type_2yt_9amr_utils_PartitionedGrid) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 188; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyType_Ready(&__pyx_type_2yt_9amr_utils_PartitionedGrid) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_2yt_9amr_utils_PartitionedGrid.tp_dict, __pyx_vtabptr_2yt_9amr_utils_PartitionedGrid) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetAttrString(__pyx_m, "PartitionedGrid", (PyObject *)&__pyx_type_2yt_9amr_utils_PartitionedGrid) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 189; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_2yt_9amr_utils_PartitionedGrid = &__pyx_type_2yt_9amr_utils_PartitionedGrid;
+ __pyx_vtabptr_2yt_9amr_utils_GridFace = &__pyx_vtable_2yt_9amr_utils_GridFace;
+ #if PY_MAJOR_VERSION >= 3
+ __pyx_vtable_2yt_9amr_utils_GridFace.proj_overlap = (int (*)(struct __pyx_obj_2yt_9amr_utils_GridFace *, __pyx_t_5numpy_float64_t *, __pyx_t_5numpy_float64_t *))__pyx_f_2yt_9amr_utils_8GridFace_proj_overlap;
+ #else
+ *(void(**)(void))&__pyx_vtable_2yt_9amr_utils_GridFace.proj_overlap = (void(*)(void))__pyx_f_2yt_9amr_utils_8GridFace_proj_overlap;
+ #endif
+ if (PyType_Ready(&__pyx_type_2yt_9amr_utils_GridFace) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_2yt_9amr_utils_GridFace.tp_dict, __pyx_vtabptr_2yt_9amr_utils_GridFace) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetAttrString(__pyx_m, "GridFace", (PyObject *)&__pyx_type_2yt_9amr_utils_GridFace) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 387; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_ptype_2yt_9amr_utils_GridFace = &__pyx_type_2yt_9amr_utils_GridFace;
+ __pyx_vtabptr_2yt_9amr_utils_ProtoPrism = &__pyx_vtable_2yt_9amr_utils_ProtoPrism;
+ #if PY_MAJOR_VERSION >= 3
+ __pyx_vtable_2yt_9amr_utils_ProtoPrism.split = (PyObject *(*)(struct __pyx_obj_2yt_9amr_utils_ProtoPrism *, __pyx_t_5numpy_float64_t *, int))__pyx_f_2yt_9amr_utils_10ProtoPrism_split;
+ #else
+ *(void(**)(void))&__pyx_vtable_2yt_9amr_utils_ProtoPrism.split = (void(*)(void))__pyx_f_2yt_9amr_utils_10ProtoPrism_split;
+ #endif
+ if (PyType_Ready(&__pyx_type_2yt_9amr_utils_ProtoPrism) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetVtable(__pyx_type_2yt_9amr_utils_ProtoPrism.tp_dict, __pyx_vtabptr_2yt_9amr_utils_ProtoPrism) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (__Pyx_SetAttrString(__pyx_m, "ProtoPrism", (PyObject *)&__pyx_type_2yt_9amr_utils_ProtoPrism) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 419; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_ptype_2yt_9amr_utils_ProtoPrism = &__pyx_type_2yt_9amr_utils_ProtoPrism;
/*--- Type import code ---*/
__pyx_ptype_5numpy_dtype = __Pyx_ImportType("numpy", "dtype", sizeof(PyArray_Descr)); if (unlikely(!__pyx_ptype_5numpy_dtype)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 119; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__pyx_ptype_5numpy_flatiter = __Pyx_ImportType("numpy", "flatiter", sizeof(PyArrayIterObject)); if (unlikely(!__pyx_ptype_5numpy_flatiter)) {__pyx_filename = __pyx_f[7]; __pyx_lineno = 129; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
@@ -17042,9 +19121,9 @@
* Simple interpolators
*
*/
- __pyx_1 = __Pyx_Import(__pyx_kp_numpy, 0); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = __Pyx_Import(__pyx_kp_numpy, 0); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_1);
- if (PyObject_SetAttr(__pyx_m, __pyx_kp_np, __pyx_1) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttr(__pyx_m, __pyx_kp_np, __pyx_1) < 0) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_1); __pyx_1 = 0;
/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/PointsInVolume.pyx":27
@@ -17066,9 +19145,9 @@
* cimport numpy as np
* cimport cython
*/
- __pyx_1 = __Pyx_Import(__pyx_kp_numpy, 0); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = __Pyx_Import(__pyx_kp_numpy, 0); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_1);
- if (PyObject_SetAttr(__pyx_m, __pyx_kp_np, __pyx_1) < 0) {__pyx_filename = __pyx_f[4]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttr(__pyx_m, __pyx_kp_np, __pyx_1) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_1); __pyx_1 = 0;
/* "/Users/matthewturk/Development/yt/trunk/yt/_amr_utils/VolumeIntegrator.pyx":1
@@ -17076,9 +19155,9 @@
* Simple integrators for the radiative transfer equation
*
*/
- __pyx_1 = __Pyx_Import(__pyx_kp_numpy, 0); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ __pyx_1 = __Pyx_Import(__pyx_kp_numpy, 0); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_GOTREF(__pyx_1);
- if (PyObject_SetAttr(__pyx_m, __pyx_kp_np, __pyx_1) < 0) {__pyx_filename = __pyx_f[5]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
+ if (PyObject_SetAttr(__pyx_m, __pyx_kp_np, __pyx_1) < 0) {__pyx_filename = __pyx_f[3]; __pyx_lineno = 26; __pyx_clineno = __LINE__; goto __pyx_L1_error;}
__Pyx_DECREF(__pyx_1); __pyx_1 = 0;
/* "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/Cython/Includes/stdlib.pxd":2
@@ -17109,9 +19188,9 @@
"amr_utils.pyx",
"DepthFirstOctree.pyx",
"PointsInVolume.pyx",
+ "VolumeIntegrator.pyx",
"Interpolators.pyx",
"RayIntegrators.pyx",
- "VolumeIntegrator.pyx",
"CICDeposit.pyx",
"numpy.pxd",
};
@@ -17784,6 +19863,12 @@
"Buffer acquisition failed on assignment; and then reacquiring the old buffer failed too!");
}
+static void __Pyx_RaiseBufferIndexError(int axis) {
+ PyErr_Format(PyExc_IndexError,
+ "Out of bounds on buffer access (axis %d)", axis);
+}
+
+
static INLINE void __Pyx_RaiseNoneNotIterableError(void) {
PyErr_SetString(PyExc_TypeError, "'NoneType' object is not iterable");
@@ -18065,17 +20150,27 @@
return (npy_int64)-1;
}
-static INLINE PyObject *__Pyx_PyInt_to_py_npy_int64(npy_int64 val) {
- /**/ if (sizeof(npy_int64) < sizeof(long))
- return PyInt_FromLong((long)val);
- else if (sizeof(npy_int64) == sizeof(long))
- return (((npy_int64)-1) < ((npy_int64)0)) ?
- PyInt_FromLong((long)val) :
- PyLong_FromUnsignedLong((unsigned long)val);
- else /* (sizeof(npy_int64) > sizeof(long)) */
- return (((npy_int64)-1) < ((npy_int64)0)) ?
- PyLong_FromLongLong((PY_LONG_LONG)val) :
- PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG)val);
+static PyObject *__Pyx_UnpackItem(PyObject *iter, Py_ssize_t index) {
+ PyObject *item;
+ if (!(item = PyIter_Next(iter))) {
+ if (!PyErr_Occurred()) {
+ __Pyx_RaiseNeedMoreValuesError(index);
+ }
+ }
+ return item;
+}
+
+static int __Pyx_EndUnpack(PyObject *iter) {
+ PyObject *item;
+ if ((item = PyIter_Next(iter))) {
+ Py_DECREF(item);
+ __Pyx_RaiseTooManyValuesError();
+ return -1;
+ }
+ else if (!PyErr_Occurred())
+ return 0;
+ else
+ return -1;
}
static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb) {
@@ -18142,27 +20237,17 @@
return;
}
-static PyObject *__Pyx_UnpackItem(PyObject *iter, Py_ssize_t index) {
- PyObject *item;
- if (!(item = PyIter_Next(iter))) {
- if (!PyErr_Occurred()) {
- __Pyx_RaiseNeedMoreValuesError(index);
- }
- }
- return item;
-}
-
-static int __Pyx_EndUnpack(PyObject *iter) {
- PyObject *item;
- if ((item = PyIter_Next(iter))) {
- Py_DECREF(item);
- __Pyx_RaiseTooManyValuesError();
- return -1;
- }
- else if (!PyErr_Occurred())
- return 0;
- else
- return -1;
+static INLINE PyObject *__Pyx_PyInt_to_py_npy_int64(npy_int64 val) {
+ /**/ if (sizeof(npy_int64) < sizeof(long))
+ return PyInt_FromLong((long)val);
+ else if (sizeof(npy_int64) == sizeof(long))
+ return (((npy_int64)-1) < ((npy_int64)0)) ?
+ PyInt_FromLong((long)val) :
+ PyLong_FromUnsignedLong((unsigned long)val);
+ else /* (sizeof(npy_int64) > sizeof(long)) */
+ return (((npy_int64)-1) < ((npy_int64)0)) ?
+ PyLong_FromLongLong((PY_LONG_LONG)val) :
+ PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG)val);
}
static INLINE unsigned char __Pyx_PyInt_AsUnsignedChar(PyObject* x) {
Modified: trunk/yt/extensions/volume_rendering/grid_partitioner.py
==============================================================================
--- trunk/yt/extensions/volume_rendering/grid_partitioner.py (original)
+++ trunk/yt/extensions/volume_rendering/grid_partitioner.py Thu Jan 14 00:02:09 2010
@@ -27,7 +27,20 @@
from yt.funcs import *
import h5py
-from yt.amr_utils import PartitionedGrid
+from yt.amr_utils import PartitionedGrid, ProtoPrism, GridFace
+
+class GridFaces(object):
+ def __init__(self, grids):
+ self.faces = [ [], [], [] ]
+ for grid in grids:
+ for direction in range(3):
+ self.faces[direction].append( GridFace(grid, direction, 1) )
+ self.faces[direction].append( GridFace(grid, direction, 0) )
+ for f in self.faces:
+ f.sort(key = lambda a: a.coord)
+
+ def __getitem__(self, item):
+ return self.faces[item]
def partition_grid(start_grid, field, log_field = True, threshold = None):
if threshold is not None:
@@ -37,6 +50,13 @@
if log_field: to_cut_up = na.log10(to_cut_up)
+ GF = GridFaces(start_grid.Children + [start_grid])
+ PP = ProtoPrism(start_grid.LeftEdge, start_grid.RightEdge, GF)
+ pgs = []
+ for P in PP.sweep(0):
+ pgs += P.get_brick(start_grid.LeftEdge, start_grid.dds, to_cut_up, start_grid.child_mask)
+ return pgs
+
if len(start_grid.Children) == 0:
pg = PartitionedGrid(
to_cut_up.copy(),
Modified: trunk/yt/lagos/BaseDataTypes.py
==============================================================================
--- trunk/yt/lagos/BaseDataTypes.py (original)
+++ trunk/yt/lagos/BaseDataTypes.py Thu Jan 14 00:02:09 2010
@@ -2665,12 +2665,12 @@
for ax, v in zip('xyz', dx): self['cd%s'%ax] = v
LL = self.left_edge - self.pf["DomainLeftEdge"]
self._old_global_startindex = self.global_startindex
- self.global_startindex = na.array(na.floor(1.000001*LL / dx) - 1, dtype='int64')
+ self.global_startindex = na.rint(LL / dx).astype('int64') - 1
self.domain_width = na.rint((self.pf["DomainRightEdge"] -
self.pf["DomainLeftEdge"])/dx).astype('int64')
if level == 0 and self.level > 0:
# We use one grid cell at LEAST, plus one buffer on all sides
- idims = na.ceil((self.right_edge-self.left_edge)/dx) + 2
+ idims = na.rint((self.right_edge-self.left_edge)/dx).astype('int64') + 2
self[field] = na.zeros(idims,dtype='float64')-999
elif level == 0 and self.level == 0:
DLE = self.pf["DomainLeftEdge"]
@@ -2689,7 +2689,7 @@
old_left[2], old_right[2]]
dx = na.array([self['cd%s' % ax] for ax in 'xyz'], dtype='float64')
- new_dims = na.ceil(0.999999999 * (self.right_edge-self.left_edge)/dx) + 2
+ new_dims = na.rint((self.right_edge-self.left_edge)/dx).astype('int64') + 2
# x, y, z are the new bounds
x,y,z = (na.mgrid[0:new_dims[0], 0:new_dims[1], 0:new_dims[2]]
@@ -2699,20 +2699,27 @@
z += self.global_startindex[2]
fake_grid = {'x':x,'y':y,'z':z}
+ if field in self.pf.field_info and self.pf.field_info[field].take_log:
+ my_field = na.log10(self[field])
+ else:
+ my_field = self[field]
interpolator = TrilinearFieldInterpolator(
- self[field], old_bounds, ['x','y','z'],
+ my_field, old_bounds, ['x','y','z'],
truncate = True)
- self[field] = interpolator(fake_grid)
+ if field in self.pf.field_info and self.pf.field_info[field].take_log:
+ self[field] = 10**interpolator(fake_grid)
+ else:
+ self[field] = interpolator(fake_grid)
def _get_data_from_grid(self, grid, fields, level):
fields = ensure_list(fields)
g_fields = [grid[field] for field in fields]
c_fields = [self[field] for field in fields]
+ dims = na.array(self[field].shape, dtype='int32')
count = PointCombine.FillRegion(1,
grid.get_global_startindex(), self.global_startindex,
c_fields, g_fields,
- na.array(self[field].shape, dtype='int32'),
- grid.ActiveDimensions,
+ dims, grid.ActiveDimensions,
grid.child_mask, self.domain_width, 1, 0)
return count
Modified: trunk/yt/lagos/PointCombine.c
==============================================================================
--- trunk/yt/lagos/PointCombine.c (original)
+++ trunk/yt/lagos/PointCombine.c Thu Jan 14 00:02:09 2010
@@ -884,7 +884,7 @@
npy_int64 cdx, cdy, cdz;
npy_int64 dw[3];
int i;
- int ci, cj, ck, ri, rj, rk;
+ npy_int64 ci, cj, ck, ri, rj, rk;
int total = 0;
void (*to_call)(PyArrayObject* c_data, npy_int64 xc,
npy_int64 yc, npy_int64 zc,
More information about the yt-svn
mailing list