saalfeldlab / render

Render transformed image tiles
GNU General Public License v2.0
34 stars 32 forks source link

What shared transformation type to use for flatfield correction #114

Closed martinschorb closed 3 years ago

martinschorb commented 3 years ago

Hi,

I am trying to implement a flatfield correction using Render.

Would I need to specify the flatfield image as an array inside the JSON or can I provide a separate reference image somewhere on disk to be applied (multiply) to each tile? Also, does that array have to be full resolution, or can I provide a downscaled reference?

Thanks

trautmane commented 3 years ago

Hi Martin,

I assume you're looking for flatfield correction like this. Unfortunately, render does not currently support it. I think you would need to do the correction upstream of render and use the corrected images as the source images in render. Render does support multi-channel images and dynamic blending/rendering of multiple channels into a single image. Maybe you could abuse that functionality to achieve the same effect - but I don't know if that would really work.

martinschorb commented 3 years ago

OK, thanks.

I thought that in the TEMCA data, you would also sometimes suffer from uneven illumination. Or do you correct for this during acquisition and tune the EM on the fly?

trautmane commented 3 years ago

You are correct, we did have uneven illumination in the TEMCA data. This was addressed in 2 ways: (1) for point matching, we used a default filter that Saalfeld configured - this is what you see when using filter=true and (2) after alignment, we used Misha Kazhdan's DMG software to perform 2D intensity correction for each layer. Render also allows you to configure and name filters (or chains of filters) that can then be used during rendering. Let me know if you'd like more information about that.