Skip to content

Commit

Permalink
v4.0.0 (#107)
Browse files Browse the repository at this point in the history
* access to data structure adapted

* use tapas_hgf_binary_plotTraj instead of tapas_h2gf_binary_plotTraj; data structure has been adapted to run with the HGF plotting function

* plot boxplot as well for zeta

* plot boxplots for RW

* plot trajectories as well for RW

* jobs for rw added

* run hgfv5.2 for srl1 and srl2

* correction

* figure title: iterations replaced by samples

* plotting part updated

* final noise ROIs are written in a volume, and displayed through spm_orthviews
noise ROIs erosion is now 3D and using spm_erode

* Update Contributor-License-Agreement.md

reformatted table for better display

* plot mean and ste for h2gf and hgf results

* updates

* added name and affiliation in Contributor-License-Agreement.md

* noiseROIs after processing are now displayed only when verbose>=2

* some more help in the GUI about the expected geometry of the maks/tissue probability

* noiseROI GUI : added a Yes/No switch to force Coregister:Estimage&Reslice
yes : always do it
no : compare geometry and decide to skip coreg or still perform it

* Updated demo to increase length of sampling chains

* included physio-public/merge-tapas-development branch

* removed examples/ from .gitignore

* Implemented automatic ploting of posteriors.

* Added an example for flat model.

* Updated changelog.

* Solved a bug with invgamma.

* Added a figure with an example of the results.

* Small bug in plotting.

* PhysIO: bugfix BIDS .gz, file still open when trying to delete temp folder for unzipping

* hotfix github issue #38; restricting valid searchPositions for findpeaks_template_correlation for early peaks

* PhysIO bugfix github issue #37, first scan event and first cardiac pulse coinciding

* PhysIO: bugfix #43, prepending c/r time courses, if recording started after scan, irrespective of specified logfile names, as long as c/r time courses exist

* PhysIO: fixes BIDS bugs issue #43, #45

* WIP PhysIO R2018.2.0 update, removed suptitle dependence and added BIDS examples and default template example

* PhysIO bugfix suptitle; new findpeaks wrapper

* PhysIO bugfix issue #46, skipped tics samples in logfiles

* Start implementing summaries for seria.

* Almost complete summaries of the parameters.

* Implemented the summaries.

* Implemented summaries for prosa and nice displaying.

* Typos from the readme file removed.

* Cleaned up demo

* Small typo.

* Typo in readme file.

* Deal with invalid trials.

* Added a youtube video.

* Improved handling of the errors.

* HGF Toolbox Version 5.2.2

* New Release of rDCM

* Check for empty inputs

* Added comment on rDCM to the TAPAS CHANGELOG.md

* - HUGE: minor bugfix

* Improved the documentation.

* Added change log.

* Corrected small error in function header

* Added get revision info.

* Demo with simulations on a grid and varying noise

* HGF Toolbox Version 5.3.0

* bugfix in HGF softmax_binary_sim

according to issue #48; to establish consistency with softmax_binary by also taking reward values from the input into account

* Improved the changelog.

* Updated CHANGELOG to reflect hgf 5.3.

* Improved documentation and removed some warnings.

* Improved documentation and new video.

* Added table for summary stats to docs.

* Added code for the summaries of prosa.

* Updated requirements.

* Updated the python code.

* Added wrappers for the generation of summaries.

* Updated the summaries to use c code.

* Summaries are done in c.

* Updated data and data file.

* Small typo.

* Improved docs of download_example_data.

* Update the name of the examples and scripts.

* Improved documentation.

* Updated the examples download.

* PhysIO R2019a-v7.1.0 release: updated documentation and examples; introduced new semantic versioning; modularization of functions reflected in figure names; see CHANGELOG.md for full details

* PhysIO R2019-v7.1.0 release: added units test BIDS reader and findpeaks

* Included info on PhysIO-R2019a-v7.1.0. Note that the CHANGELOG infos from TAPAS 3.0.1 and 3.0.0 seem to be mixed up with the unreleased (3.1) here

* Updated the CHANGELOG.md

* Implemented WBIC, WAIC, parameters of second level and solved bug.

* README with external contributors and mentioning serial correlation cleanup by PhysIO, removing misleading warnings for cardiac phase and gradient gain correction

* Bugfix tapas_physio_init discovered by Dario; was not working, because utils functions used in init were not on path

* Removed the mlx file and updated the h2gf demo.

* Added utilities for delta plots.

* Small changes.

* commits from physio-public tag R2019b-v7.2.0

* Added PhysIO R2019b change summary to CHANGELOG.md

* - huge: rewrote HUGE as Matlab class

* - references for user manual

* - tapas naming scheme

* Update the version number and added references.

* Removed .DS_Store and updated example hash.

* Updated change log.

* noise ROI : PCA is now performed with MATLB built-in SVD function, instead of PCA function in "stats" toolbox

noiseROI : keep variables name coherent

* new function tapas_physio_pca to perform PCA with new SVD method or old STATS toolbox method
added also tapas_physio_pca_test to test if both methods give the same result

* fix : tapas_physio_pca_test uses now randn() for noramlly distributed numbers instead of integer numbers
fix : dimension of the output from tapas_physio_pca

* bugfix in the tests for PCA : use randn instead of randi
tests for PCA : added verification for nVoxels <= NVolumes

* New run of demo (including est struct)

* typo

* - added info to CHANGELOG.md of TAPAS about PhysIO changes

* PhysIO: updated its internal version and changelog

* PhysIO: updated README version

* Commented and change the implementation of the early unit.

* Changes during discussion with Eduardo

- alpha and beta Gaussian-gamma hyperparameter definitions adapted
- Improved comments

* HUGE: bugfix x-tick labels

* Update CHANGELOG.md with changes to HUGE

* Improved the general structure of SEM.

* Further comments and changes while discussing

* Updated small bug in preapre priors and improved prior.

* Improved the documentation.

* Renamed correctly a function.

* Improved documentation and adapted demo.

* Empirical delta plot analysis.

* Solved an apparent bug in the code.

* Improved the structure displaying posterior (SEM)

* Better posterior summaries (SEM).

* Added function for WAIC.

* Now compute the WAIC as part of the summary.

* Improved posterior summaries (SEM).

* Improved the setup script for tapas.

* Improved the prosa model.

* Updated the setup file.

* Debugging version for summary stats.

* Experimental.

* Trying to solve numerical bug.

* Founda a really serious bug with the python parameters.

* Small change.

* Simplified a bit prosa.

* Standarized the implementation of prosa.

* Seria model compatible with python3.

* Small change.

* Python3 compatible.

* Found weird bugs.

* Version 3.3.0 with new SERIA.

* included PhysIO v7.2.2 bugfix Siemens VB sync to DICOM, using PPU3T and added this new example

* PhysIO v7.2.3 (bugfix manual peak selection, github issue #85)

* allow figures to be showed/saved/closed upon review

* tweak figure show/save/close code

* tweaks

* updates figure display/save/close functionality

* make isfile/exists switch dependent on Matlab ver

 'isfile' is clearer than 'exist', because checks for correct absolute/relative path, not existence anywhere on Matlab path, but only available in Matlab version >= R2017b

* PhysIO v7.2.4, bugfix for docked figures -nodisplay now (Sam Harrison

* placeholder for release date

* HGF Toolbox v5.3.3

* Ensure parameter covariance in h2gf is positive semi-definite

* Streamlined h2gf setup loops, removed unused files

* Continued streamlining and removing unused files and functions

* Removed all instances of 'initilize', replaced with 'initialize'

* In h2gf: removed all 'initilize', replaced with 'initialize'

* HGF Toolbox v5.3.5

* HGF Toolbox v5.3.6

* PhysIO Release R2020a-v7.3.0

* HGF Toolbox v6.0

* - preparing current release

* - preparing release

* release 3.3.0 (#100)

* Added hierarchical inference part.

* Documented and simplifid output.

* Deleted some typos.

* Solved a bug in SERIA introduced by new feature.

* Added mcmcdiag and diagnostics for h2gf.

* Fixed typos

* Started editing h2gf/README.md

* Now the expected states are stored in the output structure.

* Now the correlation matrix is only of the valid parameters.

* Now return the pseudo model evidence.

* Updated the REDME file..

* Updates to h2gf_example

* Plot function provided by Sandra

* Further updates to h2gf_example

- Vary omega2 instead of kappa2
- Various other improvements

* Replaced tapas_h2gf_example.m with h2gf_demo.mlx

* Updates to h2gf_demo

* Improved h2gf_summary

- All plotting and diagnostics function from the HGF Toolbox now work
- Plotting function provided by Sandra now obsolete and removed
- Adapted h2gf_demo
- h2gf_demo now also in source (.m) not just binary (.mlx)

* Minor changes.

* Added nchain input, improved docs, simplified input.

* h2gf for srl2 data from the PRSSI EEG project, different Nr of iterations, config files and eta values can be specified

* script to run h2gf_demo_link_figures for all hgf configurations and h2gf estimations

* x-axes adjusted

* demo srl2

* Issue: conflict between pars.nchains and pars.T

- When pars.nchains = 8 and pars.T left on default, this produces an
  error
- Reproducible by running h2gf_demo.mlx

* Solved bug with chains.

* save as well as png

* replaced by h2gf_demo_srl2_link_figures

* h2gf estimations for long version of SSL task

* save figure as png with higher resolution

* jobs submitted to euler

* loops modified

* scripts to plot individual trajectories

* euler jobs added to plot individual trajectories

* ze prior mu set to log(48) instead of 0.5)

* shuffle position of subject's data on data structure included

* paths added

* script with paths to data structure for short srl task

* plot histogram of samples

* Store the rng seed into the output.

* Documented the rng_seed option.

* RW implementation

* run simulations with srl1 inputs

* variance disabled

* paths adapted

* timing adapted

* access to data structure adapted

* use tapas_hgf_binary_plotTraj instead of tapas_h2gf_binary_plotTraj; data structure has been adapted to run with the HGF plotting function

* plot boxplot as well for zeta

* plot boxplots for RW

* plot trajectories as well for RW

* jobs for rw added

* run hgfv5.2 for srl1 and srl2

* correction

* figure title: iterations replaced by samples

* plotting part updated

* plot mean and ste for h2gf and hgf results

* updates

* Updated demo to increase length of sampling chains

* Cleaned up demo

* Deal with invalid trials.

* Improved handling of the errors.

* Demo with simulations on a grid and varying noise

* Implemented WBIC, WAIC, parameters of second level and solved bug.

* Removed the mlx file and updated the h2gf demo.

* Added utilities for delta plots.

* Small changes.

* New run of demo (including est struct)

* Commented and change the implementation of the early unit.

* Changes during discussion with Eduardo

- alpha and beta Gaussian-gamma hyperparameter definitions adapted
- Improved comments

* Improved the general structure of SEM.

* Further comments and changes while discussing

* Updated small bug in preapre priors and improved prior.

* Improved the documentation.

* Renamed correctly a function.

* Improved documentation and adapted demo.

* Empirical delta plot analysis.

* Solved an apparent bug in the code.

* Improved the structure displaying posterior (SEM)

* Better posterior summaries (SEM).

* Added function for WAIC.

* Now compute the WAIC as part of the summary.

* Improved posterior summaries (SEM).

* Improved the prosa model.

* Updated the setup file.

* Debugging version for summary stats.

* Experimental.

* Trying to solve numerical bug.

* Founda a really serious bug with the python parameters.

* Small change.

* Simplified a bit prosa.

* Standarized the implementation of prosa.

* Seria model compatible with python3.

* Small change.

* Python3 compatible.

* Found weird bugs.

* Version 3.3.0 with new SERIA.

* placeholder for release date

* HGF Toolbox v5.3.3

* Ensure parameter covariance in h2gf is positive semi-definite

* Streamlined h2gf setup loops, removed unused files

* Continued streamlining and removing unused files and functions

* Removed all instances of 'initilize', replaced with 'initialize'

* In h2gf: removed all 'initilize', replaced with 'initialize'

* HGF Toolbox v5.3.5

* HGF Toolbox v5.3.6

* PhysIO Release R2020a-v7.3.0

* HGF Toolbox v6.0

* - preparing current release

* - preparing release

Co-authored-by: Eduardo Aponte <[email protected]>
Co-authored-by: Christoph Mathys <[email protected]>
Co-authored-by: siglesias <[email protected]>
Co-authored-by: Christoph Mathys <[email protected]>
Co-authored-by: Eduardo Aponte <[email protected]>
Co-authored-by: Lars Kasper <[email protected]>

* Added FDT toolbox to tasks

* Added necessary folders

* Updates to folder location checks

* Added functs to check if new TAPAS version on github

* Used try/catch in case API changed/offline

* Started functions to find dependencies

* Comments and minor improvements for init

* Renamed tapas_new_init into tapas_init

* Adapted renaming of files to file content...

* - misc: skip toolboxes with failed init

* - misc: bandwidth optimization, return path to example data

* - misc: ignore examples folder

* - misc: external code as package

* - h2gf: replace dependency on external toolbox with internal function for psrf calculation

* - h2gf: move binary data to example files

* - h2gf: add dependencies

* - huge: release 2020-09

* Update CHANGELOG.md

* First release of the tapas-ceode toolbox to integrate DCM for ERPs efficiently and accurately

* Update README.md

* Update tapas_ceode_fx_erp.m

* Update tapas_ceode_fx_cmc.m

* Update tapas_ceode_gen_erp.m

* Update tapas_ceode_int_euler.m

* Update tapas_ceode_compare_integrators_cmc.m

* Update tapas_ceode_compare_integrators_erp.m

* Update tapas_ceode_synData_cmc.m

* Update tapas_ceode_synData_erp.m

* Update CHANGELOG.md

* ceode: referral to github issues

* Initial commit of version v1.2

* Initial commit of version v1.2

* Fixed small bug related to rs-fMRI data

* rDCM Release v1.2

* rDCM Release v1.2

* rDCM Release v1.2

* Update CHANGELOG.md

* - release 4.0.0

* - init: huge init function

* Update CHANGELOG.md

* Update CHANGELOG.md

Co-authored-by: siglesias <[email protected]>
Co-authored-by: Christoph Mathys <[email protected]>
Co-authored-by: Benoît Béranger <[email protected]>
Co-authored-by: Lars Kasper <[email protected]>
Co-authored-by: Christoph Mathys <[email protected]>
Co-authored-by: Eduardo Aponte <[email protected]>
Co-authored-by: Stefan Frässle <[email protected]>
Co-authored-by: Eduardo Aponte <[email protected]>
Co-authored-by: nbuergi <[email protected]>
Co-authored-by: Eduardo Aponte <[email protected]>
Co-authored-by: jsheunis <[email protected]>
Co-authored-by: Lars Kasper <[email protected]>
Co-authored-by: [ofaull] <[[email protected]]>
Co-authored-by: Matthias Müller-Schrader <[email protected]>
Co-authored-by: dschoebi <[email protected]>
  • Loading branch information
16 people authored Sep 9, 2020
1 parent 45beaf2 commit 416a9fe
Show file tree
Hide file tree
Showing 166 changed files with 7,371 additions and 5,076 deletions.
61 changes: 61 additions & 0 deletions .admin/tapas_find_dependencies.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
function tapas_find_dependencies()
% function finding dependencies of tapas toolboxes
%
%
% (C) 2020 Matthias Müller-Schrader TNU-IBT Universität Zürich & ETH Zürich
%

% parameters
exclDir = {'.','..','.admin','.git','misc'};
useAg = false; % otherwise use ack
ignoreInds = [7,6]; %Ignore the first and last indices (strange output from ag)
printCommands = true;

cutInds = @(x) x(ignoreInds(1)+1:end - ignoreInds(2) - 1);
f = mfilename('fullpath');
[tdir, ~, ~] = fileparts(f);
pdir = tdir(1:end-7); % '/.admin' -> is tapas folder (without last '/')
curr_dir = pwd;
cd(pdir);
dr = dir(pdir);
dr = dr([dr.isdir]); % only folders

dr = dr(~ismember({dr.name},exclDir));

nDir = numel(dr);
needAlso = cell(1,nDir);
for iDir = 1:nDir
fprintf(1,'==========%s===============\n',dr(iDir).name)
drPath = strcat(pdir,filesep,dr(iDir).name);
functs = tapas_get_functions_in_sub_dirs(drPath,false);
for iFun = 1:numel(functs)
funct = functs{iFun};
funct = strrep(funct,'.m','');
if useAg
cmd_s = 'ag';
else
cmd_s = 'ack';
end
cmd = sprintf('%s %s -l -w --ignore-dir %s',cmd_s,funct,dr(iDir).name);
% --range-start=''^sub \\w+''
[stat,ret] = system(cmd);
if stat && isempty(ret)
continue;
end
%disp(ret)
retc = split(ret,newline);
if useAg
retc = cellfun(cutInds,retc,'UniformOutput',false);
end
ise = cellfun(@isempty,retc);
if all(ise)
continue;
end
retc = retc(~ise);
fprintf(1,'%s\n',funct)
fprintf(1,'\t%s\n',retc{:});
end
end


cd(curr_dir);
47 changes: 47 additions & 0 deletions .admin/tapas_get_functions_in_sub_dirs.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
function functs = tapas_get_functions_in_sub_dirs(parDir,getFullPath)
% Function returning the names of matlab functions in dir and subdirs.
%
% IN
% parDir default: pwd
% Starting here.
% getFullPath default: true
% Return full path to file (otherwise just function name).
%
% OUT
% functs
% Function names/paths in cell array
%
% Author(s): Matthias Mueller-Schrader
% (c) Institute for Biomedical Engineering, ETH and University of Zurich, Switzerland

% TODO: Include also .p, .mlx and .mex files


if nargin < 1 || isempty(parDir)
parDir = pwd;
end

if nargin < 2 || isempty(getFullPath)
getFullPath = true;
end

ret = dir(parDir);
names = {ret.name};
isdirs = [ret.isdir];
dirnames = names(isdirs);
dirnames(strcmp(dirnames,'.')|strcmp(dirnames,'..')) = []; % get rid of '.' and '..' in unix.
mfilenames = names(endsWith(names,'.m'));
if ~getFullPath
mfilenames = replace(mfilenames,'.m','');
else
% = {ret.folder};
folders = cell(1,numel(mfilenames));
folders(:) = {[ret(1).folder,filesep]};
mfilenames = join([folders;mfilenames],'',1);
end
functs = mfilenames;
for iDir = 1:numel(dirnames)
functs = [functs,getFunctionsInSubDirs([parDir,filesep,dirnames{iDir}],getFullPath)];%#ok
end


3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,5 @@ lib
*.asv
*.DS_Store
.idea
.idea/*
.idea/*
examples
27 changes: 23 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,25 @@
# Changelog
TAPAS toolbox

## [4.0.0] 2020-09-09

### Added
- [ceode](ceode/README.md): Toolbox to integrate delay differential equations (DDEs) underlying convolution based Dynamic Causal Models for ERPs.
- task/FDT: Filter Detection Task [version 0.2.2](task/FDT/README.md)
- [citation information](CITATION.cff)

### Changed
- rDCM: [version v1.2](rDCM/CHANGELOG.md)
- HUGE: removed deprecated functions
- external toolboxes are now managed as matlab packages

### Fixed
- Fixed name collision issue due to mcmcdiag toolbox (see [issue 106](https://github.com/translationalneuromodeling/tapas/issues/106))

### Known issues
- h2gf (beta): demo script currently does not work


## [3.3.0] 2020-07-17

### Added
Expand All @@ -12,7 +31,7 @@ TAPAS toolbox
### Changed
- HGF: v6.0 released
- SERIA: The constraints matrix is now automatically plot by
tapas\_sem_\display_posterior.m
tapas_sem_display_posterior.m
- SERIA: Python code is now updated to python 3.7 and the requirement file
now uses the latest libraries (numpy, scipy, cython).
- SERIA: Posterior plots includes fits of the complete group.
Expand Down Expand Up @@ -78,11 +97,11 @@ TAPAS toolbox
## [3.0.0] 2018-09-09

### Added
- tapas\_get\_tapas\_revision.m outputs the branch and hash of the repository.
- tapas_get_tapas_revision.m outputs the branch and hash of the repository.
- Revision is printed when initiliazing tapas.
- Contributor License Agreement (CLA) file
- CONTRIBUTING.md explaining coding and style guidelines, signing procedure for CLA file
- Include the function tapas\_get\_current\_version.m.
- Include the function tapas_get_current_version.m.
- Implements download of example data from the server using
tapas_download_example_data.
- Now there is log file that list the versions of tapas, the download link
Expand All @@ -97,7 +116,7 @@ TAPAS toolbox
### Changed
- README.md to include reference to CONTRIBUTING.md and explanation of CLA
- Dropped 4 digits versioning for 3.
- The version of tapas is now read from misc/log\_tapas.txt. It is the first
- The version of tapas is now read from misc/log_tapas.txt. It is the first
line of this file.
- Updated the documentation of SEM.
- Updated SEM to include hierarchical models for inference.
Expand Down
27 changes: 27 additions & 0 deletions CITATION.cff
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
cff-version: 1.1.0
message: If you use this software, please cite it as below.
authors:
- family-names: Aponte
given-names: Eduardo
- family-names: Brodersen
given-names: Kay
- family-names: Frässle
given-names: Stephan
- family-names: Harrison
given-names: Olivia
- family-names: Kaspers
given-names: Lars
- family-names: Mathys
given-names: Christoph
- family-names: Müller-Schrader
given-names: Matthias
- family-names: Schöbi
given-names: Dario
- family-names: Yao
given-names: Yu
title: "TAPAS - Translational Algorithms for Psychiatry-Advancing Science"
version: 4.0.0
date-released: 2020-09-09
repository-code: "https://github.com/translationalneuromodeling/tapas"
url: "http://www.translationalneuromodeling.org/tapas"
license: GPL-3.0-or-later
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
![TAPAS Logo](misc/TapasLogo.png?raw=true "TAPAS Logo")

*Version 3.3.0*
*Version 4.4.0*

T A P A S - Translational Algorithms for Psychiatry-Advancing Science.
========================================================================
Expand All @@ -21,6 +21,7 @@ psychiatry, computational neurology, and computational psychosomatics.

Currently, TAPAS includes the following packages:

- [ceode](ceode/README.md): Continuous Extension of ODE methods. A toolbox for robust estimation of convolution based Dynamic Causal Models (DCMs) for evoked responses (ERPs).
- [HGF](HGF/README.md): The Hierarchical Gaussian Filter; Bayesian inference
on computational processes from observed behaviour.
- [HUGE](huge/README.md): Variational Bayesian inversion for hierarchical
Expand All @@ -32,6 +33,9 @@ unsupervised generative embedding (HUGE).
- [SEM](sem/README.md): SERIA Model for Eye Movements (saccades and anti-saccades) and Reaction Times.
- [VBLM](VBLM/README.txt): Variational Bayesian Linear Regression.

And the following tasks:
- [FDT](task/FDT/README.md): Filter Detection Task.

TAPAS is written in MATLAB and distributed as open source code under
the GNU General Public License (GPL, Version 3).

Expand Down
14 changes: 14 additions & 0 deletions ceode/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Changelog
Toolbox to integrate delay differential equations (DDEs) underlying convolution based Dynamic Causal Models for ERPs.
The method uses a continuous extension of an Euler method, resulting in a robust and fast integration of the DDE.


## [1.0] 25-08-2020

### Added
- Original release of the ceode toolbox as part of the open-source software package TAPAS.
- MATLAB functions implementing the necessary steps to use ceode within the functionality of SPM.
- A brief tutorial tapas_ceode_compare_integrators_erp.m and tapas_ceode_compare_integrators_cmc.m that demonstrate
the confound of the standard, default integration scheme in SPM12.
- Documentation has been added in the README.md, and throughout the code

Loading

0 comments on commit 416a9fe

Please sign in to comment.