seung-lab / connected-components-3d

Connected components on discrete and continuous multilabel 3D & 2D images. Handles 26, 18, and 6 connected variants; periodic boundaries (4, 8, & 6)
GNU Lesser General Public License v3.0
367 stars 43 forks source link

perf: improved 6-connected decision tree #49

Closed william-silversmith closed 4 years ago

william-silversmith commented 4 years ago

We weren't taking advantage of the possibility of transmitting connectivity through the -Z label to the -Y label. This has to be done such that -Z is treated first if -X-Y doesn't match otherwise it generates extra work.

william-silversmith commented 4 years ago

New DT connectomics labels: 1.24 sec, 107.94 MVx/sec random labels: 2.51 sec, 53.46 MVx/sec

Old DT: connectomics labels: 1.18 sec, 112.30 MVx/sec

It turns out the enhanced DT is not actually better. :(