[Mne_analysis] create_ecg_epochs with mne-12

JR KING jeanremi.king at gmail.com
Thu May 12 06:18:46 EDT 2016
Search archives:

Dear Elena,

This may be due to this bug fix:

https://github.com/mne-tools/mne-python/pull/3055/files

Previously, a synthetic ecg channel was incorrectly created even when the
ecg channel was set by the user.

To check that the `create_ecg_epochs` function works on your computer, try:

```
from mne.io import Raw
from mne.preprocessing import create_ecg_epochs
from mne.datasets import sample

data_path = sample.data_path()
fname = data_path + '/MEG/sample/sample_audvis_filt-0-40_raw.fif'
raw = Raw(fname, preload=True)

ecg_epochs = create_ecg_epochs(raw, tmin=-.15, tmax=.4,
                               l_freq=1.0, h_freq=20.0,
                               reject=dict(grad=4000e-13),
                               ch_name=None, picks=None)
 ```

I haven't been able to reproduce your error, so I suspect that there is
something wrong with your raw. Can you report us

```
raw._data.shape
raw.ch_names
reject
picks
```

Best,

Jean-Rémi

On 12 May 2016 at 04:52, Elena Orekhova <orekhova.elena.v at gmail.com> wrote:

> Hello mne developers,
>
> I upgraded to mne-12 by
> % pip install --upgrade --user mne
>
> (although the output indicates  that in this way I installed mne-0.11.0
> ...?  See below )
> #################
> Collecting mne
>    Using cached mne-0.12.0.tar.gz
> Installing collected packages: mne
>   Running setup.py install for mne ... done
> Successfully installed mne-0.11.0
> ################
>
> After the upgrade  running this line (that previously worked OK)
> ecg_epochs = create_ecg_epochs(RAW, reject=reject, tmin=-.15, tmax=.4,
> ch_name=ECG_ch,  l_freq=1.0, h_freq=20.0,  picks=picks)
> gives me an error:
> Data must be a 2D array of shape (n_channels, n_samples
>
> The full error output is below.
> I believe that this relates to the upgrade.
>
> Regards,
> Elena
>
>
>
>
> _______________________________________________
> Mne_analysis mailing list
> Mne_analysis at nmr.mgh.harvard.edu
> https://mail.nmr.mgh.harvard.edu/mailman/listinfo/mne_analysis
>
>
> The information in this e-mail is intended only for the person to whom it
> is
> addressed. If you believe this e-mail was sent to you in error and the
> e-mail
> contains patient information, please contact the Partners Compliance
> HelpLine at
> http://www.partners.org/complianceline . If the e-mail was sent to you in
> error
> but does not contain patient information, please contact the sender and
> properly
> dispose of the e-mail.
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.nmr.mgh.harvard.edu/pipermail/mne_analysis/attachments/20160512/6f53b100/attachment.html 


More information about the Mne_analysis mailing list