Class ImageHDU

java.lang.Object
org.episteme.natural.physics.loaders.fits.HDU
org.episteme.natural.physics.loaders.fits.ImageHDU
Direct Known Subclasses:
OptimizedImageHDU

public class ImageHDU extends HDU
Header Data Unit representing an Image (N-dimensional array).

This class handles the reading of binary data as a generic Matrix.

Since:
1.0
Author:
Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
  • Constructor Details

    • ImageHDU

      public ImageHDU(Header header)
  • Method Details

    • getDataSize

      public long getDataSize()
      Description copied from class: HDU
      Returns the size of the data block in bytes, excluding padding.
      Specified by:
      getDataSize in class HDU
      Returns:
      data size in bytes.
    • asMatrix

      public RealDoubleMatrix asMatrix(ReadableByteChannel channel) throws IOException
      Reads the image data as a 2D Matrix of Reals.
      Parameters:
      channel - the channel to read from
      Returns:
      the matrix representation of the image
      Throws:
      IOException - if an error occurs