[Mne_analysis] errors with spyder in anaconda after installing mne python

FAIRS Amie amie.FAIRS at univ-amu.fr
Tue Jun 30 08:17:57 EDT 2020
Search archives:

        External Email - Use Caution        

Dear Dan,

Thanks for the code. Unfortunately it didn't work, but that might be because I didn't know what I was doing! I tried the code you wrote and also edited it based on the link you sent and neither way worked. I ended up with the spyder version distributed by anaconda and a separate version of spyder. They didn't play well together it seems as the individual version wouldn't open (it just froze).

Anyway, I did some googling and found that spyder doesn't like PyQt5 versions higher than 5.11. I tried using conda to uninstall PyQt5 and reinstall an older version but was blocked by anaconda. To get around this, I went into the mne python environment file, changed the PyQt5 version to be ==5.10 (rather than >=5.10), and reinstalled mne python. This has worked! Now spyder opens from within anaconda. 

I don't know yet if this will break mne commands? I assume no seeing as the environment file allows PyQt5 5.10 as a package version? 

I also have no clue if other people will run into this issue as well.

Best,

Amie

------------------   
Dr. Amie Fairs
Post-doctorant
Aix-Marseille Université
Laboratoire Parole et Langage (LPL) | CNRS UMR 7309 | 5 Avenue Pasteur | 13100 Aix-en-Provence
Email : amie.fairs at univ-amu.fr

While I may send this email outside of typical working hours, I have no expectation to receive an email outside of your typical hours.

Date: Mon, 29 Jun 2020 17:33:55 +0000
From: Dan McCloy <dan at mccloy.info>
Subject: Re: [Mne_analysis] errors with spyder in anaconda after
	installing	mne python
To: Discussion and support forum for the users of MNE Software
	<mne_analysis at nmr.mgh.harvard.edu>
Message-ID:
	<sqs-vJBujz5qgKgA_Zc8Q-cwVFrasKD2344JXELRmfLr7FOSMFXUpTTrE9JZ6UWSO9fvKAIxa0PJ8Tsiz3S1tLhsbJ8dj8fr2XgeAlBn__8=@mccloy.info>
	
Content-Type: text/plain; charset="utf-8"

        External Email - Use Caution        

Hi Amie,

One option you could try is what Spyder developers call "the modular installation approach" [1] --- install Spyder into one conda environment, and install MNE-Python into a different environment. Then, when you launch Spyder, change the "Preferences > Python Interpreter > Use the following interpreter" setting to match the python executable in the MNE-Python conda environment. This would look something like:

# download MNE-Python environment file
curl --remote-name https://raw.githubusercontent.com/mne-tools/mne-python/master/environment.yml
# create new environment "mne"
conda env update -n mne --file environment.yml # create new environment "spyder"
conda create -n spyder python=3 spyder
# activate spyder env & launch Spyder GUI conda activate spyder spyder # now, set the python interpreter as described.

[1]: https://github.com/spyder-ide/spyder/wiki/Working-with-packages-and-environments-in-Spyder#working-with-other-environments-and-python-installations

-- dan
Daniel McCloy
https://dan.mccloy.info
Research Scientist
Institute for Learning and Brain Sciences University of Washington

??????? Original Message ???????
On Monday, June 29, 2020 7:11 AM, Alexandre Gramfort <alexandre.gramfort at inria.fr> wrote:

> External Email - Use Caution
>
> hi,
>
> can you report what
>
> mne.sys_info()
>
> reports in a simple python terminal?
>
> did you remove all other Python / anaconda installs from your machine?
>
> Alex
>
> Mne_analysis mailing list
> Mne_analysis at nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis





********




More information about the Mne_analysis mailing list