ANTsX / ANTsPy

A fast medical imaging analysis library in Python with algorithms for registration, segmentation, and more.
https://antspyx.readthedocs.io
Apache License 2.0
586 stars 161 forks source link

ENH: remove or rework insufficient rgb support ? #633

Closed ncullen93 closed 1 month ago

ncullen93 commented 1 month ago

The ConvertScalarImageToRGB function from ANTs cannot be wrapped due to some unsolvable errors. RGB images are basically insufficiently supported in antspy right now. The easiest option would be to remove rgb support and treat any such images as vector images. Otherwise they need better support.

The main question is whether rgb images are useful for anything other than visualization? The plotting part is already handled by matplotlib colormaps, so if not then they should probably be removed.

coveralls commented 1 month ago

Coverage Status

coverage: 81.329% (+0.5%) from 80.836% when pulling 09c7134714412fe089b590a03a1024408f84cd19 on wrap-convertscalartorgb into 9266f2fb977b3d1a7a36c48082becce689573360 on master.

cookpa commented 1 month ago

RGB does provide some extra functionality for some filters in the RGB space. I don't use them myself, though.

What I would like to have is the ability to write a vector image as an RGB or RGBA file.

ntustison commented 1 month ago

Thanks @ncullen93 . I don't think I've ever used this functionality through ANTsPy. I'm fine with removing it for now and perhaps revisiting once RGB support has expanded.