sp.similarity.from.mesh | R Documentation |
The sp.similarity.from.mesh
function computes Hausdorff
distances and surface Dice similarity coefficient.
sp.similarity.from.mesh(
mesh1,
mesh2,
hausdorff.coeff = c("HD.max", "HD.mean"),
hausdorff.quantile = c(0.5, 0.95),
surface.tol = seq(0, 10, 1)
)
mesh1 , mesh2 |
espadon mesh class objects |
hausdorff.coeff |
Vector indicating the requested Hausdorff distance metrics from among
'HD.max','HD.mean'. Equal to |
hausdorff.quantile |
numeric vector of probabilities with values between 0 and 1,
representing the quantiles of the unsigned distances between |
surface.tol |
numeric vector representing the maximum margins of
deviation which may be tolerated without penalty. Equal to |
Returns a list containing (if requested):
Hausdorff
: dataframe including the maximum, mean and quantiles
smetrics
: dataframe with the columns:
tol
: the requested tolerances
sDSC
: the surface Dice similarity coefficients,defined by
Nikolov et al [1]
sAPL
: the surface Added Path Length in \mjeqnmm^2ascii,
introduced (in pixels) by Vaassen et al [2]
[1] \insertRefNikolov2018DeepLTespadon
[2] \insertRefVaassen2020Evalespadon
sp.similarity.from.bin
library (Rvcg)
# espadon mesh of two spheres of radius R1=10 and R2=11, separated by dR = 3
sph <- vcgSphere ()
mesh1 <- obj.create ("mesh")
mesh1$nb.faces <- ncol (sph$it)
mesh1$mesh <- sph
mesh2 <- mesh1
R1 <- 10
R2 <- 11
dR <- 3
mesh1$mesh$vb[1:3,] <- R1 * mesh1$mesh$normals[1:3,] + mesh1$mesh$vb[1:3,]
mesh2$mesh$vb[1:3,] <- R2 * mesh2$mesh$normals[1:3,] + mesh2$mesh$vb[1:3,] +
matrix (c (dR, 0, 0), ncol = ncol (mesh2$mesh$vb), nrow = 3)
sp.similarity.from.mesh (mesh1 , mesh2,
hausdorff.quantile = seq (0, 1, 0.05),
surface.tol = seq (0, dR + abs(R2-R1), 0.5))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.