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
7d4a6c56
Commit
7d4a6c56
authored
8 years ago
by
Paul McCarthy
Browse files
Options
Downloads
Patches
Plain Diff
Expansion range takes into account all previous dimensions. That makes
no sense, I know.
parent
27df5ee5
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
fsl/data/imagewrapper.py
+11
-4
11 additions, 4 deletions
fsl/data/imagewrapper.py
with
11 additions
and
4 deletions
fsl/data/imagewrapper.py
+
11
−
4
View file @
7d4a6c56
...
@@ -476,8 +476,8 @@ def calcExpansion(slices, coverage):
...
@@ -476,8 +476,8 @@ def calcExpansion(slices, coverage):
expansion
[
dimx
][
1
]
=
xhi
expansion
[
dimx
][
1
]
=
xhi
# And will span the union of
# And will span the union of
# the ra
n
ge and c
overage for
# the
cove
rage
,
and c
alculated
# every other dimension.
#
range for
every other dimension.
for
dimy
,
ylo
,
yhi
in
reqRanges
:
for
dimy
,
ylo
,
yhi
in
reqRanges
:
if
dimy
==
dimx
:
if
dimy
==
dimx
:
continue
continue
...
@@ -487,9 +487,16 @@ def calcExpansion(slices, coverage):
...
@@ -487,9 +487,16 @@ def calcExpansion(slices, coverage):
# this duplication.
# this duplication.
yLowCover
,
yHighCover
=
coverage
[:,
dimy
,
vol
]
yLowCover
,
yHighCover
=
coverage
[:,
dimy
,
vol
]
expLow
,
expHigh
=
expansion
[
dimy
]
expansion
[
dimy
][
0
]
=
min
((
ylo
,
yLowCover
))
if
np
.
isnan
(
expLow
):
expLow
=
yLowCover
expansion
[
dimy
][
1
]
=
max
((
yhi
,
yHighCover
))
if
np
.
isnan
(
expHigh
):
expHigh
=
yHighCover
expLow
=
min
((
ylo
,
yLowCover
,
expLow
))
expHigh
=
max
((
yhi
,
yHighCover
,
expHigh
))
expansion
[
dimy
][
0
]
=
expLow
expansion
[
dimy
][
1
]
=
expHigh
# Finish off this expansion by
# Finish off this expansion by
# adding indices for the vector/
# adding indices for the vector/
...
...
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