We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The sample files are in .mat format but the method to load uses h5py,
It would be helpful if there was a np array to data format conversion method in the util e.g.
def LoadDataSet(load_dir, variable = 'data_fs', padding = True, Norm = True): f = h5py.File(load_dir,'r') if np.array(f[variable]).ndim==3: data=np.expand_dims(np.transpose(np.array(f[variable]),(0,2,1)),axis=1) else: data=np.transpose(np.array(f[variable]),(1,0,3,2)) data=data.astype(np.float32) if padding: pad_x=int((256-data.shape[2])/2) pad_y=int((256-data.shape[3])/2) print('padding in x-y with:'+str(pad_x)+'-'+str(pad_y)) data=np.pad(data,((0,0),(0,0),(pad_x,pad_x),(pad_y,pad_y))) if Norm: data=(data-0.5)/0.5 return data
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The sample files are in .mat format but the method to load uses h5py,
It would be helpful if there was a np array to data format conversion method in the util e.g.
The text was updated successfully, but these errors were encountered: