supereeg icon indicating copy to clipboard operation
supereeg copied to clipboard

get_slice for nifti subclass for 4D to 3D image

Open lucywowen opened this issue 7 years ago • 0 comments

for next release, change nifti get_slice method to something like this:

def get_slice(self, index): if len(self.shape)>3: if self.shape[3]==1: return nib.Nifti1Image(header=self.header, dataobj=np.squeeze(self.get_data()), affine=self.affine)

lucywowen avatar Oct 09 '18 21:10 lucywowen