MEASURE_MODEL_MSD: Measure the reference against a set of images using mean-squared-differences and return mean. Code written by Katherine Smith, 2003 GENERAL score = measure_model_msd(warped_images) INPUT/S -warped_images: A set of images (similar to the model). OUTPUT/S -score: Mean-squared difference score. PENDING WORK - KNOWN BUG/S -None. COMMENT/S -The name is misleading because models are not involved. Consider renaming. RELATED FUNCTION/S MSD, EVAL_MSD ABOUT -Created: November 23rd, 2003 -Last update: February 18th, 2004 -Revision: 0.0.9 -Author: R. S. Schestowitz, University of Manchester ==============================================================
0001 function score = measure_model_msd(warped_images) 0002 % MEASURE_MODEL_MSD: Measure the reference against a set of images using 0003 % mean-squared-differences and return mean. 0004 % 0005 % Code written by Katherine Smith, 2003 0006 % 0007 % GENERAL 0008 % 0009 % score = measure_model_msd(warped_images) 0010 % 0011 % INPUT/S 0012 % 0013 % -warped_images: 0014 % A set of images (similar to the model). 0015 % 0016 % OUTPUT/S 0017 % 0018 % -score: 0019 % Mean-squared difference score. 0020 % 0021 % PENDING WORK 0022 % 0023 % - 0024 % 0025 % KNOWN BUG/S 0026 % 0027 % -None. 0028 % 0029 % COMMENT/S 0030 % 0031 % -The name is misleading because models are not involved. Consider 0032 % renaming. 0033 % 0034 % RELATED FUNCTION/S 0035 % 0036 % MSD, EVAL_MSD 0037 % 0038 % ABOUT 0039 % 0040 % -Created: November 23rd, 2003 0041 % -Last update: February 18th, 2004 0042 % -Revision: 0.0.9 0043 % -Author: R. S. Schestowitz, University of Manchester 0044 % ============================================================== 0045 0046 n_images = size(warped_images,2); 0047 % get number of images 0048 ref_image = warped_images(:,1); 0049 % set reference image 0050 for i=1:n_images 0051 score(i) = msd(ref_image, warped_images(:,i)); 0052 % record the squared mean difference of all images against the reference 0053 end 0054 score = mean(score); 0055 % get the mean score