Skip to content

Commit

Permalink
Fix ODF background axes
Browse files Browse the repository at this point in the history
  • Loading branch information
msorelli committed Jul 18, 2024
1 parent 70fe8ec commit 340a257
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion foa3d/odf.py
Original file line number Diff line number Diff line change
Expand Up @@ -437,8 +437,8 @@ def generate_odf_background(bg_img, bg_mrtrix_mmap, vxl_side):
elif bg_img.ndim == 4:
tmp_slice = 255.0 * np.sum(np.abs(bg_img[z, ...]), axis=-1)
tmp_slice = np.where(tmp_slice <= 255.0, tmp_slice, 255.0)
tmp_slice = np.swapaxes(tmp_slice, 0, 1).astype(np.uint8)

tmp_slice = transform_axes(tmp_slice, swapped=(0, 1), flipped=(0, 1))
bg_mrtrix_mmap[..., z // vxl_side] = \
resize(tmp_slice, output_shape=new_shape, anti_aliasing=True, preserve_range=True)

Expand Down

0 comments on commit 340a257

Please sign in to comment.