-
Notifications
You must be signed in to change notification settings - Fork 0
19th Dec 2023: Improving robustness of well segmentation
In our last meeting we noted a potential flaw in the well segmentation algorithm, where a single well on an otherwise blank row or column would be ignored. I've made some changes to the well segmentation algorithm to address this.
The new function is called def _filter_spurious_peaks(peaks: list, threshold=0.2) -> tuple[list, float]:
in the codebase.
I've also adjusted the default values of the LoG and peak finder functions.
Here are a couple of examples of the effect of changing the threshold parameter of the LoG algorithm. This finds candidate well centres, which is the basis for the automatic grid detection.
Question from Adrien:
With these segmentation algorithms, are we able to clearly attribute a label to each well that contains cells for us to put a name on each well correctly?
I've added a unit test using real data to test the single-well case:
Input image:
After projecting the peaks to the vertical axis, you get a histogram like this:
I found that the following parameters are robust to a few spurious well detections, and still find the correct 16x24 grid on this test case and all other plates so far
peak_finder_kwargs={"peak_prominence": 1/25, "filter_threshold": 0.2}, blob_log_kwargs={"threshold": 0.12},