Hi Openvibers,
Do you use the FastICA box on OV ? In the current implementation, an ICA estimation (demixing matrix and ICs) seems operated on every chunk of data being received ? (which is, whatever the data chunck count you select on the acquisition server, a very small number of samples for the ICA to work with ?). Does it make sense to you, or do you agregate the signals before sending them to the box ? With my signals, the signal separation (method fastica.separate) is very slow, OV is largely unable to hold the real time, and the demixed signals are full of discontinuities (each time a new demixing matrix is computed, meaning at each new data chunck)
Independent Component Analysis on OV
-
- Posts: 775
- Joined: Tue Dec 04, 2012 3:53 pm
- Location: INRIA Rennes, FRANCE
Re: Independent Component Analysis on OV
Hi Jeff,
FastICA is not an online algorithm, its a batch algorithm -- it requires the full dataset. To achieve this in Openvibe, you can use epoching boxes. The only reasonable thing you can do with the result is to redirect it to a file and then use it either by loading it or analyzing it somewhere else.
We have a clear todo list for the ICA box, but so far nobody has had the time to do anything about it - we haven't needed it in our lab during my time here.
Serious problems with the current (contrib) FastICA box:
Re-runs FastICA for every received block. Without massive epoching, the result is worthless.
If epoching is used, the output will have epoching discontinuities.
No parameters are exposed to the user.
The box should be changed to
Expose relevant parameters to GUI
Divide operation properly to model estimation and model apply phases (save spatial filter)
Collect data until EOF / stop is received and only after that estimate the ICA model.
Only output a matrix in Spatial Filter format. This matrix is then to be used in a separate online scenario to perform signal separation on the received signal.
Allow matrix input also, not just signal
Provide decent documentation
Cheers,
Jussi
FastICA is not an online algorithm, its a batch algorithm -- it requires the full dataset. To achieve this in Openvibe, you can use epoching boxes. The only reasonable thing you can do with the result is to redirect it to a file and then use it either by loading it or analyzing it somewhere else.
We have a clear todo list for the ICA box, but so far nobody has had the time to do anything about it - we haven't needed it in our lab during my time here.
Serious problems with the current (contrib) FastICA box:
Re-runs FastICA for every received block. Without massive epoching, the result is worthless.
If epoching is used, the output will have epoching discontinuities.
No parameters are exposed to the user.
The box should be changed to
Expose relevant parameters to GUI
Divide operation properly to model estimation and model apply phases (save spatial filter)
Collect data until EOF / stop is received and only after that estimate the ICA model.
Only output a matrix in Spatial Filter format. This matrix is then to be used in a separate online scenario to perform signal separation on the received signal.
Allow matrix input also, not just signal
Provide decent documentation
Cheers,
Jussi
Re: Independent Component Analysis on OV
Hi Jussi,jtlindgren wrote: The box should be changed to
Expose relevant parameters to GUI
Divide operation properly to model estimation and model apply phases (save spatial filter)
Collect data until EOF / stop is received and only after that estimate the ICA model.
Only output a matrix in Spatial Filter format. This matrix is then to be used in a separate online scenario to perform signal separation on the received signal.
Allow matrix input also, not just signal
Provide decent documentation
Yes, this si basically what I had to do to be able to test FastICA under OV:
Jeff
-
- Posts: 775
- Joined: Tue Dec 04, 2012 3:53 pm
- Location: INRIA Rennes, FRANCE
Re: Independent Component Analysis on OV
Wow, looks super. If you'd ever like to contribute these changes back to the upstream, we'd be delighted to include them.
Cheers,
Jussi
Cheers,
Jussi
Re: Independent Component Analysis on OV
Hello Jussijtlindgren wrote:Wow, looks super. If you'd ever like to contribute these changes back to the upstream, we'd be delighted to include them.
Cheers,
Jussi
Here are the .h and .cpp files but you might be upset by this little adaptation which was just intended to test the Fastica algo with different settings and produce a spatial filter file... In French we would say that it is coded "à l'arrache"
Jeff
- Attachments
-
- ovpCFastICA.cpp
- (8.42 KiB) Downloaded 373 times
-
- ovpCFastICA.h
- (4.72 KiB) Downloaded 378 times
-
- Posts: 775
- Joined: Tue Dec 04, 2012 3:53 pm
- Location: INRIA Rennes, FRANCE
Re: Independent Component Analysis on OV
Many thanks! I'll give it a review, test and possibly a little polish soon and then consider integrating it. Much appreciated.
Cheers,
Jussi
Cheers,
Jussi
-
- Posts: 775
- Joined: Tue Dec 04, 2012 3:53 pm
- Location: INRIA Rennes, FRANCE
Re: Independent Component Analysis on OV
I merged your contribution to 'wip-jlindgre-merge-fastica-mods' branch. We can include it to the next release.
In addition to your new features, I hacked in the following additional modifications,
Thanks again for the contribution.
Cheers,
Jussi
In addition to your new features, I hacked in the following additional modifications,
Code: Select all
commit 5855ad3fbb9645f773b830442c01c2f94e232ccd
Author: Jussi Lindgren <jussi.lindgren@inria.fr>
Date: Wed Feb 17 11:03:18 2016 +0100
Plugins: Misc fixes to the FastICA box
- User can now choose between symmetric/deflation estimation
- Fixed estimation of chosen number of components
- Added some safety checks
- Some code cleanup & refactoring
- Wrote more detailed documentation
- Updated the corresponding tutorial scenario
Cheers,
Jussi
-
- Posts: 9
- Joined: Sat Jul 11, 2015 10:02 am
Re: Independent Component Analysis on OV
How can I add ovpCFastICA.h and ovpCFastICA.pp to openVIBE ?