What you save in scan time you will spend on stitching the images on a slow raspberry pi processor. Furthermore, I could not find a software solution that can stitch an asymmetrical grid.
I agree that long term being able to intelligently skip blank areas would be nice, Iāve done some work tiling non-rectangular scans but itās a way away from being released.
For now @dgrosen, using the frequency of colours within a field of view Iāve got a basic background detect working that will only autofocus if thereās more than a thin slice of sample within the FOV. Is the animation below the sort of thing youāre hoping for?
YES. This is amazing.
Hi,
Just an idea, some microscopes can image whole samples in a spiral going outward (instead of serpentine). I donāt know if this is possible here but it has the benefit of starting in the sample, where the autofocus might work, rather than outside.
Great, itās a bit fiddly to set up, but should work for your samples. Could you send me some images of FOVs (ideally from the OFM) of a sample and background youād like to automatically scan please? The focus isnāt important
Gladly. I will upload a few examples and share the link later today. Thanks.
@pristinscope The newest version of the software now has the option of a spiral scan.
(developed by @JohemianKnapsody)
Hi @JohemianKnapsody. I have the files ready but they are quite large to post here. I would like to share a link to my one drive folder with the files. can you please send me your email to dgrosen@bcm.edu? thanks
Amazing!!! What kind of witchcraft are you doing with the code?!
It will be hard to stitch a spiral pattern, However, I think that predefining the image positions in a file on the grid collection stitching plugin in ImageJ can work.
Thanks for the images @dgrosen. Iām not sure if youāre happy for me to post previews of them here to show what Iām doing?
Just to confirm, all features in the images are considered the sample and can be focused on, except the very empty images (64, 69-72, 85-93, for example)?
Hereās a preview of how my tiling code copes with āspiralā scans, updating after each new image. Clearly itās not a true spiral, more a concentric series of rectangles. Main things that need adding are a nicer way to smooth between the edges of images, and a final step once all images are taken to see if thereās any small adjustments that would improve the overall tiling. Iāll see how ImageJ gets on with this style of scan too
Yes, you can post them here to share with the OF community. Let me know if you need more examples. Thanks
I tried the snake scan and works fantastic! Is really and innovative solution Iāve never seen on any scanner. The problem is 1) finding a way to stitch the images reliably and 2) focusing. I did a quick manual mosaic on ImageJ on this 2x2 grid
The rendering looks good.
I was not that successful using a 3x3 spiral grid.
This is amazing progress!!!
@dgrosen Iām curious about that last stitch - it looks like thereās a lot of rotation as well as translation. Has something funky happened to your stage?
Yes, it came out funny. No problem with the microscope at all. I dont have a programmatic way of stitching so I did it manually wit MosaicJ. The MosaicJ plugin in ImageJ has a funny way of stitching things. I think it was trying to stitch the white background images the best it could and came out that way.
Iāve had the same problem with ImageJ, even without the issues focusing it has no way to tile the empty background. Work on your sample seems pretty positive - thereāll be a calibration step, then you can set a percent of the FOV that needs to be sample (or ānot-backgroundā) for the autofocus procedure to be run.
@r.w.bowman, I think weāll need to store the z position of every image, then when returning to the top of a raster column, use the previous columnās top image z. Snake scans are working without this, but raster is too unreliable.
@JohemianKnapsody I thought raster scan did this already - but we should probably dive into the code and think about how to handle it more nicely. Of course, you can also pull it out of the captures database, but thatās possibly going the long way round!
Sorry Richard, I meant it should then be able to perform that check at any point in the column. So in the image below, if it doesnāt autofocus at the top of column 4, then the second cell down should look at the height to the left instead of copying the height from above
Ah, I see - I guess we probably want to be fairly general in that case, just keep a list of XYZ coordinates that were deemed to be in focus, and then use whichever XY point is closest as a starting estimate. Might be worth storing XYZt, so you can tie-break by figuring out which was most recent as well. That has the nice property that if the last point worked, youāll use the last point by default (though there will be a little bit of thought required to make sure the threshold for using time vs using XY is sensible).
Doing that on a sample with a lot of background, this is the 10x10 scan I got
Itās only focused on the areas with sample, and not lost focus elsewhere. Iāll make sure itās as readable as possible, then work out how to share it with @dgrosen if youāre both happy with it