JaneliaSciComp / bigstream

Tools for distributed alignment of massive images
BSD 3-Clause "New" or "Revised" License
75 stars 21 forks source link

Feature request: exceptions when alignment fails #43

Open krokicki opened 6 months ago

krokicki commented 6 months ago

When insufficient moving spots are found, currently the issue is logged and the identity matrix is returned. It would be nice to throw an exception in this and other exceptional cases.

GFleishman commented 6 months ago

Hi @krokicki and @cgoina!

I have added this feature to the master branch. There are three relevant commits. Here I update the docstring to describe the new functionality: https://github.com/JaneliaSciComp/bigstream/commit/6afdb8b9daaa5e610aa2785059ac032c859f7277 Here I update the code so that failed safeguards now raise a ValueError: https://github.com/JaneliaSciComp/bigstream/commit/0930479a07f04958462b8cf0861f69b834100bf7 Here I make sure that this behavior is turned off in the distributed context (where we want warnings and defaults instead of exceptions): https://github.com/JaneliaSciComp/bigstream/commit/d81ad7b67541d607c7680d18ae0a63832c895347

I'll wait a bit before closing the thread in case either of you want to look at the update or comment?