Skip to content

Commit 921173b

Browse files
committed
FIX: CoordinateAxis.__getitem__ fix
1 parent a458ec3 commit 921173b

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

nibabel/coordimage.py

+1-4
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ def __getitem__(self, slicer):
4141
return self
4242
elif isinstance(slicer, slice):
4343
slicer = fill_slicer(slicer, len(self))
44-
print(slicer)
4544
start, stop, step = slicer.start, slicer.stop, slicer.step
4645
else:
4746
raise TypeError(f'Indexing type not supported: {type(slicer)}')
@@ -50,7 +49,6 @@ def __getitem__(self, slicer):
5049
pstop = 0
5150
for parcel in self.parcels:
5251
pstart, pstop = pstop, pstop + len(parcel)
53-
print(pstart, pstop)
5452
if pstop < start:
5553
continue
5654
if pstart >= stop:
@@ -59,8 +57,7 @@ def __getitem__(self, slicer):
5957
substart = (start - pstart) % step
6058
else:
6159
substart = start - pstart
62-
print(slice(substart, stop - pstart, step))
63-
subparcels.append(parcel[substart : stop - pstop : step])
60+
subparcels.append(parcel[substart : stop - pstart : step])
6461
return CoordinateAxis(subparcels)
6562

6663
def get_indices(self, parcel, indices=None):

0 commit comments

Comments
 (0)