Skip to content
Commits on Source (9)
# Tagging a commit with [circle front] will build the front page and perform test-doc.
# Tagging a commit with [circle full] will build everything.
version: 2
jobs:
build:
docker:
# 3.6-jessie is too new for conda
- image: circleci/python:3.6-jessie
steps:
# Get our data and merge with upstream
- checkout
- run: echo $(git log -1 --pretty=%B) | tee gitlog.txt
- run: echo ${CI_PULL_REQUEST//*pull\//} | tee merge.txt
- run:
command: |
if [[ $(cat merge.txt) != "" ]]; then
echo "Merging $(cat merge.txt)";
git remote add upstream git://github.com/mne-tools/mne-python.git
git pull --ff-only upstream "refs/pull/$(cat merge.txt)/merge";
fi
# Load our data
- restore_cache:
keys:
- data-cache-0
- data-cache-1
- data-cache-2
- data-cache-3
- data-cache-4
- data-cache-5
- data-cache-6
- data-cache-7
- data-cache-8
- pip-cache
# Spin up Xvfb
- run: /sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -screen 0 1400x900x24 -ac +extension GLX +render -noreset;
- run: echo "export DISPLAY=:99" >> $BASH_ENV;
- run: echo "export OPENBLAS_NUM_THREADS=4" >> $BASH_ENV;
# Fix libgcc_s.so.1 pthread_cancel bug:
# https://github.com/ContinuumIO/anaconda-issues/issues/9190#issuecomment-386508136
# https://github.com/golemfactory/golem/issues/1019
- run: sudo apt-get install libgl1-mesa-glx libegl1-mesa libxrandr2 libxrandr2 libxss1 libxcursor1 libxcomposite1 libasound2 libxi6 libxtst6 qt5-default
# Get latest Anaconda running
- run:
command: |
wget -q http://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O ~/miniconda.sh;
chmod +x ~/miniconda.sh;
~/miniconda.sh -b -p ~/miniconda;
echo "export PATH=~/miniconda/bin:$PATH" >> $BASH_ENV;
- run:
command: |
conda update --yes --quiet conda;
conda env create --quiet -f environment.yml;
source activate mne;
conda install sphinx;
pip install sphinx_fontawesome sphinx_bootstrap_theme "https://api.github.com/repos/sphinx-gallery/sphinx-gallery/zipball/master" memory_profiler
pip uninstall --yes mne;
echo "source activate mne" >> $BASH_ENV;
- save_cache:
key: pip-cache
paths:
- ~/.cache/pip
# The conda-provided PyQt5 does not work on CircleCI for some reason,
# possibly because the libGL expects a sufficiently modern libgcc
# and conda rolls their own (libgcc-ng package).
- run: conda remove --yes qt pyqt matplotlib sip libxcb icu vtk
- run: pip uninstall --yes mayavi vtk
- run: pip install vtk mayavi PyQt5 PyQt5-sip sip matplotlib
- run: echo "export LD_PRELOAD=~/miniconda/envs/mne/lib/libgobject-2.0.so.0" >> $BASH_ENV
- run: pip install --upgrade "https://api.github.com/repos/nipy/PySurfer/zipball/master"
# Look at what we have and fail early if there is some library conflict
- run: which python
- run: python -c "import mne; mne.sys_info()"
- run: LIBGL_DEBUG=verbose python -c "from mayavi import mlab; import matplotlib.pyplot as plt; mlab.figure(); plt.figure()"
- run: python -c "import mne; mne.set_config('MNE_LOGGING_LEVEL', 'info')"
- run: python -c "import mne; level = mne.get_config('MNE_LOGGING_LEVEL'); assert level.lower() == 'info', repr(level)"
# Figure out if we should run a full, pattern, or noplot version
- run: python setup.py develop
- run: if ! git remote -v | grep upstream ; then git remote add upstream git://github.com/mne-tools/mne-python.git; fi
- run: git fetch upstream
- run: git branch -a
- run: mkdir -p ~/mne_data
- run:
command: |
touch pattern.txt;
if [ "$CIRCLE_BRANCH" == "master" ] || [[ $(cat gitlog.txt) == *"[circle full]"* ]]; then
echo html_dev > build.txt;
elif [ "$CIRCLE_BRANCH" == "maint/0.17" ]; then
echo html_stable > build.txt;
else
FNAMES=$(git diff --name-only $CIRCLE_BRANCH $(git merge-base $CIRCLE_BRANCH upstream/master));
if [[ $(cat gitlog.txt) == *"[circle front]"* ]]; then
FNAMES="tutorials/plot_mne_dspm_source_localization.py tutorials/plot_receptive_field.py examples/connectivity/plot_mne_inverse_label_connectivity.py tutorials/plot_sensors_decoding.py tutorials/plot_stats_cluster_spatio_temporal.py tutorials/plot_visualize_evoked.py "${FNAMES};
python -c "import mne; print(mne.datasets.testing.data_path(update_path=True))";
fi;
echo FNAMES="$FNAMES";
for FNAME in $FNAMES; do
if [[ `expr match $FNAME "\(tutorials\|examples\)/.*plot_.*\.py"` ]] ; then
echo "Checking example $FNAME ...";
PATTERN=`basename $FNAME`"\\|"$PATTERN;
if [[ $(cat $FNAME | grep -x ".*datasets.*sample.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.sample.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*spm_face.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.spm_face.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*somato.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.somato.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*eegbci.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.eegbci.load_data(1, [6, 10, 14], update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*hf_sef.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.hf_sef.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*brainstorm.*bst_auditory.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.brainstorm.bst_auditory.data_path(update_path=True))" --accept-brainstorm-license;
fi;
if [[ $(cat $FNAME | grep -x ".*brainstorm.*bst_raw.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.brainstorm.bst_raw.data_path(update_path=True))" --accept-brainstorm-license;
fi;
if [[ $(cat $FNAME | grep -x ".*brainstorm.*bst_phantom_ctf.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.brainstorm.bst_phantom_ctf.data_path(update_path=True))" --accept-brainstorm-license;
fi;
if [[ $(cat $FNAME | grep -x ".*brainstorm.*bst_phantom_elekta.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.brainstorm.bst_phantom_elekta.data_path(update_path=True))" --accept-brainstorm-license;
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*megsim.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.megsim.load_data(condition='visual', data_format='single-trial', data_type='simulation', update_path=True))";
python -c "import mne; print(mne.datasets.megsim.load_data(condition='visual', data_format='raw', data_type='experimental', update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*hcp_mmp_parcellation.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.sample.data_path(update_path=True))";
SUBJECTS_DIR=~/mne_data/MNE-sample-data/subjects python -c "import mne; print(mne.datasets.fetch_hcp_mmp_parcellation())" --accept-hcpmmp-license;
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*misc.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.misc.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*testing.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.testing.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*kiloword.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.kiloword.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*mtrf.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.mtrf.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*fieldtrip_cmc.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.fieldtrip_cmc.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*multimodal.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.multimodal.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*opm.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.opm.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*phantom_4dbti.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.phantom_4dbti.data_path(update_path=True))";
fi;
fi;
done;
echo PATTERN="$PATTERN";
if [[ $PATTERN ]]; then
PATTERN="\(${PATTERN::-2}\)";
echo html_dev-pattern > build.txt;
else
echo html_dev-noplot > build.txt;
fi;
fi;
echo "$PATTERN" > pattern.txt;
- run: echo "PATTERN=$(cat pattern.txt)"
- run: echo "BUILD=$(cat build.txt)"
- run: ls -al ~/mne_data;
- run:
command: |
if [[ $(cat build.txt) == "html_dev" ]] || [[ $(cat build.txt) == "html_stable" ]]; then
SUBJECTS_DIR=~/mne_data/MNE-sample-data/subjects python -c "import mne; mne.datasets._download_all_example_data()";
fi;
- run: if [ ! -d ~/mne-tools.github.io ]; then git clone https://github.com/mne-tools/mne-tools.github.io.git ~/mne-tools.github.io --depth=1; fi;
# Run doctest (if it's full or front) before building the docs
- run:
command: |
if [[ $(cat gitlog.txt) == *"[circle front]"* ]] || [[ $(cat build.txt) == "html_dev" ]] || [[ $(cat build.txt) == "html_stable" ]]; then
make test-doc;
fi;
# Build docs
- run:
command: |
cd doc;
PATTERN=$(cat ../pattern.txt) make $(cat ../build.txt);
- run: python -c "import mne; level = mne.get_config('MNE_LOGGING_LEVEL'); assert level.lower() == 'info', repr(level)"
- store_artifacts:
path: doc/_build/html/
destination: html
# Keep these separate, maybe better in terms of size limitations (?)
- save_cache:
key: data-cache-0
paths:
- ~/.mne
- ~/mne-tools.github.io
- ~/mne_data/mTRF_1.5
- save_cache:
key: data-cache-1
paths:
- ~/mne_data/HF_SEF
- ~/mne_data/MEGSIM
- save_cache:
key: data-cache-2
paths:
- ~/mne_data/MNE-brainstorm-data
- ~/mne_data/MNE-eegbci-data
- save_cache:
key: data-cache-3
paths:
- ~/mne_data/MNE-fieldtrip_cmc-data
- ~/mne_data/MNE-kiloword-data
- save_cache:
key: data-cache-4
paths:
- ~/mne_data/MNE-misc-data
- ~/mne_data/MNE-multimodal-data
- save_cache:
key: data-cache-5
paths:
- ~/mne_data/MNE-OPM-data
- ~/mne_data/MNE-phantom-4DBTi
- save_cache:
key: data-cache-6
paths:
- ~/mne_data/MNE-sample-data
- ~/mne_data/MNE-somato-data
- save_cache:
key: data-cache-7
paths:
- ~/mne_data/MNE-spm-face
- ~/mne_data/MNE-testing-ata
- save_cache:
key: data-cache-8
paths:
- ~/mne_data/MNE-visual_92_categories-data
- deploy:
name: Triage deployment
command: |
if [ "${CIRCLE_BRANCH}" == "master" ]; then
echo "Deploying dev docs.";
git config --global user.email "circle@mne.com";
git config --global user.name "Circle Ci";
pushd ~/mne-tools.github.io && git checkout master && git pull origin master && popd;
pushd doc/_build && rm -Rf ~/mne-tools.github.io/dev && cp -a html ~/mne-tools.github.io/dev && popd;
pushd ~/mne-tools.github.io && git add -A && git commit -m "CircleCI update of dev docs (${CIRCLE_BUILD_NUM})." && git push origin master && popd;
elif [ "${CIRCLE_BRANCH}" == "maint/0.17" ]; then
echo "Deploying stable docs.";
git config --global user.email "circle@mne.com";
git config --global user.name "Circle Ci";
pushd ~/mne-tools.github.io && git checkout master && git pull origin master && popd;
pushd doc/_build && rm -Rf ~/mne-tools.github.io/stable cp -a html_stable ~/mne-tools.github.io/stable && popd;
pushd ~/mne-tools.github.io && git add -A && git commit -m "CircleCI update of stable docs (${CIRCLE_BUILD_NUM})." && git push origin master && popd;
else
echo "No deployment (build: ${CIRCLE_BRANCH}).";
fi
# Contributing to MNE-Python
First off, thanks for taking the time to contribute!
The following is a quick summary to a set of guidelines for contributing to [MNE-Python](https://github.com/mne-python/mne-python) on GitHub. These are mostly guidelines, not rules. Use your best judgment, and feel free to propose changes to this document in a pull request.
## Code of Conduct
This project and everyone participating in it is governed by the [MNE-Python's Code of Conduct](CODE_OF_CONDUCT.md). By participating, you are expected to uphold this code. Please report unacceptable behavior to [mne-conduct@googlegroups.com](mailto:mne-conduct@googlegroups.com).
## How to contribute
Before contributing make sure you are familiar with [our contributing guide](https://martinos.org/mne/contributing.html).
---
name: Blank issue
about: Create an issue without a template.
---
---
name: Bug report
about: Create a report to help us improve.
---
Detailed instructions on how to file a bug can be found in our [FAQ](https://martinos.org/mne/stable/faq.html#i-think-i-found-a-bug-what-do-i-do).
If your issue is a usage question, please consider asking on our [Gitter channel](https://gitter.im/mne-tools/mne-python) or on our [mailing list](https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis) instead of opening an issue.
#### Describe the bug
Please provide a clear and concise description of the bug.
#### Steps and/or code to reproduce
Please provide a code snippet or [minimal working example (MWE)](https://en.wikipedia.org/wiki/Minimal_Working_Example)
to replicate your problem.
This MWE should be self-contained, which means that other MNE-Python contributors
should be able to copy and paste the provided snippet and replicate the bug.
If possible, use MNE-Python testing examples to reproduce the error. Otherwise,
provide a small and anonymized portion of your data required to reproduce the bug.
If the code is too long, feel free to put it in a [public gist](https://gist.github.com) and link
it in the issue.
Example:
```Python
import mne
fname = mne.datasets.sample.data_path() + '/MEG/sample/sample_audvis_raw.fif'
raw = mne.io.read_raw_fif(fname)
raw = mne.concatenate_raws([raw])
raw.save('test_raw.fif', overwrite=True)
raw_read = mne.io.read_raw_fif('test_raw.fif') # this breaks
```
#### Expected results
Provide a clear and concise description of what you expected to happen.
#### Actual results
Please paste or specifically describe the actual output or traceback.
#### Additional information
Paste the output of `mne.sys_info()` here.
---
name: Feature request
about: Suggest an idea for this project.
---
If your issue is a usage question, please consider asking on our [Gitter channel](https://gitter.im/mne-tools/mne-python) or on our [mailing list](https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis) instead of opening an issue.
#### Describe the problem
Please provide a clear and concise description of the problem.
#### Describe your solution
A clear and concise description of what you want to happen.
#### Describe possible alternatives
A clear and concise description of any alternative solutions or features you have considered.
#### Additional context
Add any other context or screenshots about the feature request here.
Thanks for contributing a pull request! Please make sure you have read the
[contribution guidelines](https://martinos.org/mne/stable/contributing.html)
before submitting.
Please be aware that we are a loose team of volunteers so patience is
necessary. Assistance handling other issues is very welcome. We value
all user contributions, no matter how minor they are. If we are slow to
review, either the pull request needs some benchmarking, tinkering,
convincing, etc. or more likely the reviewers are simply busy. In either
case, we ask for your understanding during the review process.
Again, thanks for contributing!
#### Reference issue
Example: Fixes #1234.
#### What does this implement/fix?
Explain your changes.
#### Additional information
Any additional information you think is important.
......@@ -41,6 +41,7 @@ MEGSIM*
build
coverage
.cache/
.pytest_cache/
dist/
doc/_build/
......@@ -64,3 +65,11 @@ examples/visualization/foobar.html
# sublime
*-e
# Visual Studio Code
.vscode
# Emacs
*.py#
*.rst#
Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> Alexandre Gramfort <alexandre.gramfort@inria.fr>
Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> Alexandre Gramfort <alexandre.gramfort@gmail.com>
Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> Alexandre Gramfort <alexandre.gramfort@m4x.org>
Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr> Alexandre Gramfort <gramfort@localhost.(none)>
Alexandre Gramfort <alexandre.gramfort@inria.fr> Alexandre Gramfort <alexandre.gramfort@telecom-paristech.fr>
Alexandre Gramfort <alexandre.gramfort@inria.fr> Alexandre Gramfort <alexandre.gramfort@inria.fr>
Alexandre Gramfort <alexandre.gramfort@inria.fr> Alexandre Gramfort <alexandre.gramfort@gmail.com>
Alexandre Gramfort <alexandre.gramfort@inria.fr> Alexandre Gramfort <alexandre.gramfort@m4x.org>
Alexandre Gramfort <alexandre.gramfort@inria.fr> Alexandre Gramfort <gramfort@localhost.(none)>
Martin Luessi <mluessi@nmr.mgh.harvard.edu> mluessi@nmr.mgh.harvard.edu <mluessi@nmr.mgh.harvard.edu>
Martin Luessi <mluessi@nmr.mgh.harvard.edu> martin <martin@think.hsd1.ma.comcast.net>
Martin Luessi <mluessi@nmr.mgh.harvard.edu> martin <martin@think.(none)>
......@@ -76,7 +77,9 @@ Jaakko Leppakangas <jaeilepp@gmail.com> jaeilepp <jaeilepp@gmail.com>
Jair Montoya <montoya.jair.m@gmail.com> jmontoyam <montoya.jair.m@gmail.com>
Natalie Klein <neklein@andrew.cmu.edu> natalieklein <neklein@andrew.cmu.edu>
Daniel McCloy <dan.mccloy@gmail.com> drammock <dan.mccloy@gmail.com>
Fede Raimondo <slashack@gmail.com> Fede <slashack@gmail.com>
Fede Raimondo <federaimondo@gmail.com> Fede <slashack@gmail.com>
Fede Raimondo <federaimondo@gmail.com> Fede Raimondo <fraimondo@dc.uba.ar>
Fede Raimondo <federaimondo@gmail.com> Fede Raimondo <federaimondo@gmail.com>
Emily Stephen <emilyps14@gmail.com> emilyps14 <emilyps14@gmail.com>
Marian Dovgialo <mdovgialo@fabrizzio.zfb.fuw.edu.pl>
Guillaume Dumas <deep@introspection.eu> deep-introspection <deep@introspection.eu>
......@@ -100,3 +103,18 @@ Mathurin Massias <mathurin.massias@gmail.com> mathurinm <mathurinm@users.noreply
Simon Kern <simon.kern@online.de> skjerns <simon.kern@online.de>
S. M. Gutstein <s.m.gutstein@gmail.com> smgutstein <s.m.gutstein@gmail.com>
Robin Tibor Schirrmeister <robintibor@gmail.com> robintibor <robintibor@gmail.com>
Anne-Sophie Dubarry <as_dub@hotmail.com> annesodub <as_dub@hotmail.com>
Claire Braboszcz <claire@guakamole.org> claire-braboszcz <claire@guakamole.org>
Larry Eisenman <leisenman@wustl.edu> lneisenman <lneisenman@hotmail.com>
Mathurin Massias <mathurin.massias@gmail.com> mathurinm <mathurin.massias@gmail.com>
Pierre Ablin <pierreablin@gmail.com> pierreablin <pierreablin@gmail.com>
Erik Hornberger <erik.hornberger@shi-g.com> er06645810 <erik.hornberger@shi-g.com>
Kostiantyn Maksymenko <makkostya@ukr.net> Maksymenko Kostiantyn <makkostya@ukr.net>
Nathalie Gayraud <nathalie.gayraud@inria.fr> Nathalie <nathalie.gayraud@inria.fr>
Dominik Krzemiński <raymon92@gmail.com> dokato <raymon92@gmail.com>
Ezequiel Mikulan <39155887+ezemikulan@users.noreply.github.com> ezemikulan <39155887+ezemikulan@users.noreply.github.com>
Hubert Banville <hubert.jbanville@gmail.com> hubertjb <hubert.jbanville@gmail.com>
Sara Sommariva <sommariva@dima.unige.it> sarasommariva <sommariva@dima.unige.it>
Manu Sutela <manu.sutela@gmail.com> MJAS1 <manu.sutela@gmail.com>
Joan Massich <mailsik@gmail.com> Joan Massich <sik@visor.udg.edu>
David Sabbagh <dav.sabbagh@gmail.com> DavidSabbagh <33925146+DavidSabbagh@users.noreply.github.com>
\ No newline at end of file
......@@ -3,75 +3,68 @@ dist: trusty
sudo: false
cache:
apt: true
pip: true
env:
# TRAVIS_PYTHON_VERSION is only needed for neo's setup.py
# OPENBLAS_NUM_THREADS=1 avoid slowdowns:
# https://github.com/xianyi/OpenBLAS/issues/731
global: PYTHON_VERSION=3.6 DISPLAY=:99.0 MNE_LOGGING_LEVEL=warning TEST_LOCATION=src
PIP_DEPENDENCIES="codecov pytest-faulthandler pytest-sugar" OPTION=""
TRAVIS_PYTHON_VERSION=3.6
PIP_DEPENDENCIES="codecov pytest-faulthandler" OPTION=""
TRAVIS_PYTHON_VERSION=3.6 CONDA_VERSION=">=4.3.27"
OPENBLAS_NUM_THREADS=1
matrix:
include:
# No data + style testing
- os: linux
env: DEPS=nodata MNE_DONTWRITE_HOME=true MNE_FORCE_SERIAL=true MNE_SKIP_NETWORK_TEST=1
CONDA_DEPENDENCIES="numpy scipy matplotlib sphinx nose pytest pytest-cov"
PIP_DEPENDENCIES="flake8 numpydoc codespell git+git://github.com/PyCQA/pydocstyle.git codecov check-manifest pytest-sugar"
CONDA_DEPENDENCIES="numpy scipy matplotlib sphinx pytest pytest-cov"
PIP_DEPENDENCIES="flake8 numpydoc codespell git+git://github.com/PyCQA/pydocstyle.git codecov check-manifest"
OPTION="--doctest-ignore-import-errors"
# Linux
- os: linux
env: CONDA_ENVIRONMENT="environment.yml"
SPLIT=0
- os: linux
env: CONDA_ENVIRONMENT="environment.yml"
SPLIT=1
# OSX
# OSX conda
- os: osx
env: CONDA_ENVIRONMENT="environment.yml"
SPLIT=0
- os: osx
env: CONDA_ENVIRONMENT="environment.yml"
SPLIT=1
# 2.7 + non-default stim channel
- os: linux
env: CONDA_ENVIRONMENT="environment2.yml" MNE_STIM_CHANNEL=STI101
SPLIT=0
# PIP + non-default stim channel
- os: linux
env: CONDA_ENVIRONMENT="environment2.yml" MNE_STIM_CHANNEL=STI101
SPLIT=1
env: MNE_STIM_CHANNEL=STI101
language: python
python: "3.6"
# 2.7 Old dependencies
- os: linux
env: PYTHON_VERSION=2.7
CONDA_DEPENDENCIES="numpy=1.8 scipy=0.12 matplotlib=1.3 pandas=0.12 scikit-learn=0.14 nose pytest pytest-cov"
SPLIT=0
- os: linux
env: PYTHON_VERSION=2.7
CONDA_DEPENDENCIES="numpy=1.8 scipy=0.12 matplotlib=1.3 pandas=0.12 scikit-learn=0.14 nose pytest pytest-cov"
SPLIT=1
CONDA_DEPENDENCIES="numpy=1.8 scipy=0.12 matplotlib=1.3 pandas=0.13 scikit-learn=0.15 pytest pytest-cov"
# Minimal
- os: linux
env: DEPS=minimial
CONDA_DEPENDENCIES="numpy scipy matplotlib nose pytest pytest-cov"
SPLIT=0
- os: linux
env: DEPS=minimial
CONDA_DEPENDENCIES="numpy scipy matplotlib nose pytest pytest-cov"
SPLIT=1
CONDA_DEPENDENCIES="numpy scipy matplotlib pytest pytest-cov"
# Setup anaconda
before_install:
- if [ "${TRAVIS_OS_NAME}" == "linux" ]; then
/sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -screen 0 1400x900x24 -ac +extension GLX +render -noreset;
fi;
- git clone https://github.com/astropy/ci-helpers.git
- source ci-helpers/travis/setup_conda.sh
- if [ ! -z $CONDA_ENVIRONMENT ]; then
- if [ -z "$CONDA_ENVIRONMENT" ] && [ -z "$CONDA_DEPENDENCIES" ]; then
pip uninstall -y numpy;
pip install numpy scipy vtk;
pip install -r requirements.txt;
else
git clone https://github.com/astropy/ci-helpers.git;
source ci-helpers/travis/setup_conda.sh;
if [ ! -z "$CONDA_ENVIRONMENT" ]; then
pip uninstall --yes mne;
fi;
if [ "${TRAVIS_OS_NAME}" == "osx" ]; then
pip install --upgrade pyqt5>=5.10;
fi;
fi
# Don't source mne_setup_sh here because changing PATH etc. can't be done in a script
- if [ "${DEPS}" == "" ]; then
export MNE_ROOT="${PWD}/minimal_cmds";
......@@ -88,6 +81,11 @@ before_install:
fi;
install:
# Rvm overrides cd with a function so that it can hook into it to run
# some scripts, see https://github.com/travis-ci/travis-ci/issues/8703
- if [ "${TRAVIS_OS_NAME}" == "osx" ]; then
unset -f cd;
fi;
# Suppress the parallel outputs for logging cleanliness
- python setup.py build
- python setup.py install
......@@ -144,28 +142,36 @@ script:
CONDITION='not ultraslowtest';
fi;
- python -c "import mne; print(mne.sys_info())"
# Determine directories to test
# Determine directories to test (could use SPLIT=0 SPLIT=1 but currently
# we are fast enough, so disable it)
- if [ -z ${SPLIT} ]; then
USE_DIRS="mne/";
else
if [ "${SPLIT}" == "0" ]; then
MNE_DIRS=". beamformer channels commands connectivity datasets decoding forward gui inverse_sparse io";
else
elif [ "${SPLIT}" == "1" ]; then
MNE_DIRS="minimum_norm preprocessing realtime simulation stats time_frequency viz";
elif [ "${SPLIT}" == "2" ]; then
MNE_DIRS=".";
else
MNE_DIRS="beamformer channels commands connectivity datasets decoding forward gui inverse_sparse io";
fi;
USE_DIRS="";
for DIR in ${MNE_DIRS}; do
USE_DIRS="mne/${DIR}/tests ${USE_DIRS}";
if [ "${DIR}" == "." ]; then
USE_DIRS="mne/tests mne/*.py ${USE_DIRS}";
else
USE_DIRS="mne/${DIR}/ ${USE_DIRS}";
fi;
done;
fi;
- echo py.test -m "${CONDITION}" ${OPTION} ${USE_DIRS} --cov=mne;
- py.test -m "${CONDITION}" ${OPTION} ${USE_DIRS} --cov=mne;
- if [ "${DEPS}" == "nodata" ]; then
make pep;
check-manifest --ignore doc,logo,mne/io/*/tests/data*,mne/io/tests/data,mne/preprocessing/tests/data;
fi;
after_success:
after_script:
# Need to run from source dir to exectue "git" commands
- cd ${SRC_DIR};
- codecov;
# Contributor Covenant Code of Conduct
## Our Pledge
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
## Our Standards
Examples of behavior that contributes to creating a positive environment include:
* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members
Examples of unacceptable behavior by participants include:
* The use of sexualized language or imagery and unwelcome sexual attention or advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a professional setting
## Our Responsibilities
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
## Scope
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
## Enforcement
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at mne-conduct@googlegroups.com. The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
## Attribution
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
[homepage]: http://contributor-covenant.org
[version]: http://contributor-covenant.org/version/1/4/
include *.rst
include LICENSE.txt
include requirements.txt
include mne/__init__.py
recursive-include examples *.py
......@@ -34,13 +35,22 @@ recursive-exclude examples/MNE-somato-data *
exclude Makefile
exclude .coveragerc
exclude *.yml
exclude dictionary.txt
exclude ignore_words.txt
exclude .mailmap
recursive-exclude mne *.pyc
recursive-exclude doc *
recursive-exclude logo *
exclude CODE_OF_CONDUCT.md
exclude .github
exclude .github/CONTRIBUTING.md
exclude .github/ISSUE_TEMPLATE
exclude .github/ISSUE_TEMPLATE/blank.md
exclude .github/ISSUE_TEMPLATE/bug_report.md
exclude .github/ISSUE_TEMPLATE/feature_request.md
exclude .github/PULL_REQUEST_TEMPLATE.md
# Test files
recursive-exclude mne/io/tests/data *
......
......@@ -5,7 +5,7 @@
PYTHON ?= python
PYTESTS ?= py.test
CTAGS ?= ctags
CODESPELL_SKIPS ?= "*.fif,*.eve,*.gz,*.tgz,*.zip,*.mat,*.stc,*.label,*.w,*.bz2,*.annot,*.sulc,*.log,*.local-copy,*.orig_avg,*.inflated_avg,*.gii,*.pyc,*.doctree,*.pickle,*.inv,*.png,*.edf,*.touch,*.thickness,*.nofix,*.volume,*.defect_borders,*.mgh,lh.*,rh.*,COR-*,FreeSurferColorLUT.txt,*.examples,.xdebug_mris_calc,bad.segments,BadChannels,*.hist,empty_file,*.orig,*.js,*.map,*.ipynb,searchindex.dat"
CODESPELL_SKIPS ?= "*.fif,*.eve,*.gz,*.tgz,*.zip,*.mat,*.stc,*.label,*.w,*.bz2,*.annot,*.sulc,*.log,*.local-copy,*.orig_avg,*.inflated_avg,*.gii,*.pyc,*.doctree,*.pickle,*.inv,*.png,*.edf,*.touch,*.thickness,*.nofix,*.volume,*.defect_borders,*.mgh,lh.*,rh.*,COR-*,FreeSurferColorLUT.txt,*.examples,.xdebug_mris_calc,bad.segments,BadChannels,*.hist,empty_file,*.orig,*.js,*.map,*.ipynb,searchindex.dat,install_mne_c.rst,plot_*.rst,*.rst.txt,c_EULA.rst*,*.html"
CODESPELL_DIRS ?= mne/ doc/ tutorials/ examples/
all: clean inplace test test-doc
......@@ -37,6 +37,8 @@ sample_data:
testing_data:
@python -c "import mne; mne.datasets.testing.data_path(verbose=True);"
pytest: test
test: in
rm -f .coverage
$(PYTESTS) -m 'not ultraslowtest' mne
......@@ -97,21 +99,31 @@ flake:
@echo "flake8 passed"
codespell: # running manually
@codespell -w -i 3 -q 3 -S $(CODESPELL_SKIPS) -D ./dictionary.txt $(CODESPELL_DIRS)
@codespell -w -i 3 -q 3 -S $(CODESPELL_SKIPS) --ignore-words=ignore_words.txt $(CODESPELL_DIRS)
codespell-error: # running on travis
@codespell -i 0 -q 7 -S $(CODESPELL_SKIPS) -D ./dictionary.txt $(CODESPELL_DIRS)
@codespell -i 0 -q 7 -S $(CODESPELL_SKIPS) --ignore-words=ignore_words.txt $(CODESPELL_DIRS)
pydocstyle:
@echo "Running pydocstyle"
@pydocstyle
@pydocstyle mne
docstring:
@echo "Running docstring tests"
@$(PYTESTS) --doctest-modules mne/tests/test_docstring_parameters.py
check-manifest:
check-manifest --ignore .circleci*,doc,logo,mne/io/*/tests/data*,mne/io/tests/data,mne/preprocessing/tests/data,.DS_Store
check-readme:
python setup.py check --restructuredtext --strict
nesting:
@echo "Running import nesting tests"
@$(PYTESTS) mne/tests/test_import_nesting.py
pep:
@$(MAKE) -k flake pydocstyle docstring codespell-error
@$(MAKE) -k flake pydocstyle docstring codespell-error check-manifest nesting check-readme
manpages:
@echo "I: generating manpages"
......@@ -131,5 +143,4 @@ build-doc-stable:
cd doc; make clean
cd doc; DISPLAY=:1.0 xvfb-run -n 1 -s "-screen 0 1280x1024x24 -noreset -ac +extension GLX +render" make html_stable
docstyle:
@pydocstyle
docstyle: pydocstyle
......@@ -6,9 +6,9 @@
|MNE|_
.. |Travis| image:: https://api.travis-ci.org/mne-tools/mne-python.png?branch=master
.. _Travis: https://travis-ci.org/mne-tools/mne-python
.. _Travis: https://travis-ci.org/mne-tools/mne-python/branches
.. |Appveyor| image:: https://ci.appveyor.com/api/projects/status/7isroetnxsp7hgxv/branch/master?svg=true
.. |Appveyor| image:: https://ci.appveyor.com/api/projects/status/jg8ncqql9wayo8mg/branch/master?svg=true
.. _Appveyor: https://ci.appveyor.com/project/mne-tools/mne-python/branch/master
.. |Circle| image:: https://circleci.com/gh/mne-tools/mne-python.svg?style=svg
......@@ -20,84 +20,94 @@
.. |Zenodo| image:: https://zenodo.org/badge/5822/mne-tools/mne-python.svg
.. _Zenodo: https://zenodo.org/badge/latestdoi/5822/mne-tools/mne-python
.. |MNE| image:: http://mne-tools.github.io/dev/_static/mne_logo.png
.. _MNE: https://mne-tools.github.io
.. |MNE| image:: https://martinos.org/mne/stable/_static/mne_logo.png
.. _MNE: https://martinos.org/mne
`MNE-Python <http://mne-tools.github.io/>`_
=======================================================
MNE-Python
==========
This package is designed for sensor- and source-space analysis of [M/E]EG
data, including frequency-domain and time-frequency analyses, MVPA/decoding
and non-parametric statistics. This package generally evolves quickly and
user contributions can easily be incorporated thanks to the open
development environment .
`MNE-Python software`_ is an open-source Python package for exploring,
visualizing, and analyzing human neurophysiological data such as MEG, EEG, sEEG,
ECoG, and more. It includes modules for data input/output, preprocessing,
visualization, source estimation, time-frequency analysis, connectivity analysis,
machine learning, and statistics.
Get more information
^^^^^^^^^^^^^^^^^^^^
If you're unfamiliar with MNE, you can visit the
`MNE homepage <http://mne-tools.github.io/>`_ for full user documentation.
Documentation
^^^^^^^^^^^^^
`MNE documentation`_ for MNE-Python is available online.
Get the latest code
^^^^^^^^^^^^^^^^^^^
To get the latest code using `git <https://git-scm.com/>`_, simply type:
Installing MNE-Python
^^^^^^^^^^^^^^^^^^^^^
To install the latest stable version of MNE-Python, you can use pip_ in a terminal:
.. code-block:: bash
$ git clone git://github.com/mne-tools/mne-python.git
pip install -U mne
If you don't have git installed, you can download a
`zip of the latest code <https://github.com/mne-tools/mne-python/archive/master.zip>`_.
**Note** that MNE-Python 0.17 will be the last release to support Python 2. From MNE-Python 0.18, only Python 3 will be supported.
Install MNE-python
^^^^^^^^^^^^^^^^^^
For more complete instructions and more advanced installation methods (e.g. for
the latest development version), see the `getting started page`_.
As with most Python packages, to install the latest stable version of
MNE-Python, you can do:
Get the latest code
^^^^^^^^^^^^^^^^^^^
To install the latest version of the code using pip_ open a terminal and type:
.. code-block:: bash
$ pip install mne
pip install -U https://api.github.com/repos/mne-tools/mne-python/zipball/master
To get the latest code using `git <https://git-scm.com/>`__, open a terminal and type:
.. code-block:: bash
git clone git://github.com/mne-tools/mne-python.git
Alternatively, you can also download a
`zip file of the latest development version <https://github.com/mne-tools/mne-python/archive/master.zip>`__.
For more complete instructions and more advanced install methods (e.g. for
the latest development version), see the
`getting started page <http://mne-tools.github.io/stable/getting_started.html>`_
page.
Dependencies
^^^^^^^^^^^^
The minimum required dependencies to run the software are:
The minimum required dependencies to run MNE-Python are:
- Python >= 2.7
- NumPy >= 1.8
- SciPy >= 0.12
- matplotlib >= 1.3
For full functionality, some functions require:
- scikit-learn >= 0.18
- nibabel >= 2.1.0
- pandas >= 0.12
- Matplotlib >= 1.3
- Mayavi >= 4.6
- PySurfer >= 0.8
- Scikit-learn >= 0.15 (>= 0.18 recommended)
- NiBabel >= 2.1.0
- Pandas >= 0.13
- Picard >= 0.3
- CuPy >= 4.0 (for NVIDIA CUDA acceleration)
- DIPY >= 0.10.1
To use NVIDIA CUDA for resampling and FFT FIR filtering, you will also need
to install the NVIDIA CUDA SDK, pycuda, and scikits.cuda. See the
`getting started page <http://mne-tools.github.io/stable/getting_started.html>`_
for more information.
Contributing to MNE-Python
^^^^^^^^^^^^^^^^^^^^^^^^^^
Contribute to MNE-python
^^^^^^^^^^^^^^^^^^^^^^^^
Please see the documentation on the MNE-Python homepage:
Please see the documentation on the MNE-python homepage:
https://martinos.org/mne/contributing.html
http://martinos.org/mne/contributing.html
Mailing list
^^^^^^^^^^^^
http://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
Licensing
^^^^^^^^^
......@@ -106,7 +116,7 @@ MNE-Python is **BSD-licenced** (3 clause):
This software is OSI Certified Open Source Software.
OSI Certified is a certification mark of the Open Source Initiative.
Copyright (c) 2011, authors of MNE-Python
Copyright (c) 2011-2017, authors of MNE-Python.
All rights reserved.
Redistribution and use in source and binary forms, with or without
......@@ -135,3 +145,10 @@ MNE-Python is **BSD-licenced** (3 clause):
(including negligence or otherwise) arising in any way out of the use
of this software, even if advised of the possibility of such
damage.**
.. _MNE-Python software: https://martinos.org/mne
.. _MNE documentation: http://martinos.org/mne/documentation.html
.. _getting started page: https://martinos.org/mne/getting_started.html
.. _pip: https://pip.pypa.io/en/stable/
......@@ -4,7 +4,7 @@ environment:
CONDA_ENVIRONMENT: "environment.yml"
PIP_DEPENDENCIES: "codecov pytest-faulthandler"
matrix:
- PYTHON_VERSION: "2.7"
- PYTHON_VERSION: "3.6"
PYTHON_ARCH: "64"
install:
......
......@@ -23,6 +23,7 @@ def print_help():
print("\nGetting help example : mne compute_proj_eog -h")
sys.exit(0)
if len(sys.argv) == 1:
print_help()
elif ("help" in sys.argv[1] or "-h" in sys.argv[1]):
......
machine:
environment:
# We need to set this variable to let Anaconda take precedence
PATH: "/home/ubuntu/miniconda/envs/circleenv/bin:/home/ubuntu/miniconda/bin:$PATH"
DISPLAY: ":99.0"
# We should really build merged versions like on Travis, not the individual branches
# Adapted from:
# https://gist.github.com/amacneil/f14db753919e0af2d7d2f5a8da7fce65
checkout:
post:
- echo $(git log -1 --pretty=%B) > gitlog.txt
- echo ${CI_PULL_REQUEST//*pull\//} > merge.txt
- if [[ $(cat merge.txt) != "" ]]; then
echo "Merging $(cat merge.txt)";
git pull --ff-only origin "refs/pull/$(cat merge.txt)/merge";
fi
dependencies:
cache_directories:
- "~/miniconda"
- "~/.mne"
- "~/mne_data/HF_SEF"
- "~/mne_data/MNE-sample-data"
- "~/mne_data/MNE-testing-data"
- "~/mne_data/MNE-misc-data"
- "~/mne_data/MNE-spm-face"
- "~/mne_data/MNE-somato-data"
- "~/mne_data/MNE-brainstorm-data"
- "~/mne_data/MEGSIM"
- "~/mne_data/MNE-eegbci-data"
- "~/mne_data/mTRF_1.5"
- "~/mne_data/MNE-fieldtrip_cmc-data"
- "~/mne-tools.github.io"
# Various dependencies
pre:
# Get a running Python
- cd ~;
# Disable pyenv (no cleaner way provided by CircleCI as it prepends pyenv version to PATH)
- rm -rf ~/.pyenv;
- rm -rf ~/virtualenvs;
# Get Anaconda and conda-based requirements
- >
if [ ! -d "/home/ubuntu/miniconda" ]; then
echo "Setting up conda";
wget -q http://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O ~/miniconda.sh;
chmod +x ~/miniconda.sh;
~/miniconda.sh -b -p /home/ubuntu/miniconda;
conda update --yes --quiet conda;
else
echo "Conda already set up.";
fi
- if ! conda env list | grep circleenv; then
conda create -n circleenv --yes pip python=2.7 pip;
sed -i "s/ENABLE_USER_SITE = .*/ENABLE_USER_SITE = False/g" /home/ubuntu/miniconda/envs/circleenv/lib/python2.7/site.py;
else
echo "Conda env already set up.";
fi;
- conda install -n circleenv --yes numpy scipy scikit-learn matplotlib sphinx pillow six IPython pandas mayavi nose;
- ls -al /home/ubuntu/miniconda;
- ls -al /home/ubuntu/miniconda/bin;
- echo $PATH;
- echo $CIRCLE_BRANCH
- which python;
- which pip;
- cat /home/ubuntu/miniconda/envs/circleenv/lib/python2.7/site.py | grep "ENABLE_USER_SITE"
- pip install --upgrade pyface;
- pip install --upgrade git+https://github.com/enthought/mayavi.git
- git clone https://github.com/sphinx-gallery/sphinx-gallery.git;
- cd sphinx-gallery && pip install -r requirements.txt && python setup.py develop;
- pip install sphinx_bootstrap_theme pysurfer nilearn neo numpydoc;
override:
# Figure out if we should run a full, pattern, or noplot version
- cd /home/ubuntu/mne-python && python setup.py develop;
- if ! git remote -v | grep upstream ; then git remote add upstream git://github.com/mne-tools/mne-python.git; fi;
- git fetch upstream;
- git branch -a;
- mkdir -p ~/mne_data;
- if [[ $(cat gitlog.txt) == *"[circle front]"* ]]; then
PATTERN="plot_mne_dspm_source_localization.py\|plot_receptive_field.py\|plot_mne_inverse_label_connectivity.py\|plot_sensors_decoding.py\|plot_stats_cluster_spatio_temporal.py\|plot_visualize_evoked.py\|";
else
PATTERN="";
fi;
if [ "$CIRCLE_BRANCH" == "master" ] || [[ $(cat gitlog.txt) == *"[circle full]"* ]]; then
echo html_dev > build.txt;
elif [ "$CIRCLE_BRANCH" == "maint/0.15" ]; then
echo html_stable > build.txt;
else
FNAMES=$(git diff --name-only $CIRCLE_BRANCH $(git merge-base $CIRCLE_BRANCH upstream/master));
echo FNAMES="$FNAMES";
for FNAME in $FNAMES; do
if [[ `expr match $FNAME "\(tutorials\|examples\)/.*plot_.*\.py"` ]] ; then
echo "Checking example $FNAME ...";
PATTERN=`basename $FNAME`"\\|"$PATTERN;
if [[ $(cat $FNAME | grep -x ".*datasets.*sample.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.sample.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*spm_face.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.spm_face.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*somato.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.somato.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*eegbci.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.eegbci.load_data(1, [6, 10, 14], update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*hf_sef.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.hf_sef.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*brainstorm.*bst_auditory.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.brainstorm.bst_auditory.data_path(update_path=True))" --accept-brainstorm-license;
fi;
if [[ $(cat $FNAME | grep -x ".*brainstorm.*bst_raw.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.brainstorm.bst_raw.data_path(update_path=True))" --accept-brainstorm-license;
fi;
if [[ $(cat $FNAME | grep -x ".*brainstorm.*bst_phantom_ctf.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.brainstorm.bst_phantom_ctf.data_path(update_path=True))" --accept-brainstorm-license;
fi;
if [[ $(cat $FNAME | grep -x ".*brainstorm.*bst_phantom_elekta.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.brainstorm.bst_phantom_elekta.data_path(update_path=True))" --accept-brainstorm-license;
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*megsim.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.megsim.load_data(condition='visual', data_format='single-trial', data_type='simulation', update_path=True))";
python -c "import mne; print(mne.datasets.megsim.load_data(condition='visual', data_format='raw', data_type='experimental', update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*hcp_mmp_parcellation.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.sample.data_path(update_path=True))";
SUBJECTS_DIR=~/mne_data/MNE-sample-data/subjects python -c "import mne; print(mne.datasets.fetch_hcp_mmp_parcellation())" --accept-hcpmmp-license;
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*misc.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.misc.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*mtrf.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.mtrf.data_path(update_path=True))";
fi;
if [[ $(cat $FNAME | grep -x ".*datasets.*fieldtrip_cmc.*" | wc -l) -gt 0 ]]; then
python -c "import mne; print(mne.datasets.fieldtrip_cmc.data_path(update_path=True))";
fi;
fi;
done;
echo PATTERN="$PATTERN";
echo NEED_SAMPLE="$NEED_SAMPLE";
if [[ $PATTERN ]]; then
PATTERN="\(${PATTERN::-2}\)";
echo html_dev-pattern > build.txt;
else
echo html_dev-noplot > build.txt;
fi;
fi;
echo "$PATTERN" > pattern.txt;
- echo BUILD="$(cat build.txt)"
- ls -al ~/mne_data;
- if [[ $(cat build.txt) == "html_dev" ]] || [[ $(cat build.txt) == "html_stable" ]]; then
SUBJECTS_DIR=/home/ubuntu/mne_data/MNE-sample-data/subjects python -c "import mne; mne.datasets._download_all_example_data()";
fi;
- python -c "import mne; mne.sys_info()";
- >
if [ ! -d "/home/ubuntu/mne-tools.github.io" ]; then
cd .. && git clone https://github.com/mne-tools/mne-tools.github.io.git && cd mne-tools.github.io;
fi;
- /sbin/start-stop-daemon --start --quiet --pidfile /tmp/custom_xvfb_99.pid --make-pidfile --background --exec /usr/bin/Xvfb -- :99 -screen 0 1400x900x24 -ac +extension GLX +render -noreset;
test:
override:
# Mayavi can bomb on exit (yay!), turning a successful build into a failure.
# We thus tee into a log (which returns 0) and then parse afterward for
# what immediately precedes the "Build finished." line.
- if [[ $(cat build.txt) == "html_dev-noplot" ]]; then cd doc && make html_dev-noplot | tee $CIRCLE_ARTIFACTS/log.txt; elif [[ $(cat build.txt) == "html_dev-pattern" ]]; then cd doc && PATTERN=$(cat ../pattern.txt) make html_dev-pattern | tee $CIRCLE_ARTIFACTS/log.txt; else make test-doc; cd doc; make $(cat ../build.txt) | tee $CIRCLE_ARTIFACTS/log.txt; fi:
timeout: 1500
- tail $CIRCLE_ARTIFACTS/log.txt | grep -E "auto_tutorials\s*\[100%\]\s*plot_|Build finished"
post:
- if [[ $(cat build.txt) == "html_stable" ]]; then
cp -a doc/_build/html_stable $CIRCLE_ARTIFACTS/;
else
cp -a doc/_build/html $CIRCLE_ARTIFACTS/;
fi;
deployment:
production:
branch: master
commands:
- git config --global user.email "circle@mne.com"
- git config --global user.name "Circle Ci"
- cd ../mne-tools.github.io && git checkout master && git pull origin master
- cd doc/_build && rm -Rf ~/mne-tools.github.io/dev && cp -a html ~/mne-tools.github.io/dev
- cd ../mne-tools.github.io && git add -A && git commit -m 'Automated update of dev docs.' && git push origin master
stable:
branch: maint/0.15
commands:
- git config --global user.email "circle@mne.com"
- git config --global user.name "Circle Ci"
- cd ../mne-tools.github.io && git checkout master && git pull origin master
- cd doc/_build && rm -Rf ~/mne-tools.github.io/stable && cp -a html_stable ~/mne-tools.github.io/stable
- cd ../mne-tools.github.io && git add -A && git commit -m 'Automated update of stable docs.' && git push origin master
python-mne (0.17+dfsg-1) UNRELEASED; urgency=medium
* Team upload.
* New upstream version
* debhelper 11
* Point Vcs fields to salsa.debian.org
* Standards-Version: 4.2.1
* Testsuite: autopkgtest-pkg-python
-- Andreas Tille <tille@debian.org> Wed, 19 Dec 2018 09:05:00 +0100
python-mne (0.15.2+dfsg-2) unstable; urgency=medium
* up_check_numpy to skip a test for warnings being issued with
......
......@@ -4,8 +4,9 @@ Uploaders: Alexandre Gramfort <alexandre.gramfort@m4x.org>,
Yaroslav Halchenko <debian@onerussian.com>,
Michael Hanke <michael.hanke@gmail.com>
Section: python
Testsuite: autopkgtest-pkg-python
Priority: optional
Build-Depends: debhelper (>= 10),
Build-Depends: debhelper (>= 11~),
python-all,
python-nibabel,
python-numpy,
......@@ -27,9 +28,9 @@ Build-Depends: debhelper (>= 10),
libjs-jquery,
libjs-jquery-ui,
yui-compressor
Standards-Version: 3.9.8
Vcs-Browser: https://anonscm.debian.org/cgit/debian-med/python-mne.git
Vcs-Git: https://anonscm.debian.org/git/debian-med/python-mne.git
Standards-Version: 4.2.1
Vcs-Browser: https://salsa.debian.org/med-team/python-mne
Vcs-Git: https://salsa.debian.org/med-team/python-mne.git
Homepage: http://martinos.org/mne
X-Python-Version: >= 2.7
......
......@@ -6,16 +6,7 @@ Reviewed-By: Yaroslav O. Halchenko <debian@onerussian.com>
--- a/mne/report.py
+++ b/mne/report.py
@@ -30,7 +30,7 @@ from .parallel import parallel_func, che
from .externals.tempita import HTMLTemplate, Template
from .externals.six import BytesIO
-from .externals.six import moves
+from .externals.six import moves, PY3
VALID_EXTENSIONS = ['raw.fif', 'raw.fif.gz', 'sss.fif', 'sss.fif.gz',
'-eve.fif', '-eve.fif.gz', '-cov.fif', '-cov.fif.gz',
@@ -1201,21 +1201,27 @@ class Report(object):
@@ -1359,21 +1359,27 @@ class Report(object):
@verbose
def _init_render(self, verbose=None):
"""Initialize the renderer."""
......