View source: R/randomImageTransformAugmentation.R
randomImageTransformAugmentation | R Documentation |
The function will apply rigid, affine or deformable maps to an input set of training images. The reference image domain defines the space in which this happens.
randomImageTransformAugmentation(
imageDomain,
predictorImageList,
outcomeImageList,
n = 8,
typeOfTransform = "Affine",
interpolator = c("linear", "nearestNeighbor"),
sdAffine = 1,
nControlPoints = 100,
spatialSmoothing = 3,
composeToField = FALSE,
numberOfCompositions = 4,
deformationBasis,
directoryName,
imageDomainY,
normalization = "none"
)
imageDomain |
defines default spatial domain for images. NOTE: if the
input images do not match the spatial domain of the domain image, we
internally resample the target to the domain. This may have unexpected
consequences if you are not aware of this. This operation will test
|
predictorImageList |
list of lists of image predictors |
outcomeImageList |
optional list of image outcomes |
n |
number of simulations to run |
typeOfTransform |
one of the following options
|
interpolator |
nearestNeighbor or linear (string) for predictor and outcome images respectively |
sdAffine |
roughly controls deviation from identity matrix |
nControlPoints |
number of control points for simulated deformation |
spatialSmoothing |
spatial smoothing for simulated deformation |
composeToField |
defaults to FALSE, will return deformation fields otherwise i.e. maps any transformation to a single deformation field. |
numberOfCompositions |
integer greater than or equal to one |
deformationBasis |
list containing deformationBasis set |
directoryName |
where to write to disk (optional) |
imageDomainY |
optional spatial domain for outcome images. |
normalization |
optional intensity normalization either none, standardize or 01. |
list (if no directory set) or boolean for success, failure
Avants BB
randomImageTransformBatchGenerator
library( ANTsR )
i1 = antsImageRead( getANTsRData( "r16" ) )
i2 = antsImageRead( getANTsRData( "r64" ) )
s1 = thresholdImage( i1, "Otsu", 3 )
s2 = thresholdImage( i2, "Otsu", 3 )
rand = randomImageTransformAugmentation( i1,
list( list(i1), list(i2) ), list( s1, s2 ) )
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.