[pymvpa] InteractiveShell object

Abduljalil Sireis kentman234 at gmail.com
Tue Feb 26 18:00:06 UTC 2013


I wrote the commands in ipython shell as you suggested so here we have the
output result..

On Tue, Feb 26, 2013 at 12:05 PM, Yaroslav Halchenko
<debian at onerussian.com>wrote:

>
> On Tue, 26 Feb 2013, Abduljalil Sireis wrote:
>
> >      head ./test.py # in your shell
> >      then ?
>
> >    #!/usr/bin/env ipython
> >    # -*- coding: utf-8 -*-
> >    """
> >    Spyder Editor
> >    This temporary script file is located here:
> >    /home/brain/.spyder2/.temp.py
> >    """
> >      > >...<
> >    /home/brain/ipython scripts/test.py in <module>()
> >         12 import mvpa2.suite as mvpa2
> >         13 import IPython
> >    ---> 14 IPython.embed()
> >         15
> >         16 path = os.path.join('brain')
>
> ho ho -- that might be the source of the problem (something spyder
> injects having assumptions on ipython's version)
>
> >      >    �what happens if you run it with pure python, not ipython, i.e.
> >      >      python test.py
> >      >      ?
> >      >    AttributeError: 'module' object has no attribute 'embed'
>
> >      so the same (thus not ipython-dependent), good
>
> so I was wrong -- it is ipython dependent since script imports it ;)
>
> >      >      > � �2. output of�print mvpa2.wtf()
> >      >      that should be ran in (i)python interpreter (e.g. just start
> >      ipython,
> >      >      and
> >      >      then type
> >      >      mvpa2.wtf()
> >      >      )
> >      >      > � �bash: syntax error near unexpected token `('
> >      >    �NameError: name 'mvpa2' is not defined
>
> >      ;) ok -- first enter
>
> >      import mvpa2
>
> >    i entered  import mvpa2.suite as mvpa2
> >    shouldn't that be enough? :-)
>
> should if import succeeds... now I see that we recommend this way in the
> FAQ but I guess we better advise not to import 'as mvpa2' but better as
> 'as mv'.
>
> anyways -- if you imported it 'as mvpa2' and there were no errors you
> must be able to
>
> print mvpa2.wtf()
>
> if it doesn't work -- again -- copy/paste entire "protocol of struggle"
> not just the last error ;)  so just do
>
> in your shell start ipython:
>
> ipython
>
> in ipython shell do
>
> import mvpa2
> print mvpa2.wtf()
>
> it must work and it would provide us all information neeeded
>
> --
> Yaroslav O. Halchenko
> http://neuro.debian.net http://www.pymvpa.org http://www.fail2ban.org
> 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
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/pkg-exppsy-pymvpa/attachments/20130226/e2c1cc80/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: output result
Type: application/octet-stream
Size: 4821 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-exppsy-pymvpa/attachments/20130226/e2c1cc80/attachment-0001.obj>


More information about the Pkg-ExpPsy-PyMVPA mailing list