bUnwarpJ registration

I am using two images for registration one is source and other is target. I could see the process is going on. How the images are converting from one form to other but not able to save the output. As soon as the execution bar ends, the output window vanish . I end up with Registered source image and Registered target image window. If I scoll on the register source image window, I am not able to see Wraped mask, deformation field, deformation grid.
Please advice.

Dear @Sonali, it would help if you can provide with more details about this problem. Namely:

  • Which version of bUnwarpJ are you using? Do you know if it is the latest one?
  • Are you working with ImageJ or Fiji?
  • Which operative system are you using?
  • Can you post the source and target images here so we can try to reproduce the error?


Dear Sonali,
In the case you go within the “Advanced Options” you have checkboxes where you can activate “Verbose” or “Save Transformtion”.
Also in the case you want to reapply a saved transformation to a picture, you need to input not only the transformation file, but as well a source and target picture (the last one been needed only to define the width and height of the transformed picture).
Thus in the case you are interrested, I developped a new version of the UnwarpJ plugin where only the transformation file and source picture are needed (the width and height of the transformed picture being input by parameters).
In the case you are interrested by this version, just drop me a mail.
My best regards,
Philippe CARL (philippe.carl@unistra.fr)

It is 2.6 Bunwrap plugin. I hope it is latest version of bUnwrap registration.I am working on Fiji. Operative system is window 7. I have Source STL file and taget is DICOM images. I was trying to upload the data but could not do it. Could you please advice me how can I do BUnwrap Registration for this two data files ?

STL is not an image format, you need to convert the file to a binary image. Have a look at this other conversation.

1 Like

I too have a question concerning bUnwarpJ registration.
I can follow the example and your video tutorial. However, I see that unwarping of your image of the Eifel tower in the example you already need to have a perfect picture of the tower. If you only have a camera with very distorting lens you will never have a reference image that you could use as absolute truth. Even if there was one official image or you would pick out a postcard that you would like to use as reference, it would never line up with your image.

What are strategies to work around this conundrum?
What is a good choice of reference image?

If you create a synthetic image first for example of a grid of points, a chess board or Escher’s birds and fish. Then print this pattern and image it with the distorting lens you would still have to be concerned with the quality of the print, the perfect positioning of the camera so that during the effort to correct the barrel or pincushion of the lens not additional distortions from perspective or uneven focus are introduced and end up in the transformation correction that would be applied to all future images with this lens and possibly make things even worse.

Please advise how your plugin could be used to solve this problem or please point me to other workflow that could.

Edit after posing the original question:
I now have found

I will have a closer look at the strategies described there.

I also see:

But if you are not working with a TEM but a regular camera it might be difficult to move the camera in an exact plane across a large high contrast planar object maintaining a perpendicular view.


This strategy looks very promising to me, but at this time I can not locate the EasyCalib.exe which seems to be required for the calculation and I do not see the way to apply the corrections that are calculated to a production image to yield an unwarped image for precise angle measurements.


Hello @stmfiji,

What you are pointing out is the basic problem of registration. If your moving image is more than just the target image (also called “fixed” image) distorted by a geometric transformation, you might never recover the original image in a perfect way. It’s something we have to live with, so we register by maximizing a given similarity metric (for instance mutual information or cross-correlation) to minimize the possible differences between our registered image and the ideal one.

Sometimes, we are not even interesting on recover the original image perfectly because we are registering slightly different images. For instance consecutive histological or TEM sections.

That being said, there are ways of leading your registration towards the ideal image by pre-processing the moving image (for example using histogram matching) or by using manual or automatic landmarks.