Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
fslpy
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Analyze
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
FSL
fslpy
Commits
ac0ba15a
There was a problem fetching the pipeline summary.
Commit
ac0ba15a
authored
7 years ago
by
Paul McCarthy
Browse files
Options
Downloads
Patches
Plain Diff
bugfix to test
parent
5f11f96f
No related branches found
No related tags found
No related merge requests found
Pipeline
#
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
tests/test_image.py
+15
-9
15 additions, 9 deletions
tests/test_image.py
with
15 additions
and
9 deletions
tests/test_image.py
+
15
−
9
View file @
ac0ba15a
...
...
@@ -750,9 +750,14 @@ def _test_Image_changeData(imgtype):
newdmin
=
dmin
-
100
newdmax
=
dmax
+
100
# random value below the data range
minx
,
miny
,
minz
=
randvox
()
img
[
minx
,
miny
,
minz
]
=
newdmin
# random value below the data range,
# making sure not to overwrite the
# max
while
True
:
minx
,
miny
,
minz
=
randvox
()
if
not
np
.
isclose
(
img
[
minx
,
miny
,
minz
],
dmax
):
img
[
minx
,
miny
,
minz
]
=
newdmin
break
assert
notified
.
get
(
'
data
'
,
False
)
assert
notified
.
get
(
'
dataRange
'
,
False
)
...
...
@@ -762,13 +767,14 @@ def _test_Image_changeData(imgtype):
notified
.
pop
(
'
data
'
)
notified
.
pop
(
'
dataRange
'
)
# random value above the data range
maxx
,
maxy
,
maxz
=
randvox
()
while
(
maxx
,
maxy
,
maxz
)
==
(
minx
,
miny
,
minz
)
:
# random value above the data range
,
# making sure not to overwrite the
# min
while
True
:
maxx
,
maxy
,
maxz
=
randvox
()
img
[
maxx
,
maxy
,
maxz
]
=
newdmax
if
not
np
.
isclose
(
img
[
maxx
,
maxy
,
maxz
],
newdmin
):
img
[
maxx
,
maxy
,
maxz
]
=
newdmax
break
assert
notified
.
get
(
'
data
'
,
False
)
assert
notified
.
get
(
'
dataRange
'
,
False
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment