Main Content


Perform fast in-scene atmospheric correction



    newhcube = fastInScene(hcube)returns atmospherically corrected data cube by computing the surface reflectance values from the top of atmosphere (TOA) reflectance values in input hyperspectral data. Use this function to perform fast atmospheric correction that uses the in-scene characteristics for estimating the correction parameters.

    The fast in-scene method gives best correction results, if the hyperspectral data

    • is radiometrically calibrated

    • is uniformly illuminated

    • does not contain large water bodies, cloud, or cloud shadows

    • contain adequate dark pixels for approximately computing the baseline spectrum

    • contain heterogeneous regions that include soil, water, vegetation, and man-made structures. The method assumes that the mean reflectance spectrum of different endmember spectra are scene-independent.


    This function requires the Image Processing Toolbox™ Hyperspectral Imaging Library. You can install the Image Processing Toolbox Hyperspectral Imaging Library from Add-On Explorer. For more information about installing add-ons, see Get and Manage Add-Ons.


    collapse all

    Read hyperspectral data into the workspace.

    inputCube = hypercube('EO1H0440342002212110PY_cropped.dat');

    Remove low signal-to-noise ratio (SNR) bands from the hyperspectral data cube.

    inputCube = removeBands(inputCube,'BandNumber',find(~inputCube.Metadata.BadBands));

    Convert digital number (DN) to top of atmosphere (TOA) reflectance values.

    inputCube = dn2reflectance(inputCube);

    Remove atmospheric effects from the input hyperspectral data based on the in-scene characteristics.

    correctedCube = fastInScene(inputCube);

    Input Arguments

    collapse all

    Input hyperspectral data, specified as a hypercube object. The DataCube property of the hypercube object stores the hyperspectral data cube. For better results, the input values must be TOA reflectance values. If the input values are digital numbers, use the dn2reflectance function to estimate the TOA reflectance values.

    Output Arguments

    collapse all

    Output hyperspectral data, returned as hypercube object. The pixel values of the data cube returned at the output specifies the surface reflectance values.


    [1] Bernstein, L.S., S.M. Adler-Golden, R.L. Sundberg, R.Y. Levine, T.C. Perkins, A. Berk, A.J. Ratkowski, G. Felde, and M.L. Hoke. “A New Method for Atmospheric Correction and Aerosol Optical Property Retrieval for VIS-SWIR Multi- and Hyperspectral Imaging Sensors: QUAC (QUick Atmospheric Correction).” In Proceedings. 2005 IEEE International Geoscience and Remote Sensing Symposium, 2005. IGARSS ’05., 5:3549–52. Seoul, Korea: IEEE, 2005.

    Introduced in R2020b