├── README.md ├── dramms-1.4.1-source.tar.gz ├── dramms-1.4.1-source ├── AUTHORS.txt ├── BasisProject.cmake ├── CMakeLists.txt ├── COPYING.txt ├── CTestConfig.cmake ├── ChangeLog.txt ├── INSTALL.txt ├── README.txt ├── TODO.txt ├── build │ ├── CMakeLists.txt │ └── FastPD.patch ├── config │ └── Settings.cmake ├── doc │ ├── AllExamples.png │ ├── CMakeLists.txt │ ├── DRAMMS_Flyer.pdf │ ├── DRAMMS_Flyer.tex │ ├── Framework.jpg │ ├── RoleOfConfidenceMap.jpg │ ├── RoleOfOptimalAttributes.jpg │ ├── about.rst │ ├── changelog.rst │ ├── cmake.png │ ├── download.rst │ ├── faq.rst │ ├── fastpd.rst │ ├── index.rst │ ├── installation.rst │ ├── manual.rst │ ├── people.rst │ ├── publications.rst │ ├── references.bib │ ├── static │ │ ├── brazil.jpg │ │ ├── dramms.css │ │ ├── email-icon.jpg │ │ ├── france.jpg │ │ ├── germany.jpg │ │ ├── icon.gif │ │ └── logo.png │ ├── tools │ │ ├── CalculateRAVENS.png │ │ ├── combine.rst │ │ ├── defop.rst │ │ ├── jacobian.rst │ │ ├── ravens.rst │ │ └── warp.rst │ ├── tutorials.rst │ └── tutorials │ │ ├── 2DHistMR.rst │ │ ├── 2DSimulated.rst │ │ ├── 2a_2DSimulated.png │ │ ├── 2b_3DMouseBrain_Histology2MRI.png │ │ ├── 3a_3DHealthyBrain_SkullStripped.png │ │ ├── 3b_3DHealthyBrain_RawImageWithSkull.png │ │ ├── 3c_3DLesionedBrain_NormalizationToTemplate.png │ │ ├── 3d_3DTumorBrain_RecurrenceNormalizationToTemplate.png │ │ ├── 3d_3DTumorBrain_RecurrenceNormalizationToTemplate_cronal.png │ │ ├── 3e_3DCardiac_CrossSubjectStripped.png │ │ ├── 3g_3DCardiacLongitudinal.png │ │ ├── 3g_3DCardiacMotion.jpg │ │ ├── 3h_3DBreast_CancerGrowth.png │ │ ├── 3j_3DProstate_Hisotology2MRI.png │ │ ├── 3k_3DMouseBrain_MouseDevelopment.png │ │ ├── 3l_3DPediatricBrain_BabyGrowth.png │ │ ├── BrainSkullStripped.rst │ │ ├── BrainWithLesion.rst │ │ ├── BrainWithSkull.rst │ │ ├── BrainWithTumorRecurrence.rst │ │ ├── BreastCancerChange_NonResponder.png │ │ ├── BreastLongitudinal.rst │ │ ├── CardiacCrossSubjects.rst │ │ ├── CardiacLongitudinal.rst │ │ ├── CardiacMotionMovie.gif │ │ ├── MouseBrainLongitudinal.rst │ │ ├── PediatricBrainLongitudinal.rst │ │ ├── ProstateHist2MRI.rst │ │ ├── intro2a_2DSimulated.png │ │ ├── intro2b_3DMouseBrain_Histology2MRI.png │ │ ├── intro3a_3DHealthyBrain_SkullStripped.png │ │ ├── intro3b_3DHealthyBrain_RawImageWithSkull.png │ │ ├── intro3c_3DLesionedBrain_NormalizationToTemplate.png │ │ ├── intro3d_3DTumorBrain_RecurrenceNormalizationToTemplate.png │ │ ├── intro3e_3DCardiac_CrossSubjectStripped.png │ │ ├── intro3g_3DCardiacLongitudinal.png │ │ ├── intro3h_3DBreast_CancerGrowth.png │ │ ├── intro3j_3DProstate_Hisotology2MRI.png │ │ ├── intro3k_3DMouseBrain_MouseDevelopment.png │ │ └── intro3l_3DPediatricBrain_BabyGrowth.png ├── src │ ├── CMakeLists.txt │ ├── common │ │ ├── CMakeLists.txt │ │ ├── cres.cxx │ │ ├── cres.h │ │ ├── general.cxx │ │ ├── general.h │ │ ├── image.cxx │ │ ├── image.h │ │ ├── image.hxx │ │ ├── imageio.cxx │ │ ├── imageio.h │ │ ├── matrix.cxx │ │ ├── matrix.h │ │ ├── mvcd.cxx │ │ ├── mvcd.h │ │ ├── utilities.cxx │ │ └── utilities.h │ ├── dramms.sh.in │ └── tools │ │ ├── ApplyTransform.cxx │ │ ├── CMakeLists.txt │ │ ├── CalculateGaborTextures.cxx │ │ ├── CalculateImageSimilarity.cxx │ │ ├── CalculateJacobianMap.cxx │ │ ├── CalculateRavensMaps.cxx │ │ ├── CheckTwoImages.cxx │ │ ├── CombineFeatureLists.cxx │ │ ├── CombineTransforms.cxx │ │ ├── ConvertDeformation.cxx │ │ ├── ConvertImage.cxx │ │ ├── Deform2D.cxx │ │ ├── Deform3D.cxx │ │ ├── DiscreteOptimizationUtilities.cxx │ │ ├── DiscreteOptimizationUtilities.h │ │ ├── GeneralUtilities.cxx │ │ ├── GeneralUtilities.h │ │ ├── GenerateGaborListFile.cxx │ │ ├── GenerateImageListFile.cxx │ │ ├── ImageOperation.cxx │ │ ├── MatchHistograms.cxx │ │ └── TransformOperation.cxx └── test │ ├── CMakeLists.txt │ ├── baseline │ ├── H08c_to_H09c_default_affine.nii.gz │ ├── H08c_to_H09c_default_noaffine.nii.gz │ ├── H08c_to_H09c_with_initdef.nii.gz │ ├── cardiac_T05_to_T01.hdr │ ├── cardiac_T05_to_T01.img │ ├── jac_H08c_to_H09c.nii.gz │ ├── jac_na01_RPI_to_002_RPI.nii.gz │ ├── na01_RPI_to_002_RPI.nii.gz │ ├── na01_RPI_to_002_RPI_nn.nii.gz │ ├── ravens_H08c_to_H09c_1.nii.gz │ └── warped_H08c_to_H09c.nii.gz │ └── input │ ├── 002_ds_analyze.hdr │ ├── 002_ds_analyze.img │ ├── H08c.nii.gz │ ├── H08c_tissueforravens.nii.gz │ ├── H09c.nii.gz │ ├── cardiacT01c.hdr │ ├── cardiacT01c.img │ ├── cardiacT05c.hdr │ ├── cardiacT05c.img │ ├── def_H08c_to_H09c_noaffine.nii.gz │ ├── na01_ds_analyze.hdr │ └── na01_ds_analyze.img └── dramms-1.5.1-source.tar.gz /README.md: -------------------------------------------------------------------------------- 1 | DRAMMS Image Registration Toolbox 2 | ======================================================= 3 | 4 | 5 | **Introduction**: DRAMMS is a software package designed for 2D-to-2D and 3D-to-3D deformable medical image registration tasks. 6 | 7 | 8 | 9 | **Download**: github folder dramms-1.5.1 (https://github.com/ouyangming/DRAMMS/blob/master/dramms-1.5.1-source.tar.gz) 10 | 11 | or DRAMMS website (http://www.cbica.upenn.edu/sbia/software/dramms/download.html) 12 | 13 | **Installation**: http://www.cbica.upenn.edu/sbia/software/dramms/installation.html 14 | 15 | 16 | **Applications**: Some typical applications of DRAMMS include, but are not limited to, 17 | 18 | - Cross-subject registration of the same organ (can be brain, breast, cardiac, etc); 19 | 20 | - Mono- and Multi-modality registration (MRI, CT, histology); 21 | 22 | - Longitudinal registration (pediatric brain growth, cancer development, mouse brain development, etc); 23 | 24 | - Registration under missing correspondences (e.g., vascular lesions, tumors, histological cuts). 25 | 26 | 27 | **Features**: 28 | 29 | - Fully-automatic --- no need for segmentation or any prior knowledge or user-initialization/intervention; 30 | 31 | - User-friendly --- two input images, two output (the registered image and the deformaiton field); 32 | - Generality --- default parameters work reasonably well for most cases (raw images, preprocessed images, multi-site data, etc) 33 | 34 | 35 | **Environment**: runs in UNIX/Mac, takes Nifti/ANALYZE/MetaImage format. 36 | 37 | **Demonstration & Tutorial**: http://www.cbica.upenn.edu/sbia/software/dramms/tutorials.html 38 | 39 | 40 | 41 | 42 | ----- 43 | 44 | 45 | 46 | 47 | **Software development**: Yangming Ou, Andreas Schuh, Aris Sotiras, Christos Davatzikos (advisor). 48 | 49 | **Algorithm authors**: Yangming Ou, Aris Sotiras, Nikos Paragios, Christos Davatzikos. 50 | 51 | **Released by**: Section of Biomedical Image Analysis (SBIA), University of Pennsylvania 52 | -------------------------------------------------------------------------------- /dramms-1.4.1-source.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source.tar.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/AUTHORS.txt: -------------------------------------------------------------------------------- 1 | 2 | Section of Biomedical Image Analysis 3 | Department of Radiology 4 | University of Pennsylvania 5 | 3600 Market Street, Suite 380 6 | Philadelphia, PA 19104 7 | 8 | Web: http://www.rad.upenn.edu/sbia/ 9 | Email: sbia-software at uphs.upenn.edu 10 | 11 | Copyright (c) 2011-2013 University of Pennsylvania. All rights reserved. 12 | See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 13 | 14 | 15 | 16 | INTRODUCTION 17 | ============ 18 | 19 | This document lists the authors of this software and further people who 20 | significantly contributed to it. 21 | 22 | See the README and COPYING documents for general information, 23 | acknowledgements of contributions other kind, and licensing. 24 | 25 | 26 | 27 | SOFTWARE AUTHORS 28 | ================ 29 | 30 | The original author of this software is: 31 | 32 | - Yangming Ou Yangming.Ou@uphs.upenn.edu 33 | 34 | 35 | 36 | SOFTWARE CONTRIBUTORS 37 | ===================== 38 | 39 | Listed below are the names of the ones who contributed notably to this software. 40 | 41 | - Aristeidis Sotiras Helped implement discrete optimization part based FastPD. 42 | 43 | - Andreas Schuh He greatly helped to improve the quality of the software and 44 | contributed implementations for reading and writing NIfTI-1 45 | images using the nifticlib library. 46 | 47 | 48 | 49 | ACKNOWLEDGEMENT 50 | =============== 51 | 52 | Discrete optimization part is based on Demo version of FastPD algorithm by 53 | 54 | - Nikos Komodakis http://www.csd.uoc.gr/~komod/FastPD/index.html 55 | - Nikos Paragios 56 | 57 | Gabor feature extraction and deformation data structures are based on code from 58 | 59 | - Yiqiang Zhan 60 | - Dinggang Shen 61 | 62 | 63 | We sincerely thank all the following testers for their precious feedback and suggestions 64 | during the development of DRAMMS software 65 | 66 | within SBIA 67 | 68 | Hamed Akbari 69 | Harsha Battapady 70 | Vanessa Clark 71 | Xiao Da 72 | Jimit Doshi 73 | Harini Eavani 74 | Guray Erus 75 | Bilwaj Gaonkar 76 | Meng-Kang (Michael) Hsieh 77 | Madhura Ingalhalikar 78 | Dongjin Kwon 79 | Drew Parker 80 | Alex Smith 81 | Erdem Varol 82 | Steffen Wachenfeld 83 | Dong Hye Ye 84 | 85 | outside SBIA 86 | 87 | Nikolaos Koutsouleris (Germany) 88 | Helene Langet (France) 89 | Lena Rademacher (Germany) 90 | Marcus Zanetti (Brazil) 91 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/BasisProject.cmake: -------------------------------------------------------------------------------- 1 | ############################################################################## 2 | # @file BasisProject.cmake 3 | # @brief Meta-data of this BASIS project. 4 | # 5 | # This file defines project meta-data by calling the basis_project() function. 6 | # This meta-data is used by BASIS to setup the project. Moreover, if the 7 | # project is a module of another BASIS project, the dependencies to other 8 | # modules have to be specified here such that the top-level project can analyze 9 | # the inter-module dependencies 10 | # (see page Project Modularization of BASIS documentation). 11 | # 12 | # @sa http://www.rad.upenn.edu/sbia/software/basis/standard/modules/ 13 | # 14 | # However, not only dependencies to other modules can be specified here, 15 | # but also dependencies on external packages. A more flexible alternative to 16 | # resolve external dependencies is to add the corresponding basis_find_package() 17 | # statements to the Depends.cmake file. This should, however, only be done 18 | # if specifying the dependencies as arguments to the basis_project() function 19 | # cannot be used to resolve the dependencies properly. If you only need to 20 | # make use of additional variables set by the package configuration file 21 | # of the external package or the corresponding Find.cmake module, 22 | # add the related CMake code to the Settings.cmake file instead. 23 | # 24 | # Example: 25 | # @code 26 | # basis_project ( 27 | # # ------------------------------------------------------------------------ 28 | # # meta-data 29 | # NAME MyProject 30 | # PROVIDER PackageProvider 31 | # VERSION 2.1.4 32 | # DESCRIPTION "This is the description of the project named" 33 | # " MyProject which follows BASIS." 34 | # AUTHOR "Max Muster" 35 | # COPYRIGHT "2011-2013 University of Pennsylvania" 36 | # LICENSE "See COPYING file." 37 | # CONTACT "SBIA Group " 38 | # # ------------------------------------------------------------------------ 39 | # # dependencies 40 | # DEPENDS NiftiCLib PythonInterp 41 | # OPTIONAL_DEPENDS MPI 42 | # TEST_DEPENDS Perl 43 | # ) 44 | # @endcode 45 | # 46 | # Copyright (c) 2011--2013 University of Pennsylvania. All rights reserved.
47 | # See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 48 | # 49 | # Contact: SBIA Group 50 | ############################################################################## 51 | 52 | # Note: The #<*> patterns are required by the basisproject tool and should be 53 | # kept on a separate line as last commented argument of the corresponding 54 | # options of the basis_project() command. 55 | 56 | basis_project ( 57 | # -------------------------------------------------------------------------- 58 | # meta-data 59 | NAME DRAMMS 60 | PROVIDER SBIA 61 | VERSION 1.4.1 # always 0.0.0 in trunk, but should be the current version in braches and tags 62 | DESCRIPTION "Deformable Registration via Attribute Matching and Mutual-Saliency weighting" 63 | AUTHORS "Yangming Ou" "Aristeidis Sotiras" "Andreas Schuh" 64 | COPYRIGHT "2011--2013 University of Pennsylvania" 65 | LICENSE "See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file." 66 | CONTACT "SBIA Group " 67 | # -------------------------------------------------------------------------- 68 | # dependencies 69 | DEPENDS 70 | NiftiCLib 71 | DRAMMSFastPD # patched FastPD library 72 | # 73 | OPTIONAL_DEPENDS 74 | # 75 | TEST_DEPENDS 76 | # 77 | OPTIONAL_TEST_DEPENDS 78 | # 79 | ) 80 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | ############################################################################## 2 | # @file CMakeLists.txt 3 | # @brief Root build configuration file. 4 | # 5 | # Copyright (c) 2011, 2012 University of Pennsylvania. All rights reserved.
6 | # See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | # 8 | # Contact: SBIA Group 9 | ############################################################################## 10 | 11 | # ---------------------------------------------------------------------------- 12 | # minimum required CMake version 13 | cmake_minimum_required (VERSION 2.8.4) 14 | 15 | # ---------------------------------------------------------------------------- 16 | # version of BASIS template used by this project 17 | set (TEMPLATE_VERSION 1.7) 18 | 19 | # ---------------------------------------------------------------------------- 20 | # include BASIS policies, settings, macros, and functions 21 | 22 | # circumvent issue with CMake's find_package() interpreting these variables 23 | # relative to the current binary directory instead of the top-level directory 24 | if (BASIS_DIR AND NOT IS_ABSOLUTE "${BASIS_DIR}") 25 | set (BASIS_DIR "${CMAKE_BINARY_DIR}/${BASIS_DIR}") 26 | get_filename_component (BASIS_DIR "${BASIS_DIR}" ABSOLUTE) 27 | endif () 28 | # moreover, users tend to specify the installation prefix instead of the 29 | # actual directory containing the package configuration file 30 | if (IS_DIRECTORY "${BASIS_DIR}") 31 | list (INSERT CMAKE_PREFIX_PATH 0 "${BASIS_DIR}") 32 | endif () 33 | # if BASIS is not found, set CMAKE_INSTALL_PREFIX to invalid value if not 34 | # set explicitly at the command-line such that BASIS will still initialize 35 | # it to its defaults even though already cached 36 | find_package (BASIS) 37 | if (NOT BASIS_FOUND) 38 | if (CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) 39 | set (CMAKE_INSTALL_PREFIX "" CACHE INTERNAL "Installation prefix." FORCE) 40 | endif () 41 | message (FATAL_ERROR "BASIS not found! Please specify installation directory" 42 | " of BASIS or the location of the BASISConfig.cmake file" 43 | " using the BASIS_DIR variable.") 44 | endif () 45 | 46 | # ---------------------------------------------------------------------------- 47 | # configure build system 48 | basis_project_impl () 49 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/CTestConfig.cmake: -------------------------------------------------------------------------------- 1 | ############################################################################## 2 | # @file CTestConfig.cmake 3 | # @brief Dashboard configuration file. 4 | # 5 | # Copyright (c) 2011, 2012 University of Pennsylvania. All rights reserved.
6 | # See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | # 8 | # Contact: SBIA Group 9 | ############################################################################## 10 | 11 | # set CTest/CDash project name 12 | set (CTEST_PROJECT_NAME "DRAMMS") 13 | 14 | # start time of Nightly test model 15 | # 16 | # All Nightly tests which are executed within a time window of 24 hours 17 | # starting at the specified start time, will replace previous submissions 18 | # made within the same time frame such that for each time frame of 24 hours 19 | # only one result of test executions is present on the dashboard. 20 | # The execution of the Nightly tests is usually triggered automatically 21 | # via a scheduled cron job that is run once every 24 hours. 22 | # 23 | # Use the Continuous or Experimental test models if you want to execute 24 | # tests manually. 25 | set (CTEST_NIGHTLY_START_TIME "2:00:00 UTC") 26 | 27 | # dashboard submission to SBIA CDash server 28 | # 29 | # Note: By default, CTest does not support HTTPS as submission method. 30 | # In order to enable it, CTest (and hence CMake) has to be build 31 | # manually with the option CMAKE_USE_OPENSSL enabled. 32 | set (CTEST_DROP_METHOD "http") 33 | set (CTEST_DROP_SITE "sbia-portal.uphs.upenn.edu") 34 | set (CTEST_DROP_LOCATION "/cdash/submit.php?project=${CTEST_PROJECT_NAME}") 35 | set (CTEST_DROP_SITE_CDASH TRUE) 36 | 37 | # launchers 38 | # 39 | # See CTest.cmake module. 40 | set (CTEST_USE_LAUNCHERS 0) 41 | 42 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/INSTALL.txt: -------------------------------------------------------------------------------- 1 | 2 | Section of Biomedical Image Analysis 3 | Department of Radiology 4 | University of Pennsylvania 5 | 3600 Market Street, Suite 380 6 | Philadelphia, PA 19104 7 | 8 | Web: https://www.rad.upenn.edu/sbia/ 9 | Email: sbia-software at uphs.upenn.edu 10 | 11 | Copyright (c) 2011--2013 University of Pennsylvania. All rights reserved. 12 | See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 13 | 14 | 15 | 16 | INTRODUCTION 17 | ============ 18 | 19 | This document contains the build and installation instructions. 20 | 21 | For general build and installation instructions which apply to any software 22 | developed on top of the SBIA Build system And Software Implementation 23 | Standard (BASIS) [1], please refer to the respective how-to guide of the 24 | BASIS documentation [2]. 25 | 26 | 27 | 28 | OBTAINING A COPY OF THE SOFTWARE 29 | ================================ 30 | 31 | Please see the corresponding section of the BASIS how-to guide [2]. 32 | 33 | 34 | 35 | INSTALLING A BINARY DISTRIBUTION PACKAGE 36 | ======================================== 37 | 38 | Please see the corresponding section of the BASIS how-to guide [2]. 39 | 40 | 41 | 42 | RUNTIME REQUIREMENTS 43 | ==================== 44 | 45 | - FMRIB Software Library (FSL) 4.0 46 | 47 | Web: http://www.fmrib.ox.ac.uk/fsl/ 48 | Download: http://www.fmrib.ox.ac.uk/fsl/fsl/downloading.html 49 | Ubuntu: fsl 50 | 51 | The input images to the deformable registration implemented by DRAMMS 52 | have to be affinely coregistered. Therefore, the dramms command optionally 53 | (-a option) makes use of FSL's FLIRT command to do so. Thus, if the 54 | input images to DRAMMS are not already affinely registered and the -a option 55 | of dramms is used, FSL has to be installed on your system. 56 | 57 | 58 | 59 | BUILDING THE SOFTWARE FROM SOURCES 60 | ================================== 61 | 62 | In the following, only the additional build dependencies and CMake settings 63 | available to configure this software package are summarized. For a list of 64 | general build dependencies and step-by-step instructions on how to use CMake 65 | and GNU Make to build and install the software, please refer to the 66 | corresponding section of the BASIS how-to guide [2]. 67 | 68 | 69 | Bundle Build 70 | ------------ 71 | 72 | For the convenient build of this software together with its prerequisites, 73 | a CMake configuration file which uses CMake's ExternalProject command in 74 | order to download, configure, build, and install the prerequisites, and then 75 | this software can be found in the build/ directory of the source distribution 76 | package. 77 | 78 | Note: This bundle build may require an internet connection if not all required 79 | packages are included in the build/ directory to be able to download the 80 | source packages of the prerequisites. 81 | 82 | The steps for building the entire bundle of this software package are: 83 | 84 | 1. Change into the build/ directory of the source package: 85 | 86 | $ cd dramms-$version-source/build 87 | 88 | 2. Run CMake to configure the build: 89 | 90 | $ ccmake . 91 | 92 | In particular, configure the CMAKE_INSTALL_PREFIX where the software and 93 | its prerequisites should be installed. 94 | 95 | 3. Build and install the software and its prerequisite libraries: 96 | 97 | $ make 98 | 99 | Note that if the CMAKE_INSTALL_PREFIX is only writable by the super user, 100 | you need to run GNU Make either as root user or with sudo. 101 | 102 | 4. Remove all temporary source and build files from build/ directory (optional): 103 | 104 | $ make clean 105 | 106 | 107 | Build Dependencies 108 | ------------------ 109 | 110 | The following software has to be installed (if not optional). 111 | 112 | - BASIS >= 2.1 113 | 114 | Web Site: http://www.rad.upenn.edu/sbia/software/basis/ 115 | Download: http://www.rad.upenn.edu/sbia/software/distributions/basis-current-source.tar.gz 116 | 117 | This project is based on BASIS, a meta-project developed at SBIA to 118 | standardize and simplify the software development. 119 | 120 | - nifticlib 2.0 or greater 121 | 122 | Web: http://niftilib.sourceforge.net/ 123 | Download: http://sourceforge.net/projects/niftilib/files/nifticlib/ 124 | Ubuntu: nifticlib (maverick) 125 | 126 | - FastPD (patched) 127 | 128 | Web: http://www.csd.uoc.gr/~komod/FastPD/ 129 | Download: http://www.csd.uoc.gr/~komod/FastPD/ (registration required) 130 | 131 | The original FastPD implementation from Drs. Nikos Komodakis and Nikos Paragios 132 | has to be patched before it can be used by DRAMMS. Therefore, execute the following 133 | commands on Unix in order to build the modified version of FastPD. 134 | 135 | $ unzip FastPD_DemoVersion.zip -d dramms-fastpd 136 | $ patch -d dramms-fastpd -p1 < dramms-$version-source/build/FastPD.patch 137 | $ cd dramms-fastpd 138 | $ cmake -DCMAKE_BUILD_TYPE:STRING=Release . 139 | $ make 140 | 141 | 142 | Build Steps 143 | ----------- 144 | 145 | The common steps to build, test, and install software based on CMake, 146 | including this software, are as follows: 147 | 148 | 1. Extract source files. 149 | 2. Create build directory and change to it. 150 | 3. Run CMake to configure the build tree. 151 | 4. Build the software using selected build tool. 152 | 5. Test the built software. 153 | 6. Install the built files. 154 | 155 | On Unix-like systems with GNU Make as build tool, these build steps can be 156 | summarized by the following sequence of commands executed in a shell, 157 | where $package and $version are shell variables which represent the name 158 | of this package and the obtained version of the software. 159 | 160 | $ tar xzf $package-$version-source.tar.gz 161 | $ mkdir $package-$version-build 162 | $ cd $package-$version-build 163 | $ ccmake ../$package-$version-source 164 | 165 | - Press 'c' to configure the build system and 'e' to ignore warnings. 166 | - Set INSTALL_PREFIX and other CMake variables and options. 167 | - Continue pressing 'c' until the option 'g' is available. 168 | - Then press 'g' to generate the configuration files for GNU Make. 169 | 170 | $ make 171 | $ make test (optional) 172 | $ make install (optional) 173 | 174 | An exhaustive list of minimum build dependencies, including the build tools 175 | along detailed step-by-step build, test, and installation instructions can 176 | be found in the corresponding "Building the Software from Sources" section 177 | of the BASIS how-to guide on software installation [2]. 178 | 179 | Please refer to this guide first if you are uncertain about above steps or 180 | have problems to build, test, or install the software on your system. 181 | If this guide does not help you resolve the issue, please contact us at 182 | . In case of failing tests, please attach 183 | the output of the following command to your email: 184 | 185 | $ ctest -V &> test.log 186 | 187 | In the following, only package-specific CMake settings available to 188 | configure the build and installation of this software are documented. 189 | 190 | 191 | CMake Options 192 | ------------- 193 | 194 | DRAMMSFastPD_DIR Directory containing the DRAMMSFastPDConfig.cmake file, which 195 | is located in the build directory of the patched FastPD build. 196 | 197 | 198 | Advanced CMake Options 199 | ---------------------- 200 | 201 | (no additional advanced CMake options considered by this package) 202 | 203 | 204 | 205 | REFERENCES 206 | ========== 207 | 208 | [1] http://www.rad.upenn.edu/sbia/software/basis/ 209 | 210 | [2] http://www.rad.upenn.edu/sbia/software/basis/howto/install.html 211 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/TODO.txt: -------------------------------------------------------------------------------- 1 | - ConvertDeformation 2 | 3 | * Make sure that conversion into ITK format is correct and that the resulting deformation 4 | field can be used with ITK filters for warping images. For example, GLISTR, includes a 5 | small program named WarpImage which takes an ITK deformation field and applies it to 6 | an intensity image. It therefore uses the itk::WarpImageFilter. 7 | 8 | - DeformationOperation 9 | 10 | * Add test for composition of affine transformation and deformation field in ITK format. 11 | * Add more tests for the different usages of the program. 12 | 13 | - ComposeTransformations() in utilities.cxx 14 | 15 | * Fix composition of affine transformation and deformation field to make it more general. 16 | Rigth now it most likely only works for the use case of DRAMMS. 17 | * Implement composition of deformation field and affine transformation, i.e., 18 | T o D, where T is an affine transformation and D is a deformation field. 19 | 20 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/config/Settings.cmake: -------------------------------------------------------------------------------- 1 | ############################################################################## 2 | # @file Settings.cmake 3 | # @brief Non-default project settings. 4 | # 5 | # This file is included by basis_project_impl() after it looked for the 6 | # required and optional dependencies and the CMake variables related to the 7 | # project directory structure were defined (see BASISDirectories.cmake file 8 | # in @c PROJECT_BINARY_DIR, where BASIS is here the name of the project). 9 | # It is further included before the BasisSettings.cmake file. 10 | # 11 | # In particular, build options should be added in this file using CMake's 12 | # 13 | # option() command. Further, any common settings related to using a found 14 | # dependency can be set here if the basis_use_package() command was enable 15 | # to import the required configuration of a particular external package. 16 | # 17 | # Copyright (c) 2013 University of Pennsylvania. All rights reserved.
18 | # See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 19 | # 20 | # Contact: SBIA Group 21 | # 22 | # @ingroup BasisSettings 23 | ############################################################################## 24 | 25 | # ============================================================================ 26 | # packaging 27 | # ============================================================================ 28 | 29 | list (APPEND CPACK_SOURCE_IGNORE_FILES 30 | "build/bundle" 31 | "build/CMakeFiles" 32 | "build/CMakeCache.txt" 33 | "build/Makefile" 34 | "build/cmake_install.cmake" 35 | ) 36 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/AllExamples.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/AllExamples.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | ############################################################################## 2 | # @file CMakeLists.txt 3 | # @brief Build configuration of software documentation. 4 | # 5 | # This build configuration builds and/or installs the documentation of the 6 | # software package. The documentation can be divided into user documentation 7 | # (e.g., software manual) and developer documentation (e.g., developer's guide). 8 | # For developers, both those using a library provided by this package and the 9 | # package maintainers, the documentation of the API is of particular interest. 10 | # Developers who are responsible for maintaining this software may be provided 11 | # with even more detailed documentation of the implementation in the so-called 12 | # developer's guide. 13 | # 14 | # See the basis_add_doc() command for details on the documentation build tools 15 | # supported by BASIS for the generation of documentation from plain text files 16 | # and in-source code comments. 17 | # 18 | # Copyright (c) 2012 University of Pennsylvania. All rights reserved.
19 | # See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 20 | # 21 | # Contact: SBIA Group 22 | ############################################################################## 23 | 24 | # Exclude PDF of software manual from distribution package to reduce its size. 25 | list (APPEND CPACK_SOURCE_IGNORE_FILES "doc/DRAMMS_Software_Manual.pdf" 26 | "doc/DRAMMS_Flyer.pdf") 27 | 28 | # ============================================================================ 29 | # settings 30 | # ============================================================================ 31 | 32 | # output names of PDF's generated from reStructuredText sources (excl. extension) 33 | set (SITE_OUTPUT_NAME "${PROJECT_NAME}_Web_Site") 34 | set (MANUAL_OUTPUT_NAME "${PROJECT_NAME}_Software_Manual") 35 | set (GUIDE_OUTPUT_NAME "${PROJECT_NAME}_Developer_Guide") 36 | 37 | # in particular, EXCLUDE_FROM_DOC will be added if pre-generated files exist 38 | set (APIDOC_OPTIONS) 39 | set (SITE_OPTIONS) 40 | set (MANUAL_OPTIONS) 41 | set (GUIDE_OPTIONS) 42 | 43 | # ============================================================================ 44 | # pre-generated output files 45 | # ============================================================================ 46 | 47 | # API documentation 48 | if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/apidoc/html/index.html") 49 | basis_add_doc ("${CMAKE_CURRENT_SOURCE_DIR}/apidoc/html" DESTINATION "${INSTALL_DOC_DIR}/apidoc") 50 | list (APPEND APIDOC_OPTIONS EXCLUDE_FROM_DOC) 51 | endif () 52 | 53 | # web site 54 | foreach (N IN ITEMS ${SITE_OUTPUT_NAME} site Site) 55 | if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${N}.pdf") 56 | basis_add_doc (${N}.pdf OUTPUT_NAME "${SITE_OUTPUT_NAME}.pdf") 57 | list (APPEND SITE_OPTIONS EXCLUDE_FROM_DOC) 58 | break () 59 | endif () 60 | endforeach () 61 | 62 | # software manual 63 | foreach (N IN ITEMS ${MANUAL_OUTPUT_NAME} manual Manual UserManual SoftwareManual UserGuide userguide) 64 | if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${N}.pdf") 65 | basis_add_doc (${N}.pdf OUTPUT_NAME "${MANUAL_OUTPUT_NAME}.pdf") 66 | list (APPEND MANUAL_OPTIONS EXCLUDE_FROM_DOC) 67 | break () 68 | endif () 69 | endforeach () 70 | 71 | # developer's guide 72 | foreach (N IN ITEMS ${GUIDE_OUTPUT_NAME} guide DeveloperGuide DeveloperManual developerguide) 73 | if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${N}.pdf") 74 | basis_add_doc (${N}.pdf OUTPUT_NAME "${GUIDE_OUTPUT_NAME}.pdf") 75 | list (APPEND GUIDE_OPTIONS EXCLUDE_FROM_DOC) 76 | break () 77 | endif () 78 | endforeach () 79 | 80 | # ============================================================================ 81 | # API documentation (in-source code comments) 82 | # ============================================================================ 83 | 84 | basis_add_doc ( 85 | apidoc ${APIDOC_OPTIONS} 86 | GENERATOR Doxygen 87 | HTML_DESTINATION "${INSTALL_DOC_DIR}/apidoc" 88 | ) 89 | 90 | # ============================================================================ 91 | # comprehensive manual 92 | # ============================================================================ 93 | 94 | if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/index.rst") 95 | 96 | basis_add_doc ( 97 | softwaremanual ${MANUAL_OPTIONS} 98 | GENERATOR Sphinx 99 | BUILDER pdf html dirhtml man 100 | MAN_SECTION 7 101 | HTML_THEME ${PROJECT_PACKAGE_VENDOR_L} 102 | RELLINKS about download installation manual tutorials faq publications people 103 | SIDEBARWIDTH 280 104 | HTML_SIDEBARS searchbox globaltoc 105 | HTML_STYLE dramms.css 106 | HTML_LOGO logo.png 107 | HTML_DESTINATION "${INSTALL_DOC_DIR}/html" 108 | LATEX_TITLE "${PROJECT_NAME} Software Manual" 109 | OUTPUT_NAME "${MANUAL_OUTPUT_NAME}" 110 | AUTHORS "Yangming Ou" "Andreas Schuh" 111 | ) 112 | 113 | basis_add_custom_target (site) 114 | basis_add_custom_target (site_dirhtml) 115 | basis_add_custom_target (manual) 116 | 117 | basis_add_custom_target (softwaremanual_pdf_update 118 | COMMAND "${CMAKE_COMMAND}" -E copy_if_different 119 | "${CMAKE_CURRENT_BINARY_DIR}/latex/DRAMMS_Software_Manual.pdf" 120 | "${CMAKE_CURRENT_SOURCE_DIR}/DRAMMS_Software_Manual.pdf" 121 | ) 122 | 123 | basis_add_dependencies (softwaremanual_pdf_update softwaremanual_pdf) 124 | basis_add_dependencies (softwaremanual_html softwaremanual_pdf_update) 125 | basis_add_dependencies (softwaremanual_dirhtml softwaremanual_pdf_update) 126 | 127 | basis_add_dependencies (site softwaremanual_html) 128 | basis_add_dependencies (site_dirhtml softwaremanual_dirhtml) 129 | basis_add_dependencies (manual softwaremanual_pdf_update) 130 | 131 | # ============================================================================ 132 | # separate web site and manual 133 | # ============================================================================ 134 | 135 | else () 136 | 137 | # web site 138 | if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/site/index.rst") 139 | basis_add_doc ( 140 | site ${SITE_OPTIONS} 141 | GENERATOR Sphinx 142 | BUILDER html dirhtml pdf man 143 | MAN_SECTION 7 144 | HTML_THEME ${PROJECT_PACKAGE_VENDOR_L} 145 | RELLINKS download installation manual publications people 146 | HTML_SIDEBARS searchbox globaltoc 147 | LATEX_TITLE "${PROJECT_NAME} Web Site" 148 | OUTPUT_NAME "${SITE_OUTPUT_NAME}" 149 | ) 150 | endif () 151 | 152 | # software manual 153 | if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/manual/index.rst") 154 | basis_add_doc ( 155 | manual ${MANUAL_OPTIONS} 156 | GENERATOR Sphinx 157 | BUILDER pdf html 158 | HTML_DESTINATION "${INSTALL_DOC_DIR}/html" 159 | LATEX_TITLE "${PROJECT_NAME} Software Manual" 160 | OUTPUT_NAME "${MANUAL_OUTPUT_NAME}" 161 | ) 162 | endif () 163 | 164 | endif () 165 | 166 | # ============================================================================ 167 | # developer's guide 168 | # ============================================================================ 169 | 170 | if (EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/guide/index.rst") 171 | basis_add_doc ( 172 | guide ${GUIDE_OPTIONS} 173 | GENERATOR Sphinx 174 | BUILDER pdf html 175 | HTML_DESTINATION "${INSTALL_DOC_DIR}/guide" 176 | LATEX_TITLE "${PROJECT_NAME} Developer's Guide" 177 | OUTPUT_NAME "${GUIDE_OUTPUT_NAME}" 178 | ) 179 | endif () 180 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/DRAMMS_Flyer.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/DRAMMS_Flyer.pdf -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/DRAMMS_Flyer.tex: -------------------------------------------------------------------------------- 1 | % Copyright (c) 2012 University of Pennsylvania. All rights reserved. 2 | % See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 3 | % 4 | % Contact: SBIA Group 5 | 6 | \documentclass[a4paper,12pt]{article} 7 | 8 | \usepackage{cite} 9 | \usepackage{geometry} 10 | \usepackage{graphicx} 11 | \usepackage{subfigure} 12 | \usepackage{hyperref} 13 | \usepackage{url} 14 | 15 | \usepackage[cm]{fullpage} 16 | 17 | \usepackage{fancyvrb} 18 | \usepackage{color} 19 | 20 | \usepackage[usenames,dvipsnames]{xcolor} 21 | \definecolor{light-gray}{gray}{0.95} 22 | \newcommand{\tabincell}[2]{\begin{tabular}{@{}#1@{}}#2\end{tabular}} 23 | 24 | 25 | % Title Page 26 | \title{DRAMMS Software Flyer} 27 | \author{Yangming Ou, Andreas Schuh} 28 | 29 | \begin{document} 30 | \maketitle 31 | % \tableofcontents 32 | % \setcounter{tocdepth}{1} 33 | 34 | % \pagebreak 35 | 36 | % ============================================================================ 37 | % Introduction 38 | % ============================================================================ 39 | \section{Introduction} 40 | \label{intro} 41 | 42 | DRAMMS is a deformable image registration software package designed for 2D-to-2D and 3D-to-3D image registrations. Fig. \ref{fig:DRAMMSApplications} shows some typical applications, including, 43 | 44 | \indent -- Cross-subject registration of the same organ (brain, breast, cardiac, etc); \\ 45 | \indent -- Mono- and Multi-modality registration (MRI, CT, histology); \\ 46 | \indent -- Longitudinal registration (pediatric brain growth, cancer development, etc); \\ 47 | \indent -- Registration under partial missing correspondences (small lesions, tumors, histological cuts). \\ 48 | 49 | 50 | \begin{figure}[ht!] 51 | \centering 52 | \includegraphics[width=15cm]{AllExamples.png} 53 | \caption{Some typical DRAMMS applications.} 54 | \label{fig:DRAMMSApplications} 55 | \end{figure} 56 | 57 | \noindent {\bf{DRAMMS Homepage:}} \url{http://www.rad.upenn.edu/sbia/software/dramms/index.html} \\ 58 | \noindent {\bf{DRAMMS Manual:}} \url{http://www.rad.upenn.edu/sbia/software/dramms/_downloads/DRAMMS_Software_Manual.pdf} 59 | 60 | 61 | 62 | \section{System Requirement} 63 | \label{System} 64 | 65 | \noindent {\bf{OS:}} UNIX/LINUX or Mac. \\ 66 | \noindent {\bf{File formats:}} ANALYZE 7.5 (.hdr+.img) or NIfTI-1 (.hdr+.img, .nii, .nii.gz) images. \\ 67 | \noindent {\bf{Datatypes:}} byte, uint8, int8, short, int16, uint16, float, float32, int32. \\ 68 | \noindent {\bf{Memory:}} DRAMMS consumes considerable amount of memory ($\sim$50MB for 2D images, and $\sim$6GB for a typical pair of brain MR images $256\times256\times150$). \\ 69 | 70 | 71 | \section{Download and Install} 72 | \label{install} 73 | 74 | {\bf{Download:}} \url{http://www.rad.upenn.edu/sbia/software/dramms/download.html}. \\ 75 | {\bf{Install :}} \url{http://www.rad.upenn.edu/sbia/software/dramms/installation.html}. Requires CMake (version 2.8 or above) and GCC (version 4.1 or above). 76 | 77 | 78 | 79 | 80 | \section{Usage} 81 | \label{usage} 82 | Default usage below will get reasonable results in most cases. 83 | \begin{verbatim} 84 | dramms -S ${SourceImage} -T ${TargetImage} 85 | -O ${RegisteredImage_S2T} -D ${Deformation_S2T} 86 | \end{verbatim} 87 | More specific usage including parameter tuning in various scenarios can be found in Tutorial page \url{http://www.rad.upenn.edu/sbia/software/dramms/tutorials.html}. 88 | 89 | 90 | 91 | 92 | 93 | \begin{thebibliography}{4} 94 | 95 | \bibitem{Ou11} Yangming Ou, Aris Sotiras, Nikos Paragios, Christos Davatzikos: DRAMMS: Deformable registration via attribute matching and mutual-saliency weighting. Medical Image Analysis 15(4): 622-639 (2011). 96 | 97 | 98 | \end{thebibliography} 99 | 100 | 101 | % ============================================================================ 102 | % Bibliography 103 | % ============================================================================ 104 | \bibliographystyle{splncs03} 105 | \bibliography{references} 106 | 107 | \end{document} 108 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/Framework.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/Framework.jpg -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/RoleOfConfidenceMap.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/RoleOfConfidenceMap.jpg -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/RoleOfOptimalAttributes.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/RoleOfOptimalAttributes.jpg -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/about.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: About DRAMMS Algorithm 17 | 18 | .. meta:: 19 | :description: Brief overview of DRAMMS algorithm. Attribute Matching and Mutual-Saliency Weighting. 20 | :keywords: DRAMMS Algorithm. 21 | 22 | 23 | .. raw:: latex 24 | 25 | \pagebreak 26 | 27 | 28 | ==================== 29 | About the Algorithm 30 | ==================== 31 | 32 | DRAMMS consists of two major components -- attribute matching (AM) and mutual-saliency (MS) weighting. A systematic sketch is shown in the following figure. 33 | 34 | .. _fig_framework: 35 | 36 | .. figure:: Framework.jpg 37 | :alt: DRAMMS framework. 38 | :align: center 39 | :width: 90% 40 | :figwidth: 90% 41 | 42 | 43 | Attribute Matching (AM) 44 | ======================= 45 | 46 | DRAMMS characterizes each voxel by the geometric texture attributes around this voxel. We extract multi-scale and multi-resolution Gabor attributes at each voxel, selects the optimal components, and assembles them into a high-dimensional attribute vector for describing each voxel. 47 | 48 | Compared to the traditionally used intensity information, texture attributes are more informative. Therefore, each voxel is more distinctive, and finding its correspondence becomes more accurate. This is demonstrated in the following figure. In this figure, we calculate similarities between a red/blue point in the subject image and all voxels in the template image. The similarity is inverse proportional to the difference between attributes. Using the optimal Gabor attributes, there is a smaller number of candidates in the template image to match up with red/blue voxel in the subject image. 49 | 50 | 51 | .. _fig_attributes: 52 | 53 | .. only:: html 54 | 55 | .. figure:: RoleOfOptimalAttributes.jpg 56 | :alt: Effect of describing voxels using different types of attributes. 57 | :align: center 58 | :width: 90% 59 | :figwidth: 90% 60 | 61 | .. only:: latex 62 | 63 | .. figure:: RoleOfOptimalAttributes.jpg 64 | :alt: Effect of describing voxels using different types of attributes. 65 | :align: center 66 | :width: 75% 67 | :figwidth: 75% 68 | 69 | 70 | Mutual-Saliency (MS) Weighting 71 | ============================== 72 | 73 | Some anatomical structures can find correspondences more easily and reliably than other anatomical structures. Ideally, a registration process should use all voxels, but be mainly driven by the regions that can establish reliable correspondences. The proposed "mutual-saliency" metric automates this process. It automatically assigns different weights to different voxels based on automatically quantifying how much confidence we have for a voxel to find reliable correspondences in the other image. 74 | 75 | This is especially useful when registering images with missing correspondences (or missing data, or outlier regions), such as the pathologies (vascular lesions, tumors) in the images. The automatically-calculated mutual-saliency map reduces the negative impact of the outlier regions. 76 | 77 | The following figure demonstrates the effect of the mutual-saliency weighting. Given the template image (b), we have simulated a cross-shaped cut as well as non-rigid deformations, resulting in the simulated subject image (a). The registration is from (a) to (b), and we want to demonstrate how the mutual-saliency metric helps reduce the negative impact of the simulated cut, which does not have a counterpart in the other image. For comparison, a red point is noted in all subfigures to represent the same exact spatial locations. It is the truly corresponding point that we use to evaluate registration accuracy in this region. Registration between (a) and (b) without the mutual-saliency weighting forces other regions to fill into the simulated cut, causing artificial results such as the stitches in the resultant image (c). As a result, the true correspondence is lost. On the contrary, the mutual saliency map in (e) assigns low weights to the cut regions because of the automatic quantification of the lack of reliable correspondences in this region. Therefore, registration with mutual-saliency weighting leads to the result in (d), which is more anatomically meaningful and preserves the true correspondence. 78 | 79 | 80 | .. _fig_confidencemap: 81 | 82 | .. figure:: RoleOfConfidenceMap.jpg 83 | :alt: Effect of mutual-saliency map in handling missing correspondences (outlier regions). 84 | :align: center 85 | :width: 90% 86 | :figwidth: 90% 87 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/changelog.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: ChangeLog 17 | 18 | .. meta:: 19 | :description: Summary of changes, new features, and bug fixes for each DRAMMS release. 20 | :keywords: DRAMMS History, DRAMMS Change History, DRAMMS ChangeLog, DRAMMS Log, DRAMMS Versions, DRAMMS Development 21 | 22 | .. only:: html or dirhtml 23 | 24 | .. include:: ../ChangeLog.txt 25 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/cmake.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/cmake.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/download.rst: -------------------------------------------------------------------------------- 1 | 2 | .. raw:: html 3 | 4 | 16 | 17 | .. title:: Download 18 | 19 | .. meta:: 20 | :description: DRAMMS Download. Including DRAMMS flyer (.pdf), manual (.pdf), download link and system requirement. 21 | :keywords: DRAMMS Download, DRAMMS Manual, DRAMMS User Manual, DRAMMS Source Code, DRAMMS Open Source, DRAMMS Software, DRAMMS How-to, DRAMMS Documentation. 22 | 23 | 24 | .. raw:: latex 25 | 26 | \pagebreak 27 | 28 | .. role:: red 29 | .. role:: blue 30 | 31 | ======== 32 | Download 33 | ======== 34 | 35 | Software License 36 | ------------------ 37 | 38 | All parts of the DRAMMS software that were developed at University of Pennsylvania, 39 | Section of Biomedical Image Analysis (SBIA) (**attribute extraction, attribute matching, 40 | mutual-saliency weighting, deformation mechanism, deformation operations**) 41 | are freely available under a BSD-style open source license that is compatible with the 42 | **Open Source** definition by `The Open Source Initiative`_ and contains no restrictions 43 | on the use of the software. The full SBIA license text is included in the distribution 44 | package and is available online (`SBIA license`_). 45 | 46 | The **optimization part** of DRAMMS, however, is based on a modified version of FastPD_, 47 | which is distributed by the University of Crete, Greece and Ecole Centrale de Paris, France, 48 | under a license which only allows the non-commercial use. The use, modification, and re-distribution 49 | of FastPD by SBIA as part of the DRAMMS software are approved by FastPD's owners for the 50 | **research and academic purpose only**. FastPD is further protected by several 51 | international pending patent applications. If you are seeking the commercial use of FastPD or its variant in DRAMMS, please seek an explicit 52 | permission from the patent holders, the University of Crete, Greece and Ecole Centrale de Paris, 53 | France, as listed `here `__. 54 | 55 | The **affine registration** within DRAMMS uses FLIRT_ from the `FMRI Software Library (FSL)`_ and 56 | therefore bears `FSL license `_ which grants 57 | **non-commercial use only**. 58 | 59 | The DRAMMS implementation as provided by SBIA may, without modification, 60 | only be used for **non-commercial research and academic purpose**. 61 | 62 | .. _The Open Source Initiative: http://opensource.org/ 63 | .. _SBIA license: http://www.rad.upenn.edu/sbia/software/license.html 64 | .. _FastPD: http://www.csd.uoc.gr/~komod/FastPD/ 65 | .. _FMRI Software Library (FSL): http://fsl.fmrib.ox.ac.uk/fsl/fslwiki/FSL 66 | .. _FLIRT: http://fsl.fmrib.ox.ac.uk/fsl/fslwiki/FLIRT 67 | 68 | 69 | .. raw:: html 70 | 71 |
72 | 73 | 74 | .. _documentation: 75 | 76 | 77 | Documentation 78 | ------------- 79 | 80 | .. only:: html or dirhtml 81 | 82 | :download:`DRAMMS Flyer ` 83 | (2 pages, 0.4MB): A quick overview of DRAMMS and its use. 84 | 85 | :download:`DRAMMS Manual ` (48 pages, 9.6MB): A comprehensive software manual including detailed examples in the :doc:`tutorials` page. 86 | 87 | :doc:`DRAMMS ChangeLog `: A summary of changes, new features, and bug fixes. 88 | 89 | .. only:: latex 90 | 91 | `DRAMMS Flyer `__ 92 | (2 pages, 0.4MB): A quick overview of DRAMMS and its use. 93 | 94 | `DRAMMS Manual `__: 95 | Online version of this manual. 96 | 97 | `DRAMMS ChangeLog `__: 98 | Summary of changes, new features, and bug fixes. 99 | 100 | 101 | .. raw:: html 102 | 103 |
104 | 105 | 106 | 107 | 108 | .. _SystemRequirements: 109 | 110 | System Requirements 111 | ------------------- 112 | 113 | **Operating System:** Linux, Mac OS X 114 | 115 | **Memory Requirement:** DRAMMS requires a considerable amount of memory. 116 | The exact memory requirement depends on the dimensions of the input images. But generally, 117 | the default use of DRAMMS should `not` consume more than 12GB memory even when 118 | the input images are large (e.g., 1024*1024*600). The memory consumption for some typical image sizes is: 119 | 120 | - ~0.5GB for a typical pair of 2D images (e.g., 256*256), 121 | - ~2.5GB for a typical pair of 3D cardiac/breast images (e.g., 256*256*100), 122 | - ~3.0GB for a typical pair of 3D brain images (small) (e.g., 256*256*124), 123 | - 4-10GB for a typical pair of 3D brain images (big) (e.g., 256*256*256). 124 | - 10-11GB for a typical pair of 3D head+neck CT images (big) (e.g., 512*512*350). 125 | 126 | The good thing is that users can choose to use less memory if their system can only 127 | afford less (see :ref:`FAQ.4 `). Be aware, though, that this may cause a slight 128 | decrease in the registration accuracy. 129 | 130 | 131 | .. raw:: html 132 | 133 |
134 | 135 | .. _register: 136 | 137 | 138 | 139 | Register for Download 140 | --------------------- 141 | 142 | DRAMMS was first publicly released on August, 24, 2012. The current version is 1.4.1., which was released on Oct, 20, 2013. See the :doc:`history of DRAMMS `. 143 | 144 | .. only:: latex 145 | 146 | Please |register here|_ to receive an email with the download links of the software. 147 | 148 | 149 | .. raw:: html 150 | 151 | 152 | 155 | 156 | .. |register here| replace:: **register here** 157 | .. _register here: http://www.rad.upenn.edu/sbia/software/dramms/download.html#register 158 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/fastpd.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Build of FastPD Software for use with DRAMMS 17 | 18 | .. meta:: 19 | :description: How to patch and build FastPD for use with DRAMMS software, a step-by-step guide. 20 | :keywords: DRAMMS FastPD Installation, DRAMMS FastPD Install, DRAMMS FastPD Configuration, DRAMMS FastPD Setup. 21 | 22 | 23 | =============== 24 | Build of FastPD 25 | =============== 26 | 27 | The original `FastPD`_ implementation from Drs. Nikos Komodakis and Nikos Paragios has to be patched before it can be used 28 | by DRAMMS. Therefore, on Unix execute the following commands in order to build the modified version of FastPD. 29 | 30 | .. raw:: html 31 | 32 |
33 | 34 | 35 | **Step 1. Download FastPD_DemoVersion.zip**: 36 | 37 | Register `here `_ to receive an email with the download link. 38 | 39 | .. raw:: html 40 | 41 |
42 | 43 | 44 | **Step 2. Unzip source files and apply patch**:: 45 | 46 | unzip FastPD_DemoVersion.zip -d dramms-fastpd 47 | patch -d dramms-fastpd -p1 < dramms-$version-source/build/FastPD.patch 48 | 49 | .. raw:: html 50 | 51 |
52 | 53 | 54 | **Step 3. Build FastPD**:: 55 | 56 | cd dramms-fastpd 57 | cmake -DCMAKE_BUILD_TYPE:STRING=Release . 58 | make 59 | 60 | .. raw:: html 61 | 62 |
63 | 64 | 65 | When building DRAMMS, set the ``DRAMMSFastPD_DIR`` CMake variable to the ``dramms-fastpd`` build 66 | directory, which, after the build of the patched FastPD, contains the file ``DRAMMSFastPDConfig.cmake``. 67 | Once DRAMMS is built and installed, the ``dramms-fastpd`` directory and its contents can be removed. 68 | 69 | 70 | .. _FastPD: http://www.csd.uoc.gr/~komod/FastPD/ 71 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/index.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: DRAMMS Image Registration Software: Homepage 17 | 18 | .. meta:: 19 | :description: DRAMMS Homepage. DRAMMS is a publicly-available, open-source, genetic medical image registration software. 20 | :keywords: DRAMMS Software, DRAMMS Registration, DRAMMS Download, DRAMMS Homepage, DRAMMS Webpage, DRAMMS Source Code, Image Registration Software, Image Registration Tool, Image Registration Toolkit, Medical Image Registration, Deformable Registration, Non-rigid Registration, Gabor Attribute, Attribute Matching, Mutual-Saliency, Registration with Outliers, Deformable Registration via Attribute Matching and Mutual-Saliency Weighting, DRAMMS SBIA, DRAMMS Christos Davatzikos, DRAMMS Yangming Ou, DRAMMS Andreas Schuh. 21 | 22 | 23 | .. raw:: latex 24 | 25 | \pagestyle{headings} 26 | 27 | 28 | Overview 29 | ======== 30 | 31 | **Deformable Registration via Attribute Matching and Mutual-Saliency Weighting (DRAMMS)** 32 | [`MedIA2011 `__], 33 | is a software package designed for 2D-to-2D and 3D-to-3D image registration tasks. 34 | 35 | Some typical applications of DRAMMS include, 36 | 37 | - **Cross-subject** registration of the same organ (can be brain, breast, cardiac, etc); 38 | - **Mono-** and **Multi-modality** registration (MRI, CT, histology); 39 | - **Longitudinal** registration (pediatric brain growth, cancer development, mouse brain development, etc); 40 | - Registration under **missing correspondences** (e.g., vascular lesions, tumors, histological cuts). 41 | 42 | 43 | DRAMMS is implemented as a Unix command-line tool. It is fully automatic and easy to use --- users input 44 | two images, and DRAMMS will output the registered image and the associated deformation. No need for pre-segmentation of 45 | structures, or prior knowledge, or human initialization/interventions. 46 | 47 | 48 | .. toctree:: 49 | :hidden: 50 | 51 | self 52 | about 53 | download 54 | changelog 55 | installation 56 | manual 57 | tutorials 58 | faq 59 | publications 60 | people 61 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/installation.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Installation of DRAMMS Software 17 | 18 | .. meta:: 19 | :description: How to install DRAMMS software, a step-by-step guide. 20 | :keywords: DRAMMS Installation, DRAMMS Install, DRAMMS Configuration, DRAMMS Setup. 21 | 22 | 23 | ============ 24 | Installation 25 | ============ 26 | 27 | Prerequisites 28 | ============= 29 | 30 | .. raw:: html 31 | 32 |
33 | 34 | +----------------+----------+-------------------------------------------------------------+ 35 | | Dependency | Version | Description | 36 | +================+==========+=============================================================+ 37 | | CMake_ | 2.8.4 | To compile and build DRAMMS. Use version 2.8.4 -- 2.8.9. | 38 | +----------------+----------+-------------------------------------------------------------+ 39 | | FSL_ | 4.1.5 | FLIRT_ is used for affine registration. | 40 | +----------------+----------+-------------------------------------------------------------+ 41 | | NiftiClib_ | 2.0.0 | To provide NIfTI-1_ support. | 42 | +----------------+----------+-------------------------------------------------------------+ 43 | | BASIS_ | 2.1.4 | A SBIA meta-project to standardize software development. | 44 | +----------------+----------+-------------------------------------------------------------+ 45 | | FastPD_ | | The `Demo version `__ | 46 | | | | provided by the author of FastPD must be patched for use | 47 | | | | with DRAMMS (see :doc:`here `). | 48 | +----------------+----------+-------------------------------------------------------------+ 49 | 50 | .. raw:: html 51 | 52 |
53 | 54 | Out of these five dependencies: 55 | 56 | users need to install two dependencies --- CMake_ and FSL_ --- before DRAMMS installation; 57 | 58 | users need **not** to install the other three dependencies --- BASIS_, NiftiCLib_, and FastPD_ 59 | are by default built as part of the build and installation as described below. 60 | 61 | 62 | .. raw:: html 63 | 64 |
65 | 66 | 67 | Build and Installation 68 | ====================== 69 | 70 | Please follow commands below in a shell/terminal (e.g., Bash_). They will configure and build DRAMMS using `GNU Make`_. 71 | The main CMake configuration file (``CMakeLists.txt``) is located in the ``dramms-$version-source/build/`` subdirectory. 72 | 73 | 74 | .. raw:: html 75 | 76 |
77 | 78 | **Step 1. Extract source files**:: 79 | 80 | tar xzf dramms-${version}-source.tar.gz 81 | 82 | 83 | .. raw:: html 84 | 85 |
86 | 87 | 88 | 89 | **Step 2. Change to the build directory**:: 90 | 91 | cd dramms-${version}-source/build 92 | 93 | 94 | .. raw:: html 95 | 96 |
97 | 98 | 99 | 100 | **Step 3. Run CMake to configure the build tree**:: 101 | 102 | ccmake . 103 | 104 | After the execution of this command, you will see a screen like below (`Fig_ccmake`_). 105 | 106 | 107 | .. _`Fig_ccmake`: 108 | 109 | .. figure:: cmake.png 110 | :alt: CMake window. 111 | :align: center 112 | :width: 90% 113 | :figwidth: 90% 114 | 115 | Fig_ccmake: Configuring dramms installation using ``ccmake``. 116 | 117 | .. raw:: latex 118 | 119 | \clearpage 120 | 121 | In this ccmake interface, please do: 122 | 123 | 3.1. Change ``CMAKE_INSTALL_PREFIX`` to the folder you want to install DRAMMS into. This folder should be outside the ``dramms-${version}-source`` folder. Make sure you have the **write** access to this folder. 124 | 125 | 3.2. Keep pressing letter ``c`` on your keyboard until option ``g`` is available/displayed on the screen. 126 | 127 | 3.3. Then press ``g`` on your keyboard to generate the makefiles and to quit this ccmake window. 128 | 129 | 130 | .. raw:: html 131 | 132 |
133 | 134 | 135 | **Step 4. Build and install DRAMMS**:: 136 | 137 | make 138 | 139 | Upon the success of the above compilation and build process, DRAMMS is installed into the directory 140 | specified by the ``CMAKE_INSTALL_PREFIX`` (set during build configuration in step 3). 141 | The DRAMMS :ref:`Command-line Tools ` are located in the ``bin/`` subdirectory. 142 | 143 | 144 | .. raw:: html 145 | 146 |
147 |
148 | 149 | 150 | .. note:: If the automatic build of BASIS, the NiftiCLib, or FastPD fails, please build and install 151 | these packages separately before the build of DRAMMS. 152 | Note that in case of FastPD, the original implementation of Nikos Komodakis has to be patched 153 | before it can be used with DRAMMS. See the :doc:`fastpd` guide for details. 154 | 155 | Then follow steps 1-4 above, where the CMake options ``USE_SYSTEM_BASIS``, ``USE_SYSTEM_NiftiCLib``, 156 | and/or ``USE_SYSTEM_DRAMMSFastPD`` have to be set to ON in step 3. 157 | Ensure further that the ``BASIS_DIR``, ``NiftiCLib_DIR``, and ``DRAMMSFastPD_DIR`` 158 | CMake variables point to the installed prerequisite packages (after the configuration step). 159 | 160 | 161 | .. toctree:: 162 | :hidden: 163 | 164 | fastpd 165 | 166 | 167 | .. _CMake: http://www.cmake.org/cmake/resources/software.html 168 | .. _GNU Make: http://www.gnu.org/software/make/ 169 | .. _FSL : http://www.fmrib.ox.ac.uk/fsl/fsl/downloading.html 170 | .. _FLIRT: http://fsl.fmrib.ox.ac.uk/fsl/fslwiki/FLIRT 171 | .. _NiftiClib: http://sourceforge.net/projects/niftilib/files/nifticlib/ 172 | .. _NIfTI-1: http://nifti.nimh.nih.gov/nifti-1/ 173 | .. _Bash: http://www.gnu.org/software/bash/ 174 | .. _BASIS: http://www.rad.upenn.edu/sbia/software/basis/ 175 | .. _FastPD: http://www.csd.uoc.gr/~komod/FastPD/ 176 | .. _BASIS how-to guide on software installation: http://www.rad.upenn.edu/sbia/software/basis/howto/install.html#building-from-sources 177 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/manual.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: DRAMMS Manual 17 | 18 | .. meta:: 19 | :description: Introducing the main command-line tool for image registration. Also introducing auxiliary tools for operations on deformations (warp image, calculate Jacobian and/or RAVENS, operate on one or two deformations). 20 | :keywords: DRAMMS Manual, DRAMMS Tools, DRAMMS Commands, DRAMMS How-to, DRAMMS Help. 21 | 22 | 23 | .. role:: red 24 | 25 | .. |br| raw:: html 26 | 27 |
28 | 29 | .. Page break after table of contents in LaTeX/PDF output. 30 | .. raw:: latex 31 | 32 | \pagebreak 33 | 34 | 35 | .. _CommandLineTools: 36 | 37 | Manual 38 | ================== 39 | 40 | :red:`The PDF file including this manual and the tutorials can be downloaded here:` :download:`DRAMMS_Software_Manual.pdf `. 41 | 42 | 43 | Registration Command 44 | -------------------- 45 | 46 | .. raw:: html 47 | 48 |
49 | 50 | The main command of DRAMMS which registers two images and optionally performs further 51 | analysis of the obtained deformation is named ``dramms``. The simplest use is: :: 52 | 53 | dramms --source sourceimage.hdr --target targetimage.nii 54 | --outimg outimage.img --outdef outdef.nii.gz 55 | 56 | 57 | .. raw:: html 58 | 59 |
60 | 61 | **Supported File Formats:** NIfTI-1_ (recommended), `ANALYZE 7.5`_ 62 | 63 | **Supported Datatypes:** byte (unsigned char, uint8), int8, short, int16, uint16, float, float32, int32. 64 | 65 | **Parameter Settings:** The default settings will give reasonable results in many cases. 66 | We recommend a look at the :doc:`tutorials` page and :ref:`FAQ.8 `, :ref:`FAQ.9 `, :ref:`FAQ.10 ` for task-specific uses. 67 | If in a particular case neither the default nor the example settings give satisfactory results, 68 | please refer to :ref:`FAQ.1 ` for the most important parameters to tune. 69 | 70 | **Memory Settings:** The memory requirement is largely dependent on the image size and the specific task --- 71 | see :ref:`SystemRequirements` for some general rules, and the :doc:`tutorials` 72 | page for some task-specific examples. How to reserve the mount of memory can be found in :ref:`FAQ.4 `. 73 | If ``dramms`` terminated due to the lack of available memory, please refer to :ref:`FAQ.5 ` for how to reduce the memory consumption while still obtaining reasonable results. 74 | 75 | 76 | **Other Usages:** 77 | 78 | - Multi-Modality Registration :ref:`FAQ.8 ` 79 | - Registration with initialized deformation :ref:`FAQ.9 ` 80 | - Registration with Cost-Function-Masking :ref:`FAQ.10 ` 81 | 82 | 83 | .. _NIfTI-1: http://nifti.nimh.nih.gov/nifti-1/ 84 | .. _ANALYZE 7.5: http://web.archive.org/web/20070927191351/http://www.mayo.edu/bir/PDF/ANALYZE75.pdf 85 | 86 | 87 | .. raw:: html 88 | 89 |
90 |
91 | 92 | Auxiliary Commands 93 | ------------------ 94 | 95 | .. raw:: html 96 | 97 |
98 | 99 | .. DRAMMS provides a number of tools which apply or operate on the obtained deformations: 100 | 101 | +---------------------------------------------------+-------------------+ 102 | | Operation | Command | 103 | +===================================================+===================+ 104 | | Warp images | |dramms-warp| | 105 | +---------------------------------------------------+-------------------+ 106 | | Calculate Jacobian Determinants | |dramms-jacobian| | 107 | +---------------------------------------------------+-------------------+ 108 | | Calculate RAVENS maps | |dramms-ravens| | 109 | +---------------------------------------------------+-------------------+ 110 | | Invert/Smooth deformation, or | |dramms-defop| | 111 | | Print-out displacement at a voxel | | 112 | +---------------------------------------------------+-------------------+ 113 | |Compose/Add/Subtract/Average two transformations | |dramms-combine| | 114 | +---------------------------------------------------+-------------------+ 115 | 116 | .. |dramms-warp| replace:: :doc:`dramms-warp ` 117 | .. |dramms-jacobian| replace:: :doc:`dramms-jacobian ` 118 | .. |dramms-ravens| replace:: :doc:`dramms-ravens ` 119 | .. |dramms-defop| replace:: :doc:`dramms-defop ` 120 | .. |dramms-combine| replace:: :doc:`dramms-combine ` 121 | 122 | .. toctree:: 123 | :hidden: 124 | 125 | tools/warp 126 | tools/jacobian 127 | tools/ravens 128 | tools/defop 129 | tools/combine 130 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/people.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | 17 | .. title:: People 18 | 19 | .. meta:: 20 | :description: People Contributed to DRAMMS Algorithm and Software. DRAMMS Contact. 21 | :keywords: DRAMMS People, DRAMMS Authors, DRAMMS Developers, DRAMMS Contact. 22 | 23 | 24 | ====== 25 | People 26 | ====== 27 | 28 | Advisor 29 | ======= 30 | 31 | - `Christos Davatzikos `_ |emailChristos| 32 | 33 | .. |emailChristos| image:: static/email-icon.jpg 34 | :scale: 3% 35 | :target: mailto:Christos.Davatzikos@uphs.upenn.edu 36 | 37 | 38 | .. _SoftwareDevelopment: 39 | 40 | Software Development (01/2009 -- , see :doc:`DRAMMS History `) 41 | ========================================================================= 42 | 43 | - `Yangming Ou `_ |emailYangming| 44 | - `Andreas Schuh `_ |emailAndreas| 45 | - `Aristeidis Sotiras `_ |emailAris| 46 | 47 | .. |emailYangming| image:: static/email-icon.jpg 48 | :scale: 3% 49 | :target: mailto:Yangming.Ou@uphs.upenn.edu 50 | 51 | .. |emailAndreas| image:: static/email-icon.jpg 52 | :scale: 3% 53 | :target: mailto:andreas.schuh.84@gmail.com 54 | 55 | .. |emailAris| image:: static/email-icon.jpg 56 | :scale: 3% 57 | :target: mailto:sotar22@gmail.com 58 | 59 | 60 | .. _AlgorithmDevelopment: 61 | 62 | Algorithm Development (02/2008 -- 10/2009) 63 | ========================================== 64 | 65 | - `Yangming Ou `_ 66 | - `Aristeidis Sotiras `_ 67 | - `Nikos Paragios `_ 68 | - `Christos Davatzikos `_ 69 | 70 | 71 | .. _SoftwareTesters: 72 | 73 | Acknowledgement to Libraries 74 | ============================ 75 | 76 | - FSL flirt tool for affine registration ( Analysis Group, FMRIB, Oxford, UK) 77 | - NiftiClib (Bob Cox, Rick Reynolds) 78 | - FastPD MRF Optimization Code (Nikos Komodakis, Nikos Paragios) 79 | - Feature extraction, data structure (Yiqiang Zhan, Dinggang Shen) 80 | 81 | 82 | .. _software-testers: 83 | 84 | Software Testing 85 | ================ 86 | 87 | **Thank you for your precious feedback and suggestions during the development of this software!** 88 | 89 | **Within SBIA** 90 | 91 | - Hamed Akbari 92 | - Harsha Battapady 93 | - Vanessa Clark 94 | - Xiao Da 95 | - Jimit Doshi 96 | - Harini Eavani 97 | - Guray Erus 98 | - Bilwaj Gaonkar 99 | - Meng-Kang Hsieh 100 | - Madhura Ingalhalikar 101 | - Dongjin Kwon 102 | - Drew Parker 103 | - Alex Smith 104 | - Erdem Varol 105 | - Steffen Wachenfeld 106 | - Dong Hye Ye 107 | 108 | 109 | **Outside SBIA** 110 | 111 | - Nikolaos Koutsouleris |Germany| 112 | - Helene Langet |France| 113 | - Lena Rademacher |Germany| 114 | - Marcus Zanetti |Brazil| 115 | 116 | 117 | 118 | .. |Germany| image:: static/germany.jpg 119 | :scale: 6% 120 | 121 | .. |France| image:: static/france.jpg 122 | :scale: 6% 123 | 124 | .. |Brazil| image:: static/brazil.jpg 125 | :scale: 6% 126 | 127 | 128 | .. Start a new page in LaTeX/PDF output after the changes. 129 | .. raw:: latex 130 | 131 | \clearpage 132 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/references.bib: -------------------------------------------------------------------------------- 1 | @article{Ou09, 2 | author = {Yangming Ou and Christos Davatzikos}, 3 | year = 2009, 4 | title = {DRAMMS: deformable registration via attribute matching and mutual-saliency weighting}, 5 | journal = {Information Processing in Medical Imaging (IPMI)}, 6 | pages = {50-62} 7 | } 8 | @article{Ou11, 9 | author = {Yangming Ou, Aristeidis Sotiras, Nikos Paragios, Christos Davatzikos}, 10 | year = 2011, 11 | title = {DRAMMS: deformable registration via attribute matching and mutual-saliency weighting}, 12 | journal = {Medical Image Analysis}, 13 | pages = {622--639}, 14 | vol = {15(4)} 15 | } 16 | @article{Jenkinson01, 17 | author = {Mark Jenkinson, Stephen Smith}, 18 | year = 2001, 19 | title = {A global optimisation method for robust affine registration of brain images}, 20 | journal = {Medical Image Analysis}, 21 | pages = {143-156}, 22 | vol = {5(2)} 23 | } -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/static/brazil.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/static/brazil.jpg -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/static/dramms.css: -------------------------------------------------------------------------------- 1 | /* 2 | Origin: $URL: https://sbia-svn.uphs.upenn.edu/projects/DRAMMS/branches/dramms-1.4/doc/static/dramms.css $ 3 | Revision: $Rev: 1903 $ 4 | */ 5 | 6 | @import url('sbia.css'); 7 | 8 | body { 9 | min-width: 920px; 10 | } 11 | 12 | /* Examples & Tutorial Overview */ 13 | table.exampletoctable { 14 | width: 90%; 15 | margin-left: 5%; 16 | margin-right: 5%; 17 | margin-top: 20px; 18 | margin-bottom: 20px; 19 | } 20 | 21 | table.exampletoctable td, table.exampletoctable th { 22 | border: 0px; 23 | padding-top: 5px; 24 | padding-bottom: 5px; 25 | padding-left: 15px; 26 | padding-right: 15px; 27 | text-align: center; /* left */ 28 | } 29 | 30 | table.exampletoctable.brain3d img { 31 | width: 100%; 32 | } 33 | 34 | table.exampletoctable.cases2d img, table.exampletoctable.cardiac3d img { 35 | width: 75%; /* 100% */ 36 | } 37 | 38 | table.exampletoctable.breast3d img, table.exampletoctable.prostate3d img { 39 | width: 50%; /* 100% */ 40 | } 41 | 42 | /* Size of email icons and flags on People page */ 43 | #people img { 44 | width: 20px; 45 | } 46 | 47 | /* Do not show the search tip as the default text does not work for DRAMMS */ 48 | #searchbox h3 { 49 | color: black; 50 | } 51 | 52 | .searchtip { 53 | display: none 54 | } 55 | 56 | .red{ 57 | color: red; 58 | } 59 | 60 | .blue{ 61 | color: blue; 62 | } 63 | 64 | 65 | .underline { 66 | text-decoration: underline; 67 | } -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/static/email-icon.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/static/email-icon.jpg -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/static/france.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/static/france.jpg -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/static/germany.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/static/germany.jpg -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/static/icon.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/static/icon.gif -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/static/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/static/logo.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tools/CalculateRAVENS.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tools/CalculateRAVENS.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tools/combine.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Combine Two Transformations in the DRAMMS package 17 | 18 | 19 | 20 | Combine Two Transformations 21 | =========================== 22 | 23 | **Concatenating** two deformations (one A->B and the other B->C) leads to a deformation A->C: :: 24 | 25 | dramms-combine -c in_def_A2B.nii.gz in_def_B2C.nii.gz out_def_A2C.nii.gz 26 | 27 | **Concatenating** an affine transformation (A->B) and a deformation B->C produces a deformation A->C (note: please specific space A and space B by the ``-f`` and ``-t`` options): :: 28 | 29 | dramms-combine -c -f A.nii.gz -t B.nii.gz in_affine_A2B.mat in_def_B2C.nii.gz out_def_A2C.nii.gz 30 | 31 | 32 | 33 | **Add** two deformations (assuming they share the same source space, and the same target space): :: 34 | 35 | dramms-combine -a in_def_1.nii.gz in_def_2.nii.gz out_def_1add2.nii.gz 36 | 37 | **Subtract** two deformations (assuming they share the same source space, and the same target space): :: 38 | 39 | dramms-combine -s in_def_1.nii.gz in_def_2.nii.gz out_def_1minus2.nii.gz 40 | 41 | **Average** two deformations (assuming they share the same source space, and the same target space): :: 42 | 43 | dramms-combine -m in_def_1.nii.gz in_def_2.nii.gz out_def_mean.nii.gz 44 | 45 | 46 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tools/defop.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Operations on Deformation 17 | 18 | 19 | ========================= 20 | Operations on Deformation 21 | ========================= 22 | 23 | .. _readdisplacement: 24 | 25 | Read Displacement At A Voxel 26 | ============================ 27 | 28 | To display the displacement of the voxel (x,y,z) in the deformation ``def.nii.gz`` in the command window, use the following command:: 29 | 30 | dramms-defop -c ${x},${y},${z} def.nii.gz 31 | 32 | 33 | .. _invertdeformation: 34 | 35 | Invert A Transformation 36 | ======================= 37 | 38 | Invert an affine matrix: :: 39 | 40 | dramms-defop -i affine.mat inverted_affine.mat 41 | 42 | 43 | Invert a deformation: :: 44 | 45 | dramms-defop -i def.nii.gz inverted_def.nii.gz 46 | 47 | .. caution:: In general we do not recommend to directly invert a deformation using this command 48 | since the numerical calculations may introduce errors especially at object/image 49 | boundaries. Instead, we recommend to re-run the ``dramms`` registration, swapping the 50 | source and the target images. 51 | 52 | .. _smoothdeformation: 53 | 54 | Smooth A Deformation 55 | ==================== 56 | 57 | Let the output deformation replace the input deformation:: 58 | 59 | dramms-defop -s def.nii.gz 60 | 61 | To keep the input deformation and generate a new smoothed deformation:: 62 | 63 | dramms-defop -s def.nii.gz smoothed_def.nii.gz 64 | 65 | 66 | 67 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tools/jacobian.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Calculate Jacobian Determinant Maps from DRAMMS Deformations 17 | 18 | 19 | .. _JacobianCalculation: 20 | 21 | Calculate Jacobian Determinant Map 22 | ================================== 23 | 24 | The Jacobian determinate is an indicator for the volumetric change at a voxel. It encodes how each voxel 25 | has deformed in term of its volumetric change. Its value is greater than 1 if there is volume expansion, 26 | 1 if volume preservation, and less than 1 if volume contraction, 0 if volume vanish, and less than 0 27 | if this region/voxel has been deformed into other regions/voxels, which is usually undesirable. 28 | 29 | There are two ways to calculate the Jacobian Determinant map of a deformation --- a stand-alone command, or as part of the main ``dramms`` script. 30 | 31 | 32 | Option 1: using a stand-alone command 33 | ------------------------------------- 34 | 35 | The first option is via a stand-alone command named ``dramms-jacobian``. We recommend this option if you have already obtained a deformation. :: 36 | 37 | dramms-jacobian def.nii.gz outputJacDet.hdr 38 | 39 | 40 | .. raw:: html 41 | 42 |
43 | 44 | 45 | Option 2: using the main `dramms` command 46 | ------------------------------------------ 47 | 48 | The second option is suitable if you don't have a deformation yet, but want to output the Jacobian Determinant map during 49 | (or more precisely, right after) the calculation of the deformation. In other words, a user may only have two input images, and want to output the Jacobian Determinant map during registration. 50 | 51 | In this case, use the ``-J`` option of the main ``dramms`` command:: 52 | 53 | dramms -S A.hdr -T B.hdr 54 | -O A2B.hdr -D def.nii.gz 55 | -J jacdet.hdr 56 | 57 | 58 | .. raw:: html 59 | 60 |
61 |
62 | 63 | .. note:: 64 | 65 | The Jacobian Determinant map is always in the target image space (i.e., the space of B.hdr in the above example). 66 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tools/ravens.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Calculate RAVENS Maps from DRAMMS Deformations 17 | 18 | .. role:: red 19 | 20 | Calculate RAVENS Tissue Density Map 21 | ====================================== 22 | 23 | RAVENS maps are tissue density maps. They are always defined in the target image space. The RAVENS value at a 24 | voxel encodes how many times of volume has been deformed from the source image to the target image at this voxel. In other words, the RAVENS value records *volumetric change ratio* (subject:template). 25 | 26 | The differences from Jacobian Determinants are: 27 | 28 | 1) RAVENS values are never negative, regardless of the existence of deformation self-foldings; therefore 29 | 30 | 2) unlike Jacobian Determinant maps, RAVENS maps are volume-preserving; and also 31 | 32 | 3) RAVENS maps are localized -- we usually calculate one RAVENS map per ROI 33 | (hence, RAVENS calculation needs ROI masks, or label maps). 34 | 35 | There are two ways to calculate RAVENS maps --- a stand-alone command, or as part of the main ``dramms`` script. 36 | 37 | 38 | Option 1: using a stand-alone command 39 | -------------------------------------- 40 | 41 | The first option is via a stand-alone command named ``dramms-ravens``. We recommend this option if you have already obtained a deformation. :: 42 | 43 | dramms-ravens -m [,...] 44 | 45 | Required arguments:: 46 | 47 | : label image in the subject space, must be in the byte (aka uchar, uint8) datatype. 48 | : template image, where RAVENS map will reside. 49 | : deformation field (generated when registering template to subject image). 50 | : prefix for all RAVENS maps. 51 | -m [,...] : labels of up to 5 ROIs where RAVENS maps will be calculated (we will output one RAVENS map for each ROI). 52 | 53 | Optional arguments:: 54 | 55 | -f : scale factor (default: 1000) 56 | -h : help; usage of this program. 57 | 58 | 59 | .. raw:: html 60 | 61 |
62 | 63 | 64 | Option 2: using the main ``dramms`` command 65 | -------------------------------------------- 66 | 67 | The second option is suitable if you have no deformation yet, but want to output RAVENS maps during (or more precisely, right after) 68 | calculating the deformation. In other words, users may only have two input images, and the label map in the source image space. From these, users may want to calculate the RAVENS maps in one step. 69 | 70 | 71 | 72 | In this case, RAVENS maps can be calculated using the ``-R``, ``-L`` and ``-l`` options of ``dramms``. **Please note**: :red:`the registered image is in the source space; and the RAVENS maps are in the target space.` See the figure and the `note` box below. :: 73 | 74 | dramms -S source.hdr -T target.hdr 75 | -O trg2src.hdr -D def_trg2src.nii.gz 76 | -R prefix_ravens_inTargetSpace 77 | -L labelsrc.hdr -l 10,150,250 78 | 79 | - The ``-R`` argument specifies the prefix of the output RAVENS maps. The eventual output will be ${prefix}_${label1}.nii.gz, ${prefix}_${label2}.nii.gz, ..., where ${label1}, ${label2}, ..., are given by the ``-l`` argument as explained below. 80 | 81 | - The ``-L`` argument specifies the input label image or ROI image in the source image space. For example, ``-L labelsrc.hdr`` inputs a label image where, say, white matter region is labeled as 250, gray matter is labeled as 150, and CSF as 10. Please note that the input label image must be in the byte (aka. uchar or uint8) datatype. 82 | 83 | - The ``-l`` argument specifies the labels of the regions in which RAVENS maps will be calculated. For example, ``-l 10,150,150`` results in the computation of three RAVENS maps, one for each region labeled by 10, 150, 250 in ``labelsrc.hdr``. Up to 5 labels can be specified at a time. 84 | 85 | 86 | Fig. figRAVENS_ shows input and output results in this example. With this command, there will be 3 output RAVENS maps in template space: 87 | 88 | *prefix_ravens_inTargetSpace_10.nii.gz*, 89 | 90 | *prefix_ravens_inTargetSpace_150.nii.gz*, 91 | 92 | *prefix_ravens_inTargetSpace_250.nii.gz*. 93 | 94 | 95 | 96 | .. _figRAVENS: 97 | 98 | .. only:: html 99 | 100 | .. figure:: CalculateRAVENS.png 101 | :alt: Example: calculate RAVENS maps. 102 | :align: center 103 | :width: 86% 104 | :figwidth: 86% 105 | 106 | An example of how to use ``dramms`` main script to calculate RAVENS maps. 107 | 108 | .. only:: latex 109 | 110 | .. figure:: CalculateRAVENS.png 111 | :alt: Example: calculate RAVENS maps. 112 | :align: center 113 | :width: 60% 114 | :figwidth: 60% 115 | 116 | An example of how to use ``dramms`` main script to calculate RAVENS maps. 117 | 118 | .. raw:: html 119 | 120 |
121 |
122 | 123 | .. note:: 124 | 125 | 1. RAVENS calculation requires a label image, because RAVENS is usually region/structure-specific. The label image must have the uchar (aka. byte or uint8) datatype (other input images can be in any datatype). 126 | 127 | 2. RAVENS values are multiplied by a factor (default 1000) to enhance contrast. 128 | 129 | 3. RAVENS maps are saved in signed short datatype. 130 | 131 | 4. RAVENS maps are in the template/target image space. However, the registered image is in the subject/source space (:red:`we are registering the target image to the source image, in order to result in RAVENS maps in the target image space`). See the figure above. 132 | 133 | 134 | .. raw:: latex 135 | 136 | \clearpage 137 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tools/warp.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Warp Images by DRAMMS Deformations 17 | 18 | 19 | .. raw:: latex 20 | 21 | \pagebreak 22 | 23 | 24 | Warp Images 25 | =========== 26 | 27 | As described below, there are two ways to warp an image --- a stand-alone command, or as part of the main ``dramms`` script. 28 | 29 | Please be aware that, dramms software package supports the warping of a 3D image by a 3D deformation, it also supports the warping of a 4D image by a 3D deformation. The former is more common. The latter is not uncommon especially when dealing with time series images such as in fMRI analysis. In the latter case, the same 3D deformation is applied to each of the 3D block in the input 4D image, and outputs a 4D warped image. The following two options can both serve the purpose of warping 3D or 4D images. 30 | 31 | Option 1: using a stand-alone command 32 | -------------------------------------- 33 | 34 | The first option is via a stand-alone command named ``dramms-warp``, which warps an input image from source 35 | image space to target image space, using the deformation obtained when registering source to target. 36 | We recommend this option if you have already obtained a deformation. 37 | 38 | For trilinear interpolation:: 39 | 40 | dramms-warp inputImage.hdr def.nii.gz warpedImage.img 41 | 42 | 43 | For nearest neighbor interpolation:: 44 | 45 | dramms-warp inputImage.hdr def.nii.gz warpedImage.img -n 46 | 47 | 48 | .. note:: 49 | 50 | 1. The warped image resides in the target image space; 51 | 52 | 2. The warped image inherits the same datatype of the source image. So, if the input source image is float datatype, the warped image also has a datatype of float. 53 | 54 | 55 | .. raw:: html 56 | 57 |
58 | 59 | Option 2: using the main `dramms` command 60 | ------------------------------------------- 61 | 62 | The second option is suitable if you don't have a deformation yet, but want to warp another image 63 | in the source image space to the target space during (or more precisely, right after) registration. 64 | This is often the case in the atlas-based segmentation or in the structure-based functional mapping. 65 | 66 | In this case, use the ``-W`` option of ``dramms``:: 67 | 68 | dramms -S A.hdr -T B.hdr 69 | -O A2B.hdr -D def.nii.gz 70 | -L Alabel.hdr -W Alabel_warped_to_B.hdr -r 0 71 | 72 | 73 | In the above example, the ``dramms`` command calculates the deformation from image ``A`` to image ``B``; and 74 | then uses the obtained deformation to warp the image ``Alabel`` (usually ROI labels or a functional image) from ``A`` space 75 | into ``B`` space, using nearest-neighbor interpolation (``-r 0``). For trilinear interpolation, use ``-r 1`` instead. 76 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials.rst: -------------------------------------------------------------------------------- 1 | 2 | .. raw:: html 3 | 4 | 16 | 17 | .. title:: DRAMMS Tutorials 18 | 19 | .. meta:: 20 | :description: Examples and Tutorials of DRAMMS. What DRAMMS can do and how to use DRAMMS in different image registration tasks. 21 | :keywords: DRAMMS Examples, DRAMMS Tutorials, DRAMMS How-to, DRAMMS Documentation, Deformable Registration, Non-rigid Registration, Registration with Outliers, Registration with missing data, Registration with missing correspondence, Brain Registration, Cardiac Registration, Breast Registration, Prostate Registration, Registration with Lesions, Registration with Tumors, Longitudinal Registration, Cross-subject Registration, Multi-modality Registration. 22 | 23 | 24 | 25 | .. Page break after table of contents in LaTeX/PDF output. 26 | .. raw:: latex 27 | 28 | \pagebreak 29 | 30 | .. _Tutorials: 31 | 32 | Tutorials 33 | ========= 34 | 35 | .. only:: html 36 | 37 | .. tip:: Click the figures or links in each case to see details about 38 | i) **results**, 39 | ii) **command**, 40 | iii) **resources needed**, and 41 | iv) **other useful options**. 42 | 43 | 44 | 45 | 2D Images 46 | --------- 47 | 48 | .. only:: html 49 | 50 | .. csv-table:: 51 | :class: exampletoctable cases2d 52 | 53 | |2DSimulatedC|, |2DHistMRC| 54 | |2DSimulated|, |2DHistMR| 55 | 56 | 57 | .. |2DSimulatedC| replace:: `Simulated `__ 58 | 59 | .. |2DSimulated| image:: tutorials/intro2a_2DSimulated.png 60 | :alt: Registration of 2D simulated images. 61 | :target: tutorials/2DSimulated.html 62 | 63 | 64 | .. |2DHistMRC| replace:: `Histology/MR Mouse Brain `__ 65 | 66 | .. |2DHistMR| image:: tutorials/intro2b_3DMouseBrain_Histology2MRI.png 67 | :alt: Registration of 2D histology and MRI of a same mouse brain. 68 | :target: tutorials/2DHistMR.html 69 | 70 | 71 | .. toctree:: 72 | :hidden: 73 | 74 | tutorials/2DSimulated 75 | tutorials/2DHistMR 76 | 77 | 78 | 79 | 80 | 3D Brain Images 81 | --------------- 82 | 83 | .. only:: html 84 | 85 | .. csv-table:: 86 | :class: exampletoctable brain3d 87 | 88 | |BrainSkullStrippedC|, |BrainWithSkullC|, |PediatricBrainLongitudinalC| 89 | |BrainSkullStripped|, |BrainWithSkull|, |PediatricBrainLongitudinal| 90 | |BrainWithLesionC|, |BrainWithTumorRecurrenceC|, |MouseBrainLongitudinalC| 91 | |BrainWithLesion|, |BrainWithTumorRecurrence|, |MouseBrainLongitudinal| 92 | 93 | 94 | .. |BrainSkullStrippedC| replace:: `Skull-stripped `__ 95 | 96 | .. |BrainSkullStripped| image:: tutorials/intro3a_3DHealthyBrain_SkullStripped.png 97 | :alt: Registration of brain images without skulls. 98 | :target: tutorials/BrainSkullStripped.html 99 | 100 | 101 | .. |BrainWithSkullC| replace:: `With Skull, Raw Images `__ 102 | 103 | .. |BrainWithSkull| image:: tutorials/intro3b_3DHealthyBrain_RawImageWithSkull.png 104 | :alt: Registration of raw brain images with skulls and background noise. 105 | :target: tutorials/BrainWithSkull.html 106 | 107 | 108 | .. |BrainWithLesionC| replace:: `With Lesion `__ 109 | 110 | .. |BrainWithLesion| image:: tutorials/intro3c_3DLesionedBrain_NormalizationToTemplate.png 111 | :alt: Registration of brain image with lesion to normal template. 112 | :target: tutorials/BrainWithLesion.html 113 | 114 | 115 | .. |BrainWithTumorRecurrenceC| replace:: `With Tumor Recurrence `__ 116 | 117 | .. |BrainWithTumorRecurrence| image:: tutorials/intro3d_3DTumorBrain_RecurrenceNormalizationToTemplate.png 118 | :alt: Registration of brain image with recurred tumor to normal template. 119 | :target: tutorials/BrainWithTumorRecurrence.html 120 | 121 | 122 | .. |PediatricBrainLongitudinalC| replace:: `Pediatric, Longitudinal `__ 123 | 124 | .. |PediatricBrainLongitudinal| image:: tutorials/intro3l_3DPediatricBrain_BabyGrowth.png 125 | :alt: Registration of longitudinal pediatric images. 126 | :target: tutorials/PediatricBrainLongitudinal.html 127 | 128 | 129 | .. |MouseBrainLongitudinalC| replace:: `Mouse Brain, Longitudinal `__ 130 | 131 | .. |MouseBrainLongitudinal| image:: tutorials/intro3k_3DMouseBrain_MouseDevelopment.png 132 | :alt: Registration of longitudinal mouse brain images. 133 | :target: tutorials/MouseBrainLongitudinal.html 134 | 135 | 136 | .. toctree:: 137 | :hidden: 138 | 139 | tutorials/BrainSkullStripped 140 | tutorials/BrainWithSkull 141 | tutorials/PediatricBrainLongitudinal 142 | tutorials/BrainWithLesion 143 | tutorials/BrainWithTumorRecurrence 144 | tutorials/MouseBrainLongitudinal 145 | 146 | 147 | 148 | 3D Cardiac Images 149 | ----------------- 150 | 151 | .. only:: html 152 | 153 | .. csv-table:: 154 | :class: exampletoctable cardiac3d 155 | 156 | |CardiacCrossSubjectsC|, |CardiacLongitudinalC| 157 | |CardiacCrossSubjects|, |CardiacLongitudinal| 158 | 159 | 160 | .. #|CardiacCrossSubjectsC| replace:: **Cross-Subjects, Pure Heart** 161 | .. |CardiacCrossSubjectsC| replace:: `Cross-Subjects, Pure Heart `__ 162 | 163 | .. |CardiacCrossSubjects| image:: tutorials/intro3e_3DCardiac_CrossSubjectStripped.png 164 | :alt: Registration of cardiac images across subjects (all non-cardiac structures removed). 165 | :target: tutorials/CardiacCrossSubjects.html 166 | 167 | 168 | .. #|CardiacLongitudinalC| replace:: **Longitudinal** 169 | .. |CardiacLongitudinalC| replace:: `Longitudinal `__ 170 | 171 | .. |CardiacLongitudinal| image:: tutorials/intro3g_3DCardiacLongitudinal.png 172 | :alt: Registration of cardiac images over time for the same subject. 173 | :target: tutorials/CardiacLongitudinal.html 174 | 175 | 176 | .. toctree:: 177 | :hidden: 178 | 179 | tutorials/CardiacCrossSubjects 180 | tutorials/CardiacLongitudinal 181 | 182 | 183 | 184 | 185 | 186 | 3D Breast Images 187 | ---------------- 188 | 189 | .. only:: html 190 | 191 | .. csv-table:: 192 | :class: exampletoctable breast3d 193 | 194 | |BreastLongitudinalC| 195 | |BreastLongitudinal| 196 | 197 | 198 | .. #|BreastLongitudinalC| replace:: **Longitudinal** 199 | .. |BreastLongitudinalC| replace:: `Longitudinal `__ 200 | 201 | .. |BreastLongitudinal| image:: tutorials/intro3h_3DBreast_CancerGrowth.png 202 | :alt: Registration of breast images over time for the same subject. 203 | :target: tutorials/BreastLongitudinal.html 204 | 205 | 206 | .. toctree:: 207 | :hidden: 208 | 209 | tutorials/BreastLongitudinal 210 | 211 | 212 | 213 | 214 | 215 | 3D Prostate Images 216 | ------------------ 217 | 218 | .. only:: html 219 | 220 | .. csv-table:: 221 | :class: exampletoctable prostate3d 222 | 223 | |ProstateHist2MRIC| 224 | |ProstateHist2MRI| 225 | 226 | 227 | .. #|ProstateHist2MRIC| replace:: **Multi-Modality (Histology/MRI)** 228 | .. |ProstateHist2MRIC| replace:: `Multi-Modality (Histology/MRI) `__ 229 | 230 | .. |ProstateHist2MRI| image:: tutorials/intro3j_3DProstate_Hisotology2MRI.png 231 | :alt: Registration of histology and MR images of the same subject. 232 | :target: tutorials/ProstateHist2MRI.html 233 | 234 | 235 | .. toctree:: 236 | :hidden: 237 | 238 | tutorials/ProstateHist2MRI 239 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/2DHistMR.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: 2D Histology-to-MRI Registration by DRAMMS 17 | 18 | .. Page break after table of contents in LaTeX/PDF output. 19 | .. raw:: latex 20 | 21 | \pagebreak 22 | 23 | 24 | Tutorial 2: 2D Histological and MR Images of The Same Mouse Brain 25 | ================================================================= 26 | 27 | 28 | Result 29 | ------ 30 | 31 | .. _fig2b_3DMouseBrain_Histology2MRI: 32 | 33 | .. figure:: 2b_3DMouseBrain_Histology2MRI.png 34 | :alt: Registration of 2D Hist/MRI slice of mouse brain.. 35 | :align: center 36 | :width: 90% 37 | :figwidth: 90% 38 | 39 | Registration of two 2D multi-modality (histology and MR) slices of a mouse brain. 40 | 41 | 42 | 43 | 44 | Command 45 | ------- 46 | 47 | :: 48 | 49 | dramms -S src_2DHist.nii.gz -T trg_2DMRI.nii.gz 50 | -O src2trg.nii.gz -D def_src2trg.nii.gz -x 7 51 | 52 | 53 | Here, we have used option ``-x 7`` to place control points every 7 pixels in the x and y directions. If this option is not used, the program will place control points every ``int(${sizeX\}/25)`` (=10 in this 256 x 256 image) pixels, which was the case in another example regarding 2D simulated image. Placing denser control points in this example enables the program to capture more local deformations. 54 | 55 | 56 | Resources Needed 57 | ---------------- 58 | 59 | Registering this pair of 2D images (256 x 256) takes 36MB memory and finishes in 1.3 min in Linux OS (2.80GHz CPU). Compared to 1.5 min computational time in the example of 2D simulated images, denser control point grids usually takes less computational time. 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | .. Start a new page in LaTeX/PDF output after the changes. 68 | .. raw:: latex 69 | 70 | \clearpage 71 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/2DSimulated.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Registration of 2D Simulated Images by DRAMMS 17 | 18 | 19 | 20 | Tutorial 1: 2D Simulated Images 21 | ================================ 22 | 23 | Introduction 24 | ------------- 25 | 26 | This is like a "Hello World!" example of DRAMMS, to taste a little bit flavor of how DRAMMS works, and how its result/deformation looks like. 27 | 28 | 29 | 30 | Result 31 | ------ 32 | 33 | 34 | .. _fig2a_2DSimulated: 35 | 36 | .. figure:: 2a_2DSimulated.png 37 | :alt: Registration of 2D simulated images. 38 | :align: center 39 | :width: 90% 40 | :figwidth: 90% 41 | 42 | Registration of two 2D simulated images. 43 | 44 | 45 | 46 | Command 47 | ------- 48 | 49 | :: 50 | 51 | dramms -S source.hdr -T target.hdr 52 | -O S2T.hdr -D def_S2T.nii.gz 53 | 54 | 55 | Resources Needed 56 | ---------------- 57 | 58 | Registering this pair of 2D images (256 x 256) takes 42MB memory and finishes in 1.5 min in Linux OS (2.80GHz CPU). 59 | 60 | 61 | 62 | .. Start a new page in LaTeX/PDF output after the changes. 63 | .. raw:: latex 64 | 65 | \clearpage 66 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/2a_2DSimulated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/2a_2DSimulated.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/2b_3DMouseBrain_Histology2MRI.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/2b_3DMouseBrain_Histology2MRI.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3a_3DHealthyBrain_SkullStripped.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3a_3DHealthyBrain_SkullStripped.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3b_3DHealthyBrain_RawImageWithSkull.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3b_3DHealthyBrain_RawImageWithSkull.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3c_3DLesionedBrain_NormalizationToTemplate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3c_3DLesionedBrain_NormalizationToTemplate.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3d_3DTumorBrain_RecurrenceNormalizationToTemplate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3d_3DTumorBrain_RecurrenceNormalizationToTemplate.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3d_3DTumorBrain_RecurrenceNormalizationToTemplate_cronal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3d_3DTumorBrain_RecurrenceNormalizationToTemplate_cronal.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3e_3DCardiac_CrossSubjectStripped.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3e_3DCardiac_CrossSubjectStripped.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3g_3DCardiacLongitudinal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3g_3DCardiacLongitudinal.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3g_3DCardiacMotion.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3g_3DCardiacMotion.jpg -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3h_3DBreast_CancerGrowth.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3h_3DBreast_CancerGrowth.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3j_3DProstate_Hisotology2MRI.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3j_3DProstate_Hisotology2MRI.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3k_3DMouseBrain_MouseDevelopment.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3k_3DMouseBrain_MouseDevelopment.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/3l_3DPediatricBrain_BabyGrowth.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/3l_3DPediatricBrain_BabyGrowth.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/BrainSkullStripped.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Skull-stripped Brain Image Registration by DRAMMS 17 | 18 | 19 | Tutorial 3: Brain MRI of Different Subjects (Skull-stripped) 20 | =============================================================== 21 | 22 | Introduction 23 | ------------ 24 | 25 | Registering skull-stripped and healthy brain images across subjects is a classic problem in image registration. Typical applications include atlas construction and atlas-based structure/ROI labeling. It is also one of the first steps for sub-population differentiation (e.g., normal v.s. dementia populations). 26 | 27 | 28 | Result 29 | ------ 30 | 31 | .. _fig3a_3DHealthyBrain_SkullStripped: 32 | 33 | .. only:: html 34 | 35 | .. figure:: 3a_3DHealthyBrain_SkullStripped.png 36 | :alt: Registration of skull-stripped brain MR images of different subjects. 37 | :align: center 38 | :width: 80% 39 | :figwidth: 80% 40 | 41 | Registration of 3D brain MR images from two different subjects (skull-stripped). 42 | 43 | .. only:: latex 44 | 45 | .. figure:: 3a_3DHealthyBrain_SkullStripped.png 46 | :alt: Registration of skull-stripped brain MR images of different subjects. 47 | :align: center 48 | :width: 65% 49 | :figwidth: 65% 50 | 51 | Registration of 3D brain MR images from two different subjects (skull-stripped). 52 | 53 | 54 | Command 55 | ------- 56 | 57 | :: 58 | 59 | dramms -S src_brain1.nii.gz -T trg_brain2.nii.gz 60 | -O src2trg.nii.gz -D def_src2trg.nii.gz 61 | 62 | 63 | 64 | Other Options 65 | -------------- 66 | 67 | Usually, the default parameter setting gives reasonable results in cross-subject brain MR registration tasks. 68 | 69 | If one wants to make the deformation smoother (often less accurate) or more aggressive, one can look at the smoothness weight, i.e., the ``-g`` option. This weight is usually between 0 to 1, higher weight for smoother deformation. The default weight is 0.2 (i.e., ``-g 0.2``). 70 | 71 | If one wants to recover larger or smaller deformations than default parameters, please look at the ``-x``, ``-y`` and/or ``-z`` options. They are directly related to the search range in the x, y, z directions. 72 | 73 | 74 | 75 | Resources Needed 76 | ---------------- 77 | 78 | Registering this pair of 3D images (target image space 256 x 256 x 124 voxels, 1.0 x 1.0 x 1.0 mm^3/voxel) takes 5.9 GB memory and finishes in 38 minutes in Linux OS (2.80GHz CPU). 79 | 80 | If one has less memory to offer, please look at the option ``-u`` to reduce the memory usage to other levels, the lowest level being 1.6GB for this pair of images. 81 | 82 | 83 | A rule of thumb is that, the computational time and memory usage go up when image size increases: the computational time is roughly linear to the image size, and the memory consumption is roughly linear to the square root of the image size. 84 | 85 | 86 | .. Start a new page in LaTeX/PDF output after the changes. 87 | .. raw:: latex 88 | 89 | \clearpage 90 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/BrainWithLesion.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Lesion-bearing Brain Images Onto the Normal Template by DRAMMS 17 | 18 | 19 | Tutorial 6: Lesion-Bearing Brain Onto a Normal Brain Template 20 | =============================================================== 21 | 22 | Introduction 23 | ------------- 24 | 25 | Registration from lesion-bearing brain images to a normal template can help us normalize a population of brains, all having lesions, into a same template space that presents the healthy anatomy. Then we can observe the spatial distributions of lesions, correlate the lesion occurrence with the functional deficit, and monitor the treatment effect. 26 | 27 | The main difficulty is the missing correspondence problem --- lesions are present in patients' brain images but not in the normal template. The mutual-saliency component in DRAMMS helps alleviate this problem. 28 | 29 | 30 | Result 31 | ------ 32 | 33 | 34 | .. _fig3c_3DLesionedBrain_NormalizationToTemplate: 35 | 36 | .. figure:: 3c_3DLesionedBrain_NormalizationToTemplate.png 37 | :alt: Registration of 2D simulated images. 38 | :align: center 39 | :width: 80% 40 | :figwidth: 80% 41 | 42 | Registration of a 3D brain MR images with lesions (source) onto a healthy brain template (target). Red arrows point out lesions in the source image (a) and in the registered image (c). Because of mutual-saliency weighting, the negative impact of lesion is reduced. As a result, the surrounding normal regions are well aligned. 43 | 44 | 45 | 46 | 47 | Command 48 | ------- 49 | 50 | :: 51 | 52 | dramms -S src_LesionedBrain.hdr -T trg_NormalTemplate.hdr 53 | -O src2trg.nii.gz -D def_S2T.nii.gz -c 2 54 | 55 | 56 | Here ``-c 2`` options turns on the mutual-saliency weighting part of DRAMMS. The mutual-saliency weight is an automatically derived value that quantifies the ability of this voxel to establish a reliable correspondence between images. It is used to weight this voxel during the registration process. It is helpful in this case, since the mutual-saliency map informs the registration process to use the lesion regions with less confidence because they cannot find correspondences in the other image. As a result, registration relies on other normal regions whose correspondences can be reliably established. Here, no segmentation or prior knowledge of lesion regions is needed. And that's the advantage of the mutual-saliency weighting in the DRAMMS algorithm. 57 | 58 | 59 | Resources Needed 60 | ---------------- 61 | 62 | Registering this pair of 3D images (target image size 256 x 256 x 198 voxels, 1 x 1 x 1 mm^3/voxel) takes 9.5 GB memory and finishes in 62 minutes in Linux OS (2.80GHz CPU). 63 | 64 | If one can afford less memory, please use ``-u`` option to choose memory usage in different levels (the lowest being about 1/4 of maximum memory used). This may however slightly reduce registration accuracy. 65 | 66 | 67 | 68 | .. Start a new page in LaTeX/PDF output after the changes. 69 | .. raw:: latex 70 | 71 | \clearpage -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/BrainWithSkull.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Registration of Raw Brain Images (with Skull) by DRAMMS 17 | 18 | 19 | Tutorial 4: Raw Brain MR Images (with Skull, Different FOV and Background Noise) 20 | ================================================================================= 21 | 22 | 23 | Introduction 24 | ------------- 25 | 26 | Registering the raw brain images is a much more difficult problem than registering brain images without the skull or background noise. It is useful for propagating of brain masks, for aligning non-brain structures, and is needed in case skull-stripping fails. 27 | 28 | Major challenges include: 1) large inter-subject variations; 2) large amount of background noise and inhomogeneity during image scanning; 3) different fields-of-view (FOVs), where one image may contain more content than the other image, like the example shown below (the neck and nose are present in the target image but not the source image). 29 | 30 | 31 | Result 32 | ------ 33 | 34 | 35 | .. _fig3b_3DHealthyBrain_RawImageWithSkull: 36 | 37 | .. figure:: 3b_3DHealthyBrain_RawImageWithSkull.png 38 | :alt: Registration of raw brain images. 39 | :align: center 40 | :width: 100% 41 | :figwidth: 100% 42 | 43 | Registration of raw 3D brain MR images from two different subjects. The source and target images are from different datasets -- raw, having skull and background noise/sparkles, and having different fields-of-views (FOVs). 44 | 45 | 46 | 47 | 48 | Command 49 | ------- 50 | 51 | :: 52 | 53 | dramms -S src_rawbrain1.nii.gz -T trg_rawbrain2.nii.gz 54 | -O src2trg.nii.gz -D def_src2trg.nii.gz 55 | 56 | 57 | 58 | 59 | Other Options 60 | ------------- 61 | 62 | If two raw images are from the same dataset, the default parameter setting above usually gives reasonable results. 63 | 64 | If two raw images are from different datasets, and/or from different institutions, the default parameters still work successfully in a majority of the cases (>85% in our 300+ tests), just like the figure shown above. 65 | 66 | In the extreme cases (when the FOVs are too different, when the background noises are too much, when the inter-subject difference is too large), the default parameters may fail. In these extreme cases, we can make DRAMMS work again in most cases by the following two options. 67 | 68 | The **first** option is to enlarge the search range, i.e., setting bigger values in ``-x``, ``-y``, ``-z`` options in dramms command. A rule of thumb is to set ``-x`` value to be ``int(imageSizeX/35)``, ``-y`` value to be ``int(imageSizeY/35)`` and ``-z`` value to be ``int(imageSizeZ/40)``. For example, if the target image is 256 x 180 x 256, then one can first try all settings default:: 69 | 70 | dramms -S source.nii.gz -T target.nii.gz 71 | -O S2T.nii.gz 72 | -x 7 -y 5 -z 6 73 | 74 | Here the ``-x``, ``-y`` and ``-z`` values are determined according to the above mentioned rule of the thumb. 75 | 76 | 77 | The **second** option is to increase the threshold for the background noise through the ``-t`` option. This option sets an intensity threshold (in the [0, 255] range). Only those voxels having intensities (after normalizing to the [0 255] range) above this threshold are used to calculate the deformation. By default, the threshold is set at 12. In case the background noise is too strong, we can set it to 25, as the example shows below:: 78 | 79 | dramms -S source.nii.gz -T target.nii.gz 80 | -O S2T.nii.gz -t 25 81 | 82 | 83 | 84 | Resources Needed 85 | ---------------- 86 | 87 | Registering this pair of 3D images (the target image has 180 x 256 x 256 voxels, 1.20 x 0.94 x 0.94 mm^3/voxel) takes 8.7 GB memory and finishes in 87 minutes in Linux OS (2.80GHz CPU). 88 | 89 | If one can afford less memory, please use ``-u`` option to choose the memory usage in different levels (the lowest being about 1/4 of maximum memory used). This may however slightly reduce the registration accuracy. 90 | 91 | 92 | 93 | .. Start a new page in LaTeX/PDF output after the changes. 94 | .. raw:: latex 95 | 96 | \clearpage 97 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/BrainWithTumorRecurrence.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Brain Image with Recurrent Tumors Registered to the Normal Template by DRAMMS 17 | 18 | 19 | Tutorial 7: Brain with Tumor Recurrence to a Normal Brain Template 20 | ==================================================================== 21 | 22 | 23 | Introduction 24 | ------------ 25 | 26 | Here we present an example of using DRAMMS to register an image with recurrent brain tumor to a healthy brain template. This will help us correlate the recurrence of tumor with the original occurrence of tumor in the normal template space. Another application is to do this for a population of brain tumor subjects, to observe which region is more likely to have tumor recurrence, and whether the recurrence follows connectivity or follows major vessels in a population study. 27 | 28 | The main difficulties are missing correspondences: 29 | 30 | 1) after the tumor resection, there is usually a blood pool in the place of the resected tumor (pointed out by the red arrows in the figure below), which is not found in the template image; 31 | 32 | 2) around the tumor resection areas, there is usually some recurrent tumors (pointed out by the blue arrows in the figure below), which is also not seen in the template image. 33 | 34 | 35 | Result 36 | ------ 37 | 38 | The mutual-saliency component in DRAMMS helps alleviate this problem. DRAMMS automatically finds those regions that have less chance to find correspondences cross images, and use them with less weight/confidence during registration. For example, Fig. (d) shows that the mutual-saliency map has effectively assigned low weights in the regions in the target image space that correspond to outlier regions in source image space (Fig. (a)). The nice thing is that, this mutual-saliency calculation is fully automatic, doesn't need prior knowledge, or pre-segmentation of tumor or other outlier regions, and also doesn't need any human intervention or initialization. 39 | 40 | 41 | .. _fig3d_3DTumorBrain_RecurrenceNormalizationToTemplate: 42 | 43 | .. figure:: 3d_3DTumorBrain_RecurrenceNormalizationToTemplate.png 44 | :alt: Registration of brain image with tumor recurrence to normal template (axial view). 45 | :align: center 46 | :width: 90% 47 | :figwidth: 90% 48 | 49 | Registration of a brain image with recurrent tumors to a normal brain template. Without segmentation/initialization/prior-knowledge, The automatically-calculated mutual-saliency map (d), defined in target image space, has effectively assigned low weights to those regions that correspond to the outlier regions (pointed out by arrows) in the source image (a). This way, the negative impact of outlier regions is largely reduced. Registration is mainly guided by regions that can establish good correspondences. 50 | 51 | 52 | Now change to coronal view. Same legend. 53 | 54 | .. figure:: 3d_3DTumorBrain_RecurrenceNormalizationToTemplate_cronal.png 55 | :alt: Registration of brain image with tumor recurrence to normal template (cronal view). 56 | :align: center 57 | :width: 80% 58 | :figwidth: 80% 59 | 60 | 61 | 62 | Command 63 | ------- 64 | 65 | :: 66 | 67 | dramms -S src_Cardiac1.img -T trg_Cardiac2.img 68 | -O src2trg.hdr -D def_S2T.nii.gz 69 | -g 0.4 -c 2 70 | 71 | 72 | Resources Needed 73 | ---------------- 74 | 75 | Registering this pair of 3D images (target image 256x256x181 voxels, 1.0x1.0x1.0 mm^3/voxel) takes 8.8 GB memory and finishes in 33 minutes in Linux OS (2.80GHz CPU). 76 | 77 | If one can afford less memory, please use ``-u`` option to choose memory usage in different levels (the lowest being about 1/4 of maximum memory used). This may however slightly reduce registration accuracy. 78 | 79 | 80 | 81 | Note 82 | ---- 83 | 84 | In this example, we only presented registration of images with tumor recurrence. We have tried to use DRAMMS for registering original tumor images. Sometimes DRAMMS succeeded, and sometimes DRAMMS failed. The main difference is that, the original tumors often occupy larger space, and present more mass effect, edema infiltration that further complicate the problem. So it seems fair to say that DRAMMS is good at registering images with vascular lesions, acceptable for images with small number, small size and less infiltration tumors, but may fail for images with large number, large size and large mass effect tumors. 85 | 86 | 87 | 88 | .. Start a new page in LaTeX/PDF output after the changes. 89 | .. raw:: latex 90 | 91 | \clearpage -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/BreastCancerChange_NonResponder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/BreastCancerChange_NonResponder.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/BreastLongitudinal.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Registration of Longitudinal Breast Cancer Images and Quantification of Breast Cancer Changes by DRAMMS 17 | 18 | .. meta:: 19 | :description: Using DRAMMS to register longitudinal images of a breast cancer patient. This offers the opportunity to quantify cancer changes at the voxel level, which is important to evaluate treatment effects. 20 | :keywords: Breast Image Registration, Longitudinal Registration, Breast MRI, Breast Cancer Change, Treatment Effect. 21 | 22 | 23 | Tutorial 11: Longitudinal Breast Cancer MR Images 24 | ================================================== 25 | 26 | 27 | Introduction 28 | ------------ 29 | 30 | Registration is often needed to quantify breast cancer change over time. This is especially important to monitor the change of breast cancer patient, and access their response to the chemotherapy (treatment effects). It is also one of the first steps towards differentiation between complete responders (subjects who show the absence of any residual invasive cancer in the breast and the absence of any metastatic cells in the regional lymph nodes) and non-complete-responders. 31 | 32 | Below is an example. DRAMMS recovers the deformation from post to pre chemotherapy in this breast cancer patient. 33 | 34 | 35 | Result 36 | ------ 37 | 38 | .. _fig3h_3DBreast_CancerGrowth: 39 | 40 | .. figure:: 3h_3DBreast_CancerGrowth.png 41 | :alt: Registration of longitudinal breast images. 42 | :align: center 43 | :width: 88% 44 | :figwidth: 88% 45 | 46 | Registration of breast cancer images for the same subject, to monitor the effect of chemotherapy in altering breast cancer over time. 47 | 48 | 49 | 50 | 51 | Command 52 | ------- 53 | 54 | :: 55 | 56 | dramms -S src_breastPost.hdr -T trg_breastPre.hdr 57 | -O src2trg.nii.gz -D def_S2T.nii.gz -g 0.3 58 | 59 | 60 | Resources Needed 61 | ---------------- 62 | 63 | Registering this pair of 3D images (target image 256 x 256 x 64 voxels, 0.78 x 0.78 x 2.30 mm^3/voxel) takes 9.1 GB memory and finishes in 81 minutes in Linux OS (2.80GHz CPU). 64 | 65 | If one can afford less memory, please use ``-u`` option to choose memory usage in different levels (the lowest being about 1/4 of maximum memory used). This may however slightly reduce registration accuracy. 66 | 67 | 68 | Clinical Application 69 | --------------------- 70 | 71 | With the DRAMMS registration, we can recover the deformation/change over time at the voxel level. This is done by the Jacobian Determinant map calculated from the DRAMMS deformation (click here for :ref:`how to calculate Jacobian Determinant maps `). Below is an example. 72 | 73 | 74 | .. _fig3h_3DBreast_CancerGrowthJacobianMap: 75 | 76 | .. figure:: BreastCancerChange_NonResponder.png 77 | :alt: Quantification of the longitudinal cancer of a breast cancer patient, by the Jacobian Determinant maps derived from the DRAMMS-computed deformation. 78 | :align: center 79 | :width: 88% 80 | :figwidth: 88% 81 | 82 | Quantification of the longitudinal cancer of a breast cancer patient, by the Jacobian Determinant maps derived from the DRAMMS-computed deformation. 83 | 84 | 85 | .. Start a new page in LaTeX/PDF output after the changes. 86 | .. raw:: latex 87 | 88 | \clearpage -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/CardiacCrossSubjects.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Cardiac Image Registration (Cross-subject of Pure Heart) by DRAMMS 17 | 18 | 19 | Tutorial 9: Cardiac MRI (Cross-Subject, Heart Regions only) 20 | =============================================================== 21 | 22 | Introduction 23 | ------------ 24 | 25 | Registering cardiac images of different subjects can help us normalize a population of hearts into a common heart template space. It is the basis to the cardiac atlas construction and the atlas-based heart labeling. It is also one of the first steps for differentiating sub-populations (e.g., normal versus abnormal). 26 | 27 | 28 | Result 29 | ------ 30 | 31 | .. _fig3e_3DCardiac_CrossSubjectStripped: 32 | 33 | .. figure:: 3e_3DCardiac_CrossSubjectStripped.png 34 | :alt: Registration of cardiac images of different subjects. 35 | :align: center 36 | :width: 90% 37 | :figwidth: 90% 38 | 39 | Registration of a pair of 3D cardiac MR images (different subjects, short-axis, end-diastole). The non-heart structures have already been removed, making registration much easier than keeping all the non-heart structures. 40 | 41 | 42 | 43 | Command 44 | ------- 45 | 46 | :: 47 | 48 | dramms -S src_Cardiac1.img -T trg_Cardiac2.img 49 | -O src2trg.hdr -D def_S2T.nii.gz 50 | 51 | 52 | Resources Needed 53 | ---------------- 54 | 55 | Registering this pair of 3D images (target image 120 x 120 x 12 voxels, 1.25 x 1.25 x 8.0 mm^3/voxel) takes 0.6 GB memory and finishes in 2.3 minutes in Linux OS (2.80GHz CPU). 56 | 57 | If one can afford less memory, please use ``-u`` option to choose memory usage in different levels (the lowest being about 1/4 of maximum memory used). This may however slightly reduce registration accuracy. 58 | 59 | 60 | Note 61 | ----- 62 | 63 | In this example, we have removed all non-heart structures to make registration feasible. When the non-heart structures are kept, especially when different images have different fields-of-view (FOVs) to include different regions of non-heart structures, registration across subjects will be much more difficult. In such cases, DRAMMS, like many other registration methods, may be subject to a high failure rate. 64 | 65 | 66 | Publication 67 | ------------ 68 | 69 | Yangming Ou, Dong Hye Ye, Kilian M. Pohl, Christos Davatzikos. 70 | `Validation of DRAMMS among 12 Popular Methods in Cross-Subject Cardiac MRI Registration. `__ 71 | The Workshop of Biomedical Image Registration (WBIR) 2012: 209-219. 72 | 73 | .. Start a new page in LaTeX/PDF output after the changes. 74 | .. raw:: latex 75 | 76 | \clearpage -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/CardiacLongitudinal.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Longitudinal Cardiac Image Registration by DRAMMS for Cardiac Motion Analysis or Segmentation Propagation 17 | 18 | 19 | Tutorial 10: Longitudinal Cardiac MRI 20 | =============================================================== 21 | 22 | Introduction 23 | ------------- 24 | 25 | Registering longitudinal cardiac images of the same subject can help us a) analyze cardiac motion, and also b) propagate heart labeling/segmentation over time. 26 | 27 | The difficulty of registering longitudinal cardiac images of the same subject is in-between the difficulty in registering pure hearts and the difficulty in registering all structures (including non-heart structures) across subjects. 28 | 29 | 30 | .. raw:: html 31 | 32 |
33 | 34 | Result A: for Cardiac Motion Analysis 35 | -------------------------------------- 36 | 37 | A1. Cardiac motion analysis using DRAMMS registration. 38 | 39 | .. only:: html 40 | 41 | .. csv-table:: 42 | :class: exampletoctable cardiacmotion 43 | 44 | |CardiacMotion| 45 | 46 | .. |CardiacMotion| image:: CardiacMotionMovie.gif 47 | :alt: cardiac motion by DRAMMS. 48 | :width: 105% 49 | 50 | 51 | .. only:: latex 52 | 53 | A movie for DRAMMS-extracted cardiac motion can be accessed at `here `__ . 54 | 55 | 56 | .. raw:: html 57 | 58 |
59 | 60 | 61 | A2. The key components explaining the above movie of using DAMMS registration to analyze cardiac motion (right click on the image to choose to view image in new tab or to zoom in for higher resolution). 62 | 63 | .. _fig3g_3DCardiacMotion: 64 | 65 | .. figure:: 3g_3DCardiacMotion.jpg 66 | :alt: figure of key components (refresh this webpage if the figure doesn't show up in the first time). 67 | :align: center 68 | :width: 95% 69 | :figwidth: 95% 70 | 71 | 72 | 73 | 74 | .. raw:: html 75 | 76 |
77 | 78 | 79 | .. raw:: html 80 | 81 |
82 | 83 | Result B: for Propagating Cardiac Label/Segmentation 84 | ----------------------------------------------------- 85 | 86 | 87 | .. _fig3g_3DCardiacLongitudinal: 88 | 89 | .. figure:: 3g_3DCardiacLongitudinal.png 90 | :alt: Registration of longitudinal cardiac images for label/segmentation propagation. 91 | :align: center 92 | :width: 100% 93 | :figwidth: 100% 94 | 95 | Registration of longitudinal cardiac MR images for label/segmentation propagation. 96 | 97 | 98 | .. raw:: html 99 | 100 |
101 | 102 | 103 | Command 104 | ------- 105 | 106 | For results in A1 (for cardiac motion analysis), we need a relatively smooth deformation, so we used `-g 0.4` below instead of the default 0.2. 107 | 108 | We can register all follow-up images (Tn) to the baseline image (T1) independently. Or, more preferably, register each follow-up image (Tn) to the baseline image (T1) with the initialization of the deformation obtained when registering the previous time point (T(n-1)) to the baseline image. The option `-d` as shown below allows the input of an initial deformation. 109 | 110 | :: 111 | 112 | dramms -S cineMRI_Tn.hdr -T cineMRI_T1.hdr 113 | -O cineMRI_Tn_to_T1.hdr 114 | -D def_Tn_to_T1.nii.gz 115 | -g 0.4 116 | -d initial_def_T_n-1_to_T1.nii.gz 117 | 118 | 119 | For results in A2 (for label/segmentation propagation), we need a relatively aggressive deformation 120 | 121 | :: 122 | 123 | dramms -S src_CardiacTP3.hdr -T trg_CardiacTP10.hdr 124 | -O src2trg.nii.gz -D def_S2T.nii.gz 125 | 126 | 127 | 128 | Resources Needed 129 | ---------------- 130 | 131 | Registering this pair of 3D images (target image 120 x 120 x 12 voxels, 1.25 x 1.25 x 8.0 mm^3/voxel) takes 0.95 GB memory and finishes in 2.4 minutes in Linux OS (2.80GHz CPU). 132 | 133 | If one can afford less memory, please use ``-u`` option to choose memory usage in different levels (the lowest being about 1/4 of maximum memory used). This may however slightly reduce registration accuracy. 134 | 135 | 136 | 137 | Publication 138 | ------------ 139 | 140 | Elena Bernardis, Ender Konukoglu, Yangming Ou, Dimitris Metaxas, Benoit Desjardins and Kilian Pohl. 141 | `Temporal Shape Analysis via the Spectral Signature `__, International Conference on Medical Image Computing 142 | and Computer Assisted Intervention (MICCAI), Nice, France, 1-5 Oct 2012. 143 | 144 | .. Start a new page in LaTeX/PDF output after the changes. 145 | .. raw:: latex 146 | 147 | \clearpage -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/CardiacMotionMovie.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/CardiacMotionMovie.gif -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/MouseBrainLongitudinal.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Longitudinal Mouse Brain Registration by DRAMMS 17 | 18 | 19 | Tutorial 8: Longitudinal Mouse Brain MR Images 20 | ============================================== 21 | 22 | Introduction 23 | ------------- 24 | 25 | Due to the its similarity to human brain and its relative structural simplicity compared to the human brain, we often study mouse brain development to infer human brain development. Registration is thus needed to recover the change of mouse brain images at different time points. Challenges are large structural change, and the development of new structures. In the example below, the younger brain has not yet developed sophisticated cerebellum structures than the other relatively older brain. 26 | 27 | 28 | Result 29 | ------- 30 | 31 | .. _fig3k_3DMouseBrain_MouseDevelopment: 32 | 33 | .. figure:: 3k_3DMouseBrain_MouseDevelopment.png 34 | :alt: Registration of longitudinal mouse brain images. 35 | :align: center 36 | :width: 90% 37 | :figwidth: 90% 38 | 39 | Registration of longitudinal mouse brain images to follow mouse brain development. 40 | 41 | 42 | 43 | 44 | Command 45 | -------- 46 | 47 | :: 48 | 49 | dramms -S src_mouseDay2.hdr -T trg_mouseDay10.hdr 50 | -O src2trg.nii.gz -D def_S2T.nii.gz 51 | -g 0.2 -c 2 52 | 53 | 54 | 55 | Other Options 56 | ------------- 57 | 58 | If the default parameter does not give good results, it is usually caused by the structural difference in different life stages. That is, structures may change greatly in shape, size and texture, and new structures may emerge as the brain grows. 59 | 60 | Possible solutions include 61 | 62 | 1) to increase the search range in DRAMMS (setting the control point spacing via the ``-x``, ``-y`` and/or ``-z`` options); 63 | 64 | 2) to use the initialization to de-couple a large deformation into several smaller ones (usually known as "geodesic registration"). In such case, one can use deformation from A to B to better initialize the calculation of the deformation from A to C (suppose A,B,C are in time order). DRAMMS can take initial deformation by the ``-d`` option. That is, 65 | 66 | 67 | From time A to B:: 68 | 69 | dramms -S timeA.hdr -T timeB.hdr 70 | -O timeA2B.hdr -D def_timeA2B.nii.gz 71 | -g 0.2 -c 2 72 | 73 | From time A to C using A_to_B as the initialization (``"-d"`` option):: 74 | 75 | dramms -S timeA.hdr -T timeC.hdr 76 | -O timeA2C.hdr -D def_timeA2C.nii.gz 77 | -g 0.2 -c 2 78 | -d def_timeA2B.nii.gz 79 | 80 | 81 | 82 | Resources needed 83 | ----------------- 84 | 85 | Registering this pair of 3D images (target image 300 x 300 x 200 voxels, 0.0625 x 0.0625 x 0.0625 mm^3/voxel) takes 8.6 GB memory and finishes in 43 minutes in Linux OS (2.80GHz CPU). 86 | 87 | If one can afford less memory, please use ``-u`` option to choose memory usage in different levels (the lowest being about 1/4 of maximum memory used). This may however slightly reduce registration accuracy. 88 | 89 | 90 | .. Start a new page in LaTeX/PDF output after the changes. 91 | .. raw:: latex 92 | 93 | \clearpage -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/PediatricBrainLongitudinal.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Pediatric Brain Image Registration by DRAMMS 17 | 18 | 19 | Tutorial 5: Longitudinal Pediatric Images 20 | ========================================= 21 | 22 | 23 | Introduction 24 | ------------- 25 | 26 | Registration is needed to follow the pediatrics brain development. Or, we use registration to propagate the skull-stripping and tissue/structure segmentation from one time point to another time point. 27 | 28 | In this longitudinal pediatric brain registration task, the main difficulty is the large change of anatomical structure over time, and even development of new structures. Image contrast is also different, as shown in the figure below. 29 | 30 | 31 | 32 | Result 33 | ------ 34 | 35 | .. _fig3l_3DPediatricBrain_BabyGrowth: 36 | 37 | .. figure:: 3l_3DPediatricBrain_BabyGrowth.png 38 | :alt: Registration of longitudinal pediatric brain images. 39 | :align: center 40 | :width: 95% 41 | :figwidth: 95% 42 | 43 | Registration of longitudinal images of a same baby, to follow brain development. 44 | 45 | 46 | 47 | 48 | Command 49 | ------- 50 | 51 | :: 52 | 53 | dramms -S src_olderage.hdr -T trg_youngerage.hdr 54 | -O src2trg.nii.gz -D def_S2T.nii.gz -g 0.2 55 | 56 | 57 | 58 | Other Options 59 | ------------- 60 | 61 | If the structural change is too large, one can increase the search range by setting larger control point spacing via the ``-x``, ``-y`` and/or ``-z`` options. 62 | 63 | 64 | Resources Needed 65 | ---------------- 66 | 67 | Registering this pair of 3D images (target image 256 x 256 x 175 voxels, 1.0 x 1.0 x 1.0 mm^3/voxel) takes 8.2 GB memory and finishes in 30.5 minutes in Linux OS (2.80GHz CPU). 68 | 69 | If one can afford less memory, please use the ``-u`` option to choose the memory usage in different levels (the lowest being about 1/4 of maximum memory used). This may however slightly reduce registration accuracy. 70 | 71 | 72 | 73 | .. Start a new page in LaTeX/PDF output after the changes. 74 | .. raw:: latex 75 | 76 | \clearpage -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/ProstateHist2MRI.rst: -------------------------------------------------------------------------------- 1 | .. raw:: html 2 | 3 | 15 | 16 | .. title:: Prostate Histology-to-MRI Registration by DRAMMS 17 | 18 | 19 | Tutorial 12: Histological and MR Images of The Same Prostate 20 | =============================================================== 21 | 22 | Introduction 23 | ------------ 24 | 25 | Histological image, because of its *ex vivo* and *microscopic* nature, usually provides structural or pathological ground-truth. Finding MR regions corresponding to histological ground-truth regions will help us better understand how a certain structure or pathology appears in MRI. This is often the building block for future labeling or diagnosing new subjects from their MR images. 26 | 27 | Histology and MRI registration is in general a very challenging multi-modality registration task. Difficulties are: 28 | 29 | 1) completely different imaging protocols, intensity distribution and image contrasts. This often leads to the loss of a consistent relationship between the intensity distributions of two images, which violates the underlying assumption of mutual-information based classic multi-modality registration approach. 30 | 31 | 2) structural change due to loss of water (dehydration) in ex vivo histology preparation and section. 32 | 33 | 3) histological images are sectioned and scanned slice by slice, and stack to together. This sometimes known as 2.5D image has partially lost 3D integrity/continuity as seen in 3D MR images. 34 | 35 | 4) partial loss of correspondences (histological cuts) due to the sectioning during the acquisition of histological images. 36 | 37 | 38 | Below we show an example of using DRAMMS to somehow alleviate some of those issues, mostly because of attribute matching design and mutual-saliency weighting components. 39 | 40 | 41 | Result 42 | ------ 43 | 44 | .. _fig3j_3DProstate_Hisotology2MRI: 45 | 46 | .. figure:: 3j_3DProstate_Hisotology2MRI.png 47 | :alt: Registration of histological and MR images of the same prostate. 48 | :align: center 49 | :width: 90% 50 | :figwidth: 90% 51 | 52 | Registration of multi-modality images of a same prostate. Dashed circles outline the corresponding structures. 53 | 54 | 55 | 56 | 57 | Command 58 | ------- 59 | 60 | :: 61 | 62 | dramms -S src_histology.hdr -T trg_MRI.hdr 63 | -O src2trg.nii.gz -D def_S2T.nii.gz 64 | -g 0.25 -w 1 -c 2 65 | 66 | 67 | Here '-w 1' option tells dramms to use correlation coefficient (of the attribute vectors) as the similarity metric, instead of the default squared difference similarity metric. We recommend to use '-w 1' option in multi-modality registration jobs. 68 | 69 | 70 | Other Options 71 | -------------- 72 | 73 | Despite this successful example, registration of histological and MR images is very challenging task that even the affine registration may often fail. Because of the difficulty, DRAMMS may fail too. 74 | 75 | One solution is to carefully re-do affine registration outside DRAMMS scope. After having obtained a reasonable affine result, one can input the affinely registered images (src2trg_affine.nii.gz and trg.nii.gz) into DRAMMS. Meanwhile bypassing the affine part within DRAMMS by the ``-a 0`` option. 76 | 77 | 78 | 79 | Resources Needed 80 | ---------------- 81 | 82 | Registering this pair of 3D images (target image 256 x 256 x 64 voxels, 0.16 x 0.16 x 0.4 mm^3/voxel) takes 6.7 GB memory and finishes in 39 minutes in Linux OS (2.80GHz CPU). 83 | 84 | If one can afford less memory, please use ``-u`` option to choose memory usage in different levels (the lowest being about 1/4 of maximum memory used). This may however slightly reduce registration accuracy. 85 | 86 | 87 | 88 | 89 | .. Start a new page in LaTeX/PDF output after the changes. 90 | .. raw:: latex 91 | 92 | \clearpage -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro2a_2DSimulated.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro2a_2DSimulated.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro2b_3DMouseBrain_Histology2MRI.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro2b_3DMouseBrain_Histology2MRI.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3a_3DHealthyBrain_SkullStripped.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3a_3DHealthyBrain_SkullStripped.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3b_3DHealthyBrain_RawImageWithSkull.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3b_3DHealthyBrain_RawImageWithSkull.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3c_3DLesionedBrain_NormalizationToTemplate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3c_3DLesionedBrain_NormalizationToTemplate.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3d_3DTumorBrain_RecurrenceNormalizationToTemplate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3d_3DTumorBrain_RecurrenceNormalizationToTemplate.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3e_3DCardiac_CrossSubjectStripped.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3e_3DCardiac_CrossSubjectStripped.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3g_3DCardiacLongitudinal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3g_3DCardiacLongitudinal.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3h_3DBreast_CancerGrowth.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3h_3DBreast_CancerGrowth.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3j_3DProstate_Hisotology2MRI.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3j_3DProstate_Hisotology2MRI.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3k_3DMouseBrain_MouseDevelopment.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3k_3DMouseBrain_MouseDevelopment.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/doc/tutorials/intro3l_3DPediatricBrain_BabyGrowth.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/doc/tutorials/intro3l_3DPediatricBrain_BabyGrowth.png -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | ############################################################################## 2 | # @file CMakeLists.txt 3 | # @brief Build configuration of software. 4 | # 5 | # Copyright (c) 2011, 2012 University of Pennsylvania. All rights reserved.
6 | # See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | # 8 | # Contact: SBIA Group 9 | ############################################################################## 10 | 11 | # ============================================================================ 12 | # library target(s) 13 | # ============================================================================ 14 | 15 | # Add library target for each library using basis_add_library(). 16 | # 17 | # This command can not only be used to build libraries from C/C++, but also source 18 | # code written in other programming languages such as Java, Python, Perl, 19 | # MATLAB, and Bash. Note that here we consider modules written in a scripting 20 | # language which are no executables but to be included by other scripts written 21 | # in the particular language as libraries. 22 | # 23 | # Note: Public modules written in a scripting language such as Python, Perl, 24 | # MATLAB, or Bash which are intended for use by other packages should 25 | # be placed in the lib/[/]DRAMMS/ directory, 26 | # where is the language name in lowercase and is optional. 27 | # BASIS will automatically add a library build target for these modules. 28 | 29 | add_subdirectory (common) 30 | 31 | # ============================================================================ 32 | # executable target(s) 33 | # ============================================================================ 34 | 35 | # Add executable target for each executable program using basis_add_executable(). 36 | # 37 | # This command can not only be used to build executables from C/C++, but also 38 | # source code written in other programming languages such as Java, Python, Perl, 39 | # MATLAB, and Bash. 40 | 41 | add_subdirectory (tools) 42 | 43 | basis_add_executable (dramms.sh) 44 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/common/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | ############################################################################## 2 | # @file CMakeLists.txt 3 | # @brief Build configuration of software. 4 | # 5 | # Copyright (c) 2011 University of Pennsylvania. All rights reserved. 6 | # See https://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | # 8 | # Contact: SBIA Group 9 | ############################################################################## 10 | 11 | basis_add_library(common STATIC 12 | general.cxx 13 | cres.cxx 14 | matrix.cxx 15 | mvcd.cxx 16 | image.cxx 17 | imageio.cxx 18 | utilities.cxx) 19 | 20 | basis_target_link_libraries(common niftiio) 21 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/common/cres.h: -------------------------------------------------------------------------------- 1 | 2 | #pragma once 3 | #ifndef _DRAMMS_CRES_H 4 | #define _DRAMMS_CRES_H 5 | 6 | #define TINY 1.0e-20; 7 | 8 | 9 | #ifdef __cplusplus 10 | extern "C" { 11 | #endif 12 | 13 | 14 | typedef struct 15 | { 16 | float H; 17 | float K; 18 | float k1; 19 | float k2; 20 | float error; 21 | } Skappa; 22 | 23 | void nrerror(const char []); 24 | double *vector(int,int); 25 | int *ivector(int,int); 26 | double *devecotr(int,int); 27 | double **matrix(int,int,int,int); 28 | double **dmatrix(int,int,int,int); 29 | int **imatrix(int,int,int,int); 30 | double **submatrix(double **,int,int,int,int,int,int); 31 | void free_vector(double *,int,int); 32 | void free_ivector(int *,int,int); 33 | void free_dvector(double *,int,int); 34 | void free_matrix(double **,int,int,int,int); 35 | void free_dmatrix(double **,int,int,int,int); 36 | void free_imatrix(int **,int,int,int,int); 37 | void ludcmp(double **,int,int *,double *); 38 | void lubksb(double **,int,int *,double *); 39 | 40 | 41 | #ifdef __cplusplus 42 | } 43 | #endif 44 | 45 | 46 | #endif // _DRAMMS_CRES_H 47 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/common/general.cxx: -------------------------------------------------------------------------------- 1 | /** 2 | * @file general.cxx 3 | * @brief Common constants and macros. 4 | * 5 | * Copyright (c) 2011, 2012 University of Pennsylvania. All rights reserved. 6 | * See https://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | * 8 | * Contact: SBIA Group 9 | */ 10 | 11 | #include "general.h" 12 | 13 | 14 | namespace dramms { 15 | 16 | 17 | DebugLevel g_debug = DEBUG_ERROR; 18 | 19 | 20 | } // namespace dramms 21 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/common/general.h: -------------------------------------------------------------------------------- 1 | /** 2 | * @file general.h 3 | * @brief Common constants and macros. 4 | * 5 | * Copyright (c) 2011 University of Pennsylvania. All rights reserved. 6 | * See https://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | * 8 | * Contact: SBIA Group 9 | */ 10 | 11 | #pragma once 12 | #ifndef _DRAMMS_GENERAL_H 13 | #define _DRAMMS_GENERAL_H 14 | 15 | #include // floor(), ceil() 16 | #include // cout, cerr, endl 17 | #include // istringstream 18 | #include // getline(), string 19 | #include 20 | 21 | 22 | namespace dramms { 23 | 24 | 25 | // =========================================================================== 26 | // constants 27 | // =========================================================================== 28 | 29 | #define YYES 1 30 | #define NNO 0 31 | #define TRUE 1 32 | #define FALSE 0 33 | #define OOKK 1 34 | 35 | 36 | #define E_PI 3.1415926536 37 | #define G_PI 3.1415926 38 | #define INFINITE 1000000000 39 | 40 | #define MaxOfUC 255 41 | 42 | // in case we need to label brain tissue or structure. 43 | // avoid use if possible. 44 | #define BG 0 45 | #define CSF 10 46 | #define VN 50 47 | #define GM 150 48 | #define WM 250 49 | #define Z_THICKINK 1.5 50 | 51 | // =========================================================================== 52 | // debug / verbose output 53 | // =========================================================================== 54 | 55 | 56 | /** 57 | * @brief Enumeration of global debug level used by library functions. 58 | * 59 | * Depending on the debug level, the library function may or may not print 60 | * errors, warnings, and additional verbose output to STDERR or STDOUT, 61 | * respectively. 62 | */ 63 | enum DebugLevel 64 | { 65 | DEBUG_QUIET, ///< Do not print anything. 66 | DEBUG_ERROR, ///< Print only errors. 67 | DEBUG_WARN, ///< Print errors and warnings. 68 | DEBUG_ALL ///< Print all messages. 69 | }; 70 | 71 | extern DebugLevel g_debug; ///< Global debug level used by library functions. 72 | 73 | /// Print warning to @c stderr if debug level is set to @c DEBUG_LEVEL_WARN or above. 74 | #define DRAMMS_WARN(msg) \ 75 | { \ 76 | if (::dramms::g_debug >= ::dramms::DEBUG_WARN) { \ 77 | ::std::cerr << msg << ::std::endl; \ 78 | } \ 79 | } 80 | 81 | /// Print error message to @c stderr if debug level is set to @c DEBUG_LEVEL_ERROR or above. 82 | #define DRAMMS_ERROR(msg) \ 83 | { \ 84 | if (::dramms::g_debug >= ::dramms::DEBUG_ERROR) { \ 85 | ::std::cerr << msg << ::std::endl; \ 86 | } \ 87 | } 88 | 89 | /// Print verbose message to @c stdout if debug level is set to @c DEBUG_LEVEL_ALL. 90 | #define DRAMMS_MSG(msg) \ 91 | { \ 92 | if (::dramms::g_debug >= ::dramms::DEBUG_ALL) { \ 93 | ::std::cout << msg << ::std::endl; \ 94 | } \ 95 | } 96 | 97 | // =========================================================================== 98 | // macros 99 | // =========================================================================== 100 | 101 | #define MIN(x,y) ((x) < (y) ? (x) : (y)) 102 | #define MAX(x,y) ((x) > (y) ? (x) : (y)) 103 | 104 | 105 | // =========================================================================== 106 | // numeric 107 | // =========================================================================== 108 | 109 | /** 110 | * @brief Clamp floating-point value. 111 | * 112 | * @param [in] v Value. 113 | * @param [in] min Minimum allowed value. 114 | * @param [in] max Maximum allowed value. 115 | * 116 | * @returns Value if within specified range, @p min if @p v is smaller than 117 | * @p min, and @p max if @p v is greater than @p max. 118 | */ 119 | inline 120 | float clamp(float v, float min, float max) 121 | { 122 | return (v < min ? min : (v > max ? max : v)); 123 | } 124 | 125 | /** 126 | * @brief Round floating-point value. 127 | */ 128 | inline 129 | float round(float v) 130 | { 131 | return (v > 0.0f) ? floor(v + 0.5f) : ceil(v - 0.5f); 132 | } 133 | 134 | // =========================================================================== 135 | // string manipulation 136 | // =========================================================================== 137 | 138 | /** 139 | * @brief Split string at delimiters. 140 | * 141 | * @param [in] text Input string. 142 | * @param [in] delim Delimiter. 143 | * 144 | * @returns Delimited parts of string, excluding the delimiter. 145 | */ 146 | inline 147 | std::vector split(const std::string& text, char delim = '\n') 148 | { 149 | std::vector tokens; 150 | std::istringstream iss(text); 151 | std::string token; 152 | while (std::getline(iss, token, delim)) { 153 | tokens.push_back(token); 154 | } 155 | return tokens; 156 | } 157 | 158 | 159 | } // namespace dramms 160 | 161 | 162 | #endif // _DRAMMS_GENERAL_H 163 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/common/matrix.h: -------------------------------------------------------------------------------- 1 | #ifndef MATRIX_H 2 | #define MATRIX_H 3 | 4 | #include // required to avoid error regarding log2() 5 | 6 | #ifdef __cplusplus 7 | extern "C" { 8 | #endif 9 | 10 | 11 | /* Feb 2002, for warping DTI */ 12 | typedef struct 13 | { 14 | float v1 ; 15 | float v2 ; 16 | float v3 ; 17 | float v4 ; 18 | float v5 ; 19 | float v6 ; 20 | } DTIattribute ; 21 | 22 | 23 | 24 | /* Nov 2001, for Head brain image */ 25 | typedef struct 26 | { 27 | unsigned char Edge; 28 | unsigned char Tiss; 29 | unsigned char Geom; 30 | unsigned char BGvlm; 31 | unsigned char CSFvlm; 32 | unsigned char VNvlm; 33 | } HeadImgAttribute ; 34 | 35 | 36 | 37 | /* June 2001, for skull-stripped brain image */ 38 | typedef struct 39 | { 40 | unsigned char Edge; 41 | unsigned char Tiss; 42 | unsigned char Geom; 43 | unsigned char VNvlm; 44 | unsigned char CSFBG; 45 | } ImgAttribute ; 46 | 47 | 48 | 49 | typedef struct MatrixStruct 50 | { 51 | double **data; 52 | int height, width; 53 | } Matrix; 54 | 55 | typedef struct uc_MatrixStruct 56 | { 57 | unsigned char **data; 58 | int height, width; 59 | } uc_Matrix; 60 | 61 | typedef struct i_MatrixStruct 62 | { 63 | int **data; 64 | int height, width; 65 | } i_Matrix; 66 | 67 | #define TRUE 1 68 | #define FREE_ARG char* 69 | #define NR_END 1 70 | #define PI 3.141592653589793115997963468544185161590576171875 71 | 72 | static float tempr; 73 | namespace { inline float dummy_use_of_tempr() { return tempr; } } 74 | #define SWAP(a,b) {tempr=(a);(a)=(b);(b)=tempr;} 75 | 76 | #define SIGN(a,b) ((b) >= 0.0 ? fabs(a) : -fabs(a)) 77 | 78 | static float maxarg1,maxarg2; 79 | namespace { inline float dummy_use_of_maxarg() { return maxarg1 + maxarg2; } } 80 | #define FMAX(a,b) (maxarg1=(a),maxarg2=(b),(maxarg1) > (maxarg2) ? (maxarg1) : (maxarg2)) 81 | 82 | static float minarg1,minarg2; 83 | namespace { inline float dummy_use_of_minarg() { return minarg1 + minarg2; } } 84 | #define FMIN(a,b) (minarg1=(a),minarg2=(b),(minarg1) < (minarg2) ?\ 85 | (minarg1) : (minarg2)) 86 | 87 | static int iminarg1,iminarg2; 88 | namespace { inline int dummy_use_of_iminarg() { return iminarg1 + iminarg2; } } 89 | #define IMIN(a,b) (iminarg1=(a),iminarg2=(b),(iminarg1) < (iminarg2) ? (iminarg1) : (iminarg2)) 90 | 91 | static float sqrarg; 92 | namespace { inline float dummy_use_of_sqrarg() { return sqrarg; } } 93 | #define SQR(a) ((sqrarg=(a)) == 0.0 ? 0.0 : sqrarg*sqrarg) 94 | 95 | 96 | 97 | 98 | void nrerrorSHEN(const char *error_text); 99 | double *dvectorSHEN(int nl, int nh); 100 | void free_dvectorSHEN(double *v, int nl, int nh); 101 | float *vectorSHEN(int nl, int nh); 102 | void free_vectorSHEN(float *v, int nl, int nh); 103 | float **matrixSHEN(int nrl,int nrh,int ncl,int nch); 104 | void free_matrixSHEN(float **m,int nrl,int nrh,int ncl,int nch); 105 | double **dmatrixSHEN(int nrl, int nrh, int ncl, int nch); 106 | void free_dmatrixSHEN(double **m, int nrl, int nrh, int ncl, int nch); 107 | double log2(double a); 108 | void sort(double *Y, int *I, double *A, int length); 109 | void minimun(double *Y, int *I, double *A, int length); 110 | void Mat_Abs(Matrix *A); 111 | void Mat_Mean(double *mean, Matrix *A); 112 | void Mat_Variance(double *variance, Matrix *A) ; 113 | void Mat_Vector(Matrix *A, float *a); 114 | void Mat_Shift(Matrix *A, Matrix *B, int side); 115 | void Mat_Zeros(Matrix *A); 116 | void Mat_Zeros_uc(uc_Matrix *A); 117 | void Mat_Zeros_i(i_Matrix *A); 118 | void CreateMatrix(Matrix **M, int hei, int wid); 119 | void FreeMatrix(Matrix *M); 120 | void Create_i_Matrix(i_Matrix **M, int hei, int wid); 121 | void Free_i_Matrix(i_Matrix *M); 122 | void Create_uc_Matrix(uc_Matrix **M, int hei, int wid); 123 | void Free_uc_Matrix(uc_Matrix *M); 124 | void Mat_FFT2(Matrix *Output_real, Matrix *Output_imag, Matrix *Input_real, Matrix *Input_imag); 125 | void Mat_IFFT2(Matrix *Output_real, Matrix *Output_imag, Matrix *Input_real, Matrix *Input_imag); 126 | void four2(double **fftr, double **ffti, double **rdata, double **idata, int rs, int cs, int isign); 127 | void four1(double *data, int nn, int isign); 128 | void Mat_Copy(Matrix *A, Matrix *B, int h_target, int w_target, int h_begin, int w_begin, int h_end,int w_end); 129 | void Mat_uc_Copy(uc_Matrix *A, uc_Matrix *B, int h_target, int w_target, int h_begin, int w_begin,int h_end, int w_end); 130 | void Mat_i_Copy(i_Matrix *A, i_Matrix *B, int h_target, int w_target, int h_begin, int w_begin, int h_end, int w_end); 131 | void Mat_Product(Matrix *A, Matrix *B, Matrix *C); 132 | void Mat_Sum(Matrix *A, Matrix *B, Matrix *C); 133 | void Mat_Substract(Matrix *A, Matrix *B, Matrix *C); 134 | void Mat_Fliplr(Matrix *A); 135 | void Mat_Flipud(Matrix *A); 136 | void Mat_uc_Fliplr(uc_Matrix *A); 137 | void Mat_uc_Flipud(uc_Matrix *A); 138 | 139 | /*by SHEN in JHU*/ 140 | int *ivectorSHEN(long nl, long nh) ; 141 | void free_ivectorSHEN(int *v, long nl, long nh) ; 142 | int Mat_Inverse(Matrix *A, Matrix *B) ; /*A in, B out*/ 143 | void Mat_times_Vector(float *Vout, Matrix *A, float *Vin) ; 144 | void Mat_A_equal_BxC(Matrix *A, Matrix *B, Matrix *C) ; 145 | void Mat_EqualCopy(Matrix *A, Matrix *B) ; 146 | void Mat_Print(Matrix *A) ; 147 | void Mat_Calculate_EigenVectors_EigenValues(Matrix *C, float *EigenValue, Matrix *EigenVector, int PRNorNOT) ; 148 | void svdcmp(float **a, int m, int n, float w[], float **v) ; 149 | void vector_Print(float *v, int size) ; 150 | float gasdev(long *idum) ; 151 | 152 | /* June 2001 */ 153 | ImgAttribute ****ImgAttributealloc4d(int i_size,int j_size,int k_size, int t_size); 154 | ImgAttribute ***ImgAttributealloc3d(int i_size,int j_size,int k_size) ; 155 | ImgAttribute *ImgAttributealloc1d(int k_size) ; 156 | void ImgAttributefree4d(ImgAttribute ****array,int t_size,int k_size,int i_size); 157 | void ImgAttributefree3d(ImgAttribute ***array,int k_size,int i_size) ; 158 | 159 | /* June 2001 */ 160 | HeadImgAttribute ***HeadImgAttributealloc3d(int i_size,int j_size,int k_size) ; 161 | HeadImgAttribute *HeadImgAttributealloc1d(int k_size) ; 162 | void HeadImgAttributefree3d(HeadImgAttribute ***array,int k_size,int i_size) ; 163 | 164 | /* Feb 2002 */ 165 | DTIattribute ***DTIattributealloc3d(int i_size,int j_size,int k_size) ; 166 | DTIattribute *DTIattributealloc1d(int k_size) ; 167 | void DTIattributefree3d(DTIattribute ***array,int k_size,int i_size) ; 168 | 169 | //Yiqiang added on Aug. 2005 170 | void Mat_Transpose(Matrix* A,Matrix*B); 171 | 172 | void Mat_Trace(double* trace,Matrix* A); 173 | void SaveMatrix(char textX[80],Matrix* A); 174 | void OpenMatrix1(char textX[80],int *hei,int *wei); 175 | void OpenMatrix2(char textX[80],Matrix* A); 176 | 177 | #ifdef __cplusplus 178 | } 179 | #endif 180 | 181 | #endif 182 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/common/mvcd.h: -------------------------------------------------------------------------------- 1 | /************************************** 2 | *** Header file for the mvcd library*** 3 | ***************************************/ 4 | #ifndef MVCD_H 5 | #define MVCD_H 6 | 7 | #include 8 | 9 | #define degtorad M_PI/180 10 | #define radtodeg 180/M_PI 11 | 12 | 13 | #ifdef __cplusplus 14 | extern "C" { 15 | #endif 16 | 17 | 18 | typedef struct 19 | { 20 | unsigned char x; 21 | unsigned char y; 22 | } UCvector2d; 23 | 24 | typedef struct 25 | { 26 | unsigned char x; 27 | unsigned char y; 28 | unsigned char z; 29 | } UCvector3d; 30 | 31 | typedef struct 32 | { 33 | int x; 34 | int y; 35 | } Ivector2d; 36 | 37 | typedef struct 38 | { 39 | int x; 40 | int y; 41 | int z; 42 | } Ivector3d; 43 | 44 | typedef struct 45 | { 46 | int x; 47 | int y; 48 | int z; 49 | int t; 50 | } Ivector4d; 51 | 52 | typedef struct 53 | { 54 | short x; 55 | short y; 56 | } Svector2d; 57 | 58 | typedef struct 59 | { 60 | short x; 61 | short y; 62 | short z; 63 | } Svector3d; 64 | 65 | typedef struct 66 | { 67 | long x; 68 | long y; 69 | } Lvector2d; 70 | 71 | typedef struct 72 | { 73 | long x; 74 | long y; 75 | long z; 76 | } Lvector3d; 77 | 78 | typedef struct 79 | { 80 | float x; 81 | float y; 82 | } Fvector2d; 83 | 84 | typedef struct 85 | { 86 | float x; 87 | float y; 88 | float z; 89 | } Fvector3d; 90 | 91 | typedef struct 92 | { 93 | float x; 94 | float y; 95 | float z; 96 | float t; 97 | } Fvector4d; 98 | 99 | typedef struct 100 | { 101 | double x; 102 | double y; 103 | } Dvector2d; 104 | 105 | typedef struct 106 | { 107 | double x; 108 | double y; 109 | double z; 110 | } Dvector3d; 111 | 112 | typedef struct 113 | { 114 | float r; 115 | float t; 116 | float p; 117 | } Fsphere; 118 | 119 | /*****Memory Allocation*****/ 120 | 121 | char *Calloc1d(int); 122 | char **Calloc2d(int,int); 123 | char ***Calloc3d(int,int,int); 124 | unsigned char *UCalloc1d(int); 125 | unsigned char **UCalloc2d(int,int); 126 | unsigned char ***UCalloc3d(int,int,int); 127 | unsigned char ****UCalloc4d(int,int,int,int); 128 | int *Ialloc1d(int); 129 | int **Ialloc2d(int,int); 130 | int ***Ialloc3d(int,int,int); 131 | int ****Ialloc4d(int,int,int,int); 132 | short *Salloc1d(int); 133 | short **Salloc2d(int,int); 134 | short ***Salloc3d(int,int,int); 135 | short ****Salloc4d(int,int,int,int); 136 | long *Lalloc1d(int); 137 | long **Lalloc2d(int,int); 138 | long ***Lalloc3d(int,int,int); 139 | long ****Lalloc4d(int,int,int,int); 140 | float *Falloc1d(int); 141 | float **Falloc2d(int,int); 142 | float ***Falloc3d(int,int,int); 143 | float ****Falloc4d(int,int,int,int); 144 | double *Dalloc1d(int); 145 | double **dalloc2d(int,int); 146 | double ***Dalloc3d(int,int,int); 147 | double ****Dalloc4d(int,int,int,int); 148 | UCvector3d *UCvector3dalloc1d(int); 149 | UCvector3d **UCvector3dalloc2d(int,int); 150 | UCvector3d ***UCvector3dalloc3d(int,int,int); 151 | UCvector3d ****UCvector3dalloc4d(int,int,int,int); 152 | UCvector2d *UCvector2dalloc1d(int); 153 | UCvector2d **UCvector2dalloc2d(int,int); 154 | UCvector2d ***UCvector2dalloc3d(int,int,int); 155 | Ivector3d *Ivector3dalloc1d(int); 156 | Ivector3d **Ivector3dalloc2d(int,int); 157 | Ivector3d ***Ivector3dalloc3d(int,int,int); 158 | Ivector3d ****Ivector3dalloc4d(int,int,int,int); 159 | Ivector2d *Ivector2dalloc1d(int); 160 | Ivector2d **Ivector2dalloc2d(int,int); 161 | Ivector2d ***Ivector2dalloc3d(int,int,int); 162 | Svector3d *Svector3dalloc1d(int); 163 | Svector3d **Svector3dalloc2d(int,int); 164 | Svector3d ***Svector3dalloc3d(int,int,int); 165 | Svector3d ****Svector3dalloc4d(int,int,int,int); 166 | Svector2d *Svector2dalloc1d(int); 167 | Svector2d **Svector2dalloc2d(int,int); 168 | Svector2d ***Svector2dalloc3d(int,int,int); 169 | Lvector3d *Lvector3dalloc1d(int); 170 | Lvector3d **Lvector3dalloc2d(int,int); 171 | Lvector3d ***Lvector3dalloc3d(int,int,int); 172 | Lvector3d ****Lvector3dalloc4d(int,int,int,int); 173 | Lvector2d *Lvector2dalloc1d(int); 174 | Lvector2d **Lvector2dalloc2d(int,int); 175 | Lvector2d ***Lvector2dalloc3d(int,int,int); 176 | Fvector3d *Fvector3dalloc1d(int); 177 | Fvector3d **Fvector3dalloc2d(int,int); 178 | Fvector3d ***Fvector3dalloc3d(int,int,int); 179 | Fvector3d ****Fvector3dalloc4d(int,int,int,int); 180 | Fvector2d *Fvector2dalloc1d(int); 181 | Fvector2d **Fvector2dalloc2d(int,int); 182 | Fvector2d ***Fvector2dalloc3d(int,int,int); 183 | Dvector3d *Dvector3dalloc1d(int); 184 | Dvector3d **Dvector3dalloc2d(int,int); 185 | Dvector3d ***Dvector3dalloc3d(int,int,int); 186 | Dvector3d ****Dvector3dalloc4d(int,int,int,int); 187 | Dvector2d *Dvector2dalloc1d(int); 188 | Dvector2d **Dvector2dalloc2d(int,int); 189 | Dvector2d ***Dvector2dalloc3d(int,int,int); 190 | Fsphere *Fspherealloc1d(int); 191 | Ivector4d *Ivector4dalloc1d(int i_size); 192 | Fvector4d *Fvector4dalloc1d(int i_size); 193 | 194 | 195 | void Cfree2d(char **,int); 196 | void Cfree3d(char ***,int,int); 197 | void UCfree2d(unsigned char **,int); 198 | void UCfree3d(unsigned char ***,int,int); 199 | void UCfree4d(unsigned char ****,int,int,int); 200 | void Ifree2d(int **,int); 201 | void Ifree3d(int ***,int,int); 202 | void Ifree4d(int ****,int,int,int); 203 | void Sfree2d(short **,int); 204 | void Sfree3d(short ***,int,int); 205 | void Sfree4d(short ****,int,int,int); 206 | void Lfree2d(long **,int); 207 | void Lfree3d(long ***,int,int); 208 | void Lfree4d(long ****,int,int,int); 209 | void Ffree2d(float **,int); 210 | void Ffree3d(float ***,int,int); 211 | void Ffree4d(float ****,int,int,int); 212 | void Dfree2d(double **,int); 213 | void Dfree3d(double ***,int,int); 214 | void Dfree4d(double ****,int,int,int); 215 | void UCvector3dfree2d(UCvector3d **,int); 216 | void UCvector3dfree3d(UCvector3d ***,int,int); 217 | void UCvector3dfree4d(UCvector3d ****,int,int,int); 218 | void UCvector2dfree2d(UCvector2d **,int); 219 | void UCvector2dfree3d(UCvector2d ***,int,int); 220 | void Ivector3dfree2d(Ivector3d **,int); 221 | void Ivector3dfree3d(Ivector3d ***,int,int); 222 | void Ivector3dfree4d(Ivector3d ****,int,int,int); 223 | void Ivector2dfree2d(Ivector2d **,int); 224 | void Ivector2dfree3d(Ivector2d ***,int,int); 225 | void Svector3dfree2d(Svector3d **,int); 226 | void Svector3dfree3d(Svector3d ***,int,int); 227 | void Svector3dfree4d(Svector3d ****,int,int,int); 228 | void Svector2dfree2d(Svector2d **,int); 229 | void Svector2dfree3d(Svector2d ***,int,int); 230 | void Lvector3dfree2d(Lvector3d **,int); 231 | void Lvector3dfree3d(Lvector3d ***,int,int); 232 | void Lvector3dfree4d(Lvector3d ****,int,int,int); 233 | void Lvector2dfree2d(Lvector2d **,int); 234 | void Lvector2dfree3d(Lvector2d ***,int,int); 235 | void Fvector3dfree2d(Fvector3d **,int); 236 | void Fvector3dfree3d(Fvector3d ***,int,int); 237 | void Fvector3dfree4d(Fvector3d ****,int,int,int); 238 | void Fvector2dfree2d(Fvector2d **,int); 239 | void Fvector2dfree3d(Fvector2d ***,int,int); 240 | void Dvector3dfree2d(Dvector3d **,int); 241 | void Dvector3dfree3d(Dvector3d ***,int,int); 242 | void Dvector3dfree4d(Dvector3d ****,int,int,int); 243 | void Dvector2dfree2d(Dvector2d **,int); 244 | void Dvector2dfree3d(Dvector2d ***,int,int); 245 | 246 | /*****Cartesian to spherical coordinate transformation*****/ 247 | 248 | void cartesianToSpherical(Fsphere *,Fvector3d *,int); 249 | /*****Error reporting file open function****/ 250 | 251 | FILE* myopen(char *,char *); 252 | 253 | /*****Redistribute Points*****/ 254 | 255 | void Fvector2dredistribute1d(Fvector2d *,int,int); 256 | void Fvector3dredistribute1d(Fvector3d *,int,int); 257 | 258 | void Fvector3dinterpCurve1d(Fvector3d *,Fvector3d *,float *,int,int); 259 | 260 | 261 | /*****Compute magnitude of 2D and 3D vectors*****/ 262 | 263 | double Fvector2dmag(Fvector2d); 264 | double Fvector3dmag(Fvector3d); 265 | 266 | /*****Compute Normals*****/ 267 | 268 | void Fvector3dnorms2d(int,int,Fvector3d **,Fvector3d **); 269 | 270 | /***** 271 | Note: Fvector3dcurvature2d() computes curvature and is in the cres library 272 | *****/ 273 | 274 | 275 | 276 | #ifdef __cplusplus 277 | } 278 | #endif 279 | 280 | 281 | 282 | #endif 283 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/tools/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | ############################################################################## 2 | # @file CMakeLists.txt 3 | # @brief Build configuration of software. 4 | # 5 | # Copyright (c) 2011, 2012 University of Pennsylvania. All rights reserved. 6 | # See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | # 8 | # Contact: SBIA Group 9 | ############################################################################## 10 | 11 | # ---------------------------------------------------------------------------- 12 | ## @brief Add auxiliary executable for internal use by dramms script only. 13 | macro (dramms_add_advanced_tool EXENAME) 14 | basis_add_executable(${EXENAME}.cxx LIBEXEC ${ARGN}) 15 | basis_target_link_libraries(${EXENAME} common) 16 | endmacro () 17 | 18 | # ---------------------------------------------------------------------------- 19 | ## @brief Add auxiliary executable also for use by end users. 20 | macro (dramms_add_user_tool EXENAME NAME_SUFFIX) 21 | basis_add_executable(${EXENAME}.cxx ${ARGN}) 22 | basis_target_link_libraries(${EXENAME} common) 23 | basis_set_target_properties (${EXENAME} PROPERTIES OUTPUT_NAME "dramms-${NAME_SUFFIX}") 24 | endmacro () 25 | 26 | # ---------------------------------------------------------------------------- 27 | # auxiliary executables 28 | dramms_add_advanced_tool(CheckTwoImages) 29 | dramms_add_advanced_tool(GenerateGaborListFile) 30 | dramms_add_advanced_tool(GenerateImageListFile) 31 | dramms_add_advanced_tool(CalculateImageSimilarity) 32 | 33 | # ---------------------------------------------------------------------------- 34 | # tools to combine files 35 | dramms_add_advanced_tool(CombineFeatureLists) 36 | dramms_add_user_tool(CombineTransforms combine) 37 | 38 | # ---------------------------------------------------------------------------- 39 | # basic processing tools 40 | dramms_add_advanced_tool(CalculateGaborTextures) 41 | dramms_add_advanced_tool(MatchHistograms) 42 | 43 | dramms_add_user_tool(ApplyTransform warp) 44 | dramms_add_user_tool(CalculateJacobianMap jacobian) 45 | dramms_add_user_tool(CalculateRavensMaps ravens) 46 | dramms_add_user_tool(ImageOperation imgop) 47 | dramms_add_user_tool(TransformOperation defop) 48 | 49 | # ---------------------------------------------------------------------------- 50 | # conversion tools 51 | dramms_add_user_tool(ConvertDeformation convert) 52 | dramms_add_advanced_tool(ConvertImage) 53 | 54 | # ---------------------------------------------------------------------------- 55 | # deformable registration 56 | dramms_add_advanced_tool(Deform2D) 57 | dramms_add_advanced_tool(Deform3D DiscreteOptimizationUtilities.cxx GeneralUtilities.cxx) 58 | basis_target_link_libraries(Deform3D "${DRAMMSFastPD_LIBRARY}") 59 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/tools/CheckTwoImages.cxx: -------------------------------------------------------------------------------- 1 | /** 2 | * @file CheckTwoImages.cxx 3 | * @brief Checks if two input images share the same image size and voxel size. 4 | * 5 | * Copyright (c) 2012 University of Pennsylvania. All rights reserved.
6 | * See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | * 8 | * Contact: SBIA Group 9 | */ 10 | 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | 18 | #include // exename(), print_contact() 19 | 20 | 21 | // acceptable in .cxx file 22 | using namespace std; 23 | using namespace basis; 24 | using namespace dramms; 25 | 26 | 27 | // ATTENTION: The exit code of this program is the number of dimensions of 28 | // the input images! In case of an error or if the images are 29 | // not defined on the same image grid, the value 0 is returned! 30 | // On error, the value 255 is returned. 31 | 32 | 33 | // =========================================================================== 34 | // help 35 | // =========================================================================== 36 | 37 | // --------------------------------------------------------------------------- 38 | void print_help() 39 | { 40 | string exec_name = exename(); 41 | cout << "-------------------------------------------------" << endl; 42 | cout << "This program checks two intensity images or two features images. For intensity images (by default), the program checks whether two images share the same image and voxel size. In this case, the program returns 0 if two images are not in the same space, 2 if they are in the same 2D space, and 3 if they are in the same 3D space. For feature images (-f option), the program checks whether two feature images have roughly the same number of foreground voxels. It returns 100 if two images do have roughly the same number of foreground voxels, and 200 otherwise" << endl; 43 | cout << " -h help" < 2) { 94 | print_help(); 95 | cerr << "Too many arguments specified!" << endl; 96 | exit(255); 97 | } 98 | 99 | 100 | nifti_1_header *nhdr1 = nifti_read_header(argv[0], NULL, 1); 101 | if (nhdr1 == NULL) { 102 | cerr << "Failed to read header of image " << argv[0] << endl; 103 | exit(255); 104 | } 105 | 106 | nifti_1_header *nhdr2 = nifti_read_header(argv[1], NULL, 1); 107 | if (nhdr2 == NULL) { 108 | cerr << "Failed to read header of image " << argv[1] << endl; 109 | free(nhdr1); 110 | exit(255); 111 | } 112 | 113 | 114 | if (nhdr1->dim[3] < 1) { 115 | nhdr1->dim [3] = 1; 116 | nhdr1->pixdim[3] = 1.0f; 117 | } 118 | if (nhdr2->dim[3] < 1) { 119 | nhdr2->dim [3] = 1; 120 | nhdr2->pixdim[3] = 1.0f; 121 | } 122 | 123 | if (checkFeatureImage==false) 124 | { 125 | bool ShareImageSize = false; 126 | if ((nhdr1->dim[1] == nhdr2->dim[1]) && 127 | (nhdr1->dim[2] == nhdr2->dim[2]) && 128 | (nhdr1->dim[3] == nhdr2->dim[3])) ShareImageSize = true; 129 | 130 | bool ShareVoxelSize = false; 131 | if ((nhdr1->pixdim[1] == nhdr2->pixdim[1]) && 132 | (nhdr1->pixdim[2] == nhdr2->pixdim[2]) && 133 | (nhdr1->pixdim[3] == nhdr2->pixdim[3])) ShareVoxelSize = true; 134 | 135 | if ( (ShareImageSize==true)&&(ShareVoxelSize==true) ) { 136 | //cout << "Two images share the same image and voxel sizes." << endl; 137 | cout << "Image size: (" << nhdr1->dim [1] << ", " << nhdr1->dim [2] << ", " << nhdr1->dim [3] << ")" << endl; 138 | cout << "Voxel size: (" << nhdr1->pixdim[1] << ", " << nhdr1->pixdim[2] << ", " << nhdr1->pixdim[3] << ")" << endl; 139 | if (nhdr1->dim[3] == 1) { 140 | free(nhdr1); 141 | free(nhdr2); 142 | exit(2); 143 | } else if (nhdr1->dim[3] > 1) { 144 | free(nhdr1); 145 | free(nhdr2); 146 | exit(3); 147 | } 148 | } 149 | else 150 | { 151 | cout << "Two images vary by image size and/or voxel size." << endl; 152 | cout << "Image size: (" << nhdr1->dim [1] << ", " << nhdr1->dim [2] << ", " << nhdr1->dim [3] << ") for the first image, (" << nhdr2->dim [1] << ", " << nhdr2->dim [2] << ", " << nhdr2->dim [3] << ") for the second image. " << endl; 153 | cout << "Voxel size: (" << nhdr1->pixdim [1] << ", " << nhdr1->pixdim [2] << ", " << nhdr1->pixdim [3] << ") for the first image, (" << nhdr2->pixdim [1] << ", " << nhdr2->pixdim [2] << ", " << nhdr2->pixdim [3] << ") for the second image. " << endl; 154 | } 155 | free(nhdr1); 156 | free(nhdr2); 157 | exit(0); 158 | } 159 | else // check feature images 160 | { 161 | Image* imageA = ReadImage(argv[0]); 162 | Image* imageB = ReadImage(argv[1]); 163 | unsigned char ***imgA, ***imgB; 164 | imgA = imageA->img.uc; 165 | imgB = imageB->img.uc; 166 | int dimx = imageA->region.nx; 167 | int dimy = imageA->region.ny; 168 | int dimz = imageA->region.nz; 169 | 170 | int i,j,k; 171 | int minjA, maxjA, minjB, maxjB; 172 | int countA=0; 173 | int countB=0; 174 | int countAfilled=0; 175 | int countBfilled=0; 176 | for (k=0;k0) { 186 | countA++; 187 | minjA=MIN(minjA,j); 188 | maxjA=MAX(maxjA,j); 189 | } 190 | if (imgB[k][i][j]>0) { 191 | countB++; 192 | minjB=MIN(minjB,j); 193 | maxjB=MAX(maxjB,j); 194 | } 195 | } 196 | countAfilled += MAX(maxjA-minjA, 0); 197 | countBfilled += MAX(maxjB-minjB, 0); 198 | } 199 | // printf("countA=%d, countB=%d, ratio=%f\ncountAfilled=%d, countBfilled=%d, ratio=%f\n", countA, countB, (float)countA/(float)countB, countAfilled, countBfilled, (float)countAfilled/(float)countBfilled); 200 | 201 | if ( ( (countA>1.25*countB) || (countA<0.8*countB) )&&( (countAfilled>1.15*countBfilled) || (countAfilled<0.87*countBfilled) ) ){ 202 | delete imageA; 203 | delete imageB; 204 | exit(200); 205 | } 206 | else 207 | { 208 | delete imageA; 209 | delete imageB; 210 | exit(100); 211 | } 212 | } 213 | } 214 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/tools/CombineFeatureLists.cxx: -------------------------------------------------------------------------------- 1 | /** 2 | * @file CombineFeatureLists.cxx 3 | * @brief combine two feature lists into one. 4 | * 5 | * Copyright (c) 2012 University of Pennsylvania. All rights reserved.
6 | * See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | * 8 | * Contact: SBIA Group 9 | */ 10 | 11 | #include 12 | #include // cout, cerr, endl 13 | #include 14 | #include 15 | #include 16 | #include // exename(), print_contact() 17 | 18 | 19 | // acceptable in .cxx file 20 | using namespace std; 21 | using namespace basis; 22 | using namespace dramms; 23 | 24 | 25 | // =========================================================================== 26 | // help 27 | // =========================================================================== 28 | 29 | // --------------------------------------------------------------------------- 30 | void print_help() 31 | { 32 | string exec_name = exename(); 33 | cout << "-------------------------------------------------" << endl; 34 | cout << "This program combines two input feature lists into a single list. " << endl; 35 | cout << "-------------------------------------------------" << endl << endl; 36 | cout << "Usage:" << endl; 37 | cout << " " << exec_name << " " << endl; 38 | cout << endl; 39 | cout << "Example: " << endl; 40 | cout << " " << exec_name <<" GaborFeature1.lst GaborFeature2.lst GaborFeature_all.lst " << endl; 41 | cout << endl; 42 | print_contact(); 43 | } 44 | 45 | 46 | 47 | int main(int argc,char *argv[]) 48 | { 49 | int numFeatures1, numFeatures2, numFeaturesCombined; 50 | int idx; 51 | 52 | char featureName[1000]; 53 | FILE *fp1, *fp2, *fpCombined; 54 | 55 | argc -= optind; 56 | argv += optind; 57 | if (argc != 3) { 58 | print_help(); 59 | exit(1); 60 | } 61 | 62 | const char* fileName1 = argv[0]; 63 | const char* fileName2 = argv[1]; 64 | const char* fileNameCombined = argv[2]; 65 | 66 | 67 | if (NULL==(fp1=fopen(fileName1,"rb"))){ 68 | printf("File %s doesn't exist!\n",fileName1); 69 | exit(1); 70 | } 71 | if (NULL==(fp2=fopen(fileName2,"rb"))){ 72 | printf("File %s doesn't exist!\n",fileName2); 73 | exit(1); 74 | } 75 | fscanf(fp1,"%d",&numFeatures1); 76 | fscanf(fp2,"%d",&numFeatures2); 77 | numFeaturesCombined = numFeatures1+numFeatures2; 78 | fpCombined = fopen(fileNameCombined, "w"); 79 | fprintf(fpCombined, "%d\n", numFeaturesCombined); 80 | 81 | 82 | for (idx=1;idx<=numFeatures1;idx++) 83 | { 84 | fscanf(fp1,"%s",featureName); 85 | fprintf(fpCombined, "%s\n", featureName); 86 | } 87 | fclose(fp1); 88 | for (idx=1;idx<=numFeatures2;idx++) 89 | { 90 | fscanf(fp2,"%s",featureName); 91 | fprintf(fpCombined, "%s\n", featureName); 92 | } 93 | fclose(fp2); 94 | fclose(fpCombined); 95 | 96 | printf("\n%d features in file %s\n", numFeatures1, fileName1); 97 | printf("%d features in file %s\n", numFeatures2, fileName2); 98 | printf("=>\n"); 99 | printf("%d featuers combined in file %s\n\n", numFeaturesCombined, fileNameCombined); 100 | } 101 | 102 | 103 | 104 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/tools/DiscreteOptimizationUtilities.h: -------------------------------------------------------------------------------- 1 | /** 2 | * @file DiscreteOptimizationUtilities.h 3 | * @brief Discrete optimization calling FastPD. 4 | * 5 | * The Copyright
6 | * Department of Computer Science,
7 | * University of Crete, Greece 8 | * 9 | * Mathématiques Appliquées aux Systèmes (MAS),
10 | * Ecole Centrale de Paris, France 11 | * 12 | * Copyright (c) 2009. All rights reserved.
13 | * See http://www.csd.uoc.gr/~komod/FastPD/ for more details. 14 | * 15 | * Copyright (c) 2011, 2012 University of Pennylvania. All rights reserved.
16 | * See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file.
17 | * Modification based on written authorization from FastPD's author. 18 | * 19 | * Contact: SBIA Group 20 | */ 21 | 22 | 23 | 24 | #ifndef __DISCRETEOPTUT_H__ 25 | #define __DISCRETEOPTUT_H__ 26 | 27 | #include "common/mvcd.h" 28 | 29 | void computeLabels(int numSamples, int distBetweenControlPointsX, int distBetweenControlPointsY, int distBetweenControlPointsZ, Fvector3d resolutionRatio, int levelIndex, int method, float *labels, float label_factor, int iter, int numIterInEachResolution, int indexGridLevel, int numGridLevels, int fastApproximationOrNot); 30 | void computePairs(int numControlPointsX, int numControlPointsY, int numControlPointsZ, int *pairs); 31 | void computeWcosts(int numPairs, float regWeight, float *wcosts); 32 | void computeWcosts_Ou(int numPairs, int numPoints, int numLabels, float regWeight, float *lcosts, float *dist, float *wcosts); 33 | void computeDist(float *labels, int numLabels, Fvector3d voxelSize, int distMethod, float threshold, float *dist, int distBetweenControlPointsX, int distBetweenControlPointsY, int distBetweenControlPointsZ); 34 | void computeUnary(unsigned char ****SF, unsigned char ****TF, float *labels, int numControlPointsX, int numControlPointsY, 35 | int numControlPointsZ, int distBetweenControlPointsX, int distBetweenControlPointsY, int distBetweenControlPointsZ, int method, 36 | int distBasedWeight, Ivector3d imageSize, Fvector3d resolutionRatio, float ***confidenceMap, Fvector3d ***defField, int numLabels, 37 | int numFeatures, int SimilarityMeasure, int chk, unsigned char ***mask, float *lcosts, int AdditionOrComposition, float *weightsX, float *weightsY, float *weightZ); 38 | void labels2deformations(int *optimalLabels, float *labels, int numControlPointsX, int numControlPointsY, 39 | int numControlPointsZ, Fvector3d ***controlPointDisp, int numLabels); 40 | #endif 41 | 42 | 43 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/tools/GeneralUtilities.h: -------------------------------------------------------------------------------- 1 | #ifndef __GENERALUTIL_H__ 2 | #define __GENERALUTIL_H__ 3 | 4 | #include "common/mvcd.h" 5 | 6 | int myround(float x); 7 | float featureCost(unsigned char ****trg, unsigned char ****src, float ***confidenceMap, int x_trg, int y_trg, 8 | int z_trg, float x_src, float y_src, float z_src, int numFeatures, int SimilarityMeasure, Ivector3d imageSize); 9 | //float myTrilinearInterpolation(unsigned char ***Img, float x, float y, float z, Ivector3d imageSize); 10 | void precomputeWeights(Ivector3d imageSize, int distBetweenControlPointsX, int distBetweenControlPointsY, int distBetweenControlPointsZ, Fvector3d resolutionRatio, int method, 11 | float *weightsX, float *weightsY, float *weightsZ); 12 | 13 | #endif 14 | 15 | 16 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/src/tools/GenerateGaborListFile.cxx: -------------------------------------------------------------------------------- 1 | /** 2 | * @file GenerateGaborListFile.cxx 3 | * @brief generate a (text) list of Gabor feature images. 4 | * 5 | * Copyright (c) 2012 University of Pennsylvania. All rights reserved.
6 | * See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | * 8 | * Contact: SBIA Group 9 | */ 10 | 11 | #include 12 | #include // cout, cerr, endl 13 | #include 14 | #include 15 | #include 16 | #include // exename(), print_contact() 17 | 18 | 19 | // acceptable in .cxx file 20 | using namespace std; 21 | using namespace basis; 22 | using namespace dramms; 23 | 24 | 25 | // =========================================================================== 26 | // help 27 | // =========================================================================== 28 | 29 | // --------------------------------------------------------------------------- 30 | void print_help() 31 | { 32 | string exec_name = exename(); 33 | cout << "-------------------------------------------------" << endl; 34 | cout << "This program generate a text list of Gabor feature images. " << endl; 35 | cout << "-------------------------------------------------" << endl << endl; 36 | cout << "Usage:" << endl; 37 | cout << " " << exec_name << " " << endl; 38 | cout << endl; 39 | cout << "Optional arguments:" << endl; 40 | cout << "\t -s : the number of scales in Gabor features (default: 3)" << endl; 41 | cout << "\t -o : the number of orientations in Gabor features (default: 3)" < 6 | * See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 7 | * 8 | * Contact: SBIA Group 9 | */ 10 | 11 | #include 12 | #include // cout, cerr, endl 13 | #include 14 | #include 15 | #include 16 | #include // exename(), print_contact() 17 | 18 | 19 | // acceptable in .cxx file 20 | using namespace std; 21 | using namespace basis; 22 | using namespace dramms; 23 | 24 | 25 | // =========================================================================== 26 | // help 27 | // =========================================================================== 28 | 29 | // --------------------------------------------------------------------------- 30 | void print_help() 31 | { 32 | string exec_name = exename(); 33 | cout << "-------------------------------------------------" << endl; 34 | cout << "This program generate a text file that lists intensity image as feature image to be used in deformation. " << endl; 35 | cout << "-------------------------------------------------" << endl << endl; 36 | cout << "Usage:" << endl; 37 | cout << " " << exec_name << " " << endl; 38 | cout << endl; 39 | cout << "Example: " << endl; 40 | cout << " " << exec_name <<" A.img ImageFeatures.lst " << endl; 41 | cout << endl; 42 | print_contact(); 43 | } 44 | 45 | 46 | 47 | 48 | int main(int argc,char *argv[]) 49 | { 50 | FILE *fp; 51 | 52 | argc -= optind; 53 | argv += optind; 54 | if (argc != 2) { 55 | print_help(); 56 | exit(1); 57 | } 58 | 59 | const char* ImageName=argv[0]; 60 | const char* ListFileName=argv[1]; 61 | 62 | 63 | fp = fopen(ListFileName, "w"); 64 | fprintf(fp, "1\n"); 65 | fprintf(fp, "%s\n", ImageName); 66 | fclose(fp); 67 | 68 | printf("\nImage list has been written into file %s\n\n", ListFileName); 69 | } 70 | 71 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | ############################################################################## 2 | # @file CMakeLists.txt 3 | # @brief Build configuration of software testing. 4 | # 5 | # Unit tests test only single functions, classes, and modules of the software. 6 | # System tests, on the other side, execute the programs of this package with 7 | # given test input data and compare the output of the programs to the expected 8 | # results. For the definition of system tests which perform image regression 9 | # tests, i.e., compare the images written by the test to given baseline images, 10 | # the basis.testdriver executable target imported from BASIS can be used to 11 | # execute the executable to test and perform the regression tests. 12 | # 13 | # Example: 14 | # @code 15 | # basis_add_test ( 16 | # COMMAND basis.testdriver -v 17 | # --intensity-tolerance 2 18 | # --compare "t1_bc.nii.gz" 19 | # "${PROJECT_TESTING_DIR}/baseline/t1_bc.nii.gz" 20 | # -- 21 | # $ 22 | # "${PROJECT_TESTING_DIR}/input/t1.nii.gz" 23 | # t1_bc.nii.gz 24 | # ) 25 | # @endcode 26 | # 27 | # If the tests are implemented in C/C++ as supported by CMake's 28 | # create_test_sourcelist() function, a custom test driver can be generated 29 | # using the basis_add_test_driver() function and this test driver then be used 30 | # to execute the tests and perform the regression tests. 31 | # 32 | # Example: 33 | # @code 34 | # basis_add_test_driver (testdriver test1.cxx test2.cxx test3.cxx) 35 | # 36 | # basis_add_test ( 37 | # COMMAND testdriver -v 38 | # --intensity-tolerance 2 39 | # --compare "t1_bc.nii.gz" 40 | # "${PROJECT_TESTING_DIR}/baseline/t1_bc.nii.gz" 41 | # -- 42 | # biascorrect # test1.cxx defines int biascorrect(int argc, char* argv[]) 43 | # "${PROJECT_TESTING_DIR}/input/t1.nii.gz" 44 | # t1_bc.nii.gz 45 | # ) 46 | # 47 | # # ... 48 | # @endcode 49 | # 50 | # @sa http://www.cmake.org/cmake/help/cmake-2-8-docs.html#command:create_test_sourcelist 51 | # 52 | # The built test executables can be found in @c TESTING_RUNTIME_DIR. 53 | # The test output shall be written to @c TESTING_OUTPUT_DIR. In most cases, 54 | # a subdirectory for each test should be created under this output directory. 55 | # Therefore, the basis_add_test() function creates such subdirectory and sets 56 | # the working directory of the test to this output directory. 57 | # 58 | # Copyright (c) 2011, 2012 University of Pennsylvania. All rights reserved.
59 | # See http://www.rad.upenn.edu/sbia/software/license.html or COPYING file. 60 | # 61 | # Contact: SBIA Group 62 | ############################################################################## 63 | 64 | # ============================================================================ 65 | # internal tests 66 | # ============================================================================ 67 | 68 | if (IS_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/internal") 69 | add_subdirectory ("internal") 70 | endif () 71 | 72 | # ============================================================================ 73 | # public tests 74 | # ============================================================================ 75 | 76 | set (INPUT_DIR "${CMAKE_CURRENT_SOURCE_DIR}/input") 77 | set (BASELINE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/baseline") 78 | 79 | if (APPLE) 80 | # these very liberal tolerances seem to be required due to the 81 | # affine registration that is done prior to the deformable one; 82 | # only after increasing them, the test passed on my 83 | # MacBook Pro Retina (early 2013) with OS X 10.8.4 and FSL 5.0.1 84 | # -schuha 85 | set (WITH_AFFINE_INTENSITY_TOLERANCE 5) 86 | set (WITH_AFFINE_MAX_NUMBER_OF_DIFFERENCES 1000) 87 | else () 88 | set (WITH_AFFINE_INTENSITY_TOLERANCE 5) 89 | set (WITH_AFFINE_MAX_NUMBER_OF_DIFFERENCES 500) 90 | endif () 91 | 92 | 93 | basis_add_test( 94 | dramms_default_noaffine 95 | COMMAND 96 | basis.testdriver 97 | --compare "H08c_to_H09c_default_noaffine.nii.gz" 98 | "${BASELINE_DIR}/H08c_to_H09c_default_noaffine.nii.gz" 99 | --intensity-tolerance 0.01 100 | -- 101 | $ -v -v 102 | -a 0 103 | -S ${INPUT_DIR}/H08c.nii.gz 104 | -T ${INPUT_DIR}/H09c.nii.gz 105 | -O H08c_to_H09c_default_noaffine.nii.gz 106 | -D def_H08c_to_H09c_noaffine.nii.gz 107 | ) 108 | 109 | 110 | basis_add_test( 111 | dramms_default_affine 112 | COMMAND 113 | basis.testdriver 114 | --intensity-tolerance ${WITH_AFFINE_INTENSITY_TOLERANCE} 115 | --max-number-of-differences ${WITH_AFFINE_MAX_NUMBER_OF_DIFFERENCES} 116 | --compare "H08c_to_H09c_default_affine.nii.gz" 117 | "${BASELINE_DIR}/H08c_to_H09c_default_affine.nii.gz" 118 | -- 119 | $ -v -v 120 | -S "${INPUT_DIR}/H08c.nii.gz" 121 | -T "${INPUT_DIR}/H09c.nii.gz" 122 | -O H08c_to_H09c_default_affine.nii.gz 123 | ) 124 | 125 | 126 | basis_add_test( 127 | dramms_warping 128 | COMMAND 129 | basis.testdriver 130 | --compare "warped_H08c_to_H09c.nii.gz" 131 | "${BASELINE_DIR}/warped_H08c_to_H09c.nii.gz" 132 | -- 133 | $ -v -v 134 | -a 0 135 | -g 0.2 136 | -x 4 137 | -y 5 138 | -S "${INPUT_DIR}/H08c.nii.gz" 139 | -T "${INPUT_DIR}/H09c.nii.gz" 140 | -L "${INPUT_DIR}/H08c.nii.gz" 141 | -W warped_H08c_to_H09c.nii.gz 142 | -r 0 143 | ) 144 | 145 | 146 | basis_add_test( 147 | dramms_jacobian 148 | COMMAND 149 | basis.testdriver 150 | --intensity-tolerance 0.01 151 | --compare jac_H08c_to_H09c.nii.gz 152 | "${BASELINE_DIR}/jac_H08c_to_H09c.nii.gz" 153 | -- 154 | $ -v -v 155 | -a 0 156 | -g 0.5 157 | -S "${INPUT_DIR}/H08c.nii.gz" 158 | -T "${INPUT_DIR}/H09c.nii.gz" 159 | -J jac_H08c_to_H09c.nii.gz 160 | ) 161 | 162 | 163 | basis_add_test( 164 | dramms_ravens 165 | COMMAND 166 | basis.testdriver 167 | --compare "ravens_H08c_to_H09c.nii.gz" 168 | "${BASELINE_DIR}/ravens_H08c_to_H09c_1.nii.gz" 169 | -- 170 | $ -v -v 171 | -a 0 172 | -g 0.3 173 | -n 4 174 | -k 5 175 | -t 30 176 | -S "${INPUT_DIR}/H08c.nii.gz" 177 | -T "${INPUT_DIR}/H09c.nii.gz" 178 | -L "${INPUT_DIR}/H08c_tissueforravens.nii.gz" 179 | -l 1 180 | -R ravens_H08c_to_H09c.nii.gz 181 | ) 182 | 183 | 184 | basis_add_test( 185 | dramms_initdef 186 | COMMAND 187 | basis.testdriver 188 | --intensity-tolerance 3 189 | --max-number-of-differences 20 190 | --compare "H08c_to_H09c_with_initdef.nii.gz" 191 | "${BASELINE_DIR}/H08c_to_H09c_with_initdef.nii.gz" 192 | -- 193 | $ -v -v 194 | -a 0 195 | -S "${INPUT_DIR}/H08c.nii.gz" 196 | -T "${INPUT_DIR}/H09c.nii.gz" 197 | -d "${INPUT_DIR}/def_H08c_to_H09c_noaffine.nii.gz" 198 | -O H08c_to_H09c_with_initdef.nii.gz 199 | ) 200 | 201 | 202 | basis_add_test( 203 | dramms_brainregwarpjac 204 | COMMAND 205 | basis.testdriver 206 | --intensity-tolerance ${WITH_AFFINE_INTENSITY_TOLERANCE} 207 | --max-number-of-differences ${WITH_AFFINE_MAX_NUMBER_OF_DIFFERENCES} 208 | --compare "na01_to_002.nii.gz" 209 | "${BASELINE_DIR}/na01_RPI_to_002_RPI.nii.gz" 210 | --compare "na01_to_002_nn.nii.gz" 211 | "${BASELINE_DIR}/na01_RPI_to_002_RPI_nn.nii.gz" 212 | --intensity-tolerance 0.1 213 | --compare "jac_na01_to_002.nii.gz" 214 | "${BASELINE_DIR}/jac_na01_RPI_to_002_RPI.nii.gz" 215 | -- 216 | $ -v -v 217 | -g 0.4 218 | -k 4 219 | -n 6 220 | -z 2 221 | -t 15 222 | -S "${INPUT_DIR}/na01_ds_analyze.hdr" 223 | -T "${INPUT_DIR}/002_ds_analyze.hdr" 224 | -O na01_to_002.nii.gz 225 | -J jac_na01_to_002.nii.gz 226 | -W na01_to_002_nn.nii.gz 227 | -L "${INPUT_DIR}/na01_ds_analyze.hdr" 228 | -r 0 229 | ) 230 | 231 | 232 | basis_add_test( 233 | dramms_3dimagewith2slices 234 | COMMAND 235 | basis.testdriver 236 | --intensity-tolerance 3 237 | --max-number-of-differences 20 238 | --compare "cardiac_T05_to_T01.img" 239 | "${BASELINE_DIR}/cardiac_T05_to_T01.img" 240 | -- 241 | $ -v -v 242 | -S "${INPUT_DIR}/cardiacT05c.hdr" 243 | -T "${INPUT_DIR}/cardiacT01c.hdr" 244 | -O cardiac_T05_to_T01.hdr 245 | ) 246 | 247 | 248 | basis_set_tests_properties( 249 | dramms_default_noaffine 250 | dramms_default_affine 251 | dramms_warping 252 | dramms_jacobian 253 | dramms_ravens 254 | dramms_initdef 255 | dramms_brainregwarpjac 256 | dramms_3dimagewith2slices 257 | PROPERTIES 258 | LABELS dramms 259 | ) 260 | -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/H08c_to_H09c_default_affine.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/H08c_to_H09c_default_affine.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/H08c_to_H09c_default_noaffine.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/H08c_to_H09c_default_noaffine.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/H08c_to_H09c_with_initdef.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/H08c_to_H09c_with_initdef.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/cardiac_T05_to_T01.hdr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/cardiac_T05_to_T01.hdr -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/cardiac_T05_to_T01.img: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/cardiac_T05_to_T01.img -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/jac_H08c_to_H09c.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/jac_H08c_to_H09c.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/jac_na01_RPI_to_002_RPI.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/jac_na01_RPI_to_002_RPI.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/na01_RPI_to_002_RPI.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/na01_RPI_to_002_RPI.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/na01_RPI_to_002_RPI_nn.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/na01_RPI_to_002_RPI_nn.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/ravens_H08c_to_H09c_1.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/ravens_H08c_to_H09c_1.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/baseline/warped_H08c_to_H09c.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/baseline/warped_H08c_to_H09c.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/002_ds_analyze.hdr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/002_ds_analyze.hdr -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/002_ds_analyze.img: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/002_ds_analyze.img -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/H08c.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/H08c.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/H08c_tissueforravens.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/H08c_tissueforravens.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/H09c.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/H09c.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/cardiacT01c.hdr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/cardiacT01c.hdr -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/cardiacT01c.img: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/cardiacT01c.img -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/cardiacT05c.hdr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/cardiacT05c.hdr -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/cardiacT05c.img: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/cardiacT05c.img -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/def_H08c_to_H09c_noaffine.nii.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/def_H08c_to_H09c_noaffine.nii.gz -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/na01_ds_analyze.hdr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/na01_ds_analyze.hdr -------------------------------------------------------------------------------- /dramms-1.4.1-source/test/input/na01_ds_analyze.img: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.4.1-source/test/input/na01_ds_analyze.img -------------------------------------------------------------------------------- /dramms-1.5.1-source.tar.gz: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ouyangming/DRAMMS/2210a6f6435bbc1fca6f1697945ceca0649579b7/dramms-1.5.1-source.tar.gz --------------------------------------------------------------------------------