Closed christianbrodbeck closed 11 years ago
@christianmbrodbeck .. it seems like we have to update the sample dataset again. Can you verify that the tests work with this one:
http://martinos.org/~mluessi/MNE-sample-data-processed.tar.gz
Your issue with running mri_info
is probably caused by you having "FREESURFER_HOME" defined, but not having the executables (such as mri_info
) runnable from Python. I wonder if we can just directly check if mri_info
is in the PATH somewhere...
And I'm not sure how you can be missing the -7
sensitivity map, assuming these lines ran correctly:
https://github.com/mne-tools/mne-scripts/blob/master/sample-data/run_meg_tutorial.sh#L112
Maybe you silently hit an error while running the script? You should try running those lines manually to see if it's hitting an error, so we can fix it. Otherwise, where is the file output going...?
The first error is just strange. Perhaps you can make a copy of the volume inverse operator /before/ running mne-scripts, and then upload the before and after versions somewhere? That way we could use viz.show_diff
(or whatever I called it) to look at the differences between the files.
Thanks! The only error that remains after updating the sample dataset is the last one:
ERROR: Test equivalence of vert_to_mni for nibabel and freesurfer
----------------------------------------------------------------------
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/7.3/lib/python2.7/site-packages/nose/case.py", line 197, in runTest
self.test(*self.arg)
File "/Library/Frameworks/Python.framework/Versions/7.3/lib/python2.7/site-packages/numpy/testing/decorators.py", line 146, in skipper_func
return f(*args, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/7.3/lib/python2.7/site-packages/numpy/testing/decorators.py", line 146, in skipper_func
return f(*args, **kwargs)
File "/Users/christian/Documents/Eclipse/projects/mne-python/mne/tests/test_source_space.py", line 100, in test_vertex_to_mni_fs_nibabel
coords_2 = vertex_to_mni(vertices, hemis, subject, mode='freesurfer')
File "/Users/christian/Documents/Eclipse/projects/mne-python/mne/utils.py", line 323, in dec
return function(*args, **kwargs)
File "/Users/christian/Documents/Eclipse/projects/mne-python/mne/source_space.py", line 679, in vertex_to_mni
xfm = _read_talxfm(subject, subjects_dir, mode)
File "/Users/christian/Documents/Eclipse/projects/mne-python/mne/utils.py", line 323, in dec
return function(*args, **kwargs)
File "/Users/christian/Documents/Eclipse/projects/mne-python/mne/source_space.py", line 752, in _read_talxfm
stdout, stderr = run_subprocess(['mri_info', conv, path])
File "/Users/christian/Documents/Eclipse/projects/mne-python/mne/utils.py", line 172, in run_subprocess
p = subprocess.Popen(command, *args, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/7.3/lib/python2.7/subprocess.py", line 679, in __init__
errread, errwrite)
File "/Library/Frameworks/Python.framework/Versions/7.3/lib/python2.7/subprocess.py", line 1249, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
-------------------- >> begin captured stdout << ---------------------
Running subprocess: ['mri_info', '--vox2ras', u'/Users/christian/Documents/Eclipse/projects/mne-python/examples/MNE-sample-data/subjects/sample/mri/orig.mgz']
--------------------- >> end captured stdout << ----------------------
-------------------- >> begin captured logging << --------------------
mne: INFO: Running subprocess: ['mri_info', '--vox2ras', u'/Users/christian/Documents/Eclipse/projects/mne-python/examples/MNE-sample-data/subjects/sample/mri/orig.mgz']
--------------------- >> end captured logging << ---------------------
@christianmbrodbeck I assume that the "/Users/christian/Documents/Eclipse/projects/mne-python/examples/MNE-sample-data/subjects/sample/mri/orig.mgz" exists, thus it's an issue with not having mri_info
even though FREESURFER_HOME
is defined. This is pathological behavior, since having FREESURFER_HOME
defined should imply freesurfer functions are available... either that or we're not testing for FREESURFER_HOME
existence correctly.
And I'd still like to see why your install makes an incompatible volume inverse operator. It would be good to sort that out.
@Eric89GXL the dataset on the FTP server does not yet include the sensitivity maps (the one linked above does) so it needs to be updated.
@mluessi yeah I know, but @christianmbrodbeck said that he ran all of the latest scripts, which should have generated the sensitivity maps, thus my confusion why they weren't there.
I assume that the "/Users/christian/Documents/Eclipse/projects/mne-python/examples/MNE-sample-data/subjects/sample/mri/orig.mgz" exists, thus it's an issue with not having mri_info even though FREESURFER_HOME is defined
How would I test that? From the same shell that I run the tests from:
$ mri_info --vox2ras /Users/christian/Documents/Eclipse/projects/mne-python/examples/MNE-sample-data/subjects/sample/mri/orig.mgz
-1.00000 0.00000 -0.00000 122.72638
0.00000 0.00000 1.00000 -118.96091
0.00000 -1.00000 0.00000 100.71201
0.00000 0.00000 0.00000 1.00000
And I'd still like to see why your install makes an incompatible volume inverse operator
I'm running the mne-scripts on the new sample data and will let you know the outcome
You could open up Python and do:
import mne
mne.utils.run_subprocess('mri_info')
And you should get:
subprocess.CalledProcessError: Command 'mri_info' returned non-zero exit status 1
because it runs, but gives a non-zero exit status. If you instead get the OSError
file not found, then Freesurfer must not be configured correctly, despite having FREESURFER_HOME
defined.
Also, you could try:
import os
print 'FREESURFER_HOME' in os.environ
print os.getenv('FREESURFER_HOME') + '/bin' in os.getenv('PATH').split(os.pathsep)
which should say True
for both if Freesurfer is configured correctly.
Yes, after running the mne-scripts I get the ERROR: Test MNE inverse computation on volume source space
again. Here is the sample_audvis-meg-vol-7-meg-inv.fif produced by the mne-scripts on my computer. Can you work with that, or do you need more files?
On the other hand, the Freesurfer problem seems to be that Python does not interpret ~
in the path. If I replace ~
with the full path in my PATH variable the mri_info
related error disappears! Is this a known issue/feature?
@christianmbrodbeck I'm looking at your file now, I'll see if I can find a relevant difference.
I'm not sure about the ~
issue. My guess is that's the tilde is a bash shell expansion feature, and thus will only be recognized by shell scripts. os.abspath()
should also know how to interpret it correctly. I'm not sure if we can correct for it easily...
Looks like your version does indeed do something different from what @mluessi and my versions do. Specifically, it doesn't put the 353 = FIFFB_MNE_PARENT_MRI_FILE
entry in the source space file. Are you using an older version of MNE? We can probably avoid throwing the error here, since we should maintain backward compatibility in any case.
We could make a copy of os.environ for run_subprocess()
and apply os.abspath() to all entries in the ['PATH'] entry. Unless it is actually not proper to use ~
in the PATH environment variable(?)
I'm using MNE-2.7.3 (SVN revision 3268)
@christianmbrodbeck I think it's more standard to use $HOME
instead of ~
to avoid issues like this (the $HOME
should be expanded immediately, whereas the ~
may not be), but I'm not the biggest Bash expert.
As far as the volume inverse error goes, supporting that version of MNE might be a bit of a pain, but we should probably make it work since it was the last stable release.
@christianmbrodbeck you should run the nightly built as we needed with matti some new stuff to make it work 2 years ago. Don't worry there are no big changes between your version and the nightly build.
@agramfort shouldn't we make it so that volume source spaces work with the last stable MNE build? Or are these broken in some way? It looks like it should be possible to pull the trans from higher up in the FIFF file...
So we could check whether "~"
is in os.environ['PATH'], and if so issue a warning and suggest using "$HOME"
?
Re-running the scripts with the nightly build now...
I'm not sure what the best course of action is. It should be a pretty isolated set of cases that we're going to hit, so I'm not too concerned about it.
@christianmbrodbeck the one remaining thing I don't understand is why you running the mne-scripts didn't produce the -7
version of the sensitivity maps, because it should have.
So, after rectifying the PATH and re-running the mne-scripts with the nightly MNE I can now run the tests without errors :)
Great, might as well close this issue, then. (@agramfort can comment on my related PR separately.)
Closing, thanks for the help!
I have a related question (as I too get failing unit tests), hence posting it here. I downloaded the latest dataset from the link provided in this thread, used the MNE-nightly and then ran the mne-scripts. I run into the following error:
mkheadsurf done mne_surf2bem: error while loading shared libraries: libgfortran.so.1: cannot open shared object file: No such file or directory mne_make_morph_maps: error while loading shared libraries: libgfortran.so.1: cannot open shared object file: No such file or directory mne_make_morph_maps: error while loading shared libraries: libgfortran.so.1: cannot open shared object file: No such file or directory mne_make_morph_maps: error while loading shared libraries: libgfortran.so.1: cannot open shared object file: No such file or directory
I checked and it appears that I have a later version of this library: libgfortran.so.3 but mne does not appear to accept that. Is there a way around this? Thanks!
take the lib from there:
https://dl.dropboxusercontent.com/u/2140486/libgfortran.so.1
I unfortunately did not find a way to fix the nightly build to avoid the problem.
Thanks a lot @agramfort ! Checking with the new libraries now ...
getting closer ... just the forward solution doesn't seem to work now. this is how the output for the unit tests looks like: http://neuro.hut.fi/~mainak/unit_tests.txt . I don't have NVidia graphics card or CUDA, so that is fine, but there are still two failures and one error (which appear to be different from those described above). Do you know how I should resolve this? Thanks!
this one is really weird. Does it work if you replace the broken file with the one from the martinos download? it's a forward operator.
That's funny: I replaced the file sample_audvis-meg-oct-6-fwd.fif
from the martinos download and the I/O unit test: "Test IO for forward solutions ..." now passes. But the other two issues still remain, i.e: "Test making forward solution from python ... FAIL" and "Test reading labels from parc. by comparing with mne_annot2labels ... ERROR". Do I need to replace any other file?
ps: I do not have OpenGL installed - could that be an issue for MNE? I thought that was only required if I wanted GUI ...
@mainakjas it seems like the MNE command line are not in your path but the MNE_ROOT
environment variable is set. Those tests will only be executed if this environment variable is set. Have a look at requires_mne
in utils.py
.
@mluessi I called utils.has_command_line_tools()
and it returned True
. Here is what I have added to my bashrc file:
` export FREESURFER_HOME=/host/Users/Mainak/Desktop/Python/GSoc/Tools/freesurfer source $FREESURFER_HOME/SetUpFreeSurfer.sh
export MNE_ROOT=/home/mainak/MNE . $MNE_ROOT/bin/mne_setup_sh `
Does this look ok? No Matlab as of now, but I can install if required. So, I do appear to have MNE command line tools paths setup correctly ... or did you mean something else?
@mainakjas this does look correct. Can you run the MNE commands from the command line? Also, remember that you will need to open a new shell for the changes in .bashrc to be applied.
I recon you need to do source $MNE_ROOT/bin/mne_setup_sh
instead of just running it.
@mluessi I tried running mne_browse_raw
from the command line and it did open the GUI. I am not too familiar with these tools, but I reckon that should be enough?
@Eric89GXL : Tried that too! stays the same. I still get the one FAIL and one ERROR.
wait, I just noticed this on the command line when I opened mne_browse_raw
:
mainak@ubuntu:~/mne-python$ mne_browse_raw Using a 4096-point FFT in filtering of raw data with 2048-sample tapers bandpass = 0.0 ( 0.0) ... 40.0 ( 5.0) Hz filter is on 64-bit architecture. Using 600.00 Mbytes for ring buffers Warning: Cannot convert string "-adobe-helvetica-medium-r-normal--14-*-iso8859-1" to type FontStruct Warning: Cannot convert string "-adobe-helvetica-bold-r-normal--14-*-iso8859-1" to type FontStruct 24 selections loaded from /home/mainak/MNE/share/mne/mne_browse_raw/mne_browse_raw.sel Current selection is Vertex Initial settings data created.
Does this provide any clues?
@mainakjas the mne_browse_raw
output looks fine. In the same shell from where you are running the nosetests, can you run mne_annot2labels
and see if it works.
This is what I get:
mainak@ubuntu:~/mne-python$ mne_annot2labels usage: mne_annot2labels [options] Convert parcellation data to labels. Label files will be output in the current directory --parc name Name of the parcellation. --subject name The subject. --help print this info. --version print version info.
I am just wondering if this could be an issue with the file permissions in freesurfer somehow (because I have that in host -- the linux is a wubi install). Copying freesurfer into home directory to check if it works with that ...
hum strange. could you try to reproduce the problem with a minimal number of lines of code?
copying freesurfer into home directory didn't help - so nothing with permissions etc. @agramfort I'll try that and get back. Should be a good exercise as such.
@agramfort : I was trying to reproduce the FAIL but now after I reinstalled the operating system, I no longer get the FAIL. There is an ERROR in its place.
======================================================================
ERROR: Test making forward solution from python
----------------------------------------------------------------------
Traceback (most recent call last):
File "/usr/local/lib/python2.7/dist-packages/nose/case.py", line 197, in runTest
self.test(*self.arg)
File "/usr/local/lib/python2.7/dist-packages/numpy/testing/decorators.py", line 146, in skipper_func
return f(*args, **kwargs)
File "/home/mainakjas/github/mne-python/mne/tests/test_forward.py", line 256, in test_do_forward_solution
subjects_dir=subjects_dir, overwrite=True)
File "/home/mainakjas/github/mne-python/mne/utils.py", line 308, in dec
return function(*args, **kwargs)
File "/home/mainakjas/github/mne-python/mne/forward.py", line 1404, in do_forward_solution
fwd = read_forward_solution(op.join(path, fname))
File "/home/mainakjas/github/mne-python/mne/utils.py", line 308, in dec
return function(*args, **kwargs)
File "/home/mainakjas/github/mne-python/mne/forward.py", line 330, in read_forward_solution
fid, tree, _ = fiff_open(fname)
File "/home/mainakjas/github/mne-python/mne/utils.py", line 308, in dec
return function(*args, **kwargs)
File "/home/mainakjas/github/mne-python/mne/fiff/open.py", line 50, in fiff_open
fid = open(fname, "rb") # Open in binary mode
IOError: [Errno 2] No such file or directory: '/tmp/tmpSLZYFu/temp-fwd.fif'
It is clear that the problem is that the temporary file generated is somehow wrong. I checked and there was no such folder /tmpSLZYFu in the /temp directory. I even tried with a small script (below) and this is the same problem:
import os
import os.path as op
from mne.datasets import sample
from mne.utils import requires_mne, _TempDir
from mne.fiff import Raw
from mne import do_forward_solution
data_path = sample.data_path()
fname_raw = op.join(data_path, '..', '..','mne', 'fiff', 'tests', 'data',
'test_raw.fif')
fname = op.join(data_path, 'MEG', 'sample', 'sample_audvis-meg-oct-6-fwd.fif')
fname_mri = op.join(data_path, 'MEG', 'sample', 'sample_audvis_raw-trans.fif')
temp_dir = _TempDir()
existing_file = op.join('test.fif')
@requires_mne
def reproduce_test_do_forward_solution():
"""Test making forward solution from python
"""
subjects_dir = os.path.join(data_path, 'subjects')
print subjects_dir
raw = Raw(fname_raw)
fwd_py = do_forward_solution('sample', raw, mindist=5, spacing='oct-6',
bem='sample-5120', mri=fname_mri, eeg=False,
subjects_dir=subjects_dir, overwrite=True)
and the error for the script above looks the same:
Out[56]: <module 'reproduce_ut_errors' from 'reproduce_ut_errors.py'>
reproduce_ut_errors.reproduce_test_do_forward_solution()
/home/mainakjas/github/mne-python/examples/MNE-sample-data/subjects
Opening raw data file /home/mainakjas/github/mne-python/examples/MNE-sample-data/../../mne/fiff/tests/data/test_raw.fif...
Read a total of 3 projection items:
PCA-v1 (1 x 102) idle
PCA-v2 (1 x 102) idle
PCA-v3 (1 x 102) idle
Range : 25800 ... 40199 = 42.956 ... 66.930 secs
Ready.
Adding average EEG reference projection.
Created an SSP operator (subspace dimension = 4)
1 matching events found
Reading 0 ... 601 = 0.000 ... 1.001 secs...
[done]
Applying baseline correction ... (mode: mean)
Running forward solution generation command:
['mne_do_forward_solution', '--subject', 'sample', '--meas', '/tmp/tmpJX7nIr/evoked.fif', '--fwd', 'temp-fwd.fif', '--destdir', '/tmp/tmpJX7nIr', '--spacing', 'oct-6', '--mindist', '5', '--bem', 'sample-5120', '--mri', u'/home/mainakjas/github/mne-python/examples/MNE-sample-data/MEG/sample/sample_audvis_raw-trans.fif', '--megonly', '--overwrite'] and subjects_dir /home/mainakjas/github/mne-python/examples/MNE-sample-data/subjects
Stdout:
Stderr:
mne_forward_solution version 2.9 compiled at Dec 21 2009 19:51:36
Source space : /home/mainakjas/github/mne-python/examples/MNE-sample-data/subjects/sample/bem/sample-oct-6-src.fif
MRI -> head transform source : /home/mainakjas/github/mne-python/examples/MNE-sample-data/MEG/sample/sample_audvis_raw-trans.fif
Measurement data : /tmp/tmpJX7nIr/evoked.fif
BEM model : /home/mainakjas/github/mne-python/examples/MNE-sample-data/subjects/sample/bem/sample-5120-bem.fif
Accurate field computations
Do computations in head coordinates.
Free source orientations
Destination for the solution : temp-fwd.fif
Reading /home/mainakjas/github/mne-python/examples/MNE-sample-data/subjects/sample/bem/sample-oct-6-src.fif...
Read 2 source spaces a total of 8196 active source locations
Coordinate transformation: MRI (surface RAS) -> head
0.999310 0.009985 -0.035787 -3.17 mm
0.012759 0.812405 0.582954 6.86 mm
0.034894 -0.583009 0.811716 28.88 mm
0.000000 0.000000 0.000000 1.00
Read 306 MEG channels from /tmp/tmpJX7nIr/evoked.fif
Read 60 EEG channels from /tmp/tmpJX7nIr/evoked.fif
Coordinate transformation: MEG device -> head
0.991420 -0.039936 -0.124467 -6.13 mm
0.060661 0.984012 0.167456 0.06 mm
0.115790 -0.173570 0.977991 64.74 mm
0.000000 0.000000 0.000000 1.00
EEG not requested. EEG channels omitted.
57 coil definitions read
Head coordinate coil definitions created.
Source spaces are now in head coordinates.
Setting up the BEM model using /home/mainakjas/github/mne-python/examples/MNE-sample-data/subjects/sample/bem/sample-5120-bem-sol.fif...
Loading surfaces...
Triangle normals and neighboring triangles...[done]
Vertex neighbors...[done]
Distances between neighboring vertices...[15360 distances done]
Homogeneous model surface loaded.
Loading the solution matrix...
Loaded linear collocation BEM solution from /home/mainakjas/github/mne-python/examples/MNE-sample-data/subjects/sample/bem/sample-5120-bem-sol.fif
Employing the head->MRI coordinate transform with the BEM model.
BEM model /home/mainakjas/github/mne-python/examples/MNE-sample-data/subjects/sample/bem/sample-5120-bem-sol.fif is now set up
Source spaces are in head coordinates.
Checking that the sources are inside the inner skull and at least 5.0 mm away (will take a few...)
2 source space points omitted because they are outside the inner skull surface.
364 source space points omitted because of the 5.0-mm distance limit.
1 source space points omitted because they are outside the inner skull surface.
331 source space points omitted because of the 5.0-mm distance limit.
Thank you for waiting.
Setting up compensation data...
No compensation set. Nothing more to do.
Composing the field computation matrix...[done]
2 processors. I will use one thread for each of the 2 source spaces.
Computing MEG at 7498 source locations (free orientations)...done.
writing temp-fwd.fif...done
Finished.
Reading forward solution from /tmp/tmpJX7nIr/temp-fwd.fif...
Traceback (most recent call last):
File "<ipython-input-57-107c8ee7bd90>", line 1, in <module>
reproduce_ut_errors.reproduce_test_do_forward_solution()
File "/usr/local/lib/python2.7/dist-packages/numpy/testing/decorators.py", line 146, in skipper_func
return f(*args, **kwargs)
File "reproduce_ut_errors.py", line 38, in reproduce_test_do_forward_solution
subjects_dir=subjects_dir, overwrite=True)
File "/usr/local/lib/python2.7/dist-packages/mne-0.6.git-py2.7.egg/mne/utils.py", line 308, in dec
return function(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/mne-0.6.git-py2.7.egg/mne/forward.py", line 1404, in do_forward_solution
fwd = read_forward_solution(op.join(path, fname))
File "/usr/local/lib/python2.7/dist-packages/mne-0.6.git-py2.7.egg/mne/utils.py", line 308, in dec
return function(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/mne-0.6.git-py2.7.egg/mne/forward.py", line 330, in read_forward_solution
fid, tree, _ = fiff_open(fname)
File "/usr/local/lib/python2.7/dist-packages/mne-0.6.git-py2.7.egg/mne/utils.py", line 308, in dec
return function(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/mne-0.6.git-py2.7.egg/mne/fiff/open.py", line 50, in fiff_open
fid = open(fname, "rb") # Open in binary mode
IOError: [Errno 2] No such file or directory: '/tmp/tmpJX7nIr/temp-fwd.fif'
What do you think? I think this probably requires some modification in forward.py
but I'm not sure ...
mne_forward_solution did write something according to the log but apparently not where it should have. Your version dates back from 2009. Do you use the nightly build?
Houston, success! No errors or fails any more! Phew, careless me - I should've downloaded the nightly build.
mainakjas@Mainak:~/github/mne-python$ nosetests mne/tests
/home/mainakjas/github/mne-python/mne/datasets/sample/sample.py:133: UserWarning: Sample dataset (version 0.6) is older than mne-python (version 0.6.git). If the examples fail, you may need to update the sample dataset by using force_update=True
% (sample_version, mne_version))
Qt: Session management error: Authentication Rejected, reason : None of the authentication protocols specified are supported and host-based authentication failed
Test IO for noise covariance matrices ... ok
Test estimation from raw on continuous recordings (typically empty room) ... ok
Test estimation from raw with triggers ... ok
Test arithmetic with noise covariance matrices ... ok
Test cov regularization ... ok
Test whitening of evoked data ... ok
Test IO for .dip files ... ok
Test combining event ids in epochs compared to events ... ok
Test epochs from raw files with IO as fif file ... ok
Test handling projection (apply proj in Raw or in Epochs) ... ok
Test arithmetic of evoked data ... ok
Test IO of evoked data made from epochs ... ok
Test calculation and read/write of standard error ... ok
Test of epochs rejection ... ok
Test preload of epochs ... ok
Test of indexing and slicing operations ... ok
Test of average obtained vs C code ... ok
Test epochs Pandas exporter ... ok
Test of crop of epochs ... ok
Test of resample of epochs ... [Parallel(n_jobs=2)]: Done 1 out of 125 | elapsed: 0.0s remaining: 1.8s
[Parallel(n_jobs=2)]: Done 150 out of 752 | elapsed: 0.2s remaining: 0.9s
[Parallel(n_jobs=2)]: Done 301 out of 752 | elapsed: 0.4s remaining: 0.6s
[Parallel(n_jobs=2)]: Done 452 out of 752 | elapsed: 0.5s remaining: 0.3s
[Parallel(n_jobs=2)]: Done 603 out of 752 | elapsed: 0.7s remaining: 0.2s
[Parallel(n_jobs=2)]: Done 752 out of 752 | elapsed: 0.8s finished
ok
Test detrending of epochs ... ok
Test of bootstrapping of epochs ... ok
Test copy epochs ... ok
Test test_to_nitime ... ok
Test epoch count equalization and condition combining ... ok
Test accessing epochs by event name ... ok
Test SSP proj methods from ProjMixin class ... ok
Test event merging ... ok
Test IO for events ... ok
Test find events in raw file ... ok
Test making events of a fixed length ... ok
Test defining response events ... ok
Test notch filters ... ok
Test low-, band-, high-pass, and band-stop filters plus resampling ... [Parallel(n_jobs=2)]: Done 1 out of 2 | elapsed: 0.0s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 2 out of 2 | elapsed: 0.1s finished
[Parallel(n_jobs=2)]: Done 1 out of 2 | elapsed: 0.0s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 2 out of 2 | elapsed: 0.0s finished
[Parallel(n_jobs=2)]: Done 1 out of 2 | elapsed: 0.0s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 2 out of 2 | elapsed: 0.0s finished
[Parallel(n_jobs=2)]: Done 1 out of 2 | elapsed: 0.0s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 2 out of 2 | elapsed: 0.0s finished
[Parallel(n_jobs=2)]: Done 1 out of 2 | elapsed: 0.0s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 2 out of 2 | elapsed: 0.0s finished
ok
Test CUDA-based filtering ... SKIP: Skipping test: test_cuda
CUDA not initialized
Test zeroth and first order detrending ... ok
Test numpy.in1d() replacement ... ok
Test numpy.tril_indices() replacement ... ok
Test numpy.unravel_index() replacement ... ok
Test numpy.copysign() replacement ... ok
Test firwin2 backport ... ok
Test IIR filtfilt replacement ... ok
Test IO for forward solutions ... ok
Test projection of source space data to sensor space ... ok
Test restriction of source space to source SourceEstimate ... ok
Test restriction of source space to label ... ok
Test averaging forward solutions ... ok
Test making forward solution from python ... ok
Test label subject name extraction ... ok
Test label addition ... ok
Test IO for label + stc files ... ok
Test IO of label files ... ok
Test reading labels from parcellation ... ok
Test reading labels from parc. by comparing with mne_annot2labels ... ok
Test stc_to_label ... ok
Test inter-subject label morphing ... [Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.4s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.4s finished
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.5s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.5s finished
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.4s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.4s finished
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.5s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.5s finished
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.4s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.4s finished
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.5s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.5s finished
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.4s remaining: 0.0s
[Parallel(n_jobs=2)]: Done 1 out of 1 | elapsed: 0.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 0.1s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 0.1s finished
ok
Test generation of circular source labels ... ok
Test extracting label data from SourceEstimate ... ok
Test parsing of .ave file ... ok
Test sensitivity map computation ... ok
Test SSP computation on epochs ... [Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 0.1s
[Parallel(n_jobs=1)]: Done 7 out of 7 | elapsed: 0.4s finished
[Parallel(n_jobs=2)]: Done 1 out of 7 | elapsed: 0.2s remaining: 1.1s
[Parallel(n_jobs=2)]: Done 3 out of 7 | elapsed: 0.3s remaining: 0.4s
[Parallel(n_jobs=2)]: Done 5 out of 7 | elapsed: 0.5s remaining: 0.2s
[Parallel(n_jobs=2)]: Done 7 out of 7 | elapsed: 0.6s finished
ok
Test SSP computation on raw ... [Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 0.0s
[Parallel(n_jobs=1)]: Done 16 out of 16 | elapsed: 0.7s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 0.1s
[Parallel(n_jobs=1)]: Done 6 out of 6 | elapsed: 0.8s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 0.6s
[Parallel(n_jobs=1)]: Done 2 out of 2 | elapsed: 1.3s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 1.6s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 1.6s finished
[Parallel(n_jobs=2)]: Done 1 out of 98 | elapsed: 0.0s remaining: 0.7s
[Parallel(n_jobs=2)]: Done 74 out of 376 | elapsed: 0.1s remaining: 0.4s
[Parallel(n_jobs=2)]: Done 150 out of 376 | elapsed: 0.2s remaining: 0.3s
[Parallel(n_jobs=2)]: Done 226 out of 376 | elapsed: 0.2s remaining: 0.2s
[Parallel(n_jobs=2)]: Done 302 out of 376 | elapsed: 0.3s remaining: 0.1s
[Parallel(n_jobs=2)]: Done 376 out of 376 | elapsed: 0.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 0.8s
[Parallel(n_jobs=1)]: Done 2 out of 2 | elapsed: 1.5s finished
ok
Test reading of selections ... ok
Test reading and writing volume STCs ... ok
Test stc expansion ... ok
Test IO for STC files ... ok
Test IO for w files ... ok
Test arithmetic for STC files ... ok
Test stc methods lh_data, rh_data, bin(), center_of_mass(), resample() ... [Parallel(n_jobs=2)]: Done 1 out of 81 | elapsed: 0.0s remaining: 1.1s
[Parallel(n_jobs=2)]: Done 15 out of 81 | elapsed: 0.0s remaining: 0.1s
[Parallel(n_jobs=2)]: Done 41 out of 199 | elapsed: 0.0s remaining: 0.1s
[Parallel(n_jobs=2)]: Done 97 out of 487 | elapsed: 0.1s remaining: 0.2s
[Parallel(n_jobs=2)]: Done 297 out of 1491 | elapsed: 0.1s remaining: 0.6s
[Parallel(n_jobs=2)]: Done 302 out of 1516 | elapsed: 0.1s remaining: 0.6s
[Parallel(n_jobs=2)]: Done 305 out of 1535 | elapsed: 0.1s remaining: 0.6s
[Parallel(n_jobs=2)]: Done 688 out of 3438 | elapsed: 0.3s remaining: 1.3s
[Parallel(n_jobs=2)]: Done 699 out of 3493 | elapsed: 0.5s remaining: 1.9s
[Parallel(n_jobs=2)]: Done 3000 out of 7498 | elapsed: 1.4s remaining: 2.1s
[Parallel(n_jobs=2)]: Done 4500 out of 7498 | elapsed: 1.9s remaining: 1.3s
[Parallel(n_jobs=2)]: Done 6000 out of 7498 | elapsed: 2.5s remaining: 0.6s
[Parallel(n_jobs=2)]: Done 7498 out of 7498 | elapsed: 3.1s finished
ok
Test extraction of label time courses from stc ... ok
Test nearest neighbor searches ... ok
Test morphing of data ... [Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 0.2s
[Parallel(n_jobs=1)]: Done 2 out of 2 | elapsed: 0.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 1.3s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 1.3s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 1.4s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 1.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 0.2s
[Parallel(n_jobs=1)]: Done 2 out of 2 | elapsed: 0.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 1.4s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 1.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 1.4s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 1.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 1.4s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 1.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 1.4s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 1.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 1.4s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 1.4s finished
[Parallel(n_jobs=1)]: Done 1 jobs | elapsed: 1.5s
[Parallel(n_jobs=1)]: Done 1 out of 1 | elapsed: 1.5s finished
ok
Test applying linear (time) transform to data ... ok
Test that modifying the stc data removes the kernel and sensor data ... ok
Test stc Pandas exporter ... ok
Test spatio-temporal connectivity from triangles ... ok
Test spatio-temporal connectivity from source spaces ... ok
Test reading of source space meshes ... ok
Test writing and reading of source spaces ... ok
Test conversion of vertices to MNI coordinates ... ok
Test equivalence of vert_to_mni for nibabel and freesurfer ... ok
Test reading of bem surfaces ... ok
Test reading and writing of Freesurfer surface mesh files ... ok
Test logging (to file) ... ok
Test mne-python config file support ... ok
Test show_fiff ... ok
mne.tests.test_utils.test_deprecated ... /home/mainakjas/github/mne-python/mne/utils.py:275: DeprecationWarning: Function deprecated_func is deprecated; message
warnings.warn(msg, category=DeprecationWarning)
ok
Test plotting of ERP topography ... ok
Test plotting of TFR ... ok
Test plotting of power ... ok
Test plotting of epochs image topography ... ok
Test plotting of evoked ... ok
Test plotting of (sparse) source estimates ... ok
Test plotting of covariances ... ok
Test plotting of ICA panel ... ok
Test plotting of epochs image ... ok
Test plotting connectivity circle ... ok
Test plotting a drop log ... ok
Test plotting of raw data ... ok
Test comparing fiff files ... ok
Name Stmts Miss Cover Missing
---------------------------------------------------------------
mne 35 1 97% 68
mne.baseline 37 8 78% 54, 72-73, 77-79, 81-82
mne.beamformer 1 0 100%
mne.beamformer._lcmv 105 84 20% 62-169, 213-220, 264-274, 325-336
mne.connectivity 3 0 100%
mne.connectivity.effective 37 29 22% 117-164
mne.connectivity.spectral 469 394 16% 34, 37, 40, 43, 49-58, 62, 66, 72-75, 79, 88-91, 100-104, 113-116, 124-127, 131, 135-138, 146-149, 153, 157-160, 169-176, 184-188, 192-194, 198-213, 221-224, 228-231, 235-255, 263-266, 270-276, 280-288, 299-401, 406-423, 432-433, 442-444, 449-457, 462-470, 475-502, 699-1051
mne.connectivity.utils 14 11 21% 10-17, 36-45
mne.cov 317 33 90% 29, 32, 83-85, 108-118, 121-123, 177, 240, 270, 354, 366, 374, 376, 448, 480-483, 506, 613, 626-627, 678
mne.cuda 165 112 32% 9-10, 45-104, 156-190, 217-224, 280-316, 361-386
mne.datasets 2 0 100%
mne.datasets.megsim 1 0 100%
mne.datasets.megsim.megsim 66 56 15% 67-129, 181-192
mne.datasets.megsim.urls 25 9 64% 150-160
mne.datasets.sample 1 0 100%
mne.datasets.sample.sample 71 30 58% 27, 58, 70-102, 107-115, 126
mne.dipole 19 1 95% 41
mne.epochs 685 12 98% 216, 221, 268-270, 446, 465, 592-593, 597, 769, 1350, 1396
mne.event 269 31 88% 52, 61, 106, 121-123, 135, 145-146, 158, 220, 230, 317, 496-497, 511, 572-574, 642-655, 658
mne.fiff 8 0 100%
mne.fiff.channels 12 0 100%
mne.fiff.compensator 15 1 93% 21
mne.fiff.constants 506 0 100%
mne.fiff.cov 89 11 88% 52, 64, 69, 79, 86, 107-109, 165, 175-176
mne.fiff.ctf 129 108 16% 19, 42-102, 130-214, 217, 244-258
mne.fiff.evoked 323 101 69% 99, 108-109, 113-114, 119-125, 134-135, 143, 149-150, 177-185, 188, 192-207, 225, 242-243, 251-254, 257-258, 301-305, 343-350, 410-418, 448-489, 505-512, 539-540, 578-579
mne.fiff.matrix 59 12 80% 20, 59-62, 67, 74, 79, 108-111, 121
mne.fiff.meas_info 243 32 87% 52, 54, 59, 61, 106-108, 124, 127, 130, 133, 148-150, 156, 158, 182-184, 201, 210-213, 217-219, 227, 247-249, 340, 349, 359-361
mne.fiff.open 103 8 92% 67, 70, 73, 78, 134, 170-171, 193
mne.fiff.pick 165 47 72% 42, 49-62, 119-120, 172-177, 181, 203, 205, 207, 209, 211, 216, 221-226, 257, 284-303, 350-354, 390, 409-411, 448
mne.fiff.proj 230 11 95% 99, 126-128, 239, 245, 258, 264, 270, 276, 377, 612
mne.fiff.raw 720 276 62% 82-84, 89, 128-131, 135, 139-142, 148, 173-180, 198-200, 211-213, 225, 231-244, 250-261, 271-275, 316, 319, 338, 343, 349, 366-372, 416-437, 490-493, 555-603, 673-682, 733, 796, 803, 883-885, 889, 894, 908, 915-917, 935, 938-939, 955, 958, 962, 1034-1038, 1075, 1121-1133, 1144, 1172-1173, 1182, 1202-1267, 1326-1362, 1389-1404, 1446, 1464, 1505, 1507, 1591, 1601, 1718-1729, 1768, 1771, 1777, 1783-1788, 1815, 1817-1830, 1835, 1857-1858
mne.fiff.tag 245 55 78% 42-47, 50-59, 118, 123-128, 152, 154, 156, 159, 221, 238, 247, 252-266, 279, 291-296, 307, 314, 317, 323, 343-347, 350-354, 418, 437-440, 447
mne.fiff.tree 95 2 98% 23-24
mne.fiff.write 195 22 89% 52-54, 59-61, 66-68, 108-122, 305
mne.filter 430 74 83% 79, 109, 112, 116, 305-306, 354-366, 466, 470, 474, 487, 493, 499, 580, 589, 598-601, 681, 685, 694, 706, 709-713, 783, 793-795, 866, 873, 882-884, 981, 994-1001, 1034-1042, 1051, 1075, 1146, 1210, 1213, 1217, 1243-1245, 1277, 1283, 1293, 1317, 1320-1321, 1336
mne.fixes 191 83 57% 27-44, 48-65, 76-81, 84-89, 99, 103-108, 114-116, 121, 126-131, 136, 144, 165, 170, 183, 196, 208, 216-224, 234-238, 243-244, 250-254, 261, 267, 368, 371, 375, 378, 381, 384, 394-395, 414, 425
mne.forward 742 176 76% 76, 81, 120, 151-152, 157-158, 163-164, 169-170, 177-180, 192-193, 196-200, 226-227, 238-239, 263-264, 271, 277-278, 284-288, 335-336, 341-342, 347-349, 362-363, 374, 384, 397-398, 407-411, 419, 427-428, 433-437, 464, 471-472, 477, 504-506, 518, 529, 541, 609-610, 620, 627, 635, 658-663, 671-689, 697-705, 731, 734-735, 773-796, 802-822, 829-878, 926, 944, 1002, 1067, 1152, 1271, 1320-1321, 1334, 1342, 1364, 1376, 1380, 1382, 1384, 1434, 1457
mne.label 415 59 86% 72, 81-83, 136, 150, 161-163, 310, 312, 321, 325, 342, 371, 379-382, 393-399, 431, 444, 471, 520, 544, 558, 561, 593, 600, 613, 622, 631, 740, 744, 752, 801-811, 819, 822-833, 839
mne.layouts 1 0 100%
mne.layouts.layout 100 56 44% 45-56, 83, 100, 139-175, 195-232
mne.minimum_norm 2 0 100%
mne.minimum_norm.inverse 532 409 23% 44-54, 84-85, 93-94, 103-104, 111-112, 118-119, 128-129, 137-138, 148-149, 159-160, 163, 192, 207-208, 213-217, 233-234, 260-262, 292-370, 391-404, 410-423, 449-565, 577-637, 641-657, 662, 696-733, 789-847, 854-904, 948-957, 985-1001, 1011-1055, 1093-1284, 1301-1307
mne.minimum_norm.time_frequency 238 211 11% 81-116, 123-183, 194-250, 313-327, 383-459, 471-586, 651-667
mne.misc 61 18 70% 28-29, 42, 66-67, 85-100
mne.mixed_norm 1 0 100%
mne.mixed_norm.debiasing 48 38 21% 42-58, 98-133
mne.mixed_norm.inverse 176 156 11% 23-62, 67-84, 156-253, 258-272, 361-429
mne.mixed_norm.optim 307 274 11% 20-21, 26-30, 35-39, 66-90, 114-127, 165-175, 182-238, 245-260, 308-397, 409-425, 430-433, 438-440, 447-449, 452, 460-463, 466, 536-631
mne.parallel 39 23 41% 41-49, 75-78, 81-94
mne.preprocessing 5 0 100%
mne.preprocessing.ecg 60 52 13% 42-90, 132-168
mne.preprocessing.eog 43 34 21% 39-80, 87-117
mne.preprocessing.ica 497 311 37% 175, 180, 197-210, 245, 252, 257-258, 295-326, 349, 377-381, 385-405, 416-430, 456-486, 492-507, 511-513, 532-541, 543, 546, 585-589, 637-652, 694-709, 739-753, 789-817, 847-878, 965, 974, 1014, 1017, 1023, 1036-1037, 1045-1050, 1068, 1073-1082, 1087-1095, 1114-1120, 1158-1161, 1167-1170, 1198-1202, 1208-1212, 1217-1226, 1232-1242, 1246-1252, 1274-1306, 1324-1345, 1347-1348, 1350-1383, 1394-1396, 1408-1435, 1580-1600
mne.preprocessing.maxfilter 101 87 14% 44-86, 90, 190-281
mne.preprocessing.peak_finder 85 77 9% 50-172
mne.preprocessing.ssp 80 64 20% 26-27, 108-206, 287-294, 373-380
mne.proj 151 15 90% 63-64, 66-67, 69-70, 126, 130, 141, 276, 280, 284, 286, 314, 345
mne.selection 40 5 88% 50, 60, 80-82, 98
mne.simulation 2 0 100%
mne.simulation.evoked 34 25 26% 49-52, 77-86, 113-125
mne.simulation.source 72 66 8% 31-45, 74-107, 148-190
mne.source_estimate 947 66 93% 78, 279, 288-291, 300-303, 350, 374-378, 391, 528, 578, 812, 884, 886, 1113, 1386-1387, 1413, 1510, 1530-1533, 1581, 1613-1616, 1681, 1719, 1775, 1834, 1892, 1927, 1939, 1941, 1981, 2039, 2071, 2138-2145, 2179, 2213, 2217-2220, 2225, 2229-2231, 2241-2242, 2244, 2252, 2255, 2267, 2305, 2338, 2340
mne.source_space 406 86 79% 52, 59, 64, 77, 143, 210, 216, 221-224, 228-270, 274, 277, 282, 290, 294, 298, 305, 309, 317, 324, 331-333, 338, 345, 359, 468-487, 489-493, 497, 578-589, 594-595, 678, 763
mne.stats 3 0 100%
mne.stats.cluster_level 488 413 15% 34-58, 64-68, 81-113, 122-169, 174-182, 185-193, 200-203, 286-357, 360-391, 398-408, 410-411, 416, 419-437, 440-452, 455-458, 463-466, 475-487, 491-492, 495-502, 509-541, 547-592, 600-706, 715-740, 777-784, 883-891, 1007-1015, 1128-1144, 1234-1250, 1279-1284, 1291-1315, 1321-1326
mne.stats.multi_comp 33 29 12% 14-15, 50-78, 99-102
mne.stats.parametric 25 21 16% 56-76, 81
mne.stats.permutations 48 39 19% 37-48, 53-57, 117-150
mne.surface 207 56 73% 73-74, 82-83, 100, 130, 146-147, 153-154, 162, 172-173, 177-178, 184-187, 191-192, 196-197, 250-252, 257-267, 289-310, 320, 346, 386
mne.time_frequency 5 0 100%
mne.time_frequency.ar 43 38 12% 52-77, 104-115, 148-152
mne.time_frequency.multitaper 164 75 54% 45, 59, 91, 157-160, 220, 224, 241-242, 282-358, 377-380, 403-410, 482-529
mne.time_frequency.psd 32 24 25% 67-98
mne.time_frequency.stft 89 78 12% 46-105, 136-187, 206-211, 230-233
mne.time_frequency.tfr 157 136 13% 54-81, 86-91, 98-132, 139-158, 184-201, 225-237, 243-259, 310-332, 338-341, 379-407
mne.transforms 1 0 100%
mne.transforms.transforms 139 71 49% 36-46, 62-74, 90-94, 110-114, 142, 180, 225, 267-339
mne.utils 423 143 66% 45, 48-49, 56-58, 92-93, 134-144, 182, 249, 263, 325-326, 341, 355, 360, 384, 444, 579, 588-589, 637-638, 648, 693-695, 697, 699, 718-719, 721-724, 730-742, 758-759, 773, 795-809, 817-837, 842-843, 864-917, 922-934, 939-944, 950, 963, 968, 974, 983-984
mne.viz 1067 201 81% 112-119, 182-206, 254-255, 263-266, 270, 274, 395, 401, 403, 470, 496, 500, 503, 558, 560, 631-635, 653, 655, 663-664, 668-673, 691, 759, 779-780, 792-793, 816, 828, 849, 922, 1025, 1031, 1048, 1070, 1075, 1082-1155, 1163-1165, 1172-1184, 1189, 1236, 1481, 1510, 1607, 1617, 1620, 1917, 1919-1920, 1926, 2046, 2054, 2068, 2070, 2077, 2081, 2174-2176, 2181-2187, 2189-2192, 2197-2202, 2204-2207, 2212-2249, 2251, 2270, 2306, 2371, 2378
---------------------------------------------------------------
TOTAL 14189 5286 63%
----------------------------------------------------------------------
Ran 100 tests in 396.550s
OK (SKIP=1)
My guess is that it was not working with the earlier version because I was running a 64-bit operating system (and a 64-bit MNE) on a 32-bit machine, which was somehow messing up the computations. Now, it is all 32-bit and it works! Thanks so much for being patient with this :)
Continuing from discussion on https://github.com/mne-tools/mne-python/pull/563, I currently have 3 errors in the tests on master (after redownloading the sample dataset and executing the three mne-scripts):
Number 1 does not seem to occur before running the mne-scipts, only afterwards.
1:
2:
3: