append_YAPC_ICESat2_ATL03.py

  • Reads ICESat-2 ATL03 geolocated photon height product files and appends photon classification flags from YAPC (Yet Another Photon Classifier) to granules

    • weight_ph_norm: photon weight normalization

    • weight_ph: normalized YAPC signal-to-noise ratio for each photon event

    • yapc_conf: YAPC-based confidence levels for each photon event

Source code

Calling Sequence

usage: append_YAPC_ICESat2_ATL03.py [-h] [--K K] [--min-knn MIN_KNN]
                                    [--min-ph MIN_PH]
                                    [--min-x-spread MIN_X_SPREAD]
                                    [--min-h-spread MIN_H_SPREAD]
                                    [--win-x WIN_X] [--win-h WIN_H]
                                    [--aspect ASPECT]
                                    [--method {ball_tree,linear,brute}]
                                    [--metric {height,manhattan}]
                                    [--norm {segment,granule}]
                                    [--output {append,copy,reduce}]
                                    [--verbose] [--mode MODE]
                                    infile [infile ...]

Positional Arguments

infile

ICESat-2 ATL03 file to run

options

--K, -k

Number of values for KNN algorithm

  • Use 0 for dynamic selection of neighbors

--min-knn

Minimum value of K used in the KNN algorithm

--min-ph

Minimum number of photons for a segment to be valid

--min-x-spread

Minimum along-track spread of photon events

--min-h-spread

Minimum window of heights for photon events

--win-x

Along-track length of window

--win-h

Height of window

  • Use 0 for dynamic window height

--aspect

Aspect ratio of x and h window

  • Use 0 for pre-defined window dimensions

--method

Possible choices: ball_tree, linear, brute

Algorithm for computing photon event weights

  • 'ball_tree': use scikit.learn.BallTree with custom distance metric

  • 'linear': use a brute-force approach with linear algebra

  • 'brute': use a brute-force approach

--metric

Possible choices: height, manhattan

Metric for computing distances

  • 'height': height differences

  • 'manhattan': manhattan distances

--norm

Possible choices: segment, granule

Normalization scheme for weights

  • 'segment': normalize photon weights for each segment

  • 'granule': normalize photon weights over complete granule

--output, -O

Possible choices: append, copy, reduce

Output file type

  • 'append': add photon classification flags to original ATL03 file

  • 'copy': add photon classification flags to a copied ATL03 file

  • 'reduce': create a new file with the photon classification flags

--verbose, -V

Verbose output of run

--mode, -M

Permissions mode of output files