Skip to content
Snippets Groups Projects
Commit df4ca6f0 authored by Paul McCarthy's avatar Paul McCarthy :mountain_bicyclist:
Browse files

TEST: Suppressing more warnings. Image(indexed) parameter is deprecated. More

work to do here
parent 1a114121
No related branches found
No related tags found
No related merge requests found
...@@ -225,7 +225,7 @@ def test_load_atlas(): ...@@ -225,7 +225,7 @@ def test_load_atlas():
reg.rescanAtlases() reg.rescanAtlases()
probatlas = reg.loadAtlas('harvardoxford-cortical', probatlas = reg.loadAtlas('harvardoxford-cortical',
indexed=True, calcRange=False, loadData=False) calcRange=False, loadData=False)
probsumatlas = reg.loadAtlas('harvardoxford-cortical', loadSummary=True) probsumatlas = reg.loadAtlas('harvardoxford-cortical', loadSummary=True)
lblatlas = reg.loadAtlas('talairach') lblatlas = reg.loadAtlas('talairach')
...@@ -240,7 +240,7 @@ def test_find(): ...@@ -240,7 +240,7 @@ def test_find():
reg.rescanAtlases() reg.rescanAtlases()
probatlas = reg.loadAtlas('harvardoxford-cortical', probatlas = reg.loadAtlas('harvardoxford-cortical',
indexed=True, calcRange=False, loadData=False) calcRange=False, loadData=False)
probsumatlas = reg.loadAtlas('harvardoxford-cortical', loadSummary=True) probsumatlas = reg.loadAtlas('harvardoxford-cortical', loadSummary=True)
lblatlas = reg.loadAtlas('talairach') lblatlas = reg.loadAtlas('talairach')
...@@ -273,7 +273,7 @@ def test_prepareMask(): ...@@ -273,7 +273,7 @@ def test_prepareMask():
reg.rescanAtlases() reg.rescanAtlases()
probatlas = reg.loadAtlas('harvardoxford-cortical', probatlas = reg.loadAtlas('harvardoxford-cortical',
indexed=True, loadData=False, calcRange=False) loadData=False, calcRange=False)
probsumatlas = reg.loadAtlas('harvardoxford-cortical', loadSummary=True) probsumatlas = reg.loadAtlas('harvardoxford-cortical', loadSummary=True)
lblatlas = reg.loadAtlas('talairach') lblatlas = reg.loadAtlas('talairach')
......
...@@ -45,8 +45,7 @@ def _get_atlas(atlasID, res, summary=False): ...@@ -45,8 +45,7 @@ def _get_atlas(atlasID, res, summary=False):
kwargs = {} kwargs = {}
else: else:
kwargs = {'loadData' : False, kwargs = {'loadData' : False,
'calcRange' : False, 'calcRange' : False}
'indexed' : True}
atlas = fslatlases.loadAtlas(atlasID, atlas = fslatlases.loadAtlas(atlasID,
loadSummary=summary, loadSummary=summary,
......
...@@ -98,7 +98,6 @@ def test_coords(seed): ...@@ -98,7 +98,6 @@ def test_coords(seed):
atlas = fslatlases.loadAtlas( atlas = fslatlases.loadAtlas(
ad.atlasID, ad.atlasID,
resolution=2, resolution=2,
indexed=True,
calcRange=False, calcRange=False,
loadData=False) loadData=False)
......
...@@ -442,7 +442,6 @@ def test_bad_mask(seed): ...@@ -442,7 +442,6 @@ def test_bad_mask(seed):
atlas = fslatlases.loadAtlas( atlas = fslatlases.loadAtlas(
atlasID, atlasID,
loadSummary=use_label, loadSummary=use_label,
indexed=True,
loadData=False, loadData=False,
calcRange=False) calcRange=False)
ashape = list(atlas.shape[:3]) ashape = list(atlas.shape[:3])
......
...@@ -9,6 +9,7 @@ ...@@ -9,6 +9,7 @@
import os.path as op import os.path as op
import shutil import shutil
import tempfile import tempfile
import warnings
import numpy as np import numpy as np
import pytest import pytest
...@@ -166,9 +167,12 @@ def test_loadVestLutFile(): ...@@ -166,9 +167,12 @@ def test_loadVestLutFile():
for i in range(4): for i in range(4):
f = testfiles[i] f = testfiles[i]
d = testdata[ i] d = testdata[ i]
dnorm = (d - d.min()) / (d.max() - d.min())
lutnorm = vest.loadVestLutFile(f) with warnings.catch_warnings():
lut = vest.loadVestLutFile(f, normalise=False) warnings.simplefilter('ignore')
dnorm = (d - d.min()) / (d.max() - d.min())
lutnorm = vest.loadVestLutFile(f)
lut = vest.loadVestLutFile(f, normalise=False)
assert lut.shape == d.shape assert lut.shape == d.shape
assert lutnorm.shape == dnorm.shape assert lutnorm.shape == dnorm.shape
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment