[med-svn] [python-mne] 298/376: FIX: reading old evoked file
Yaroslav Halchenko
debian at onerussian.com
Fri Nov 27 17:23:09 UTC 2015
This is an automated email from the git hooks/post-receive script.
yoh pushed a commit to annotated tag v0.1
in repository python-mne.
commit d32cb2b1af6d9fd129c3392872cbdea6841694e8
Author: Alexandre Gramfort <alexandre.gramfort at inria.fr>
Date: Thu Jun 9 21:50:34 2011 -0400
FIX: reading old evoked file
---
mne/fiff/evoked.py | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/mne/fiff/evoked.py b/mne/fiff/evoked.py
index 618c808..c74b07d 100644
--- a/mne/fiff/evoked.py
+++ b/mne/fiff/evoked.py
@@ -186,7 +186,7 @@ class Evoked(object):
if nepoch != 1 and nepoch != info['nchan']:
fid.close()
raise ValueError('Number of epoch tags is unreasonable '
- '(nepoch = %d nchan = %d)' % (nepoch, info['nchan']))
+ '(nepoch = %d nchan = %d)' % (nepoch, info['nchan']))
if nepoch == 1:
# Only one epoch
@@ -194,12 +194,9 @@ class Evoked(object):
# May need a transpose if the number of channels is one
if all_data.shape[1] == 1 and info['nchan'] == 1:
all_data = all_data.T
-
else:
# Put the old style epochs together
- all_data = epoch[0].data.T
- for k in range(1, nepoch):
- all_data = np.r_[all_data, epoch[k].data.T]
+ all_data = np.concatenate([e.data[None, :] for e in epoch], axis=0)
if all_data.shape[1] != nsamp:
fid.close()
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/python-mne.git
More information about the debian-med-commit
mailing list