Giter VIP home page Giter VIP logo

Comments (7)

agramfort avatar agramfort commented on July 24, 2024

we could add this but maybe a better way is indeed to make epochs from raw with fixed length such as 1s. I would allow you do reject bad segments for the SSP computation.

wdyt?

from mne-python.

larsoner avatar larsoner commented on July 24, 2024

I think both ways will make sense for different uses. In my code, I actually don't want epoch rejection because there is some large, low-frequency drift (that goes away with a couple continuous projectors) that would disqualify all epochs. I currently have code for doing it by chunking epochs with a chosen fixed length, but I was hoping to get something that was actually equivalent to what is done in mne_process_raw (to stay as close as possible).

from mne-python.

larsoner avatar larsoner commented on July 24, 2024

I noticed that the way the projectors are computed in compute_proj_evoked in proj.py is by taking the sum across epochs of the matrix multiplications (channelsxtime into timexchannels). I am curious why this is done instead of using the matrix multiplication of the temporally-concatenated (across epochs) matrices (chanellsxconcatenated_time into concatenated_timexchannels)? I understand the former is probably more efficient, but is one preferable to another from a mathematical standpoint? I ask because I noticed that I got different results when "faking" continuous projection calculation by using consecutive 1, 10, or 100 second windows to create epochs from my raw data.

from mne-python.

larsoner avatar larsoner commented on July 24, 2024

I submitted some continuous SSP code to code review so we can discuss it there.

from mne-python.

agramfort avatar agramfort commented on July 24, 2024

I currently have code for doing it by chunking epochs with a chosen fixed length

a function like:

mne.make_fix_length_events(raw, duration=4)

would be convenient to have.

I noticed that the way the projectors are computed in compute_proj_evoked
in proj.py is by taking the sum across epochs of the matrix multiplications
(channelsxtime into timexchannels). I am curious why this is done instead of
using the matrix multiplication of the temporally-concatenated (across
epochs) matrices (chanellsxconcatenated_time into
concatenated_timexchannels)?

memory allocation. You don't need to read everything in memory by doing so.

I understand the former is probably more
efficient, but is one preferable to another from a mathematical standpoint?

no just efficiency

I ask because I noticed that I got different results when "faking"
continuous projection calculation by using consecutive 1, 10, or 100 second
windows to create epochs from my raw data.

hum. can you submit a test script?

from mne-python.

larsoner avatar larsoner commented on July 24, 2024

I'll add the make_fix_length_events(raw, duration=4) [but I'll probably make the default 1 second] function to my modified codebase, where we can continue the discussion. Closing this one.

from mne-python.

agramfort avatar agramfort commented on July 24, 2024

perfect !

from mne-python.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.