Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wip: trying out bbdt for 2D boolean case #42

Draft
wants to merge 24 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
fd65a38
wip: trying out bbdt for 2D boolean case
william-silversmith Sep 6, 2020
0c3297d
wip: can run bbdt but it segfaults
william-silversmith Sep 6, 2020
28c475d
fix: bbdt appears to be working though it needs tuning
william-silversmith Sep 7, 2020
ee232f4
wip: trying a more traditional approach
william-silversmith Sep 7, 2020
c61003f
perf: skip some checks given we know X is ok
william-silversmith Sep 7, 2020
ce6914b
wip: may have fixed issue with pieces not being unified
william-silversmith Sep 7, 2020
c5af4ff
perf: replace function calls with macros
william-silversmith Sep 30, 2020
021dda2
test: save test configuration
william-silversmith Sep 30, 2020
db36a72
fix: incorrect references
william-silversmith Oct 2, 2020
8f972b0
Merge branch 'master' into wms_bbdt
william-silversmith Oct 3, 2020
5852d79
perf: skip unification if unnecessary
william-silversmith Oct 3, 2020
aa0e7dd
fix+perf: errors in decision tree and unnecessary unifies
william-silversmith Oct 3, 2020
27e847e
perf: skip unnecessary check of B
william-silversmith Oct 3, 2020
8edf301
refactor: whitespace change
william-silversmith Oct 3, 2020
e2ce90a
wip: not working but closer in concept to the was bbdt should work
william-silversmith Dec 25, 2020
8f7915e
fix: several errors in bbdt implementation
william-silversmith Dec 25, 2020
089e851
fix: oA computed wrong
william-silversmith Dec 25, 2020
604602f
perf: faster relabel loop
william-silversmith Dec 26, 2020
1e73adb
fix: make comparison more robust
william-silversmith Dec 26, 2020
fcf6602
fix: make the comparison more robust in relabel
william-silversmith Dec 26, 2020
80b9a9e
fix: loc was not computed correctly for odd sizes
william-silversmith Dec 26, 2020
47ac1ca
fix: missing join of A
william-silversmith Dec 26, 2020
0df79d7
perf: faster relabel loop
william-silversmith Dec 26, 2020
fb35532
fix: np.bool doesn't work anymore
william-silversmith Jul 19, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ shared:
g++ -fPIC -shared -std=c++11 -O3 cc3d.hpp -ffast-math -o cc3d.so

test: FORCE
g++ -pg -std=c++11 -g -O3 test.cpp -ffast-math -o test
g++ -std=c++11 -g -O3 test.cpp -ffast-math -o test

FORCE:
8 changes: 4 additions & 4 deletions automated_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -416,7 +416,7 @@ def test_compare_scipy_26(out_dtype):
import scipy.ndimage.measurements

sx, sy, sz = 128, 128, 128
labels = np.random.randint(0,2, (sx,sy,sz), dtype=np.bool)
labels = np.random.randint(0,2, (sx,sy,sz), dtype=bool)

structure = [
[[1,1,1], [1,1,1], [1,1,1]],
Expand All @@ -436,7 +436,7 @@ def test_compare_scipy_18():
import scipy.ndimage.measurements

sx, sy, sz = 256, 256, 256
labels = np.random.randint(0,2, (sx,sy,sz), dtype=np.bool)
labels = np.random.randint(0,2, (sx,sy,sz), dtype=bool)

structure = [
[[0,1,0], [1,1,1], [0,1,0]],
Expand All @@ -457,7 +457,7 @@ def test_compare_scipy_6():
import scipy.ndimage.measurements

sx, sy, sz = 256, 256, 256
labels = np.random.randint(0,2, (sx,sy,sz), dtype=np.bool)
labels = np.random.randint(0,2, (sx,sy,sz), dtype=bool)

cc3d_labels = cc3d.connected_components(labels, connectivity=6)
scipy_labels, wow = scipy.ndimage.measurements.label(labels)
Expand Down Expand Up @@ -574,7 +574,7 @@ def test_region_graph_6():
])

def test_stress_upper_bound_for_binary():
labels = np.zeros((256,256,256), dtype=np.bool)
labels = np.zeros((256,256,256), dtype=bool)
for z in range(256):
for y in range(256):
off = (y + (z % 2)) % 2
Expand Down
Loading