mcfaddendavid / betalight-calibration

A tool for calibrating cameras using a gaseous tritium light source (betalight)
3 stars 1 forks source link

Source for binaries? #1

Open beniroquai opened 2 years ago

beniroquai commented 2 years ago

Hey! Great project! Is it possible to share the example file that processes the two image stacks you showed in the executable? Perhaps it's worth bringing it to the web using Imjoy.io. Happy to help! :-)

mcfaddendavid commented 2 years ago

Glad you like it :-)

Do you mean the tool and examples available at https://cloud.uni-jena.de/s/Br9ygp92nfTWkgN?path=%2Fgui-calibration-tool ? The example image stacks are in the examples.zip file. You will also find the source for the tool there. I will probably add it to the NanoImagingPack repository eventually, to have it in one place.

A web app sounds great, anything that encourages people to use it. I mainly want to avoid people needing to install anything so that they can use it straight away. Do you have any quick examples for some simple image processing with Imjoy.io?

beniroquai commented 2 years ago

Ah, thanks! Would you mind adding the code to the repo as well? :)

I would like to translate it to the browser-based version to convince people to use it. I think to really simplify it, it would make sense to isolatethe calibration function from the nanoimagingpack. Did you ever try that? If we can restrict to let it run using native python packages (e.g. numpy, scipy) it can run entirely in the web-python framework.

Thanks!

beniroquai commented 2 years ago

Hey, I was able to convert the code to pure python to get it run in the browser: cal_readnoise_pure_python.ipynb.txt You can test it here => Pyolite.

This can now be converted to the ImJoy Plugin. So no installation is necessary, everything runs locally.

What do you think?

mcfaddendavid commented 2 years ago

I think it looks great. It would certainly be convenient to distribute the function without installing NanoImagingPack. Some thoughts on the Jupyter lite solution:

If we can iron out those problems I'd love to make an example notebook. I think I'll still provide the GUI tool for now, as it still seems to be a bit easier for people who aren't familiar with Jupyter and it also doesn't require an internet connection.

Ideally, I would like to use bio-formats for reading images, which will probably be a bit more difficult to get running on people's computers. Do you know if that has been successfully used with imjoy yet?

beniroquai commented 2 years ago

Hm, good question. I actually don't quite know if you really need to upload anything. I thought no since everything runs in your browser. There is no server-space where you would upload your data actually.. Python lite runs entirely on your machine but with remote python bindings. Perhaps a bit like javascript.

Here is the "GUI": https://github.com/openUC2/UC2-ImJoy-Plugins/blob/master/repository/WindowPlugin.imjoy.html and here is the "worker file": https://github.com/openUC2/UC2-ImJoy-Plugins/blob/master/repository/UC2_tools_calreadnoise.imjoy.html.

We should make it work. You can simply share the link and the code will automatically work in the browser. What do you think?