This is a static copy of a profile reportHome
imresize>fixupSize (82820 calls, 5.287 sec)
Generated 05-Nov-2014 07:53:36 using cpu time.
subfunction in file /usr1/opt/matlab/7.13/toolbox/images/images/imresize.m
Copy to new window for comparing multiple runs
Parents (calling functions)
Lines where the most time was spent
Line Number | Code | Calls | Total Time | % Time | Time Plot |
688 | if all(isnan(output_size)) | 82820 | 0.871 s | 16.5% |  |
703 | end | 82820 | 0.521 s | 9.8% |  |
702 | output_size = ceil(output_size... | 82820 | 0.461 s | 8.7% |  |
684 | if ~all(output_size) | 82820 | 0.451 s | 8.5% |  |
683 | if ~isempty(output_size) | 82820 | 0.411 s | 7.8% |  |
All other lines | | | 2.574 s | 48.7% |  |
Totals | | | 5.287 s | 100% | |
Children (called functions)
No childrenCode Analyzer results
Coverage results
[ Show coverage for parent directory ]
Total lines in function | 28 |
Non-code lines (comments, blank lines) | 10 |
Code lines (lines that can run) | 18 |
Code lines that did run | 9 |
Code lines that did not run | 9 |
Coverage (did run/can run) | 50.00 % |
Function listing
time calls line
676 function [output_size, size_dim] = fixupSize(params)
677 % If params.output_size has a NaN in it, calculate the appropriate
678 % value to substitute for the NaN.
679
0.31 82820 680 output_size = params.output_size;
0.33 82820 681 size_dim = [];
682
0.41 82820 683 if ~isempty(output_size)
0.45 82820 684 if ~all(output_size)
685 error(message('images:imresize:zeroOutputSize'));
686 end
687
0.87 82820 688 if all(isnan(output_size))
689 error(message('images:imresize:allNaN'));
690 end
691
0.38 82820 692 if isnan(output_size(1))
693 output_size(1) = params.output_size(2) * size(params.A, 1) / size(params.A, 2);
694 size_dim = 2;
695
0.28 82820 696 elseif isnan(output_size(2))
697 output_size(2) = params.output_size(1) * size(params.A, 2) / size(params.A, 1);
698 size_dim = 1;
699
700 end
701
0.46 82820 702 output_size = ceil(output_size);
0.52 82820 703 end
Other subfunctions in this file are not included in this listing.