mirror of
https://github.com/wassname/scikit-image.git
synced 2026-07-12 11:59:31 +08:00
Merge pull request #1171 from jjhelmus/unwrap_phase_3d_bug
BUG: segmentation fault when unwrapping 3d image
This commit is contained in:
@@ -144,5 +144,12 @@ def test_invalid_input():
|
||||
assert_raises(ValueError, unwrap_phase, np.zeros((1, 1)), 'False')
|
||||
|
||||
|
||||
def test_unwrap_3d_middle_wrap_around():
|
||||
# Segmentation fault in 3D unwrap phase with middle dimension connected
|
||||
# GitHub issue #1171
|
||||
image = np.zeros((20, 30, 40), dtype=np.float32)
|
||||
unwrap = unwrap_phase(image, wrap_around=[False, True, False])
|
||||
assert np.all(unwrap == 0)
|
||||
|
||||
if __name__ == "__main__":
|
||||
run_module_suite()
|
||||
|
||||
@@ -786,7 +786,7 @@ void verticalEDGEs(VOXELM *voxel, EDGE *edge, int volume_width, int volume_heig
|
||||
}
|
||||
voxel_pointer++;
|
||||
}
|
||||
voxel_pointer += next_voxel + 1;
|
||||
voxel_pointer += next_voxel;
|
||||
}
|
||||
}
|
||||
params->no_of_edges = no_of_edges;
|
||||
|
||||
Reference in New Issue
Block a user