hatzakislab / DeepFRET-GUI

GNU General Public License v3.0
9 stars 5 forks source link

Detection of "dual cam" setup only works specifically for Hatzakis lab #14

Closed simonbonano closed 4 years ago

simonbonano commented 4 years ago

When loading a movie, DeepFRET detects whether the format is "dual cam" or "quad view". The function is_interleaved_dual_cam in container.py reads the meta data of the loaded tif file to detect whether the format is dual cam or not, however the function only works on specific formats from Hatzakis lab. When loading "dual cam" movies from other labs, DeepFRET incorrectly detects them as "quad view" which makes analysis impossible.

Right now, the only viable option for other labs is to load data in the "quad view" format. The easiest solution to this issue would be to request a user-input to specify the format of the loaded tif (eg. as a check box in the preferences window).

komodovaran commented 4 years ago

You mean because their dual cam videos are not interleaved, but a left/right merge?

simonbonano commented 4 years ago

No. I have simulated an interleaved tif file (for testing purposes) in the "correct" dual cam format. However, the file is not recognised as dual cam format due to the way is_interleaved_dual_cam works. I made a quick fix in the code, but did not commit since it was not a viable solution.

I think the best would be to let the user decide which format he/she wants to load, since both dual cam and quad view can be quadratic (width = height) and they can be hard to distinguish.

You can download the simulated tif file here: https://drive.google.com/file/d/1dLNyNTrM1K2L4pKwPpRmVu9b8tJgZOfm/view?usp=sharing

The order goes DA->AA->DD->AA. I now it should AD instead of AA in the last frame, but I didn't bother to simulate this channel, since DeepFRET is the only software that requires this channel, and it is not being used (I made the script for comparison of existing smFRET data analysis software).

simonbonano commented 4 years ago

However, it would also be nice to have an option for left/right merge. In general it is a hazzle to load tif files into DeepFRET compared to other software (SPARTAN and iSMS). Also, DeepFRET does not accept non-ALEX tif files (it only accepts non-ALEX traces).

komodovaran commented 4 years ago

Can you provide image examples of everything you need, like in the README - Supported data formats? Then I will try to make time to add some switches. I haven't had time to look at it.

komodovaran commented 4 years ago

Should be fixed in #18. Re-open if buggy.