[pymvpa] Problem About running mvpa2 tutorial

Ceyhun Çakar cakar.ceyhun at gmail.com
Wed Oct 17 07:32:44 UTC 2012


Hello Yaroslav,

If I can help, I am very pleased.

Cheers,
Ceyhun Çakar


On Tue, Oct 16, 2012 at 6:20 AM, Yaroslav Halchenko
<debian at onerussian.com> wrote:
> cool -- thanks Ceyhun for the troubleshooting... so to prevent this
> madness with uppercasing unicode-sensitivity indeed your patch makes
> sense so I have committed it (done independently with sed ;-) )
> https://github.com/PyMVPA/PyMVPA/commit/e2e8cefb5647c718cee7711bd877b681502d26c8
>
> Thanks!
>
> On Mon, 15 Oct 2012, Ceyhun Çakar wrote:
>
>> Hello Yaroslav,
>
>> I think I've understood and solved the problem. Because issue is about
>> Turkish Localization of Linux, only Turkish user can see this problem.
>> Nevertheless I am sending my solution.
>
>> I Turkish capital of i is different than English as below.
>> Capital of  'i' is 'İ' in Turkish (Unicode Number 0x130)
>> Lower case of 'I' is 'ı' in Turkish (Unicode Number 0x131)
>
>> So, 'aligned' does not match with 'ALIGNED' in Turkish. But code
>> assumes this in mvpa2/clfs/libsmlrc/ctypes_helper.py
>
>> When I use below patch to this file, problem solved.
>
>> *** ctypes_helper_original.py 2012-10-15 21:39:35.807810206 +0300
>> --- ctypes_helper.py  2012-10-15 21:28:24.496481350 +0300
>> ***************
>> *** 12,21 ****
>>   import ctypes as C
>
>>   # define an array type to help with wrapping
>> ! c_darray = np.ctypeslib.ndpointer(dtype=np.float64,
>> flags='aligned,contiguous')
>> ! c_larray = np.ctypeslib.ndpointer(dtype=np.int64, flags='aligned,contiguous')
>> ! c_farray = np.ctypeslib.ndpointer(dtype=np.float32,
>> flags='aligned,contiguous')
>> ! c_iarray = np.ctypeslib.ndpointer(dtype=np.int32, flags='aligned,contiguous')
>
>>   def extend_args(*args):
>>       """Turn ndarray arguments into dims and arrays."""
>> --- 12,21 ----
>>   import ctypes as C
>
>>   # define an array type to help with wrapping
>> ! c_darray = np.ctypeslib.ndpointer(dtype=np.float64,
>> flags='ALIGNED,CONTIGUOUS')
>> ! c_larray = np.ctypeslib.ndpointer(dtype=np.int64, flags='ALIGNED,CONTIGUOUS')
>> ! c_farray = np.ctypeslib.ndpointer(dtype=np.float32,
>> flags='ALIGNED,CONTIGUOUS')
>> ! c_iarray = np.ctypeslib.ndpointer(dtype=np.int32, flags='ALIGNED,CONTIGUOUS')
>
>>   def extend_args(*args):
>>       """Turn ndarray arguments into dims and arrays."""
>
>> Thank you for your immediate help.
>> Ceyhun Çakar
>
>
>> On Mon, Oct 15, 2012 at 5:31 AM, Yaroslav Halchenko
>> <debian at onerussian.com> wrote:
>
>> > On Sun, 14 Oct 2012, Ceyhun Çakar wrote:
>> >> PyMVPA:
>> >>  Version:       2.0.0
>
>> > before we explore much more -- could you please upgrade to 2.2.0
>> > packages for which we provide from NeuroDebian http://neuro.debian.net/
>
>> >>   PYTHONPATH          :
>> >> ":/home/ceyhun:/usr/lib/python2.7/plat-linux2:/usr/local/lib/python2.7/dist-packages/PyBrain-0.3.1-py2.7.egg:/usr/lib/python2.7/dist-packages/ubuntuone-control-panel:/usr/lib/python2.7/dist-packages/ubuntuone-couch:/usr/local/lib/python2.7/dist-packages/Orange/orng:/usr/lib/python2.7/dist-packages:/usr/lib/python2.7/dist-packages/IPython/extensions:/usr/lib/python2.7:/usr/lib/python2.7/dist-packages/wx-2.8-gtk2-unicode:/usr/local/lib/python2.7/dist-packages/setproctitle-1.1.6-py2.7-linux-x86_64.egg:/usr/lib/python2.7/dist-packages/PIL:/usr/local/lib/python2.7/dist-packages/FuncDesigner-0.42-py2.7.egg:/usr/local/lib/python2.7/dist-packages/openopt-0.42-py2.7.egg:/usr/lib/python2.7/dist-packages/ubuntuone-storage-protocol:/usr/lib/python2.7/lib-tk:/usr/lib/python2.7/lib-dynload:/usr/lib/python2.7/dist-packages/ubuntu-sso-client:/usr/local/lib/python2.7/dist-packages/Kivy-1.3.0-py2.7-linux-x86_64.egg:/usr/lib/python2.7/dist-packages/ubuntuone-client:/usr/local/lib/python2.7/dist-packages/DerApproximator-0.42-py2.7.egg:/usr/lib/python2.7/dist-packages/ubuntuone-installer:/usr/lib/python2.7/lib-old:/usr/local/lib/python2.7/dist-packages:/usr/lib/python2.7/dist-packages/gtk-2.0:/usr/local/lib/python2.7/dist-packages/SpaceFuncs-0.42-py2.7.egg:/usr/lib/pymodules/python2.7:/usr/lib/python2.7/dist-packages/gst-0.10"
>
>> > although unlikely,  but still possible -- the number of modules of
>> > /usr/local gives a feeling that problem might be  coming from  there...
>
>> > what if you run
>
>> > grep -R ALiGNED /usr 2>/dev/null
>
>> > and then if nothing appears
>
>> > grep -R ALiGNED /home/ceyhun 2>/dev/null
>
>> > may be we could spot a bad cow ;)
>
>> > --
>> > Yaroslav O. Halchenko
>> > Postdoctoral Fellow,   Department of Psychological and Brain Sciences
>> > Dartmouth College, 419 Moore Hall, Hinman Box 6207, Hanover, NH 03755
>> > Phone: +1 (603) 646-9834                       Fax: +1 (603) 646-1419
>> > WWW:   http://www.linkedin.com/in/yarik
>
>> > _______________________________________________
>> > Pkg-ExpPsy-PyMVPA mailing list
>> > Pkg-ExpPsy-PyMVPA at lists.alioth.debian.org
>> > http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-exppsy-pymvpa
> --
> Yaroslav O. Halchenko
> Postdoctoral Fellow,   Department of Psychological and Brain Sciences
> Dartmouth College, 419 Moore Hall, Hinman Box 6207, Hanover, NH 03755
> Phone: +1 (603) 646-9834                       Fax: +1 (603) 646-1419
> WWW:   http://www.linkedin.com/in/yarik
>
> _______________________________________________
> Pkg-ExpPsy-PyMVPA mailing list
> Pkg-ExpPsy-PyMVPA at lists.alioth.debian.org
> http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-exppsy-pymvpa



-- 
Ceyhun Çakar
cakar.ceyhun at gmail.com



More information about the Pkg-ExpPsy-PyMVPA mailing list