NadirData is a data container allowing to access a source of data and define then
compute diagnostics.
Parameters:
source – Input source (name of the table if using OCTANT storage).
date_start – Starting date of the period of interest.
date_end – Ending date of the period of interest.
select_clip – Selection clip allowing to work on a subset of the source’s data.
select_shape – Shape file, GeoDataFrame or Geometry on which to limit source’s data.
orf – Path or name of the orf.
reference_track –
Setting this parameter enables source’s data interpolation on this reference
track.
Every diagnostic is then computed using these interpolated data.
File path or data of the reference track on which to interpolate read data.
A list of existing theoretical reference tracks can be shown using the
show_theoretical_tracks method:
>>> CommonData.show_theoretical_tracks()
Standard along track data (orbits) can be provided as well.
This parameter can be provided as a dictionary containing ‘data’, ‘path’
and ‘coordinates’ keys.
time – The time field. (if not provided, default is “time” field)
latitude – The latitude field. (if not provided, default is “LATITUDE” field)
longitude – The longitude field. (if not provided, default is “LONGITUDE” field)
cycle_number – Cycle number’s field. (if not provided, default is “CYCLE_NUMBER” field)
pass_number – Pass number’s field. (if not provided, default is “PASS_NUMBER” field)
diag_overwrite –
Define the behavior when adding a diagnostic with an already used name:
[default] False: raise an error
True: remove the old diagnostic and add the new one
time_extension – Whether to allow the extension of user defined time interval for specific
diagnostic requirements or not.
Selection clip used to invalidate (set to NaN) some bins.
Valid conditions are:
count
min
max
mean
median
std
var
mad
These clips are Python vector clips.
Examples:
count :>= 10 && max :< 100
min :> 3
median :> 10 && mean :> 9
add_binned_stat_2d(name, field, x, res_x, y, res_y, stats=None, stat_selection=None)
Add a 2D binned diagnostic computing requested statistics inside
boxes defined by values of the x and y parameter according their
respective resolutions.
Binned 2d data and plots can be accessed or created using special keywords:
plot=”box” (default): color mesh representation, on an x-axis/y-axis grid.
plot=”curve”:
axis=”x”: along x-axis representation of each y-field bin
axis=”y”: along y-axis representation of each x-field bin
plot=”3d”: 3d color mesh representation, on an x-axis/y-axis/z-axis 3d grid.
plot=”box3d”: 3d bins surfaces representation,
on an x-axis/y-axis/z-axis 3d grid.
Add the computation of the difference between the ascending and
descending arc values at crossovers points. Temporal statistics (by
cycle or day) can be added to the computation.
Values and time delta are computed at each point and requested statistics for
each geographical box. These data are accessible using the requested statistics
name or ‘crossover’ and ‘value’ keywords for the time delta and the values at
each crossover point.
Time delta (accessible using the ‘crossover’ keyword) might contain more points
than the actual field statistics if the field is not defined at some crossovers
points.
Crossovers data and plots can be accessed or created using special keywords:
delta parameter: cartographic representation of the difference
between the two arcs
delta=”field”: difference of the field values
delta=”time”: difference of the time values
stat parameter: geographical box or temporal statistic representation.
field (Field) – Field for which to compute the statistic.
data (NadirData) – External data (NadirData) to compute crossovers with.
This option is used to compute multi-missions crossovers.
max_time_difference (str) – Maximum delta of time between the two arcs as a string with its unit.
Any string accepted by pandas.Timedelta is valid.
i.e. ‘10 days’, ‘6 hours’, ‘1 min’, …
interp_mode (str) – Interpolation mode used to compute the field value at the crossover
position.
Any value accepted by the ‘kind’ option of scipy.interpolate.interp1d is
valid.
i.e. : ‘linear’ ‘nearest’ ‘previous’ ‘next’ ‘zero’ ‘slinear’ ‘quadratic’
or ‘cubic’ (includes interpolation splines).
‘smooth’ is also valid and uses a smoothing spline from scipy.interpolate.
UnivariateSpline.
A noise level in the signal may be specified in this form: ‘smooth[0.05]’
Then, the smoothing factor (s parameter of UnivariateSpline) is computed in
such a way : smoothing_factor = noise_level^2 * number_of_points
The s parameter roughly represents the distance between the spline and the
points on the window. In particular, with s=0, we have an interpolation
spline, which is not suitable for a noisy signal.
‘smooth’ alone uses the default value of the s parameter (not recommended).
The ‘smooth’ interpolation mode requires at least three valid values on both
sides of the intersection point.
spline_half_window_size (int) – Half window size of the spline.
jump_threshold (float) – This parameter sets the tolerance level of the jumps (holes) in the input
data. By definition, a jump is detected between (consecutive) P1 and P2 if
dist(P1, P2) > jump_threshold * MEDIAN where MEDIAN is the median of the
distance between all consecutive points. For example, to avoid having
crossovers inside holes of one measure or more, 1.9 is a suitable value.
stats (list[StatType | str] | None) – List of statistics to compute (count, max, mean, median, min, std, var,
mad) for temporal and geobox statistics.
box_selection (Field | None) – Field used as selection for computation of the count statistic.
Box in which the box_selection field does not contain any data will be set
to NaN instead of 0.
geobox_stats (list[StatType | str] | None) – Statistics included in the geobox diagnostic.
temporal_stats (list[StatType | str] | None) – Statistics included in the temporal diagnostic.
temporal_freq_kwargs (dict[str, Any]) – Additional parameters to pass to pandas.date_range underlying function.
computation_split (str | FreqType | FrequencyHandler | None) – Split frequency (day, pass, cycle or any pandas offset aliases) inside
which crossovers will be computed. Providing None (default) will compute
crossovers over the whole data.
Raises:
AltiDataError – If a data already exists with the provided name.
projection (Proj | str | None) – Projection in which to project longitude and latitude values before binning
data.
box_selection (None | str | Field) – Field used as selection for computation of the count statistic.
Box in which the box_selection field does not contain any data will be set
to NaN instead of 0.
res_x (Union[tuple[float, float, float], DataResolution, str]) – Min, max and width for the x-axis, ‘auto’ (Default: ‘auto’).
‘auto’ will use the 2.5 percentile of values as min, the 97.5 percentile
as maximum and make 40 groups in between.
File path or data of the reference track.
A list of existing theoretical reference tracks can be shown using the
show_theoretical_tracks method:
>>> CommonData.show_theoretical_tracks()
Standard along track data (orbits) can be provided as well.
This parameter can be provided as a dictionary containing ‘data’, ‘path’
and ‘coordinates’ keys.
theoretical_orf (PassIndexer | str | None) – ORF to use to determine the real starting and ending dates of the passes.
Using table’s ORF might not show missing points in the beginning and end of
a track as well as points for completely missing tracks.
This parameter might not be necessary if using fully defined tracks
(not a theoretical track) as reference.
method (MissingPointsMethod | str) – Real: The real method will use the time difference between two real
measurements to determine the missing points.
Theoretical: The theoretical method will try to match each theoretical
points to a real points and use it to determine missing points.
distance_threshold (float) – Distance threshold between real and theoretical points expressed as a factor
of the distance between two consecutive theoretical points.
An exception is raised if the threshold is exceeded.
time_gap_reference (str | timedelta64) – Standard time gap between two consecutive real points.
Use the reference track time gap as default value.
If provided as a string include the unit otherwise it will be considered as
nanoseconds.
time_gap_threshold (float) – [real method parameter] Time threshold between two consecutive real points
expressed as a factor of time_gap_reference to determine that a point is
missing.
The standard value is 2.0: if two consecutive real points have a time gap
of 2.1 * time_gap_reference then a point is considered to be missing.
geobox_stats (bool) – Whether to compute geographical box statistics or not.
temporal_freq_kwargs (dict[str, Any]) – Additional parameters to pass to pandas.date_range underlying function.
section_min_lengths (int | list[int] | None) – List of missing sections minimum length values.
Setting this parameter enables the section analyses computation.
group_names (dict[str, int]) – Dictionary containing the name of the group associated to its flag value(s).
Multiple values can be associated to a name.
Example: {“land”: 0, “ocean”: 1, “ice”: 2, “iced_ocean”: [1, 2]}.
Define two groups {“land”: 0, “ocean”: 1} using a 1/30 of degree
bathymetry grid file. This method makes the assumption bathymetry
values lesser than 0 are ocean’s surface which is not 100% correct.
If an InGridParameters:
Define groups using the provided parameters in association with the
group_names parameter.
If False or None:
Does not define groups.
group_converter (Callable[[ndarray], ndarray]) – Callable to apply to grid values to transform them into group values.
This callable has to take a numpy array as single parameter and return a new
one.
If set to None, no conversion is made.
base_diag (str) – Name of the base temporal diagnostic.
stats (list[StatType | str] | None) – Statistics result in the base_diag to compute the periodogram from.
Default to the available statistics in the provided base diagnostic.
condition (str) – Clip condition determining the section.
min_length (int) – Minimum number of point required to accept the section.
fill_missing (bool) – Whether to fill missing values with False values (require parameter
max_percent_of_false to be greater than 0 to have an effect on the result)
max_percent_of_false (float) – Maximum percent of False value accepted in the section.
Add the computation of a spectral analysis diagnostic.
Spectral analysis data and plots can be accessed or created
using special keywords:
plot=”psd” (default): Power spectral density along the wave number,
plot=”segments”: Cartographic representation of the selected segments.
In the plot=”psd” case, a “spectral_name” parameter must be provided to
specify the required spectral analysis. If not, data of the first spectral
analysis will be returned.
The segments_reduction parameter also needs to be provided if more than
one reduction was requested or if computed using dask:
segments_reduction=”mean”
segments_reduction=”median”
Additional plotting options are available to the “psd” plot type:
individual: setting it to True (Default: False) display the set of
psd on each segments instead of the average psd,
n_bins_psd: integer determining the number of bins along the psd values
axis for the individual=True case (Default: 100),
second_axis: flag allowing the display of the second x-axis, for the
segment length values equivalent to the wave number.
field (Field) – Field on which to compute the analysis.
segment_length (int) – Length of a segment (section) in number of points.
It should be something like a few hundred points. (Example: 500 units)
holes_max_length (int) – Maximum length of a hole. It should be something like a few points.
(Example: 5, Default: 1% of the segment_length parameter value)
global_resampling (bool) – Resampling Flag (Default: False).
True - If one section requires to be resampled => resample all sections.
False - Resample only sections requiring a resampling.
delta_t (timedelta64 | str) – Time gap between two measurements.
noise_amplitude (float) – Noise amplitude in data.
Default to half of the data standard deviation.
insulation_level (float) – Minimum valid values percentage on both sides of the hole (Default: 0.75).
Left and right sides are equal to hole length.
last_segment_overlapping (float) – Percentage of overlap for second-to-last segment (Default: 0.5).
When the section is divided in equal segments, the last segment might be
too short, so it will take some part of data (amount depending on this
parameter) from the previous segment.
max_time_dispersion (int) – Maximum allowed percentage of dispersion for delta_t (Default: 5).
If delta_t dispersion exceed this threshold, a warning will be displayed.
max_resampling (float) – Maximum resampled data percentage (Default: 0.25).
A warning will be displayed if this threshold is exceeded.
The resampling of a large amount of data can have a great impact on the
final result.
segments_nb_delta_t (int) – Number of segments used to compute the average time gap between two
measurements, during the segments extraction process (Default: 1).
segments_nb_delta_x (int) – Number of segments used to compute the average distance between two
measurements, during the segments extraction process (Default: 1).
spectral_conf (dict[str, dict[str | SpectralType, Any]]) – Dictionary of the spectral parameters to use for the spectral curve types.
Each key represents a spectral analysis name is associated with a dictionary
containing the parameters. This dictionary must contain at least the
“spectral_type” key and value. (Default: dictionary containing
the default “periodogram” parameters:
{“periodogram”: {“spectral_type”: “periodogram”,
“window”: “hann”, “detrend”: “linear”, …}}).
segments_reduction (list[StatType | str] | StatType | str | None) – List of statistic types used to reduce the spectral data across segments
(Default: mean).
res_segments (bool) – Flag indicating whether to save the segments data
in the spectral analysis result (Default: False).
True - Saving segments data.
False - Not saving segments data.
res_individual_psd (bool) – Flag indicating whether to save the individual
power spectrum data on each segments
in the spectral analysis result (Default: False).
True - Saving the individual psd data.
False - Not saving the individual psd data.
jobs_number (int) – Number of jobs to create (Default to the maximum possible number of periods
the data can be split into according to the provided frequency).
bar (bool | None) – [Does not work on xarray datasets] Whether to display a progress bar or not.
If None, will display if logging level <= INFO.
Additional parameters required to get the data.
Those parameters are described in the add_diagnostic method documentation.
Some frequent parameters are “stat” and “plot”.
Other parameters are more specific to some diagnostic, like:
”segments_reduction”, “individual” or “spectral_name”
for the SpectralAnalysis diagnostic
”freq”, “group”, “dtype” for the MissingPoints diagnostic,
”delta” and “freq” for the Crossover diagnostic,
”pixel_split” for Raw and RawComparison Swath diagnostics.
Merge the provided data container raw data into the current one.
If provided data and current data include the INTERPOLATED_INDEX field, data
will be considered as already aligned otherwise the provided data will be
interpolated or re-indexed along the time dimension using the provided method
Longitudes from provided data will be replaced by the current ones
Latitude from the provided data will be replaced by the current ones
Interpolation is using interp_like method from xarray.
Reindexing is using reindex_like method from xarray.
Parameters:
data (CommonData) – Data container object containing computed raw data to merge.
interp (bool) – Whether to interpolate (True) or just reindex the data (False)
{“linear”, “nearest”, “zero”,
“slinear”, “quadratic”, “cubic”} for 1-dimensional array.
linear is used by default
Reindexing methods:
None (default): don’t fill gaps
pad / ffill: propagate last valid index value forward
backfill / bfill: propagate next valid index value backward
nearest: use the nearest valid index value
kwargs –
Additional parameters passed to the underlying xarray function.
Interpolation options:
Additional keyword passed to scipy’s interpolator.
Reindexing options:
tolerance: Maximum distance between original and new labels for
inexact matches. The values of the index at the matching locations
must satisfy the equation
analyse_type (FreqType | str) – Type of period covered by this analyse (cycle, pass or custom).
It’s used to determine the type of storage group to create.
analyse_date (datetime64 | None) – Date representing the set of data used in this analyse.
It’s used to determine at which timestamp to store non-temporal diagnostics.
store (DiagnosticStore | str) – Store to write the diagnostic results to.
mode (StorageMode | str) – Storage mode to use when writing data.
analyse_type (FreqType | str) – Type of period covered by this analyse (cycle, pass or custom).
It’s used to determine the type of storage group to create.
analyse_date (Union[datetime64, Timestamp, datetime, str, DateHandler]) – Date representing the set of data used in this analyse.
It’s used to determine at which timestamp to store non-temporal diagnostics.
lock (str | None) – Dask lock to use when writing data.
mode (StorageMode | str) – Storage mode to use when writing data.
diags (str | list[str] | None) – List of the diagnostics names to store.
analyse_type (FreqType | str) – Type of period covered by this analyse (cycle, pass or custom).
It’s used to determine the type of storage group to create.
analyse_date (Union[datetime64, Timestamp, datetime, str, DateHandler]) – Date representing the set of data used in this analyse.
It’s used to determine at which timestamp to store non-temporal diagnostics.
lock (str | None) – Dask lock to use when writing data.
SwathData is a data container allowing to access a source of data and define then
compute diagnostics.
Parameters:
source – Input source (name of the table if using OCTANT storage).
date_start – Starting date of the period of interest.
date_end – Ending date of the period of interest.
select_clip – Selection clip allowing to work on a subset of the source’s data.
select_shape – Shape file, GeoDataFrame or Geometry on which to limit source’s data.
orf – Path or name of the orf.
reference_track –
Setting this parameter enables source’s data interpolation on this reference
track.
Every diagnostic is then computed using these interpolated data.
File path or data of the reference track on which to interpolate read data.
A list of existing theoretical reference tracks can be shown using the
show_theoretical_tracks method:
>>> CommonData.show_theoretical_tracks()
Standard along track data (orbits) can be provided as well.
This parameter can be provided as a dictionary containing ‘data’, ‘path’
and ‘coordinates’ keys.
time – The time field. (if not provided, default is “time” field)
latitude – The latitude field. (if not provided, default is “LATITUDE” field)
longitude – The longitude field. (if not provided, default is “LONGITUDE” field)
cycle_number – Cycle number’s field. (if not provided, default is “CYCLE_NUMBER” field)
pass_number – Pass number’s field. (if not provided, default is “PASS_NUMBER” field)
diag_overwrite –
Define the behavior when adding a diagnostic with an already used name:
[default] False: raise an error
True: remove the old diagnostic and add the new one
time_extension – Whether to allow the extension of user defined time interval for specific
diagnostic requirements or not.
Selection clip used to invalidate (set to NaN) some bins.
Valid conditions are:
count
min
max
mean
median
std
var
mad
These clips are Python vector clips.
Examples:
count :>= 10 && max :< 100
min :> 3
median :> 10 && mean :> 9
add_binned_stat_2d(name, field, x, res_x, y, res_y, stats=None, stat_selection=None)
Add a 2D binned diagnostic computing requested statistics inside
boxes defined by values of the x and y parameter according their
respective resolutions.
Binned 2d data and plots can be accessed or created using special keywords:
plot=”box” (default): color mesh representation, on an x-axis/y-axis grid.
plot=”curve”:
axis=”x”: along x-axis representation of each y-field bin
axis=”y”: along y-axis representation of each x-field bin
plot=”3d”: 3d color mesh representation, on an x-axis/y-axis/z-axis 3d grid.
plot=”box3d”: 3d bins surfaces representation,
on an x-axis/y-axis/z-axis 3d grid.
Add the computation of the difference between the ascending and
descending arc values in the crossovers diamonds or at crossovers
equivalent Nadir points (see diamond_reduction parameter for a
statistical reduction of the diamond data). Temporal statistics (by
cycle or day) can be added to the computation.
Values and time delta are computed at each point and requested statistics for
each geographical box. These data are accessible using the requested statistics
name or ‘crossover’ and ‘value’ keywords for the time delta and the values at
each crossover point.
Crossovers data and plots can be accessed or created using special keywords:
delta parameter: cartographic representation of the difference
between the two arcs
delta=”field”: difference of the field values
delta=”time”: difference of the time values
stat parameter: geographical box or temporal statistic representation.
field (Field) – Field for which to compute the statistic.
data (CommonData) – External data (NadirData) to compute crossovers with.
This option is used to compute multi-missions crossovers.
max_time_difference (str) – Maximum delta of time between the two arcs as a string with its unit.
Any string accepted by pandas.Timedelta is valid.
i.e. ‘10 days’, ‘6 hours’, ‘1 min’, …
stats (list[StatType | str] | None) – List of statistics to compute (count, max, mean, median, min, std, var,
mad) for temporal and geobox statistics.
box_selection (Field | None) – Field used as selection for computation of the count statistic.
Box in which the box_selection field does not contain any data will be set
to NaN instead of 0.
geobox_stats (list[StatType | str] | None) – Statistics included in the geobox diagnostic.
temporal_stats (list[StatType | str] | None) – Statistics included in the temporal diagnostic.
temporal_freq_kwargs (dict[str, Any]) – Additional parameters to pass to pandas.date_range underlying function.
pass_multi_intersect (bool) – Whether to look for multiple intersections between a set of 2 passes or not.
cartesian_plane (bool) – Flag determining the plane used for crossovers computation.
If True, the crossover is calculated in the cartesian plane.
If False, the crossover is calculated in the spherical plane.
Defaults to True.
crossover_table (set[tuple[int, int]] | None) – The table of possible combinations of crossovers between the two passes.
If this table is not defined, all crossovers between odd and even passes
will be calculated.
diamond_relocation (bool) – Flag determining data relocation to nadir crossover coordinates for
the statistics computation.
If True, data relocation is performed. Default value is False.
diamond_reduction (str | StatType | None) – Statistic type used to reduce the data on the crossover diamond.
Reduction is disabled with the “none” value.
(Default value is “mean”)
Raises:
AltiDataError – If a data already exists with the provided name.
projection (Proj | str | None) – Projection in which to project longitude and latitude values before binning
data.
box_selection (None | str | Field) – Field used as selection for computation of the count statistic.
Box in which the box_selection field does not contain any data will be set
to NaN instead of 0.
res_x (Union[tuple[float, float, float], DataResolution, str]) – Min, max and width for the x-axis, ‘auto’ (Default: ‘auto’).
‘auto’ will use the 2.5 percentile of values as min, the 97.5 percentile
as maximum and make 40 groups in between.
base_diag (str) – Name of the base temporal diagnostic.
stats (list[StatType | str] | None) – Statistics result in the base_diag to compute the periodogram from.
Default to the available statistics in the provided base diagnostic.
In the case of a 3d Raw comparison (z parameter provided), data and plots
can be accessed or created using special keywords:
plot=”2d” (default): 2d scatter representation.
plot=”3d”: 3d scatter representation.
To split the data in the 3d plots (separate the 2 swaths),
the following format can be used: plot=”3d:pixel_split”, where “pixel_split” is
the pixel index value to split the data at.
Add a raw data diagnostic (used for along track plotting).
Raw data and plots can be accessed or created using special keywords:
plot=”time” (default): along time representation.
plot=”map”: Cartographic representation.
plot=”3d”: 3d surface representation.
To split the data in the 3d plots (separate the 2 swaths),
the following format can be used: plot=”3d:pixel_split”, where “pixel_split” is
the pixel index value to split the data at.
Add the computation of a spectral analysis diagnostic.
Spectral analysis data and plots can be accessed or created
using special keywords:
plot=”psd” (default): Power spectral density along the wave number,
plot=”segments”: Cartographic representation of the selected segments.
The segments_reduction parameter needs to be provided if more than one
reduction was requested or if computed using dask (the stat keyword might
be used instead):
segments_reduction=”mean”
segments_reduction=”median”
The pixel parameter needs to be provided to indicate which pixel to use:
pixel=20
pixel=(55, 60)
Additional plotting options are available to the “psd” plot type:
individual: setting it to True (Default: False) display the set of
psd on each segments instead of the average psd,
n_bins_psd: integer determining the number of bins along the psd values
axis for the individual=True case (Default: 100),
second_axis: flag allowing the display of the second x-axis, for the
segment length values equivalent to the wave number.
field (Field) – Field on which to compute the analysis.
segment_length (int) – Length of a segment (section) in number of points.
It should be something like a few hundred points. (Example: 500 units)
holes_max_length (int) – Maximum length of a hole.
It should be something like a few points (Example: 5)
global_resampling (bool) – Resampling Flag (Default: False).
True - If one section requires to be resampled => resample all sections.
False - Resample only sections requiring a resampling.
delta_t (timedelta64 | str) – Time gap between two measurements.
noise_amplitude (float) – Noise amplitude in data.
Default to half of the data standard deviation.
insulation_level (float) – Minimum valid values percentage on both sides of the hole (Default: 0.75).
Left and right sides are equal to hole length.
last_segment_overlapping (float) – Percentage of overlap for second-to-last segment (Default: 0.5).
When the section is divided in equal segments, the last segment might be
too short, so it will take some part of data (amount depending on this
parameter) from the previous segment.
max_time_dispersion (int) – Maximum allowed percentage of dispersion for delta_t (Default: 5).
If delta_t dispersion exceed this threshold, a warning will be displayed.
max_resampling (float) – Maximum resampled data percentage (Default: 0.25).
A warning will be displayed if this threshold is exceeded.
The resampling of a large amount of data can have a great impact on the
final result.
segments_nb_delta_t (int) – Number of segments used to compute the average time gap between two
measurements, during the segments extraction process (Default: 1).
segments_nb_delta_x (int) – Number of segments used to compute the average distance between two
measurements, during the segments extraction process (Default: 1).
spectral_conf (dict[str, dict[str | SpectralType, Any]]) – Dictionary of the spectral parameters to use for the spectral curve types.
Each key represents a spectral analysis name is associated with a dictionary
containing the parameters. This dictionary must contain at least the
“spectral_type” key and value. (Default: dictionary containing
the default “periodogram” parameters:
{“periodogram”: {“spectral_type”: “periodogram”,
“window”: “hann”, “detrend”: “linear”, …}}).
segments_reduction (list[StatType | str] | StatType | str | None) – List of statistic types used to reduce the spectral data across segments
(Default: mean).
pixels (int | list[int | tuple[int, int]]) – Pixels indexes along cross track distance dimension for which to
compute the diagnostic.
Either a single integer (for a single pixel) or a list/tuple of:
- integers: pix
- list/tuple of two integers, describing a range (pix_min, pix_max)
pixels_selection (str | SelectionType) – Mode of spectral data reduction for the different spectral curves
computed for the provided pixel values (Default: “all”).
“all”: reduce all the spectral curves for the reduction.
“range”: reduce the spectral curves within a cross track distance range.
“none”: no reduction performed.
pixels_reduction (str | StatType) – Statistic type used to reduce the spectral data across pixels
(Default: mean).
res_segments (bool) – Flag indicating whether to save the segments data
in the spectral analysis result (Default: False).
True - Saving segments data.
False - Not saving segments data.
res_individual_psd (bool) – Flag indicating whether to save the individual
power spectrum data on each segments
in the spectral analysis result (Default: False).
True - Saving the individual psd data.
False - Not saving the individual psd data.
jobs_number (int) – Number of jobs to create (Default to the maximum possible number of periods
the data can be split into according to the provided frequency).
bar (bool | None) – [Does not work on xarray datasets] Whether to display a progress bar or not.
If None, will display if logging level <= INFO.
Additional parameters required to get the data.
Those parameters are described in the add_diagnostic method documentation.
Some frequent parameters are “stat” and “plot”.
Other parameters are more specific to some diagnostic, like:
”segments_reduction”, “individual” or “spectral_name”
for the SpectralAnalysis diagnostic
”freq”, “group”, “dtype” for the MissingPoints diagnostic,
”delta” and “freq” for the Crossover diagnostic,
”pixel_split” for Raw and RawComparison Swath diagnostics.
Merge the provided data container raw data into the current one.
If provided data and current data include the INTERPOLATED_INDEX field, data
will be considered as already aligned otherwise the provided data will be
interpolated or re-indexed along the time dimension using the provided method
Longitudes from provided data will be replaced by the current ones
Latitude from the provided data will be replaced by the current ones
Interpolation is using interp_like method from xarray.
Reindexing is using reindex_like method from xarray.
Parameters:
data (CommonData) – Data container object containing computed raw data to merge.
interp (bool) – Whether to interpolate (True) or just reindex the data (False)
{“linear”, “nearest”, “zero”,
“slinear”, “quadratic”, “cubic”} for 1-dimensional array.
linear is used by default
Reindexing methods:
None (default): don’t fill gaps
pad / ffill: propagate last valid index value forward
backfill / bfill: propagate next valid index value backward
nearest: use the nearest valid index value
kwargs –
Additional parameters passed to the underlying xarray function.
Interpolation options:
Additional keyword passed to scipy’s interpolator.
Reindexing options:
tolerance: Maximum distance between original and new labels for
inexact matches. The values of the index at the matching locations
must satisfy the equation
analyse_type (FreqType | str) – Type of period covered by this analyse (cycle, pass or custom).
It’s used to determine the type of storage group to create.
analyse_date (datetime64 | None) – Date representing the set of data used in this analyse.
It’s used to determine at which timestamp to store non-temporal diagnostics.
store (DiagnosticStore | str) – Store to write the diagnostic results to.
mode (StorageMode | str) – Storage mode to use when writing data.
analyse_type (FreqType | str) – Type of period covered by this analyse (cycle, pass or custom).
It’s used to determine the type of storage group to create.
analyse_date (Union[datetime64, Timestamp, datetime, str, DateHandler]) – Date representing the set of data used in this analyse.
It’s used to determine at which timestamp to store non-temporal diagnostics.
lock (str | None) – Dask lock to use when writing data.
mode (StorageMode | str) – Storage mode to use when writing data.
diags (str | list[str] | None) – List of the diagnostics names to store.
analyse_type (FreqType | str) – Type of period covered by this analyse (cycle, pass or custom).
It’s used to determine the type of storage group to create.
analyse_date (Union[datetime64, Timestamp, datetime, str, DateHandler]) – Date representing the set of data used in this analyse.
It’s used to determine at which timestamp to store non-temporal diagnostics.
lock (str | None) – Dask lock to use when writing data.
spectral_conf (dict[str, dict[str | SpectralType, str]]) – Dictionary of the spectral parameters to use for the spectral curve types.
Each key represents a spectral analysis name is associated with a dictionary
containing the parameters. This dictionary must contain at least the
“spectral_type” key and value.