Line Spread Functions

GalPaK provides two LSFs : Gaussian and MUSE. These are used to extrude the 2D PSF image into 3D, right before its application in Fourier space.

You may use them as the lsf argument of the Instrument, as described here.


All instruments use this LSF model by default, with their own configuration :

class galpak.GaussianLineSpreadFunction(fwhm)[source]

A line spread function that spreads as a gaussian. We assume the centroid is in the middle.

fwhm: float
Full Width Half Maximum, in µm.


This LSF requires the mpdaf module, specifically mpdaf.MUSE.LSF.

As this LSF is optional, you must explicitly tell your instrument to use it when you want to.

class galpak.MUSELineSpreadFunction(model='qsim_v1')[source]

A line spread function that uses MPDAF’s LSF. See


This requires the mpdaf module. Currently, the MPDAF module only works for odd arrays.

model: string
See mpdaf.MUSE.LSF‘s typ parameter.


In order to further customize the LSF you want to use, you can create your own LSF class and use it in the instrument, it simply needs to implement the following interface :

class galpak.LineSpreadFunction[source]

This is the interface all Line Spread Functions (LSF) should implement.


Should return this LSF as a 1D vector shaped [for_cube].

for_cube: HyperspectralCube

Return type:ndarray