Saving a Cupy array directly to JPEG without converting to NumPy

85 views Asked by At

I'm currently facing a challenge in my project where I need to save large Cupy arrays directly to JPEG files without the intermediate step of converting them to NumPy arrays due to performance considerations. The conversion time becomes a bottleneck as the array size increases.

The issue arises when attempting to read the saved JPEG file using imageio or opencv, as it doesn't directly support Cupy arrays. I'm seeking a solution that avoids using asnumpy due to its impact on conversion time, especially with large arrays.

I'm looking for insights or alternative approaches to efficiently save large Cupy arrays directly to image formats like JPEG without the need for intermediate NumPy conversion.

Any suggestions or guidance would be greatly appreciated, especially considering the constraint of minimizing conversion time.

0

There are 0 answers