Changes between Version 2 and Version 3 of Procedures/HyperspectralCalibrationCreation


Ignore:
Timestamp:
Sep 21, 2015, 12:13:16 PM (8 years ago)
Author:
lah
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Procedures/HyperspectralCalibrationCreation

    v2 v3  
    1 = Generating calibration files for Eagle and Hawk =
     1= Generating calibration files for Fenix =
    22
    3 Radiometric, wavelength and miscellaneous other calibration of Eagle and Hawk is undertaken at ARSF-Ops at least annually. This page describes how to use the calibration software written by ARSF-DAN to create the necessary calibration files from the raw calibration data.
     3Radiometric, wavelength and miscellaneous other calibration of the Fenix is undertaken at ARSF-Ops at least annually since 2014. This page describes how to use the calibration software written by ARSF-DAN to create the necessary calibration files from the raw calibration data.
    44
    55== Setup ==
    66
    7 Relevant scripts are held in the arsf-internal SVN repository under tools/libarsfcal.
     7Relevant scripts are held in the arsf-internal git repository under tools/libarsfcal.
    88
    99Note that the various calibration scripts written in Python expect to import a package called "libarsfcal". This means that you must have the directory above the libarsfcal directory in your PYTHONPATH environment variable for the scripts to run. So eg.
    1010
    1111 1. `cd ~`
    12  1. svn co libarsfcal
    1312 1. `PYTHONPATH=$PYTHONPATH:~`
    1413 1. `export PYTHONPATH=$PYTHONPATH:~`
     
    1817=== Config file ===
    1918
    20 The master calibration scripts require a config file to supply a lot of their options. An example config file can be found under libarsfcal/supplementary. Keys must be in the format `key=value`, one per line. The file must contain a `[DEFAULT]` heading holding default values, an `[eagle]` heading holding keys for the Eagle calibration and a `[hawk]` heading holding keys for the Hawk calibration.
     19The master calibration scripts require a config file to supply a lot of their options. An example config file can be found under libarsfcal/supplementary. Keys must be in the format `key=value`, one per line. The file must contain a `[DEFAULT]` heading holding default values, an `[eagle]` heading holding keys for the Eagle calibration, a `[hawk]` heading holding keys for the Hawk calibration and a `[fenix]` heading holding keys for the Hawk calibration.
    2120
    2221Keys required under [DEFAULT]:
     
    2827 * lamp_index_file=<path to CSV file matching data file names to spectral lamps>
    2928
    30 Keys required under both [eagle] and [hawk]:
     29Keys required under [eagle], [hawk] and [fenix]:
    3130
    3231 * number_of_pixels=<number of spectral pixels on sensor>
     
    3938 * lampfile=<Path to CSV file containing integrating sphere response for this sensor>
    4039 * raw_radcal_file=<Path to raw file to start from to create radiometric calibration file>
     40
     41Extra keys required for [fenix]:
     42
     43 * lampfile_with_filter=<Path to CSV file containing integrating sphere response through blue filter for this sensor>
     44 * filter_radcal_file=<Path to blue filtered raw file to start from to create radiometric calibration file>
     45 * spectrum_break_band=<last pixel in VNIR>
    4146
    4247Example files for linefile, lamp_index_file and lampfile are all under libarsfcal/supplementary.
     
    5156
    5257 * -v: Verbose. Will print a lot more stuff but makes it easier to see if it's going wrong.
    53  * -s: Specify whether Eagle or Hawk. Required to run Hawk calibration.
     58 * -s: Specify sensor. Default is Eagle.
    5459 * -x: Comma-separated regex list. Files matching these regexes will not be processed. This may be useful if there are a lot of data files in the specified raw directory (or later stages) that are not relevant to the wavelength calibration.
    5560 * -t: Specify a calibration stage to start from. Useful to skip the long-running early stages if you don't need to (for example) split the raw files again when re-running.
    5661 * -p: Pauses calibration between stages so output can be easily checked.
     62 * --hwhm: Generates fityk scripts using hwhm rather than fwhm.
     63 * --offset2: Specifies a starting offset for Fenix's SWIR. Useful if the wavelength offset is large (>1nm).
    5764
    5865=== Other scripts ===
     
    7279 * wavelength_scale.py: Generates a wavelength scale for a given spectral dataset with wavelength anchor points.
    7380 * gen_bandsets.py: Generates new bandset (.prn, .bnd and .wls) files from the results of wavelength calibration
     81
     82=== Wavelength scale checking ===
     83
     84The generated wavelength scale may be checked against the lamp lines to determine the error in each matching band and it's FWHM. The output of this test is recorded in the data analysis report. Any unrealistic FWHMs and any failing bands should be removed from the calibration and the wavelength scale regenerated.
     85
     86 '''Master script:''' calc_peak_diffs.py
     87
     88Basic usage of this requires the following arguments:
     89
     90 * -a: Final anchor file produced during wavelength calibration.
     91 * -l: Spectral lines file.
    7492
    7593== Radiometric calibration ==