Skip to content

Commit

Permalink
test(negative_controls): Added pixel check for centre of ROI, updated…
Browse files Browse the repository at this point in the history
… failed assertion message for randomSeed pixel checks
  • Loading branch information
strixy16 committed May 14, 2024
1 parent 52dda33 commit ed3bb17
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/test_negative_controls.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,9 +66,11 @@ def test_shuffleImage(nsclcCTImage, randomSeed):
np.sort(shuffled_pixels.flatten())), \
"Shuffled image has different pixel values than original image. Should just be original pixels rearranged."
assert shuffled_pixels[0,0,0] == -987, \
"Random seed is not working for shuffled image. Random seed should be 10."
"Random seed is not working for shuffled image, first voxel has wrong shuffled value. Random seed should be 10."
assert shuffled_pixels[-1,-1,-1] == 10, \
"Random seed is not working for shuffled image. Random seed should be 10."
"Random seed is not working for shuffled image, last voxel has wrong shuffled value. Random seed should be 10."
assert shuffled_pixels[238,252,124] == -118, \
"Random seed is not working for shuffled image, central ROI voxel has wrong shuffled value. Random seed should be 10."


def test_makeRandomImage(nsclcCTImage, randomSeed):
Expand Down

0 comments on commit ed3bb17

Please sign in to comment.