You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to denoise micro-CT data of a tissue sample. The data is stored in Nifti format. I can convert it into a TIFF and use the code, but I can also directly read the Nifti file using nibabel and get the 3D array. Do you know how I can use the rest of the steps?
I appreciate any help you can provide.
Sudhir
The text was updated successfully, but these errors were encountered:
your_array=nibabal(...) # or whatever you need to call to load it# re-order dimensions to SZYXC# You can use numpy.moveaxis (https://numpy.org/doc/stable/reference/generated/numpy.moveaxis.html)# to change your dataset into ZYX, then to add the S and C singleton dimensions:your_array=your_array[np.newaxis, ..., np.newaxis]
# generate patchespatch_shape= (32, 64, 64)
patches=datagen.generate_patches_from_list(your_array, shape=patch_shape) # if you have a list of imagespatches=datagen.generate_patches(your_array, shape=patch_shape) # alternatively to the previous line
Please note that we are not maintaining n2v anymore, and are developing CAREamics, which allows you to pass an array directly, along with your axes order. So it is a bit simpler, and we will be happy to help if you open an issue there.
Thanks for the fantastic library!
I want to denoise micro-CT data of a tissue sample. The data is stored in Nifti format. I can convert it into a TIFF and use the code, but I can also directly read the Nifti file using nibabel and get the 3D array. Do you know how I can use the rest of the steps?
I appreciate any help you can provide.
Sudhir
The text was updated successfully, but these errors were encountered: