jjlatval / meg-inverse-unet Goto Github PK
View Code? Open in Web Editor NEWA U-Net for approximating the MEG inverse problem
A U-Net for approximating the MEG inverse problem
Hi,
When I run simulate_data.py
, I get the error
No such file or directory: '/home/mne_data/MNE-sample-data/subjects/sample/bem/sample-ico-3-src.fif'
In fact, when I look through the appropriate /bem folder, I see corresponding .fif files for oct-6, and some other stuff, but not for ico-3. I am a newbie in MNE Python, but I wanted to reproduce your experiments, so I did this:
surf = mne.setup_source_space('sample', spacing='ico3', subjects_dir='/home/mne_data/MNE-sample-data/subjects/')
mne.write_source_spaces('/home/mne_data/MNE-sample-data/subjects/sample/bem/sample-ico-3-src.fif', surf)
Is it correct or did I miss something? Because after I ran simulate_data.py
again, it went through "computing MEG and EEG at 1282 source locations, 305 out of 366 channels remain after picking", and then it failed after these stages:
Computing inverse operator with 305 channels.
Created an SSP operator (subspace dimension = 8)
estimated rank (mag + grad): 297
Setting small MEG eigenvalues to zero.
Not doing PCA for MEG.
Created the whitener using a noise covariance matrix with rank 297 (8 small eigenvalues omitted)
Creating the depth weighting matrix...
203 planar channels
limit = 1233/1282 = 10.026908
scale = 3.16883e-08 exp = 0.8
Computing inverse operator with 305 channels.
Creating the source covariance matrix
Applying loose dipole orientations. Loose value of 0.2.
Whitening the forward solution.
Adjusting source covariance matrix.
Computing SVD of whitened and weighted lead field matrix.
largest singular value = 16.5682
scaling factor to adjust the trace = 6.47565e+21
Traceback (most recent call last):
File "simulate_data.py", line 13, in
main()
File "simulate_data.py", line 10, in main
sim.save_simulated_data()
File "/home/MEG-inverse-UNet/simulation_model/simulation_model.py", line 167, in save_simulated_data
self.mne = self.calculate_inverse_solution(data, method='MNE')
File "/MEG-inverse-UNet/simulation_model/simulation_model.py", line 222, in calculate_inverse_solution
stc = apply_inverse_raw(data, inv, lambda2=self.lambda2, method=method)
File "", line 2, in apply_inverse_raw
File "/home/anaconda3/lib/python3.6/site-packages/mne/utils.py", line 952, in verbose
return function(*args, **kwargs)
File "/home/anaconda3/lib/python3.6/site-packages/mne/minimum_norm/inverse.py", line 1057, in apply_inverse_raw
_check_reference(raw, inverse_operator['info']['ch_names'])
File "/home/anaconda3/lib/python3.6/site-packages/mne/minimum_norm/inverse.py", line 808, in _check_reference
raise ValueError('Custom EEG reference is not allowed for inverse '
ValueError: Custom EEG reference is not allowed for inverse modeling.
There is not the config.py. Please upload it. Thank you!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.