This library is written by Bradley Treeby, University College London. Contact: [email protected]
This repository provides the MATLAB functions and scripts used for comparing model results for the benchmarks outlined here.
- Download the intercomparison data files from Zenodo and unzip.
- Clone or download this code repository.
- Open MATLAB, and navigate to the code repository folder.
- Run
processAll
to generate the paper figures and supplementary materials (this may take some time, particularly to runcomputeAllMetrics
). - Run
compareTwo
to compare two models for a specified benchmark and source. For example, to compareKWAVE
andSTRIDE
for benchmark 7 for the bowl source, run:
metrics = compareTwo('KWAVE', 'STRIDE', 7, 1, 'C:\DATA', true);
This repository also hosts the .stl
files for the skull models used for benchmarks 7 to 9, along with the affine transforms to position the transducer in the coordinate system of the .stl
file. To rasterize the .stl
files to a regular Cartesian mesh with a paricular grid resolution, use rasterizeSkullMeshes
. This function requires the iso2mesh toolbox. Note, for higher-resolution grids, this function requires significant computer memory. Pre-computed meshes are available in the SKULL-MAPS
folder in the data repository stored in Zenodo (see above). Note, the rasterized meshes already incorporate the affine transforms to move the skull relative to the transducer.
To add new model results:
- Decide on a name for the model, e.g.,
NEWMODEL
and add this to the listintercomparison/getModelNames
. - Create a
NEWMODEL
folder in the downloaded results (see above). Add the model results to this folder following the naming convention, e.g.,PH1-BM1-SC1-NEWMODEL.mat
. - To compare results for one benchmark, call
compareTwo
as outlined above. - To re-generate the intercomparison results with the new model, run
processAll
.
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License along with this program. If not, see https://www.gnu.org/licenses/.