Jussi Tohka software

Welcome to Jussi Tohka's software page

On this page, you will find links to all software published by my group. Mostly these are licensed under an MIT type open source license, but there are exceptions so be sure to check the license information of each software. All software linked from this page is provided "as is" without express or implied warranty. The authors make no representations about the suitability of the software for any purpose.

Check also my github page. There you can find the most recent versions of some of the software and also some additional miscellaneous functions related to specific papers.

c/c++ programs/libraries:

Dualsurfacemin : An object oriented implementation for the dual surface minimization (DSM) algorithm. The dualsurfacemin is a C++ implementation of the fully automatic dual surface minimization (DSM) algorithm for the optimization of deformable surfaces. The method is developed for automatic surface extraction from noisy volumetric images.

MRFSEG+GAMIXTURE Software Bundle :MRFSEG+GAMIXTURE is a collection of open-source software tools written in C implementing a flexible voxel classification framework. The framework is based on a novel genetic algorithm based finite mixture model (GAMIXTURE) and a standard 3-D Markov random field (MRF) based on the iterative conditional modes (ICM) algorithm (MRFSEG). The key novelty in the MRFSEG program is the application of the configuration file to control MRF parameters. The software package is to be extended with a novel inhomogeneous MRF algorithm allowing even more flexible spatial and intensity information modeling. At the moment the software supports Analyze 7.5 images.

SVPASEG An extension of the above package dealing better with intensity nonuniformities is also available (see J. Tohka , I.D. Dinov, D.W. Shattuck, and A.W. Toga. Brain MRI Tissue Classification Based on Local Markov Random Fields, Magnetic Resonance Imaging, 28(4): 557 - 573 , 2010.). Now, supports both Analyze and NIFTI-files. Note that this software contains all the functionalities of the MRFSEG package above. This is meant to be a flexible voxel classification framework that can be easily tuned for particular applications. If, however, you're interested in partial volume estimation in high quality T1-weighted brain MRI, I would suggest to try PVEMRI below.

SPHERESMOOTH : Surface smoothing without shrinkage.

Matlab functions and toolboxes

ISC Toolbox (New: Version 2.1 released)

A Matlab toolbox for fMRI frequency-specific inter-subject correlation analysis. This is a toolbox to perform inter-subject correlation based analysis of fmri data in Matlab as well as a GUI for the visualization of the analysis results. The toolbox contains various functions to carry out the inter-subject correlation (ISC) analysis, which can be run from a GUI. A set of visualization tools - particularly designed for ISC analyses - are intergrated to the GUI. Visualization tools contain functionalities to which standard functional neuroimaging packages were difficult to adapt. The main references explaining the analyses are:

J.-P. Kauppi, I.P. Jääskeläinen, M. Sams and J. Tohka. Inter-subject correlation of brain hemodynamic responses during watching a movie: localization in space and frequency, Frontiers in Neuroinformatics, 4:5, 2010.

J.-P. Kauppi, J. Pajula J and J. Tohka (2014). A Versatile Software Package for Inter-subject Correlation Based Analyses of fMRI. Frontiers in Neuroinformatics, 8:2, 2014.

DogEll for ultrasound segmentation

DoGEll software for ultrasound fetal head segmentation (for nonprofit purposes only, TUT limited license). This is a fast implementation (C with Matlab wrapper) of the winning method of the ISBI2012 competition. References:

A. Foi, M. Maggioni, A. Pepe, S. Rueda, J.A. Noble, A. T. Papageorghiou, and J. Tohka . Difference of Gaussians Revolved Along Elliptical Paths for Ultrasound Fetal Head Segmentation. Computerized Medical Imaging and Graphics , 38(8): 774 - 784, 2014 .[Software (Matlab)] [Preprint]

S. Rueda, S. Fathima, C.L. Knight, M. Yaqub, A. T. Papageorghiou, B. Rahmatullah, A. Foi, M. Maggioni, A. Pepe, J. Tohka , R.V. Stebbing, J.E. McManigle, A. Ciurte, X. Bresson, M. Bach Cuadra, C. Sun, G. V. Ponomarev, M. S. Gelfand, M. D. Kazanov, C.-W. Wang, H.-C. Chen, C.-W. Peng, C.-M. Hung, and J.A. Noble. Evaluation and Comparison of Current Fetal Ultrasound Image Segmentation Methods for Biometric Measurements: A Grand Challenge.IEEE Transactions on Medical Imaging 33(4):797 - 813, 2014

BEE model selection

Model selection with Bayesian error estimator (also Python implementation available). This is an implementation of the parametric Bayesian Error Estimator for model selection purposes. In small-sample scenarios using parametric Bayesian error estimator can reduce the variance of the typical cross-validation based non-parametric error estimates. Also, it is fast to compute.

H. Huttunen, and J. Tohka . Model Selection for Linear Classifiers using Bayesian Error Estimation. Pattern Recognition , 48(11): 3739 - 3748, 2015. [Preprint] [Software]

Matlab functions and toolboxes:

Partial volume estimation in brain MRI

pvemri2 [Download] : A matlab implementation of the partial volume estimation for brain MRI(Tohka, Zijedenbos, Evans, NeuroImage 2004). The function also implement "the incremental k-means" based preliminary segmentation (Manjon et al MRM 2008). I'll also urge you to see our recent paper on benefits of non-local means filtering to partial volume estimation (Manjon, Tohka Robles, NeuroImage 2010) and the related code from Jose Manjon's website.

Installation: You'll need to compile two c files into mex. Saying

mex c_icm_trans.c

mex c_tissue_fractions.c

works most of the time. If for some reason a pure Matlab implementation (no mex files) is needed, it is here: pvemri2.m [Download] .

The new fast algorithms are described in J. Tohka. FAST-PVE: Extremely Fast Markov Random Field Based Brain MRI Tissue Classification. SCIA 2013, Scandinavian Conference on Image Analysis, Finland, 2013, Lecture Notes in Computer Science vol 7944 pp. 266 - 276, 2013. [Preprint] .

pvemri [Download (old version; for compatibility reasons; this one is not recommended anymore)]: A matlab implementation of the partial volume estimation for brain MRI (Tohka, Zijedenbos, Evans, NeuroImage 2004). Contains "pure" matlab implementation of the algorithm (slow, pvemri.m) and a very fast mex-based implementation (pvemrimex.m), which is recommended. The package includes mex files for 32-bit Windows XP and 32-bit Linux OS. If you have some other system you'll need to compile the included c file into mex-file. Saying mex c_icm_trans.c works most of the time. Please note that the two versions differ in order the voxels are traversed in the ICM algorithm. This can cause slight differences in the segmentation results between the two versions of the algorithm, none of them being "more correct" than the other. The algorithms are still fully deterministic.

ICA fMRI-Artifact Remover

A Matlab toolbox for fMRI artifact reduction using ICA and global decision trees described in

J. Tohka , K. Foerde, A.R. Aron, S. M. Tom, A.W. Toga, and R.A. Poldrack. Automatic Independent Component Labeling for Artifact Removal in fMRI. NeuroImage, 39(3):1227-45, 2008. [Software] [Pubmed Central version]

A matlab package for the artifact identification using readily trained Global Decision Tree classifiers (a brief manual is included in the package. The manual reflects version 1.1 and it has not been updated since version 1.1) [Download version 1.1] [Download version 1.1.1] [Download version 1.1.2]

A matlab package for training the Global Decision Tree classifiers for the artifact identification (a brief manual is included in the package. The manual reflects version 1.2 and no updates to the manual have been done since version 1.2.) [Download version 1.1] [Download version 1.2][Download version 1.2.1]

To use this package you will also need NiFTI tools which can be downloaded here

(Main) differences between new versions and the fmri_ica_classify 1.1 and fmri_ica_training 1.2:

fmri_ica_classify version 1.1.1 and fmri_ica_training version 1.2.1: These have been updated to use load_untouch_nii.m (see NiFTI tools page for details about differences between load_nii.m and load_untouch_nii.m). However, since the artifact reduction tool does not modify and/or write any image files (it rather relies on FSL programs to do the actual processing), it is not dangerous to use an older version. Thus, those who have crafted the tool to suit their needs should probably continue to use the old versions (the version 1.1 of the classifier and the version 1.2 of the classifier training).

fmri_ica_classify version 1.1.2: This was updated to use fsl_regfilt for denoising to conform to versions 3.x of the melodic software. The end result should be the same as with the older versions which used melodic -f for the same purpose. Note however that file naming conventions are different between fsl_regfilt and melodic -f . Also, the file masking seems to be different (fsl_regfilt seems not to mask files as melodic -f did).

Important : Please read the related paper and manuals. Only preliminary testing has been done, so bugs may exist...

Hemisphere segmentation in brain MRI: Adaptive Disconnection

ADisc version 1.1[Download]: Adaptive Disconnection is an algorithm for segmentating a brain MRI into left and right cerebrum, left and right cerebellum, and brain stem. It does this without any stereotactic registration just needing partial volume estimates to work. These can be obtained through pvemri (see above or [Download]). This was a part of Lu Zhao's PhD work in my team.

This new implementation made available here is very fast requiring about 5 minutes per image in contrast to slow running times reported in L. Zhao, U. Ruotsalainen, J. Hirvonen, J. Hietala and J. Tohka . Automatic cerebral and cerebellar hemisphere segmentation in 3D MRI: adaptive disconnection algorithm. Medical Image Analysis , 14(3): 360 - 372, 2010. The algorithm itself is the same one.

Version history version 1.0 (ADisc.zip): the original version; version 1.1 (current, version, ADisc11.zip): Minor bugs in function expand_tfe.m and shrink_tfe.m corrected.