brianlee324 / torch-lddmm

GPU and CPU implementation of LDDMM image registration
56 stars 16 forks source link

apply warpping map #4

Closed figo2150 closed 2 years ago

figo2150 commented 2 years ago

Suppose the template has a corresponding label map (atlas), and our goal is to obtain the label map for the target image. How to apply the warpping map (or resultant displacement field) to the template label map after lddmm registration?

figo2150 commented 2 years ago

I think I just found the answer.. (deformedlabel,,,) = lddmm.applyThisTransform(template_label, interpmode='nearest') deformed_label = deformed_label[-1].cpu().numpy()