New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
problems installing mne on win10 64bit, py3.6(anaconda). #5288
Comments
can you explain what you did?
conda env create -f environment.yml
?
|
Yes, just follow the instructions here: https://www.martinos.org/mne/stable/install_mne_python.html#get-mne-and-its-dependencies,
When I am trying to create the env for mne using
conda env create -f environment.yml
thanks!
发件人: Alexandre Gramfort <notifications@github.com>
发送时间: 2018年6月18日 10:01
收件人: mne-tools/mne-python <mne-python@noreply.github.com>
抄送: Wang Qing <vincent.w.qing@gmail.com>; Author <author@noreply.github.com>
主题: Re: [mne-tools/mne-python] problems installing mne on win10 64bit, py3.6(anaconda). (#5288)
can you explain what you did?
conda env create -f environment.yml
?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub <#5288 (comment)> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AKffsLgk7ztGp3m0DPP8w0WC5aiPJEGAks5t9wndgaJpZM4UrC7z> . <https://github.com/notifications/beacon/AKffsLwWwV-zH2I-ISk6f_0unwwxCGW2ks5t9wndgaJpZM4UrC7z.gif>
|
ok let's try together.
if you have the pb when doing:
pip install mayavi
you can ask the question on the mayavi forum / mailing list.
|
I guess it looks like some kind of general problems with installing mayavi, the problem may be the incompactable compiler version or the system did not recognize the version of complier. I will try to navigate myself in the mayavi forum, and I need to install all the following most recent version of the packages listed in the yml file, after I fix this problem, right? Great thanks.
- pip:
- mne
- mayavi
- "https://api.github.com/repos/nipy/PySurfer/zipball/master"
- nitime
- nibabel
- nilearn
- neo
- pytest-sugar
- pytest-faulthandler
- pydocstyle
- sphinx_bootstrap_theme
- "https://api.github.com/repos/sphinx-gallery/sphinx-gallery/zipball/master"
- python-picard
- sphinx_fontawesome
|
I also had a similar issue with Anaconda and Windows 10. Try to install the MNE without creating an environment and by directly installing dependencies one by one. This worked for me. For instance,
|
Now I have fixed this problem, and here are my experiences:
|
thanks for all the details. I am thinking that these details on how to make the mayavi install work on Windows should be on the mayavi documentation page. What I don't fully understand is why it works fine on Appveyor via a conda env out of the box. @prabhuramachandran any idea? Short story is: We tell MNE users do install with: http://martinos.org/mne/stable/install_mne_python.html#get-mne-and-its-dependencies |
Hmm our appveyor tests seem to be running fine! https://ci.appveyor.com/project/EnthoughtOSS/mayavi |
@prabhuramachandran we install mayavi through pip : https://github.com/mne-tools/mne-python/blob/master/environment.yml#L34 does it mean that pypi package is not enough self contained? it cannot work on a fresh win64 Python? it needs a compiler? |
I've uploaded VTK wheels on pypi but not Mayavi wheels. Mayavi has a tiny extension module but that apart is pure Python. It does need to compile a single extension (which was made using Pyrex!). That should work on appveyor. How do you install traits? I can see about making the extension module optional (for a performance hit) in mayavi if it will make things easier. |
we install
- traits>=4.6.0
- pyface>=6
- traitsui>=6
with conda. See:
https://github.com/mne-tools/mne-python/blob/master/environment.yml#L29
it's working on our CIs. Is it the cause of our issue? thanks so much for
being so reactive.
|
OK, so the rest are from conda. It should be possible to install a suitable MSVC compiler relatively easily though, https://wiki.python.org/moin/WindowsCompilers |
Now I see new problems, when I try to test mayavi with qt5 and qt4 for my installation, they works well. But when I am trying the example (http://martinos.org/mne/stable/auto_examples/connectivity/plot_mne_inverse_psi_visual.html#sphx-glr-auto-examples-connectivity-plot-mne-inverse-psi-visual-py), I got errors, no idea what happens, it seems that the vis engine and dependencies are not well maintained: builtins.RuntimeError: No pyface.toolkits plugin could be loaded for qt4 with qt5, I have the following error: File "C:\Users\Administrator\Desktop\01_2d_signals.py", line 96, in builtins.TypeError: init() got an unexpected keyword argument 'curv' |
I have found another problem with the jupyter notebook, it starts very slow, takes more than 5 mins on a i7, 16G DDR4 machine, it looks strange.... |
@Vincent-wq use qt5 the error you see is due to a recent non-cautious API change in PySurfer. We need to cut a new PySurfer release. In the mean time you can edit the file c:\Anaconda3\envs\mne\Lib\site-packages\mne\viz_3d.py and remove the curv parameter. Sorry about this. |
No need for new PySurfer release, it should be fixed by the next maintenance release of MNE |
maybe a memory usage on your machine. It's really hard to tell.
can someone around you replicate the pb on his machine?
|
I have tried on 2 different win 10 machines, the problems are the same, and quite stable for several examples. Some times, the mayavi window just disappear instantly after it is finished, quit strange, maybe I need to read more blogs on mayavi |
@prabhuramachandran your quote from last scipy still resonates in my head. "I am also known for having produced the python package which is the hardest to install" .... I will just add "among the very useful pacakges" :) |
@agramfort -- thank you for the kind comment! Glad it is still useful. The dependencies and options make it tough. Making VTK pip installable is a big help already and makes things much easier. I'm working on the enthought/mayavi#658 issue to try and make the extension module optional. However, building a module optionally is yet another of those silly things that takes time to figure out and get right. |
I've just merged a PR to only optionally add the extension module. @Vincent-wq -- can you please try with pip installing the git master version of Mayavi like so on your machine where you had the issue:
Hopefully this should make Mayavi pip installable even when a compiler is not available, albeit at the expense of one slower function which may not be used heavily by an average user. |
@prabhuramachandran I had a quick look at set_id_type_array_py and am surprised Cython helps 4x. Is this because np.insert does an extra copy? If so I think there might be a way to avoid it so it approaches Cython does for large arrays. Do you have a gist the is slow in Python but fast in Cython? |
I was surprised too but I think it is because of the temporaries created. insert creates a new temporary which is assigned. I don't have a gist but can make one, I just used the following code in a notebook:
I tried with different values of n, cs but thats the code. I tried several other approaches and they all seemed slower. Feel free to suggest any improvements or send a PR. |
Took the ~2x slowdown to ~25%, views are wonderful :) |
@larsoner shall we update our environment.yml file? |
@larsoner -- yes they are along with the ability to add an axis. Without changing the shape, this is much harder. Thanks for the extra pair of eyes. On my machine I still get close to 50% slowdown and with smaller arrays even 2x. |
@agramfort -- just FYI, I will push a point release by the next weekend. |
great
please let us know when you do
thanks
|
@prabhuramachandran Great thanks, I just did as follows (uninstall mayavi and pip install git+https://github.com/enthought/mayavi.git#egg=mayavi |
@Vincent-wq -- Thank you! That is excellent. I suspect the screenshot you sent first is just to show that the right version of mayavi is installed. As regards the vis problem, this is not a Mayavi installation issue but perhaps something to do with mne-tools, I don't know. The test error popping up is an annoyance more than an actual error. I will investigate that issue and see if anything can be done about that. Thanks for testing the installation out though. Just to reconfirm, on this setup, if you uninstall mayavi and do a normal pip install it still fails right? |
@agramfort -- I just pushed Mayavi-4.6.1 to pypi. Enjoy. |
great ! @Vincent-wq can you give a try to the new release? |
@prabhuramachandran @agramfort , sorry for the long delay, just came back from vocation.
|
can you run fine the pysurfer examples:
https://pysurfer.github.io/auto_examples/index.html
?
|
Or even simpler before that, can you interact with this window:
|
But after you run |
@Vincent-wq can I close this? |
@agramfort -- this is also relevant: enthought/mayavi#683 , it is possible that the earlier release did not implement the compiler check correctly. Should be fixed in master. |
@Vincent-wq , I'm following your steps above up to 3.6. I don't have C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\x86_amd64 because you said to install Visual Studio 2017 (v. 15). Should I install v.14 instead? |
You should no longer need MSVC (or any complier) to install Mayavi |
for this part, it works well. |
@agramfort @prabhuramachandran @larsoner @mlearnx
The good news is that, at least I can work with it, but I really want to know how to tame mayavi to work better, I may spend some time doing a visualization project, also I really do not how ipython and spider made it work, why it does not work in the system cmd console, even I am trying to tell mayavi which backend to use. Also the jupyter notebook is always not working well for me (also this time), I prefer to use wingIDE, and spider is very easy to corrupt when dealing with intensive task (lacking good default good color setting is also not that firendly). |
the new version of document suppose to have all problems settled, at least it works for me now, please refer to my last reply. |
yet, I think you already put the wheel file in the server. |
You can probably get
|
Not sure if I am doing the right thing, I have tried to set qt5 as backend for both mayavi and matplotlib as follows: and if I put qt4 for both, then TVTK Scene apears and stoped responding...
|
when I am trying to install mne using anaconda3, I have the following problem (seems the problem installing mayavi)
I have VC2015 installed and using the MSBuild Command Prompt for VS2015 command line tool;
looks like some of the dependencies has been updated since the enviorenment.yml created, what can I do, I really want to try mne as soon as possible. By the way, I am in OHBM Sigapore and has been to the hackathon just few days ago, my name is Qing Wang, hope to see you in OHBM!
B. R.
Vincet
The text was updated successfully, but these errors were encountered: