From: <js...@us...> - 2007-11-14 18:08:10
|
Revision: 4277 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=4277&view=rev Author: jswhit Date: 2007-11-14 10:08:07 -0800 (Wed, 14 Nov 2007) Log Message: ----------- regenerated with Cython 0.9.6.8 Modified Paths: -------------- trunk/toolkits/basemap-testing/src/_geod.c trunk/toolkits/basemap-testing/src/_geos.c trunk/toolkits/basemap-testing/src/_proj.c Modified: trunk/toolkits/basemap-testing/src/_geod.c =================================================================== --- trunk/toolkits/basemap-testing/src/_geod.c 2007-11-14 16:47:09 UTC (rev 4276) +++ trunk/toolkits/basemap-testing/src/_geod.c 2007-11-14 18:08:07 UTC (rev 4277) @@ -1,4 +1,4 @@ -/* Generated by Cython 0.9.6.7 on Wed Oct 31 21:20:49 2007 */ +/* Generated by Cython 0.9.6.8 on Wed Nov 14 11:06:42 2007 */ #define PY_SSIZE_T_CLEAN #include "Python.h" @@ -15,12 +15,16 @@ #define PyNumber_Index(o) PyNumber_Int(o) #define PyIndex_Check(o) PyNumber_Check(o) #endif +#ifndef WIN32 + #define __stdcall + #define __cdecl +#endif #ifdef __cplusplus #define __PYX_EXTERN_C extern "C" #else #define __PYX_EXTERN_C extern #endif -__PYX_EXTERN_C double pow(double, double); +#include <math.h> #include "stdlib.h" #include "math.h" #include "geodesic.h" @@ -35,11 +39,17 @@ #define INLINE #endif -typedef struct {const char *s; const void **p;} __Pyx_CApiTabEntry; /*proto*/ typedef struct {PyObject **p; char *s;} __Pyx_InternTabEntry; /*proto*/ typedef struct {PyObject **p; char *s; long n; int is_unicode;} __Pyx_StringTabEntry; /*proto*/ -#define __pyx_PyIndex_AsSsize_t(b) PyInt_AsSsize_t(PyNumber_Index(b)) +static INLINE Py_ssize_t __pyx_PyIndex_AsSsize_t(PyObject* b) { + Py_ssize_t ival; + PyObject* x = PyNumber_Index(b); + if (!x) return -1; + ival = PyInt_AsSsize_t(x); + Py_DECREF(x); + return ival; +} #define __Pyx_PyBool_FromLong(b) ((b) ? (Py_INCREF(Py_True), Py_True) : (Py_INCREF(Py_False), Py_False)) static INLINE int __Pyx_PyObject_IsTrue(PyObject* x) { @@ -49,6 +59,10 @@ } + +static int __pyx_skip_dispatch = 0; + + #ifdef __GNUC__ /* Test for GCC > 2.95 */ #if __GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95)) @@ -69,6 +83,8 @@ static char *__pyx_filename; static char **__pyx_f; +static char __pyx_mdoc[] = "\ncopyright (c) 2007 by Jeffrey Whitaker.\n\nPermission to use, copy, modify, and distribute this software and its\ndocumentation for any purpose and without fee is hereby granted,\nprovided that the above copyright notices appear in all copies and that\nboth the copyright notices and this permission notice appear in\nsupporting documentation.\nTHE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,\nINCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO\nEVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, INDIRECT OR\nCONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF\nUSE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\nPERFORMANCE OF THIS SOFTWARE.\n"; + static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list); /*proto*/ static PyObject *__Pyx_GetName(PyObject *dict, PyObject *name); /*proto*/ @@ -84,17 +100,23 @@ static void __Pyx_AddTraceback(char *funcname); /*proto*/ -/* Declarations from _geod */ +static PyObject *__Pyx_ImportModule(char *name); /*proto*/ +static int __Pyx_RegisterCleanup(); /*proto*/ +static PyObject* cleanup(PyObject *self, PyObject *unused); /*proto*/ +static PyMethodDef cleanup_def = {"__cleanup", (PyCFunction)&cleanup, METH_NOARGS, 0}; +/* Declarations from _geod */ + struct __pyx_obj_5_geod_Geod { PyObject_HEAD GEODESIC_T geodesic_t; PyObject *geodparams; PyObject *proj_version; - char (*geodinitstring); + char *geodinitstring; }; + static PyTypeObject *__pyx_ptype_5_geod_Geod = 0; static PyObject *__pyx_k3; static PyObject *__pyx_k4; @@ -103,20 +125,20 @@ /* Implementation of _geod */ -static char (__pyx_k2[]) = "1.8.3"; +static char __pyx_k2[] = "1.8.3"; -static PyObject *__pyx_n_math; -static PyObject *__pyx_n__dg2rad; -static PyObject *__pyx_n__rad2dg; -static PyObject *__pyx_n__doublesize; -static PyObject *__pyx_n___version__; -static PyObject *__pyx_n___new__; +static PyObject *__pyx_n___cinit__; static PyObject *__pyx_n___reduce__; static PyObject *__pyx_n__fwd; static PyObject *__pyx_n__inv; static PyObject *__pyx_n__npts; +static PyObject *__pyx_n_math; static PyObject *__pyx_n_radians; +static PyObject *__pyx_n__dg2rad; static PyObject *__pyx_n_degrees; +static PyObject *__pyx_n__rad2dg; +static PyObject *__pyx_n__doublesize; +static PyObject *__pyx_n___version__; static PyObject *__pyx_k2p; @@ -132,13 +154,13 @@ static PyObject *__pyx_builtin_RuntimeError; -static char (__pyx_k6[]) = "+"; -static char (__pyx_k7[]) = "="; -static char (__pyx_k8[]) = " "; -static char (__pyx_k9[]) = ""; +static char __pyx_k6[] = "+"; +static char __pyx_k7[] = "="; +static char __pyx_k8[] = " "; +static char __pyx_k9[] = ""; -static int __pyx_f_py_5_geod_4Geod___new__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ -static int __pyx_f_py_5_geod_4Geod___new__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static int __pyx_pf_5_geod_4Geod___new__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static int __pyx_pf_5_geod_4Geod___new__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_geodparams = 0; GEODESIC_T __pyx_v_GEOD_T; PyObject *__pyx_v_geodargs; @@ -160,7 +182,7 @@ __pyx_v_key = Py_None; Py_INCREF(Py_None); __pyx_v_value = Py_None; Py_INCREF(Py_None); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":13 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":29 * def __new__(self, geodparams): * cdef GEODESIC_T GEOD_T * self.geodparams = geodparams # <<<<<<<<<<<<<< @@ -171,30 +193,30 @@ Py_DECREF(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodparams); ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodparams = __pyx_v_geodparams; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":15 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":31 * self.geodparams = geodparams * # setup proj initialization string. * geodargs = [] # <<<<<<<<<<<<<< * for key,value in geodparams.iteritems(): * geodargs.append('+'+key+"="+str(value)+' ') */ - __pyx_1 = PyList_New(0); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 15; goto __pyx_L1;} + __pyx_1 = PyList_New(0); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 31; goto __pyx_L1;} Py_DECREF(__pyx_v_geodargs); __pyx_v_geodargs = __pyx_1; __pyx_1 = 0; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":16 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":32 * # setup proj initialization string. * geodargs = [] * for key,value in geodparams.iteritems(): # <<<<<<<<<<<<<< * geodargs.append('+'+key+"="+str(value)+' ') * self.geodinitstring = PyString_AsString(''.join(geodargs)) */ - __pyx_1 = PyObject_GetAttr(__pyx_v_geodparams, __pyx_n_iteritems); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 16; goto __pyx_L1;} - __pyx_3 = PyObject_CallObject(__pyx_1, 0); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 16; goto __pyx_L1;} + __pyx_1 = PyObject_GetAttr(__pyx_v_geodparams, __pyx_n_iteritems); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; goto __pyx_L1;} + __pyx_3 = PyObject_CallObject(__pyx_1, 0); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; goto __pyx_L1;} Py_DECREF(__pyx_1); __pyx_1 = 0; if (PyList_CheckExact(__pyx_3)) { __pyx_2 = 0; __pyx_1 = __pyx_3; Py_INCREF(__pyx_1); } - else { __pyx_1 = PyObject_GetIter(__pyx_3); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 16; goto __pyx_L1;} } + else { __pyx_1 = PyObject_GetIter(__pyx_3); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; goto __pyx_L1;} } Py_DECREF(__pyx_3); __pyx_3 = 0; for (;;) { if (PyList_CheckExact(__pyx_1)) { if (__pyx_2 >= PyList_GET_SIZE(__pyx_1)) break; __pyx_3 = PyList_GET_ITEM(__pyx_1, __pyx_2++); Py_INCREF(__pyx_3); } @@ -218,69 +240,61 @@ Py_DECREF(__pyx_3); __pyx_3 = 0; } else { - __pyx_4 = PyObject_GetIter(__pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 16; goto __pyx_L1;} + __pyx_4 = PyObject_GetIter(__pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; - __pyx_5 = __Pyx_UnpackItem(__pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 16; goto __pyx_L1;} + __pyx_5 = __Pyx_UnpackItem(__pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; goto __pyx_L1;} Py_DECREF(__pyx_v_key); __pyx_v_key = __pyx_5; __pyx_5 = 0; - __pyx_5 = __Pyx_UnpackItem(__pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 16; goto __pyx_L1;} + __pyx_5 = __Pyx_UnpackItem(__pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; goto __pyx_L1;} Py_DECREF(__pyx_v_value); __pyx_v_value = __pyx_5; __pyx_5 = 0; - if (__Pyx_EndUnpack(__pyx_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 16; goto __pyx_L1;} + if (__Pyx_EndUnpack(__pyx_4) < 0) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 32; goto __pyx_L1;} Py_DECREF(__pyx_4); __pyx_4 = 0; } - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":17 - * geodargs = [] - * for key,value in geodparams.iteritems(): - * geodargs.append('+'+key+"="+str(value)+' ') # <<<<<<<<<<<<<< - * self.geodinitstring = PyString_AsString(''.join(geodargs)) - * # initialize projection - */ - __pyx_5 = PyObject_GetAttr(__pyx_v_geodargs, __pyx_n_append); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 17; goto __pyx_L1;} - __pyx_3 = PyNumber_Add(__pyx_k6p, __pyx_v_key); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 17; goto __pyx_L1;} - __pyx_4 = PyNumber_Add(__pyx_3, __pyx_k7p); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 17; goto __pyx_L1;} + __pyx_5 = PyObject_GetAttr(__pyx_v_geodargs, __pyx_n_append); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 33; goto __pyx_L1;} + __pyx_3 = PyNumber_Add(__pyx_k6p, __pyx_v_key); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 33; goto __pyx_L1;} + __pyx_4 = PyNumber_Add(__pyx_3, __pyx_k7p); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 33; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; - __pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 17; goto __pyx_L1;} + __pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 33; goto __pyx_L1;} Py_INCREF(__pyx_v_value); PyTuple_SET_ITEM(__pyx_3, 0, __pyx_v_value); - __pyx_6 = PyObject_CallObject(((PyObject*)&PyString_Type), __pyx_3); if (unlikely(!__pyx_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 17; goto __pyx_L1;} + __pyx_6 = PyObject_CallObject(((PyObject*)&PyString_Type), __pyx_3); if (unlikely(!__pyx_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 33; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; - __pyx_3 = PyNumber_Add(__pyx_4, __pyx_6); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 17; goto __pyx_L1;} + __pyx_3 = PyNumber_Add(__pyx_4, __pyx_6); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 33; goto __pyx_L1;} Py_DECREF(__pyx_4); __pyx_4 = 0; Py_DECREF(__pyx_6); __pyx_6 = 0; - __pyx_4 = PyNumber_Add(__pyx_3, __pyx_k8p); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 17; goto __pyx_L1;} + __pyx_4 = PyNumber_Add(__pyx_3, __pyx_k8p); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 33; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; - __pyx_6 = PyTuple_New(1); if (unlikely(!__pyx_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 17; goto __pyx_L1;} + __pyx_6 = PyTuple_New(1); if (unlikely(!__pyx_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 33; goto __pyx_L1;} PyTuple_SET_ITEM(__pyx_6, 0, __pyx_4); __pyx_4 = 0; - __pyx_3 = PyObject_CallObject(__pyx_5, __pyx_6); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 17; goto __pyx_L1;} + __pyx_3 = PyObject_CallObject(__pyx_5, __pyx_6); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 33; goto __pyx_L1;} Py_DECREF(__pyx_5); __pyx_5 = 0; Py_DECREF(__pyx_6); __pyx_6 = 0; Py_DECREF(__pyx_3); __pyx_3 = 0; } Py_DECREF(__pyx_1); __pyx_1 = 0; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":18 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":34 * for key,value in geodparams.iteritems(): * geodargs.append('+'+key+"="+str(value)+' ') * self.geodinitstring = PyString_AsString(''.join(geodargs)) # <<<<<<<<<<<<<< * # initialize projection * self.geodesic_t = GEOD_init_plus(self.geodinitstring, &GEOD_T)[0] */ - __pyx_4 = PyObject_GetAttr(__pyx_k9p, __pyx_n_join); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 18; goto __pyx_L1;} - __pyx_5 = PyTuple_New(1); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 18; goto __pyx_L1;} + __pyx_4 = PyObject_GetAttr(__pyx_k9p, __pyx_n_join); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 34; goto __pyx_L1;} + __pyx_5 = PyTuple_New(1); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 34; goto __pyx_L1;} Py_INCREF(__pyx_v_geodargs); PyTuple_SET_ITEM(__pyx_5, 0, __pyx_v_geodargs); - __pyx_6 = PyObject_CallObject(__pyx_4, __pyx_5); if (unlikely(!__pyx_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 18; goto __pyx_L1;} + __pyx_6 = PyObject_CallObject(__pyx_4, __pyx_5); if (unlikely(!__pyx_6)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 34; goto __pyx_L1;} Py_DECREF(__pyx_4); __pyx_4 = 0; Py_DECREF(__pyx_5); __pyx_5 = 0; ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodinitstring = PyString_AsString(__pyx_6); Py_DECREF(__pyx_6); __pyx_6 = 0; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":20 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":36 * self.geodinitstring = PyString_AsString(''.join(geodargs)) * # initialize projection * self.geodesic_t = GEOD_init_plus(self.geodinitstring, &GEOD_T)[0] # <<<<<<<<<<<<<< @@ -289,7 +303,7 @@ */ ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t = (GEOD_init_plus(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodinitstring,(&__pyx_v_GEOD_T))[0]); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":21 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":37 * # initialize projection * self.geodesic_t = GEOD_init_plus(self.geodinitstring, &GEOD_T)[0] * if pj_errno != 0: # <<<<<<<<<<<<<< @@ -298,35 +312,27 @@ */ __pyx_7 = (pj_errno != 0); if (__pyx_7) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":22 - * self.geodesic_t = GEOD_init_plus(self.geodinitstring, &GEOD_T)[0] - * if pj_errno != 0: - * raise RuntimeError(pj_strerrno(pj_errno)) # <<<<<<<<<<<<<< - * self.proj_version = PJ_VERSION/100. - * - */ - __pyx_3 = PyString_FromString(pj_strerrno(pj_errno)); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 22; goto __pyx_L1;} - __pyx_1 = PyTuple_New(1); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 22; goto __pyx_L1;} + __pyx_3 = PyString_FromString(pj_strerrno(pj_errno)); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 38; goto __pyx_L1;} + __pyx_1 = PyTuple_New(1); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 38; goto __pyx_L1;} PyTuple_SET_ITEM(__pyx_1, 0, __pyx_3); __pyx_3 = 0; - __pyx_4 = PyObject_CallObject(__pyx_builtin_RuntimeError, __pyx_1); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 22; goto __pyx_L1;} + __pyx_4 = PyObject_CallObject(__pyx_builtin_RuntimeError, __pyx_1); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 38; goto __pyx_L1;} Py_DECREF(__pyx_1); __pyx_1 = 0; __Pyx_Raise(__pyx_4, 0, 0); Py_DECREF(__pyx_4); __pyx_4 = 0; - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 22; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 38; goto __pyx_L1;} goto __pyx_L4; } __pyx_L4:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":23 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":39 * if pj_errno != 0: * raise RuntimeError(pj_strerrno(pj_errno)) * self.proj_version = PJ_VERSION/100. # <<<<<<<<<<<<<< * * def __reduce__(self): */ - __pyx_5 = PyFloat_FromDouble((PJ_VERSION / 100.)); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 23; goto __pyx_L1;} + __pyx_5 = PyFloat_FromDouble((PJ_VERSION / 100.)); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 39; goto __pyx_L1;} Py_DECREF(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->proj_version); ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->proj_version = __pyx_5; __pyx_5 = 0; @@ -339,7 +345,7 @@ Py_XDECREF(__pyx_4); Py_XDECREF(__pyx_5); Py_XDECREF(__pyx_6); - __Pyx_AddTraceback("_geod.Geod.__new__"); + __Pyx_AddTraceback("_geod.Geod.__cinit__"); __pyx_r = -1; __pyx_L0:; Py_DECREF(__pyx_v_geodargs); @@ -352,27 +358,19 @@ static PyObject *__pyx_n___class__; -static PyObject *__pyx_f_py_5_geod_4Geod___reduce__(PyObject *__pyx_v_self, PyObject *unused); /*proto*/ +static PyObject *__pyx_pf_5_geod_4Geod___reduce__(PyObject *__pyx_v_self, PyObject *unused); /*proto*/ static char __pyx_doc_5_geod_4Geod___reduce__[] = "special method that allows pyproj.Geod instance to be pickled"; -static PyObject *__pyx_f_py_5_geod_4Geod___reduce__(PyObject *__pyx_v_self, PyObject *unused) { +static PyObject *__pyx_pf_5_geod_4Geod___reduce__(PyObject *__pyx_v_self, PyObject *unused) { PyObject *__pyx_r; PyObject *__pyx_1 = 0; PyObject *__pyx_2 = 0; PyObject *__pyx_3 = 0; Py_INCREF(__pyx_v_self); - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":27 - * def __reduce__(self): - * """special method that allows pyproj.Geod instance to be pickled""" - * return (self.__class__,(self.geodparams,)) # <<<<<<<<<<<<<< - * - * def _fwd(self, object lons, object lats, object az, object dist, radians=False): - */ - __pyx_1 = PyObject_GetAttr(__pyx_v_self, __pyx_n___class__); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 27; goto __pyx_L1;} - __pyx_2 = PyTuple_New(1); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 27; goto __pyx_L1;} + __pyx_1 = PyObject_GetAttr(__pyx_v_self, __pyx_n___class__); if (unlikely(!__pyx_1)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 43; goto __pyx_L1;} + __pyx_2 = PyTuple_New(1); if (unlikely(!__pyx_2)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 43; goto __pyx_L1;} Py_INCREF(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodparams); PyTuple_SET_ITEM(__pyx_2, 0, ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodparams); - __pyx_3 = PyTuple_New(2); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 27; goto __pyx_L1;} + __pyx_3 = PyTuple_New(2); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 43; goto __pyx_L1;} PyTuple_SET_ITEM(__pyx_3, 0, __pyx_1); PyTuple_SET_ITEM(__pyx_3, 1, __pyx_2); __pyx_1 = 0; @@ -388,7 +386,7 @@ Py_XDECREF(__pyx_2); Py_XDECREF(__pyx_3); __Pyx_AddTraceback("_geod.Geod.__reduce__"); - __pyx_r = 0; + __pyx_r = NULL; __pyx_L0:; Py_DECREF(__pyx_v_self); return __pyx_r; @@ -401,12 +399,12 @@ static PyObject *__pyx_builtin_ValueError; -static char (__pyx_k10[]) = "Buffer lengths not the same"; -static char (__pyx_k11[]) = "undefined forward geodesic (may be an equatorial arc)"; +static char __pyx_k10[] = "Buffer lengths not the same"; +static char __pyx_k11[] = "undefined forward geodesic (may be an equatorial arc)"; -static PyObject *__pyx_f_py_5_geod_4Geod__fwd(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pf_5_geod_4Geod__fwd(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_5_geod_4Geod__fwd[] = "\n forward transformation - determine longitude, latitude and back azimuth \n of a terminus point given an initial point longitude and latitude, plus\n forward azimuth and distance.\n if radians=True, lons/lats are radians instead of degrees.\n "; -static PyObject *__pyx_f_py_5_geod_4Geod__fwd(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pf_5_geod_4Geod__fwd(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_lons = 0; PyObject *__pyx_v_lats = 0; PyObject *__pyx_v_az = 0; @@ -418,14 +416,14 @@ Py_ssize_t __pyx_v_buflend; Py_ssize_t __pyx_v_ndim; Py_ssize_t __pyx_v_i; - double (*__pyx_v_lonsdata); - double (*__pyx_v_latsdata); - double (*__pyx_v_azdata); - double (*__pyx_v_distdata); - void (*__pyx_v_londata); - void (*__pyx_v_latdata); - void (*__pyx_v_azdat); - void (*__pyx_v_distdat); + double *__pyx_v_lonsdata; + double *__pyx_v_latsdata; + double *__pyx_v_azdata; + double *__pyx_v_distdata; + void *__pyx_v_londata; + void *__pyx_v_latdata; + void *__pyx_v_azdat; + void *__pyx_v_distdat; PyObject *__pyx_r; int __pyx_1; int __pyx_2; @@ -437,7 +435,7 @@ int __pyx_8; static char *__pyx_argnames[] = {"lons","lats","az","dist","radians",0}; __pyx_v_radians = __pyx_k3; - if (unlikely(!PyArg_ParseTupleAndKeywords(__pyx_args, __pyx_kwds, "OOOO|O", __pyx_argnames, &__pyx_v_lons, &__pyx_v_lats, &__pyx_v_az, &__pyx_v_dist, &__pyx_v_radians))) return 0; + if (unlikely(!PyArg_ParseTupleAndKeywords(__pyx_args, __pyx_kwds, "OOOO|O", __pyx_argnames, &__pyx_v_lons, &__pyx_v_lats, &__pyx_v_az, &__pyx_v_dist, &__pyx_v_radians))) return NULL; Py_INCREF(__pyx_v_self); Py_INCREF(__pyx_v_lons); Py_INCREF(__pyx_v_lats); @@ -445,7 +443,7 @@ Py_INCREF(__pyx_v_dist); Py_INCREF(__pyx_v_radians); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":40 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":56 * cdef void *londata, *latdata, *azdat, *distdat * # if buffer api is supported, get pointer to data buffers. * if PyObject_AsWriteBuffer(lons, &londata, &buflenlons) <> 0: # <<<<<<<<<<<<<< @@ -454,21 +452,13 @@ */ __pyx_1 = (PyObject_AsWriteBuffer(__pyx_v_lons,(&__pyx_v_londata),(&__pyx_v_buflenlons)) != 0); if (__pyx_1) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":41 - * # if buffer api is supported, get pointer to data buffers. - * if PyObject_AsWriteBuffer(lons, &londata, &buflenlons) <> 0: - * raise RuntimeError # <<<<<<<<<<<<<< - * if PyObject_AsWriteBuffer(lats, &latdata, &buflenlats) <> 0: - * raise RuntimeError - */ __Pyx_Raise(__pyx_builtin_RuntimeError, 0, 0); - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 41; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 57; goto __pyx_L1;} goto __pyx_L2; } __pyx_L2:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":42 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":58 * if PyObject_AsWriteBuffer(lons, &londata, &buflenlons) <> 0: * raise RuntimeError * if PyObject_AsWriteBuffer(lats, &latdata, &buflenlats) <> 0: # <<<<<<<<<<<<<< @@ -477,21 +467,13 @@ */ __pyx_1 = (PyObject_AsWriteBuffer(__pyx_v_lats,(&__pyx_v_latdata),(&__pyx_v_buflenlats)) != 0); if (__pyx_1) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":43 - * raise RuntimeError - * if PyObject_AsWriteBuffer(lats, &latdata, &buflenlats) <> 0: - * raise RuntimeError # <<<<<<<<<<<<<< - * if PyObject_AsWriteBuffer(az, &azdat, &buflenaz) <> 0: - * raise RuntimeError - */ __Pyx_Raise(__pyx_builtin_RuntimeError, 0, 0); - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 43; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 59; goto __pyx_L1;} goto __pyx_L3; } __pyx_L3:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":44 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":60 * if PyObject_AsWriteBuffer(lats, &latdata, &buflenlats) <> 0: * raise RuntimeError * if PyObject_AsWriteBuffer(az, &azdat, &buflenaz) <> 0: # <<<<<<<<<<<<<< @@ -500,21 +482,13 @@ */ __pyx_1 = (PyObject_AsWriteBuffer(__pyx_v_az,(&__pyx_v_azdat),(&__pyx_v_buflenaz)) != 0); if (__pyx_1) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":45 - * raise RuntimeError - * if PyObject_AsWriteBuffer(az, &azdat, &buflenaz) <> 0: - * raise RuntimeError # <<<<<<<<<<<<<< - * if PyObject_AsWriteBuffer(dist, &distdat, &buflend) <> 0: - * raise RuntimeError - */ __Pyx_Raise(__pyx_builtin_RuntimeError, 0, 0); - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 45; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 61; goto __pyx_L1;} goto __pyx_L4; } __pyx_L4:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":46 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":62 * if PyObject_AsWriteBuffer(az, &azdat, &buflenaz) <> 0: * raise RuntimeError * if PyObject_AsWriteBuffer(dist, &distdat, &buflend) <> 0: # <<<<<<<<<<<<<< @@ -523,21 +497,13 @@ */ __pyx_1 = (PyObject_AsWriteBuffer(__pyx_v_dist,(&__pyx_v_distdat),(&__pyx_v_buflend)) != 0); if (__pyx_1) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":47 - * raise RuntimeError - * if PyObject_AsWriteBuffer(dist, &distdat, &buflend) <> 0: - * raise RuntimeError # <<<<<<<<<<<<<< - * # process data in buffer - * if not buflenlons == buflenlats == buflenaz == buflend: - */ __Pyx_Raise(__pyx_builtin_RuntimeError, 0, 0); - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 47; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 63; goto __pyx_L1;} goto __pyx_L5; } __pyx_L5:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":49 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":65 * raise RuntimeError * # process data in buffer * if not buflenlons == buflenlats == buflenaz == buflend: # <<<<<<<<<<<<<< @@ -553,79 +519,71 @@ } __pyx_2 = (!__pyx_1); if (__pyx_2) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":50 - * # process data in buffer - * if not buflenlons == buflenlats == buflenaz == buflend: - * raise RuntimeError("Buffer lengths not the same") # <<<<<<<<<<<<<< - * ndim = buflenlons/_doublesize - * lonsdata = <double *>londata - */ - __pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 50; goto __pyx_L1;} + __pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 66; goto __pyx_L1;} Py_INCREF(__pyx_k10p); PyTuple_SET_ITEM(__pyx_3, 0, __pyx_k10p); - __pyx_4 = PyObject_CallObject(__pyx_builtin_RuntimeError, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 50; goto __pyx_L1;} + __pyx_4 = PyObject_CallObject(__pyx_builtin_RuntimeError, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 66; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; __Pyx_Raise(__pyx_4, 0, 0); Py_DECREF(__pyx_4); __pyx_4 = 0; - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 50; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 66; goto __pyx_L1;} goto __pyx_L6; } __pyx_L6:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":51 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":67 * if not buflenlons == buflenlats == buflenaz == buflend: * raise RuntimeError("Buffer lengths not the same") * ndim = buflenlons/_doublesize # <<<<<<<<<<<<<< * lonsdata = <double *>londata * latsdata = <double *>latdata */ - __pyx_3 = PyInt_FromSsize_t(__pyx_v_buflenlons); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 51; goto __pyx_L1;} - __pyx_4 = __Pyx_GetName(__pyx_m, __pyx_n__doublesize); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 51; goto __pyx_L1;} - __pyx_5 = PyNumber_Divide(__pyx_3, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 51; goto __pyx_L1;} + __pyx_3 = PyInt_FromSsize_t(__pyx_v_buflenlons); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 67; goto __pyx_L1;} + __pyx_4 = __Pyx_GetName(__pyx_m, __pyx_n__doublesize); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 67; goto __pyx_L1;} + __pyx_5 = PyNumber_Divide(__pyx_3, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 67; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; Py_DECREF(__pyx_4); __pyx_4 = 0; - __pyx_6 = __pyx_PyIndex_AsSsize_t(__pyx_5); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 51; goto __pyx_L1;} + __pyx_6 = __pyx_PyIndex_AsSsize_t(__pyx_5); if (unlikely((__pyx_6 == -1) && PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 67; goto __pyx_L1;} Py_DECREF(__pyx_5); __pyx_5 = 0; __pyx_v_ndim = __pyx_6; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":52 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":68 * raise RuntimeError("Buffer lengths not the same") * ndim = buflenlons/_doublesize * lonsdata = <double *>londata # <<<<<<<<<<<<<< * latsdata = <double *>latdata * azdata = <double *>azdat */ - __pyx_v_lonsdata = ((double (*))__pyx_v_londata); + __pyx_v_lonsdata = ((double *)__pyx_v_londata); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":53 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":69 * ndim = buflenlons/_doublesize * lonsdata = <double *>londata * latsdata = <double *>latdata # <<<<<<<<<<<<<< * azdata = <double *>azdat * distdata = <double *>distdat */ - __pyx_v_latsdata = ((double (*))__pyx_v_latdata); + __pyx_v_latsdata = ((double *)__pyx_v_latdata); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":54 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":70 * lonsdata = <double *>londata * latsdata = <double *>latdata * azdata = <double *>azdat # <<<<<<<<<<<<<< * distdata = <double *>distdat * for i from 0 <= i < ndim: */ - __pyx_v_azdata = ((double (*))__pyx_v_azdat); + __pyx_v_azdata = ((double *)__pyx_v_azdat); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":55 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":71 * latsdata = <double *>latdata * azdata = <double *>azdat * distdata = <double *>distdat # <<<<<<<<<<<<<< * for i from 0 <= i < ndim: * if radians: */ - __pyx_v_distdata = ((double (*))__pyx_v_distdat); + __pyx_v_distdata = ((double *)__pyx_v_distdat); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":56 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":72 * azdata = <double *>azdat * distdata = <double *>distdat * for i from 0 <= i < ndim: # <<<<<<<<<<<<<< @@ -634,17 +592,17 @@ */ for (__pyx_v_i = 0; __pyx_v_i < __pyx_v_ndim; __pyx_v_i++) { - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":57 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":73 * distdata = <double *>distdat * for i from 0 <= i < ndim: * if radians: # <<<<<<<<<<<<<< * self.geodesic_t.p1.v = lonsdata[i] * self.geodesic_t.p1.u = latsdata[i] */ - __pyx_1 = __Pyx_PyObject_IsTrue(__pyx_v_radians); if (unlikely(__pyx_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 57; goto __pyx_L1;} + __pyx_1 = __Pyx_PyObject_IsTrue(__pyx_v_radians); if (unlikely(__pyx_1 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 73; goto __pyx_L1;} if (__pyx_1) { - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":58 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":74 * for i from 0 <= i < ndim: * if radians: * self.geodesic_t.p1.v = lonsdata[i] # <<<<<<<<<<<<<< @@ -653,7 +611,7 @@ */ ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p1.v = (__pyx_v_lonsdata[__pyx_v_i]); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":59 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":75 * if radians: * self.geodesic_t.p1.v = lonsdata[i] * self.geodesic_t.p1.u = latsdata[i] # <<<<<<<<<<<<<< @@ -662,7 +620,7 @@ */ ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p1.u = (__pyx_v_latsdata[__pyx_v_i]); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":60 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":76 * self.geodesic_t.p1.v = lonsdata[i] * self.geodesic_t.p1.u = latsdata[i] * self.geodesic_t.ALPHA12 = azdata[i] # <<<<<<<<<<<<<< @@ -671,7 +629,7 @@ */ ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.ALPHA12 = (__pyx_v_azdata[__pyx_v_i]); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":61 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":77 * self.geodesic_t.p1.u = latsdata[i] * self.geodesic_t.ALPHA12 = azdata[i] * self.geodesic_t.DIST = distdata[i] # <<<<<<<<<<<<<< @@ -683,55 +641,55 @@ } /*else*/ { - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":63 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":79 * self.geodesic_t.DIST = distdata[i] * else: * self.geodesic_t.p1.v = _dg2rad*lonsdata[i] # <<<<<<<<<<<<<< * self.geodesic_t.p1.u = _dg2rad*latsdata[i] * self.geodesic_t.ALPHA12 = _dg2rad*azdata[i] */ - __pyx_3 = __Pyx_GetName(__pyx_m, __pyx_n__dg2rad); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 63; goto __pyx_L1;} - __pyx_4 = PyFloat_FromDouble((__pyx_v_lonsdata[__pyx_v_i])); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 63; goto __pyx_L1;} - __pyx_5 = PyNumber_Multiply(__pyx_3, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 63; goto __pyx_L1;} + __pyx_3 = __Pyx_GetName(__pyx_m, __pyx_n__dg2rad); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 79; goto __pyx_L1;} + __pyx_4 = PyFloat_FromDouble((__pyx_v_lonsdata[__pyx_v_i])); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 79; goto __pyx_L1;} + __pyx_5 = PyNumber_Multiply(__pyx_3, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 79; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; Py_DECREF(__pyx_4); __pyx_4 = 0; - __pyx_7 = PyFloat_AsDouble(__pyx_5); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 63; goto __pyx_L1;} + __pyx_7 = PyFloat_AsDouble(__pyx_5); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 79; goto __pyx_L1;} Py_DECREF(__pyx_5); __pyx_5 = 0; ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p1.v = __pyx_7; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":64 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":80 * else: * self.geodesic_t.p1.v = _dg2rad*lonsdata[i] * self.geodesic_t.p1.u = _dg2rad*latsdata[i] # <<<<<<<<<<<<<< * self.geodesic_t.ALPHA12 = _dg2rad*azdata[i] * self.geodesic_t.DIST = distdata[i] */ - __pyx_3 = __Pyx_GetName(__pyx_m, __pyx_n__dg2rad); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 64; goto __pyx_L1;} - __pyx_4 = PyFloat_FromDouble((__pyx_v_latsdata[__pyx_v_i])); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 64; goto __pyx_L1;} - __pyx_5 = PyNumber_Multiply(__pyx_3, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 64; goto __pyx_L1;} + __pyx_3 = __Pyx_GetName(__pyx_m, __pyx_n__dg2rad); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; goto __pyx_L1;} + __pyx_4 = PyFloat_FromDouble((__pyx_v_latsdata[__pyx_v_i])); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; goto __pyx_L1;} + __pyx_5 = PyNumber_Multiply(__pyx_3, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; Py_DECREF(__pyx_4); __pyx_4 = 0; - __pyx_7 = PyFloat_AsDouble(__pyx_5); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 64; goto __pyx_L1;} + __pyx_7 = PyFloat_AsDouble(__pyx_5); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; goto __pyx_L1;} Py_DECREF(__pyx_5); __pyx_5 = 0; ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p1.u = __pyx_7; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":65 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":81 * self.geodesic_t.p1.v = _dg2rad*lonsdata[i] * self.geodesic_t.p1.u = _dg2rad*latsdata[i] * self.geodesic_t.ALPHA12 = _dg2rad*azdata[i] # <<<<<<<<<<<<<< * self.geodesic_t.DIST = distdata[i] * geod_pre(&self.geodesic_t) */ - __pyx_3 = __Pyx_GetName(__pyx_m, __pyx_n__dg2rad); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 65; goto __pyx_L1;} - __pyx_4 = PyFloat_FromDouble((__pyx_v_azdata[__pyx_v_i])); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 65; goto __pyx_L1;} - __pyx_5 = PyNumber_Multiply(__pyx_3, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 65; goto __pyx_L1;} + __pyx_3 = __Pyx_GetName(__pyx_m, __pyx_n__dg2rad); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 81; goto __pyx_L1;} + __pyx_4 = PyFloat_FromDouble((__pyx_v_azdata[__pyx_v_i])); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 81; goto __pyx_L1;} + __pyx_5 = PyNumber_Multiply(__pyx_3, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 81; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; Py_DECREF(__pyx_4); __pyx_4 = 0; - __pyx_7 = PyFloat_AsDouble(__pyx_5); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 65; goto __pyx_L1;} + __pyx_7 = PyFloat_AsDouble(__pyx_5); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 81; goto __pyx_L1;} Py_DECREF(__pyx_5); __pyx_5 = 0; ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.ALPHA12 = __pyx_7; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":66 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":82 * self.geodesic_t.p1.u = _dg2rad*latsdata[i] * self.geodesic_t.ALPHA12 = _dg2rad*azdata[i] * self.geodesic_t.DIST = distdata[i] # <<<<<<<<<<<<<< @@ -742,7 +700,7 @@ } __pyx_L9:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":67 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":83 * self.geodesic_t.ALPHA12 = _dg2rad*azdata[i] * self.geodesic_t.DIST = distdata[i] * geod_pre(&self.geodesic_t) # <<<<<<<<<<<<<< @@ -751,7 +709,7 @@ */ geod_pre((&((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t)); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":68 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":84 * self.geodesic_t.DIST = distdata[i] * geod_pre(&self.geodesic_t) * if pj_errno != 0: # <<<<<<<<<<<<<< @@ -760,28 +718,20 @@ */ __pyx_2 = (pj_errno != 0); if (__pyx_2) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":69 - * geod_pre(&self.geodesic_t) - * if pj_errno != 0: - * raise RuntimeError(pj_strerrno(pj_errno)) # <<<<<<<<<<<<<< - * geod_for(&self.geodesic_t) - * if pj_errno != 0: - */ - __pyx_3 = PyString_FromString(pj_strerrno(pj_errno)); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 69; goto __pyx_L1;} - __pyx_4 = PyTuple_New(1); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 69; goto __pyx_L1;} + __pyx_3 = PyString_FromString(pj_strerrno(pj_errno)); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 85; goto __pyx_L1;} + __pyx_4 = PyTuple_New(1); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 85; goto __pyx_L1;} PyTuple_SET_ITEM(__pyx_4, 0, __pyx_3); __pyx_3 = 0; - __pyx_5 = PyObject_CallObject(__pyx_builtin_RuntimeError, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 69; goto __pyx_L1;} + __pyx_5 = PyObject_CallObject(__pyx_builtin_RuntimeError, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 85; goto __pyx_L1;} Py_DECREF(__pyx_4); __pyx_4 = 0; __Pyx_Raise(__pyx_5, 0, 0); Py_DECREF(__pyx_5); __pyx_5 = 0; - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 69; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 85; goto __pyx_L1;} goto __pyx_L10; } __pyx_L10:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":70 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":86 * if pj_errno != 0: * raise RuntimeError(pj_strerrno(pj_errno)) * geod_for(&self.geodesic_t) # <<<<<<<<<<<<<< @@ -790,7 +740,7 @@ */ geod_for((&((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t)); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":71 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":87 * raise RuntimeError(pj_strerrno(pj_errno)) * geod_for(&self.geodesic_t) * if pj_errno != 0: # <<<<<<<<<<<<<< @@ -799,28 +749,20 @@ */ __pyx_1 = (pj_errno != 0); if (__pyx_1) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":72 - * geod_for(&self.geodesic_t) - * if pj_errno != 0: - * raise RuntimeError(pj_strerrno(pj_errno)) # <<<<<<<<<<<<<< - * if isnan(self.geodesic_t.ALPHA21): - * raise ValueError('undefined forward geodesic (may be an equatorial arc)') - */ - __pyx_3 = PyString_FromString(pj_strerrno(pj_errno)); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; goto __pyx_L1;} - __pyx_4 = PyTuple_New(1); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; goto __pyx_L1;} + __pyx_3 = PyString_FromString(pj_strerrno(pj_errno)); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 88; goto __pyx_L1;} + __pyx_4 = PyTuple_New(1); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 88; goto __pyx_L1;} PyTuple_SET_ITEM(__pyx_4, 0, __pyx_3); __pyx_3 = 0; - __pyx_5 = PyObject_CallObject(__pyx_builtin_RuntimeError, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; goto __pyx_L1;} + __pyx_5 = PyObject_CallObject(__pyx_builtin_RuntimeError, __pyx_4); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 88; goto __pyx_L1;} Py_DECREF(__pyx_4); __pyx_4 = 0; __Pyx_Raise(__pyx_5, 0, 0); Py_DECREF(__pyx_5); __pyx_5 = 0; - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 72; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 88; goto __pyx_L1;} goto __pyx_L11; } __pyx_L11:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":73 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":89 * if pj_errno != 0: * raise RuntimeError(pj_strerrno(pj_errno)) * if isnan(self.geodesic_t.ALPHA21): # <<<<<<<<<<<<<< @@ -829,37 +771,29 @@ */ __pyx_8 = isnan(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.ALPHA21); if (__pyx_8) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":74 - * raise RuntimeError(pj_strerrno(pj_errno)) - * if isnan(self.geodesic_t.ALPHA21): - * raise ValueError('undefined forward geodesic (may be an equatorial arc)') # <<<<<<<<<<<<<< - * if radians: - * lonsdata[i] = self.geodesic_t.p2.v - */ - __pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 74; goto __pyx_L1;} + __pyx_3 = PyTuple_New(1); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 90; goto __pyx_L1;} Py_INCREF(__pyx_k11p); PyTuple_SET_ITEM(__pyx_3, 0, __pyx_k11p); - __pyx_4 = PyObject_CallObject(__pyx_builtin_ValueError, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 74; goto __pyx_L1;} + __pyx_4 = PyObject_CallObject(__pyx_builtin_ValueError, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 90; goto __pyx_L1;} Py_DECREF(__pyx_3); __pyx_3 = 0; __Pyx_Raise(__pyx_4, 0, 0); Py_DECREF(__pyx_4); __pyx_4 = 0; - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 74; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 90; goto __pyx_L1;} goto __pyx_L12; } __pyx_L12:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":75 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":91 * if isnan(self.geodesic_t.ALPHA21): * raise ValueError('undefined forward geodesic (may be an equatorial arc)') * if radians: # <<<<<<<<<<<<<< * lonsdata[i] = self.geodesic_t.p2.v * latsdata[i] = self.geodesic_t.p2.u */ - __pyx_2 = __Pyx_PyObject_IsTrue(__pyx_v_radians); if (unlikely(__pyx_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 75; goto __pyx_L1;} + __pyx_2 = __Pyx_PyObject_IsTrue(__pyx_v_radians); if (unlikely(__pyx_2 < 0)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 91; goto __pyx_L1;} if (__pyx_2) { - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":76 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":92 * raise ValueError('undefined forward geodesic (may be an equatorial arc)') * if radians: * lonsdata[i] = self.geodesic_t.p2.v # <<<<<<<<<<<<<< @@ -868,7 +802,7 @@ */ (__pyx_v_lonsdata[__pyx_v_i]) = ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p2.v; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":77 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":93 * if radians: * lonsdata[i] = self.geodesic_t.p2.v * latsdata[i] = self.geodesic_t.p2.u # <<<<<<<<<<<<<< @@ -877,7 +811,7 @@ */ (__pyx_v_latsdata[__pyx_v_i]) = ((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p2.u; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":78 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":94 * lonsdata[i] = self.geodesic_t.p2.v * latsdata[i] = self.geodesic_t.p2.u * azdata[i] = self.geodesic_t.ALPHA21 # <<<<<<<<<<<<<< @@ -889,51 +823,51 @@ } /*else*/ { - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":80 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":96 * azdata[i] = self.geodesic_t.ALPHA21 * else: * lonsdata[i] = _rad2dg*self.geodesic_t.p2.v # <<<<<<<<<<<<<< * latsdata[i] = _rad2dg*self.geodesic_t.p2.u * azdata[i] = _rad2dg*self.geodesic_t.ALPHA21 */ - __pyx_5 = __Pyx_GetName(__pyx_m, __pyx_n__rad2dg); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; goto __pyx_L1;} - __pyx_3 = PyFloat_FromDouble(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p2.v); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; goto __pyx_L1;} - __pyx_4 = PyNumber_Multiply(__pyx_5, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; goto __pyx_L1;} + __pyx_5 = __Pyx_GetName(__pyx_m, __pyx_n__rad2dg); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 96; goto __pyx_L1;} + __pyx_3 = PyFloat_FromDouble(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p2.v); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 96; goto __pyx_L1;} + __pyx_4 = PyNumber_Multiply(__pyx_5, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 96; goto __pyx_L1;} Py_DECREF(__pyx_5); __pyx_5 = 0; Py_DECREF(__pyx_3); __pyx_3 = 0; - __pyx_7 = PyFloat_AsDouble(__pyx_4); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 80; goto __pyx_L1;} + __pyx_7 = PyFloat_AsDouble(__pyx_4); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 96; goto __pyx_L1;} Py_DECREF(__pyx_4); __pyx_4 = 0; (__pyx_v_lonsdata[__pyx_v_i]) = __pyx_7; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":81 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":97 * else: * lonsdata[i] = _rad2dg*self.geodesic_t.p2.v * latsdata[i] = _rad2dg*self.geodesic_t.p2.u # <<<<<<<<<<<<<< * azdata[i] = _rad2dg*self.geodesic_t.ALPHA21 * */ - __pyx_5 = __Pyx_GetName(__pyx_m, __pyx_n__rad2dg); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 81; goto __pyx_L1;} - __pyx_3 = PyFloat_FromDouble(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p2.u); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 81; goto __pyx_L1;} - __pyx_4 = PyNumber_Multiply(__pyx_5, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 81; goto __pyx_L1;} + __pyx_5 = __Pyx_GetName(__pyx_m, __pyx_n__rad2dg); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 97; goto __pyx_L1;} + __pyx_3 = PyFloat_FromDouble(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.p2.u); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 97; goto __pyx_L1;} + __pyx_4 = PyNumber_Multiply(__pyx_5, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 97; goto __pyx_L1;} Py_DECREF(__pyx_5); __pyx_5 = 0; Py_DECREF(__pyx_3); __pyx_3 = 0; - __pyx_7 = PyFloat_AsDouble(__pyx_4); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 81; goto __pyx_L1;} + __pyx_7 = PyFloat_AsDouble(__pyx_4); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 97; goto __pyx_L1;} Py_DECREF(__pyx_4); __pyx_4 = 0; (__pyx_v_latsdata[__pyx_v_i]) = __pyx_7; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":82 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":98 * lonsdata[i] = _rad2dg*self.geodesic_t.p2.v * latsdata[i] = _rad2dg*self.geodesic_t.p2.u * azdata[i] = _rad2dg*self.geodesic_t.ALPHA21 # <<<<<<<<<<<<<< * * def _inv(self, object lons1, object lats1, object lons2, object lats2, radians=False): */ - __pyx_5 = __Pyx_GetName(__pyx_m, __pyx_n__rad2dg); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 82; goto __pyx_L1;} - __pyx_3 = PyFloat_FromDouble(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.ALPHA21); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 82; goto __pyx_L1;} - __pyx_4 = PyNumber_Multiply(__pyx_5, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 82; goto __pyx_L1;} + __pyx_5 = __Pyx_GetName(__pyx_m, __pyx_n__rad2dg); if (unlikely(!__pyx_5)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 98; goto __pyx_L1;} + __pyx_3 = PyFloat_FromDouble(((struct __pyx_obj_5_geod_Geod *)__pyx_v_self)->geodesic_t.ALPHA21); if (unlikely(!__pyx_3)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 98; goto __pyx_L1;} + __pyx_4 = PyNumber_Multiply(__pyx_5, __pyx_3); if (unlikely(!__pyx_4)) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 98; goto __pyx_L1;} Py_DECREF(__pyx_5); __pyx_5 = 0; Py_DECREF(__pyx_3); __pyx_3 = 0; - __pyx_7 = PyFloat_AsDouble(__pyx_4); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 82; goto __pyx_L1;} + __pyx_7 = PyFloat_AsDouble(__pyx_4); if (unlikely(PyErr_Occurred())) {__pyx_filename = __pyx_f[0]; __pyx_lineno = 98; goto __pyx_L1;} Py_DECREF(__pyx_4); __pyx_4 = 0; (__pyx_v_azdata[__pyx_v_i]) = __pyx_7; } @@ -947,7 +881,7 @@ Py_XDECREF(__pyx_4); Py_XDECREF(__pyx_5); __Pyx_AddTraceback("_geod.Geod._fwd"); - __pyx_r = 0; + __pyx_r = NULL; __pyx_L0:; Py_DECREF(__pyx_v_self); Py_DECREF(__pyx_v_lons); @@ -961,12 +895,12 @@ static PyObject *__pyx_k12p; static PyObject *__pyx_k13p; -static char (__pyx_k12[]) = "Buffer lengths not the same"; -static char (__pyx_k13[]) = "undefined inverse geodesic (may be an antipodal point)"; +static char __pyx_k12[] = "Buffer lengths not the same"; +static char __pyx_k13[] = "undefined inverse geodesic (may be an antipodal point)"; -static PyObject *__pyx_f_py_5_geod_4Geod__inv(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ +static PyObject *__pyx_pf_5_geod_4Geod__inv(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/ static char __pyx_doc_5_geod_4Geod__inv[] = "\n inverse transformation - return forward and back azimuths, plus distance\n between an initial and terminus lat/lon pair.\n if radians=True, lons/lats are radians instead of degrees.\n "; -static PyObject *__pyx_f_py_5_geod_4Geod__inv(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { +static PyObject *__pyx_pf_5_geod_4Geod__inv(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) { PyObject *__pyx_v_lons1 = 0; PyObject *__pyx_v_lats1 = 0; PyObject *__pyx_v_lons2 = 0; @@ -978,14 +912,14 @@ Py_ssize_t __pyx_v_buflend; Py_ssize_t __pyx_v_ndim; Py_ssize_t __pyx_v_i; - double (*__pyx_v_lonsdata); - double (*__pyx_v_latsdata); - double (*__pyx_v_azdata); - double (*__pyx_v_distdata); - void (*__pyx_v_londata); - void (*__pyx_v_latdata); - void (*__pyx_v_azdat); - void (*__pyx_v_distdat); + double *__pyx_v_lonsdata; + double *__pyx_v_latsdata; + double *__pyx_v_azdata; + double *__pyx_v_distdata; + void *__pyx_v_londata; + void *__pyx_v_latdata; + void *__pyx_v_azdat; + void *__pyx_v_distdat; PyObject *__pyx_r; int __pyx_1; int __pyx_2; @@ -997,7 +931,7 @@ int __pyx_8; static char *__pyx_argnames[] = {"lons1","lats1","lons2","lats2","radians",0}; __pyx_v_radians = __pyx_k4; - if (unlikely(!PyArg_ParseTupleAndKeywords(__pyx_args, __pyx_kwds, "OOOO|O", __pyx_argnames, &__pyx_v_lons1, &__pyx_v_lats1, &__pyx_v_lons2, &__pyx_v_lats2, &__pyx_v_radians))) return 0; + if (unlikely(!PyArg_ParseTupleAndKeywords(__pyx_args, __pyx_kwds, "OOOO|O", __pyx_argnames, &__pyx_v_lons1, &__pyx_v_lats1, &__pyx_v_lons2, &__pyx_v_lats2, &__pyx_v_radians))) return NULL; Py_INCREF(__pyx_v_self); Py_INCREF(__pyx_v_lons1); Py_INCREF(__pyx_v_lats1); @@ -1005,7 +939,7 @@ Py_INCREF(__pyx_v_lats2); Py_INCREF(__pyx_v_radians); - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":94 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":110 * cdef void *londata, *latdata, *azdat, *distdat * # if buffer api is supported, get pointer to data buffers. * if PyObject_AsWriteBuffer(lons1, &londata, &buflenlons) <> 0: # <<<<<<<<<<<<<< @@ -1014,21 +948,13 @@ */ __pyx_1 = (PyObject_AsWriteBuffer(__pyx_v_lons1,(&__pyx_v_londata),(&__pyx_v_buflenlons)) != 0); if (__pyx_1) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":95 - * # if buffer api is supported, get pointer to data buffers. - * if PyObject_AsWriteBuffer(lons1, &londata, &buflenlons) <> 0: - * raise RuntimeError # <<<<<<<<<<<<<< - * if PyObject_AsWriteBuffer(lats1, &latdata, &buflenlats) <> 0: - * raise RuntimeError - */ __Pyx_Raise(__pyx_builtin_RuntimeError, 0, 0); - {__pyx_filename = __pyx_f[0]; __pyx_lineno = 95; goto __pyx_L1;} + {__pyx_filename = __pyx_f[0]; __pyx_lineno = 111; goto __pyx_L1;} goto __pyx_L2; } __pyx_L2:; - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":96 + /* "/Users/jsw/python/matplotlib/toolkits/basemap-testing/src/_geod.pyx":112 * if PyObject_AsWriteBuffer(lons1, &londata, &buflenlons) <> 0: * raise RuntimeError * if PyObject_AsWriteBuffer(lats1, &latdata, &buflenlats) <> 0: # <<<<<<<<<<<<<< @@ -1037,21 +963,13 @@ */ __pyx_1 = (PyObject_AsWriteBuffer(__pyx_v_lats1,(&__pyx_v_latdata),(&__pyx_v_buflenlats)) != 0); if (__pyx_1) { - - /* "/private/tmp/toolkits/basemap-testing/src/_geod.pyx":97 - * raise RuntimeError - * if PyObject_AsWriteBuffer(lats1, &latdata, &buflenlats) <> 0: - * raise RuntimeError # <<<<<<<<<<<<<< - * if PyObject_AsWriteBuffer(lons2, &azdat, &buflen... [truncated message content] |