Changes between Version 2 and Version 3 of Procedures/HyperspectralCalibrationCreation
- Timestamp:
- Sep 21, 2015, 12:13:16 PM (9 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Procedures/HyperspectralCalibrationCreation
v2 v3 1 = Generating calibration files for Eagle and Hawk=1 = Generating calibration files for Fenix = 2 2 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.3 Radiometric, 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. 4 4 5 5 == Setup == 6 6 7 Relevant scripts are held in the arsf-internal SVNrepository under tools/libarsfcal.7 Relevant scripts are held in the arsf-internal git repository under tools/libarsfcal. 8 8 9 9 Note 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. 10 10 11 11 1. `cd ~` 12 1. svn co libarsfcal13 12 1. `PYTHONPATH=$PYTHONPATH:~` 14 13 1. `export PYTHONPATH=$PYTHONPATH:~` … … 18 17 === Config file === 19 18 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.19 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, a `[hawk]` heading holding keys for the Hawk calibration and a `[fenix]` heading holding keys for the Hawk calibration. 21 20 22 21 Keys required under [DEFAULT]: … … 28 27 * lamp_index_file=<path to CSV file matching data file names to spectral lamps> 29 28 30 Keys required under both [eagle] and [hawk]:29 Keys required under [eagle], [hawk] and [fenix]: 31 30 32 31 * number_of_pixels=<number of spectral pixels on sensor> … … 39 38 * lampfile=<Path to CSV file containing integrating sphere response for this sensor> 40 39 * raw_radcal_file=<Path to raw file to start from to create radiometric calibration file> 40 41 Extra 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> 41 46 42 47 Example files for linefile, lamp_index_file and lampfile are all under libarsfcal/supplementary. … … 51 56 52 57 * -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. 54 59 * -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. 55 60 * -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. 56 61 * -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). 57 64 58 65 === Other scripts === … … 72 79 * wavelength_scale.py: Generates a wavelength scale for a given spectral dataset with wavelength anchor points. 73 80 * gen_bandsets.py: Generates new bandset (.prn, .bnd and .wls) files from the results of wavelength calibration 81 82 === Wavelength scale checking === 83 84 The 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 88 Basic usage of this requires the following arguments: 89 90 * -a: Final anchor file produced during wavelength calibration. 91 * -l: Spectral lines file. 74 92 75 93 == Radiometric calibration ==