version  0.0.1
Defines the C++ API for MsPASS
Public Member Functions | Public Attributes | List of all members
mspass::algorithms::SegmentVectorProperties Class Reference

Public Member Functions

 SegmentVectorProperties (const std::vector< TimeSeries > &segments)
 
 SegmentVectorProperties (const SegmentVectorProperties &parent)
 

Public Attributes

bool dt_constant
 
bool has_dead_components
 
bool is_sorted
 
bool has_overlaps
 
bool has_gaps
 
int number_live
 
int first_live
 
double t0
 
double endtime
 
double dt
 
size_t spliced_nsamp
 
ErrorLogger elog
 

Detailed Description

File scope class to enscapsulate set of possible data problems.

Merging multiple data segments to a single time series, which is a common need with continous data, is prone to a number of practical problems. Clock issues and the design of modern digitizers can cause a mismatch in time computed by dt*nsamp and data time tags with formats like miniseed. This can create apparent gaps or overlaps. This class is intended to be used to scan a vector of time-sorted segment to flag issues that need to be handled downstream in algorithms later in this file. Issues it addresses at present are:

  1. irregular dt
  2. segments marked dead
  3. overlaps
  4. gaps
  5. Computes the length of the data being merged. Callers should test that that number is not absurd and could cause a memory alloc fault.

All attributes of this class are intentionally public as it should be thought of as a struct with convenient constructors.


The documentation for this class was generated from the following file: