You can reach me also here:
ORC-iD | 0000-0002-9050-9040 |
ResearchGate | Simon Kern |
@skjerns | |
Website | skjerns.de |
This project forked from yunzheliu/tdlm
Python code for running TDLM (temporally delayed linear modelling)
License: GNU General Public License v3.0
You can reach me also here:
ORC-iD | 0000-0002-9050-9040 |
ResearchGate | Simon Kern |
@skjerns | |
Website | skjerns.de |
In Toby Wise's paper a windowed TDLM approach is presented.
Task:
win_size
aggr_func
which is a function that post-processes the output of for each window, e.g. taking the mean differential replaypossible skeleton
def mean_diff(seq_fwd, seq_bkw):
# calculate the mean differential sequenceness
mean_diff = np.mean(seq_fwd-seq_bkw)
return mean_diff
def compute_windowed(preds, tf, win_size, aggr_func= seq_type='glm/crosscorr', ...):
# ...
win_values = []
for win in windows:
seq_fwd_win, seq_bkw_win = compute_glm(preds_win)
aggregated = aggr_func(seq_fwd_win, seq_bkw_win)
win_values += [aggregated]
# ....
# possibly convert win_values into np.ndarray if possible?
return win_values
Currently we're still using plot_sequenceness as a port from the MATLAB code.
Line 11 in 660d7b2
It would be better to have a pythonic version, e.g. using seaborn
.
Add feature to compute n-step TDLM/cross-correlation.
this is slightly more complicated to implement, haven't thought through yet what's the best option. Feel free to add ideas.
Task:
possible skeleton
def compute_glm_nstep(preds, tf, n_steps=x...)
preds_step = preds.copy()
for step in range(n_steps):
tf_step = get_next_step_tf(tf)
fwd, bkw = compute_glm(preds_step , tf, ...)
# ...
Problems:
Two functions should be added for simulation purposes:
simulate_eeg_resting_state
to create fake M/EEG data and simulate_eeg_localizer
to create localizer data
Potentially either yunzhes code can be translated to python or alternatively there are packages to simulate EEG that could be called here.
Currently we're still using unique_permutations
which is a port from MATLAB
Line 13 in 660d7b2
It would be better to have a more performant and pythonic implementation.
Also add more functions based on the suggestions in the TDLM methods paper (e.g. exclude real transitions from the shuffles)
A CI should be setup using GitHub actions and more tests need to be written.
Currently only on transition matrix can be supplied for all trials. There should be a helper function that takes several prediction trials (3d matrix) and a list of TFs (and TBs) with expected transitions for each trial
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.