> It should always match, but sometimes there's some C extra code
> hanging off.
Yes, I've seen some of that. In my case, this definitely isn't true
as the next 3 lines are more of the same. To continue on, the code in
the .c file is the beautiful
__pyx_t_9 = __pyx_v_yi;
__pyx_v_p1->y = (*__Pyx_BufPtrCContig1d(float *,
__pyx_bstruct_y_edges.buf, __pyx_t_9, __pyx_bstride_0_y_edges));
/* "/home/hoytak/workspace/gravimetrics/spatial/gridworld.pyx":126
* p2.x = x_edges[xi+1]
* p1.y = y_edges[yi]
* p2.y = y_edges[yi+1] # <<<<<<<<<<<<<<
* p1.z = z_edges[zi]
* p2.z = z_edges[zi+1]
*/
__pyx_t_10 = (__pyx_v_yi + 1);
__pyx_v_p2->y = (*__Pyx_BufPtrCContig1d(float *,
__pyx_bstruct_y_edges.buf, __pyx_t_10, __pyx_bstride_0_y_edges));
/* "/home/hoytak/workspace/gravimetrics/spatial/gridworld.pyx":127
* p1.y = y_edges[yi]
* p2.y = y_edges[yi+1]
* p1.z = z_edges[zi] # <<<<<<<<<<<<<<
* p2.z = z_edges[zi+1]
*
*/
__pyx_t_11 = __pyx_v_zi;
__pyx_v_p1->z = (*__Pyx_BufPtrCContig1d(float *,
__pyx_bstruct_z_edges.buf, __pyx_t_11, __pyx_bstride_0_z_edges));
/* "/home/hoytak/workspace/gravimetrics/spatial/gridworld.pyx":128
* p2.y = y_edges[yi+1]
* p1.z = z_edges[zi]
* p2.z = z_edges[zi+1] # <<<<<<<<<<<<<<
*
* curbox.setCoordsDirect(p1, p2)
*/
__pyx_t_12 = (__pyx_v_zi + 1);
__pyx_v_p2->z = (*__Pyx_BufPtrCContig1d(float *,
__pyx_bstruct_z_edges.buf, __pyx_t_12, __pyx_bstride_0_z_edges));
/* "/home/hoytak/workspace/gravimetrics/spatial/gridworld.pyx":130
* p2.z = z_edges[zi+1]
*
*
..................
However, the same code in the .html shows up as:
125: p1.y = y_edges[yi]
__pyx_t_9 = __pyx_v_yi;
__pyx_v_p1->y = (*__Pyx_BufPtrCContig1d(float *,
__pyx_bstruct_y_edges.buf, __pyx_t_9, __pyx_bstride_0_y_edges));
__pyx_2 = PyObject_GetAttr(__pyx_v_iterator,
__pyx_kp_next); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[1];
__pyx_lineno = 125; __pyx_clineno = __LINE__; goto __pyx_L13_error;}
__pyx_3 = PyObject_Call(__pyx_2, ((PyObject
*)__pyx_empty_tuple), NULL); if (unlikely(!__pyx_3)) {__pyx_filename =
__pyx_f[1]; __pyx_lineno = 125; __pyx_clineno = __LINE__; goto
__pyx_L13_error;}
Py_DECREF(__pyx_2); __pyx_2 = 0;
__pyx_2 = __Pyx_GetItemInt(__pyx_3, 1, 0); if (!__pyx_2)
{__pyx_filename = __pyx_f[1]; __pyx_lineno = 125; __pyx_clineno =
__LINE__; goto __pyx_L13_error;}
Py_DECREF(__pyx_3); __pyx_3 = 0;
__pyx_3 = __Pyx_GetItemInt(__pyx_2, 0, 0); if (!__pyx_3)
{__pyx_filename = __pyx_f[1]; __pyx_lineno = 125; __pyx_clineno =
__LINE__; goto __pyx_L13_error;}
Py_DECREF(__pyx_2); __pyx_2 = 0;
if (!(__Pyx_TypeTest(__pyx_3, __pyx_ptype_5numpy_dtype)))
{__pyx_filename = __pyx_f[1]; __pyx_lineno = 125; __pyx_clineno =
__LINE__; goto __pyx_L13_error;}
Py_DECREF(((PyObject *)__pyx_v_descr));
__pyx_v_descr = ((PyArray_Descr *)__pyx_3);
__pyx_3 = 0;
}
goto __pyx_L17_try;
__pyx_L13_error:;
Py_XDECREF(__pyx_2); __pyx_2 = 0;
Py_XDECREF(__pyx_3); __pyx_3 = 0;
126: p2.y = y_edges[yi+1]
__pyx_t_10 = (__pyx_v_yi + 1);
__pyx_v_p2->y = (*__Pyx_BufPtrCContig1d(float *,
__pyx_bstruct_y_edges.buf, __pyx_t_10, __pyx_bstride_0_y_edges));
__pyx_4 =
PyErr_ExceptionMatches(__pyx_builtin_StopIteration);
if (__pyx_4) {
__Pyx_AddTraceback("numpy.__getbuffer__");
if (__Pyx_GetException(&__pyx_2, &__pyx_3, &__pyx_5) < 0)
{__pyx_filename = __pyx_f[1]; __pyx_lineno = 126; __pyx_clineno =
__LINE__; goto __pyx_L15_except_error;}
127: p1.z = z_edges[zi]
__pyx_t_11 = __pyx_v_zi;
__pyx_v_p1->z = (*__Pyx_BufPtrCContig1d(float *,
__pyx_bstruct_z_edges.buf, __pyx_t_11, __pyx_bstride_0_z_edges));
__pyx_6 = PyObject_GetAttr(((PyObject
*)__pyx_v_stack), __pyx_kp_pop); if (unlikely(!__pyx_6))
{__pyx_filename = __pyx_f[1]; __pyx_lineno = 127; __pyx_clineno =
__LINE__; goto __pyx_L15_except_error;}
__pyx_7 = PyObject_Call(__pyx_6, ((PyObject
*)__pyx_empty_tuple), NULL); if (unlikely(!__pyx_7)) {__pyx_filename =
__pyx_f[1]; __pyx_lineno = 127; __pyx_clineno = __LINE__; goto
__pyx_L15_except_error;}
Py_DECREF(__pyx_6); __pyx_6 = 0;
Py_DECREF(__pyx_7); __pyx_7 = 0;
128: p2.z = z_edges[zi+1]
__pyx_t_12 = (__pyx_v_zi + 1);
__pyx_v_p2->z = (*__Pyx_BufPtrCContig1d(float *,
__pyx_bstruct_z_edges.buf, __pyx_t_12, __pyx_bstride_0_z_edges));
__pyx_8 = PyObject_Length(((PyObject
*)__pyx_v_stack)); if (unlikely(__pyx_8 == -1)) {__pyx_filename =
__pyx_f[1]; __pyx_lineno = 128; __pyx_clineno = __LINE__; goto
__pyx_L15_except_error;}
__pyx_1 = (__pyx_8 > 0);
if (__pyx_1) {
129:
So it's definitely showing stuff that isn't there (unless I'm reading
things way wrong). I don't have time for a few hours here, but I will
play around with it and try to get some other small test cases here in
a bit and file a bug report.
Thanks!
--Hoyt
++++++++++++++++++++++++++++++++++++++++++++++++
+ Hoyt Koepke
+ University of Washington Department of Statistics
+ http://www.stat.washington.edu/~hoytak/
+ [EMAIL PROTECTED]
++++++++++++++++++++++++++++++++++++++++++
_______________________________________________
Cython-dev mailing list
[email protected]
http://codespeak.net/mailman/listinfo/cython-dev