[Cython] [mailinglist] Re: problems with external data

Uwe Schmitt uschmitt at mineway.de
Fri Nov 14 13:28:21 CET 2008


Uwe Schmitt schrieb:
> Uwe Schmitt schrieb:
>>
>> Good news: the problem disappeared after upgrading to Cython 0.10,
>
> Bad news: the error occured again, I do not know what happens..
>
> I'm using  "print SVDVersion"
> and "print SVDVerbosity" which are translated as follows:
>
I depends on the usage ov SVDVerbosity: If I just read the variable I get:

     /*
    "C:\cygwin\home\uschmitt\workspace_eclipse_ganymede\PySVDLIB\src\svdlibc.pyx":157
     *     cdef SMat As
     *     #SVDVerbosity = 0
     *     print SVDVerbosity             # <<<<<<<<<<<<<<
     *
     *     if isinstance(A, scipy.sparse.spmatrix):
     */
      __pyx_1 = PyInt_FromLong(SVDVerbosity); if (unlikely(!__pyx_1))
    {__pyx_filename = __pyx_f[0]; __pyx_lineno = 157; __pyx_clineno =
    __LINE__; goto __pyx_L1_error;}
      __pyx_2 = PyTuple_New(1); if (unlikely(!__pyx_2)) {__pyx_filename
    = __pyx_f[0]; __pyx_lineno = 157; __pyx_clineno = __LINE__; goto
    __pyx_L1_error;}
      PyTuple_SET_ITEM(__pyx_2, 0, __pyx_1);
      __pyx_1 = 0;
      if (__Pyx_Print(((PyObject *)__pyx_2), 1) < 0) {__pyx_filename =
    __pyx_f[0]; __pyx_lineno = 157; __pyx_clineno = __LINE__; goto
    __pyx_L1_error;}
      Py_DECREF(((PyObject *)__pyx_2)); __pyx_2 = 0;

As soon as I add one line setting SVDVerbosity, I get:

     /*
    "C:\cygwin\home\uschmitt\workspace_eclipse_ganymede\PySVDLIB\src\svdlibc.pyx":158
     *     cdef SMat As
     *
     *     SVDVerbosity = 0             # <<<<<<<<<<<<<<
     *     print SVDVerbosity
     *
     */
      Py_INCREF(__pyx_int_0);
      Py_DECREF(__pyx_v_SVDVerbosity);
      __pyx_v_SVDVerbosity = __pyx_int_0;

      /*
    "C:\cygwin\home\uschmitt\workspace_eclipse_ganymede\PySVDLIB\src\svdlibc.pyx":159
     *
     *     SVDVerbosity = 0
     *     print SVDVerbosity             # <<<<<<<<<<<<<<
     *
     *
     */
      __pyx_1 = PyTuple_New(1); if (unlikely(!__pyx_1)) {__pyx_filename
    = __pyx_f[0]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto
    __pyx_L1_error;}
      Py_INCREF(__pyx_v_SVDVerbosity);
      PyTuple_SET_ITEM(__pyx_1, 0, __pyx_v_SVDVerbosity);
      if (__Pyx_Print(((PyObject *)__pyx_1), 1) < 0) {__pyx_filename =
    __pyx_f[0]; __pyx_lineno = 159; __pyx_clineno = __LINE__; goto
    __pyx_L1_error;}
      Py_DECREF(((PyObject *)__pyx_1)); __pyx_1 = 0;

Greetings, Uwe

PS: Thanks for developing Cython, it is a great tool !

-- 
Dr. rer. nat. Uwe Schmitt
F&E Mathematik
 
mineway GmbH
Science Park 2
D-66123 Saarbrücken
 
Telefon: +49 (0)681 8390 5334
Telefax: +49 (0)681 830 4376
 
uschmitt at mineway.de
www.mineway.de
 
Geschäftsführung: Dr.-Ing. Mathias Bauer
Amtsgericht Saarbrücken HRB 12339


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://codespeak.net/pipermail/cython-dev/attachments/20081114/9e101faf/attachment.htm 


More information about the Cython-dev mailing list