You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Aditya P. Apte edited this page Mar 22, 2018
·
1 revision
Following example demonstrate accessing scan matrix and binary segmentation mask for a structure stored within CERR's planC:
The planC object can be loaded from a .mat file or by using the global variable global planC if the file is loaded in CERR viewer. Now let's define the indices of the desired scan and structure.
% Define the structure index
structNum = 1;
% Define the scan index
scanNum = 1;
Now, let's use the utility functions in CERR to access scan and label matrices.
% Get the binary label mask
[rasterSegments, planC, isError] = getRasterSegments(structNum,planC);
[mask3M, uniqueSlices] = rasterToMask(rasterSegments, scanNum, planC);
% Get the scan matrix
scan3M = getScanArray(planC{indexS.scan}(scanNum));
scan3M = double(scan3M) - ...
planC{indexS.scan}(scanNum).scanInfo(1).CTOffset;
The scan3M and mask3M` hold the scan and label maps respectively.