.. title:: Overview

The KMOS 1.2.8 pipeline
###################################

These pages describe the python interface for the KMOS pipeline recipes.

Standard recipes
----------------
:data:`kmo_dark`
   Create master dark frame & bad pixel mask

:data:`kmo_flat`
   Create master flatfield frame and badpixel map to be used during science reduction

:data:`kmo_wave_cal`
   Create a calibration frame encoding the spectral position (i.e. wavelength) of each pixel on the detector.

:data:`kmo_illumination`
   Create a calibration frame to correct spatial non-uniformity of flatfield.

:data:`kmo_std_star`
   Create the telluric correction frame.

:data:`kmo_sci_red`
   Reconstruct obj/sky-pairs individually and combine them afterwards

Additional recipes
--------------------
:data:`kmo_dev_setup`
   Create aligned KMOS files out of test frames

:data:`kmo_copy`
   Copy a section of a cube to another cube, image or spectrum

:data:`kmo_fits_check`
   Check contents of a KMOS fits-file

:data:`kmo_fits_stack`
   Creates KMOS conform fits-files

:data:`kmo_rotate`
   Rotate a cube spatially

:data:`kmo_extract_spec`
   Extract a spectrum from a cube.

:data:`kmo_noise_map`
   Generate a noise map from a raw frame

:data:`kmo_multi_reconstruct`
   Reconstruct and combine obj/sky-pairs in one step.

:data:`kmo_shift`
   Shift a cube spatially

:data:`kmo_stats`
   Perform basic statistics on a KMOS-conform fits-file

:data:`kmo_arithmetic`
   Perform basic arithmetic on cubes

:data:`kmo_combine`
   Combine reconstructed cubes

:data:`kmo_fits_strip`
   Strip noise, rotator and/or empty extensions from a processed KMOS fits frame

:data:`kmo_illumination_flat`
   Alternative to kmo_illumination based on flatfield frames.

:data:`kmo_reconstruct`
   Performs the cube reconstruction using different interpolation methods.

:data:`kmo_sky_mask`
   Create a mask of spatial pixels that indicates which pixels can be considered as sky.

:data:`kmo_fit_profile`
   Fit spectral line profiles as well as spatial profiles with a simple function - for example to measure resolution or find the centre of a source

:data:`kmo_make_image`
   Collapse a cube to create a spatial image

:data:`kmo_sky_tweak`
   Removal of OH sky lines

.. toctree::
   :hidden:

   kmo_dark
   kmo_flat
   kmo_wave_cal
   kmo_illumination
   kmo_std_star
   kmo_sci_red
   kmo_dev_setup
   kmo_copy
   kmo_fits_check
   kmo_fits_stack
   kmo_rotate
   kmo_extract_spec
   kmo_noise_map
   kmo_multi_reconstruct
   kmo_shift
   kmo_stats
   kmo_arithmetic
   kmo_combine
   kmo_fits_strip
   kmo_illumination_flat
   kmo_reconstruct
   kmo_sky_mask
   kmo_fit_profile
   kmo_make_image
   kmo_sky_tweak

.. seealso::

     * The `KMOS Pipeline User Manual 
       <ftp://ftp.eso.org/pub/dfs/pipelines/kmos/kmos-pipeline-manual-2.9.pdf>`_ in PDF format,

     * an `overview <http://www.eso.org/sci/software/pipelines/>`_
       over the existing ESO pipelines,

     * the `python-cpl <http://packages.python.org/python-cpl>`_ package.
    
Bug reports
===========

If you experience an unexpected behavior of any component of the KMOS
pipeline recipes package, please, first refer to the list of known problems
and limitations in the pipeline manual of the current KMOS pipeline
release.

For any other issues or requests, please, send a report to the `ESO User
Support Department <usd-help@eso.org>`_, describing:

 * the KMOS pipeline version,
 * the version of your OS and C compiler,
 * the exact sequence of actions that were performed before the problem occurred,
 * what were precisely the symptoms and the possible error message(s),
 * whether the problem is repeatable.
