Closed durbank closed 4 years ago
With the changes introduced in da43586, we now have a function for integrated brightness along individual streamlines (stream_sum
). We can use this function to determine peaks in integrated brightness and group trace peaks into layer segments in descending order of integrated brightness. This means we pick the brightest, longest layers first for tracing, and work down the list from there.
PR #35 closes this issue.
In v1.1 and prior, the layer tracing picks where to start the first layer (and then subsequent layers) based on the brightest individual peak without a layer group. It would be better to base this selection off of integrated streamline brightnesses using the layer gradient field. We could convolve a Gaussian filter with the streamlines at regular depth intervals (every 4 cm? every 10 cm?) to create a smoothed potential layer. We then sum up the brightness values for each streamline and pick the brightest remaining pixel in that streamline (or perhaps simply the midpoint of the streamline?) as the starting point of the next layer grouping.
We could write a subroutine that would calculate integrated brightnesses for each streamline based on the remaining ungrouped peaks. The subroutine would then run within the loop of
radar_trace
prior to the start of each successive layer.