Skull shapes gone wrong

71 views
Skip to first unread message

Christopher Wastell

unread,
Aug 16, 2020, 5:01:26 PM8/16/20
to scalismo
Hi,

bringing skull shapes in correspondence, the registration step outputs some deformities as in:
and when projecting the registerred shape to the original shape using the closestPointOnSurface projection, fitted shape is pretty corrupted, as:


I'm wondering about the issue and steps to take to get the better registration and fitting for this.

Regards,
Chris

Marcel Luethi

unread,
Aug 17, 2020, 2:52:12 AM8/17/20
to Christopher Wastell, scalismo
Hi Christopher,

Skull shapes are pretty complex and the fitting can easily go wrong.
When we register skull shapes, we usually assist in the process with a little bit of manual intervention to make sure we have a good starting point. For that we click a few landmark, do a rigid alignment and then also use the same landmarks to compute a posterior model. Using the posterior model makes sure that we start with roughly the right size, and that the landmark points are already in good correspondence. This makes the problem much easier.

Best regards,

Marcel

--
You received this message because you are subscribed to the Google Groups "scalismo" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scalismo+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/scalismo/09b2f219-3a88-4f1a-ab8c-2e3f55fed905o%40googlegroups.com.

wastell.c...@gmail.com

unread,
Aug 17, 2020, 12:20:11 PM8/17/20
to scalismo
This is so interesting.
I've seen this in "posterior shape model" documents in ScalismoLab tutorials, let me ask a question to make it clear for myself: so in that tutorial we're using a few correspondences to create the posterior model out of a previously made model (prior). but in the registration step we haven't yet learned a model out of data, and we're just using a model created with analytical mean and kernel:
val kernel = DiagonalKernel[_3D](GaussianKernel(sigma = s) * l, outputDim = 3)

so, Is this like, we'll use this analytical model for creating a posterior shape model?

Regards,
Chris

Andreas Morel-Forster

unread,
Aug 18, 2020, 2:31:34 AM8/18/20
to scal...@googlegroups.com

Hi Chris,

Yes, exactly. In the mathematical GP setting, the prior and posterior have the exact same form, they are just Gaussian processes. But of course they have different statistics/meaning. Also it does not matter if you build your model from data or if you specify your model by an analytical mean and covariance/kernel.

This equivalence of the models is also reflected in the scalismo framework's software. They are represented by the same class. Where ever you use a model estimated from data, you could also use an analytical model.

Best, Andreas

wastell.c...@gmail.com

unread,
Aug 19, 2020, 7:19:37 AM8/19/20
to scalismo
interesting,
so for the registration part, I'm doing like this for every shape: gets error (cannot resolve overloaded method 'NDimensionalNormalDistribution' and 'posterior' although these are working in scalismolab):

//Building a Gaussian process shape model
val mean = VectorField(RealSpace[_3D], (_: Point[_3D]) => EuclideanVector.zeros[_3D])


val kernel = DiagonalKernel[_3D](GaussianKernel(sigma = s) * l, outputDim = 3)

val gp = GaussianProcess(mean, kernel)

//building posterior shape model
val refPts = refLms.map{lm => lm.point}
val tarPts = targetLms.map{lm => lm.point}
val observations = (refPts zip tarPts).map{case(rPt, tPt) => tPt - rPt}

val littleNoise = NDimensionalNormalDistribution(Vector(0,0,0), SquareMatrix((0.5f,0,0), (0,0.5f,0), (0,0,0.5f)))
val trainingData = IndexedSeq((refPts, observations, littleNoise))

val posterior : LowRankGaussianProcess[_3D, _3D] = gp.posterior(trainingData)

val lowRankGP = LowRankGaussianProcess.approximateGPCholesky(
  refMesh.pointSet,
  posterior,
  relativeTolerance = 0.05,
  interpolator = NearestNeighborInterpolator()
)


is there any advice?

Regards,
Chris

Marcel Luethi

unread,
Aug 19, 2020, 10:48:31 AM8/19/20
to wastell.c...@gmail.com, scalismo
Hi Chris

ScalismoLab uses a rather old version of Scalismo. Unfortunately we cannot change it to a new version, as otherwise we would need to redo all the videos on FutureLearn.
Anyway, for serious work it is much better to use an IDE. To make the transition easier, we have put to each tutorial in ScalismoLab a corresponding one on scalismo.org. In particular you can find a tutorial that explains how to compute a posterior model:

Best regards,

Marcel

Reply all
Reply to author
Forward
0 new messages