OpenZGY/C++ API and Internals (ALPHA)
Access seismic data stored in ZGY format.
Public Member Functions | Protected Member Functions | List of all members
InternalZGY::GenLodC Class Reference
Inheritance diagram for InternalZGY::GenLodC:
InternalZGY::GenLodImpl InternalZGY::GenLodBase

Public Member Functions

 GenLodC (const std::shared_ptr< ZgyInternalBulk > &accessor, const std::shared_ptr< ZgyInternalMeta > &meta, const compressor_t &lodcompressor, const std::vector< LodAlgorithm > &decimation, const std::function< bool(std::int64_t, std::int64_t)> &progress, bool verbose)
 
- Public Member Functions inherited from InternalZGY::GenLodImpl
 GenLodImpl (const index3_t &size, const index3_t &bricksize, RawDataType dtype, const std::array< double, 2 > &histogram_range, std::int32_t nlods_in, const std::vector< LodAlgorithm > &decimation, const std::shared_ptr< HistogramData > &histogram, double defaultvalue, const std::function< bool(std::int64_t, std::int64_t)> &progress, bool verbose)
 
std::tuple< std::shared_ptr< StatisticData >, std::shared_ptr< HistogramData > > call ()
 
- Public Member Functions inherited from InternalZGY::GenLodBase
 GenLodBase (const index3_t &size, const index3_t &bricksize, RawDataType dtype, const std::array< double, 2 > &histogram_range, std::int32_t nlods_in, const std::vector< LodAlgorithm > &decimation, const std::shared_ptr< HistogramData > &histogram, double defaultvalue, const std::function< bool(std::int64_t, std::int64_t)> &progress, bool verbose)
 

Protected Member Functions

std::shared_ptr< DataBuffer_read (std::int32_t lod, const index3_t &pos, const index3_t &size) override
 
void _write (std::int32_t lod, const index3_t &pos, const std::shared_ptr< const DataBuffer > &data) override
 
void _savestats () override
 
- Protected Member Functions inherited from InternalZGY::GenLodImpl
template<typename T >
void _accumulateT (const std::shared_ptr< const DataBuffer > &data_in)
 
void _accumulate (const std::shared_ptr< const DataBuffer > &data)
 
std::shared_ptr< DataBuffer_calculate (const index3_t &readpos_in, std::int32_t readlod)
 
std::shared_ptr< DataBuffer_decimate (const std::shared_ptr< const DataBuffer > &data, std::int64_t lod)
 
std::shared_ptr< DataBuffer_paste1 (const std::shared_ptr< DataBuffer > &result, const std::shared_ptr< const DataBuffer > &more, std::int64_t ioff, std::int64_t joff)
 
std::shared_ptr< const DataBuffer_paste4 (const std::shared_ptr< const DataBuffer > &d00, const std::shared_ptr< const DataBuffer > &d01, const std::shared_ptr< const DataBuffer > &d10, const std::shared_ptr< const DataBuffer > &d11)
 
- Protected Member Functions inherited from InternalZGY::GenLodBase
void _report (const DataBuffer *data)
 
std::string _prefix (std::int32_t lod)
 

Additional Inherited Members

- Static Protected Member Functions inherited from InternalZGY::GenLodImpl
static std::array< double, 2 > suggestHistogramRange (const std::array< double, 2 > &writtenrange, RawDataType dtype)
 
- Static Protected Member Functions inherited from InternalZGY::GenLodBase
static std::string _format_result (const std::shared_ptr< DataBuffer > &data)
 
- Protected Attributes inherited from InternalZGY::GenLodBase
std::int32_t _nlods
 
std::int64_t _total
 
std::int64_t _done
 
index3_t _surveysize
 
index3_t _bricksize
 
RawDataType _dtype
 
std::array< double, 2 > _histogram_range
 
std::vector< LodAlgorithm_decimation
 
std::shared_ptr< HistogramData_wa_histogram
 
double _wa_defaultstorage
 
std::function< bool(std::int64_t, std::int64_t)> _progress
 
bool _verbose
 

Constructor & Destructor Documentation

◆ GenLodC()

InternalZGY::GenLodC::GenLodC ( const std::shared_ptr< ZgyInternalBulk > &  accessor,
const std::shared_ptr< ZgyInternalMeta > &  meta,
const compressor_t lodcompressor,
const std::vector< LodAlgorithm > &  decimation,
const std::function< bool(std::int64_t, std::int64_t)> &  progress,
bool  verbose 
)

Generate and store low resolution bricks, histogram, and statistics. See doc/lowres.html for details. I/O is done via ZgyInternalBulk. Use this class as part as finalize(). The implementation uses plan C, which means the full resolution data will be read from the ZGY file. To implement plan D, make a derived class that redefines _read() to query the client for the required full resolution data. _read() must then also call _write() to store the data it just received.

Member Function Documentation

◆ _read()

std::shared_ptr< DataBuffer > InternalZGY::GenLodC::_read ( std::int32_t  lod,
const index3_t pos,
const index3_t size 
)
overrideprotectedvirtual

See base class for details.

Reimplemented from InternalZGY::GenLodBase.

◆ _savestats()

void InternalZGY::GenLodC::_savestats ( )
overrideprotectedvirtual

This is a stub that must be redefined except for low level unit tests. Finalize and write the computed statistics and histogram to the file.

Reimplemented from InternalZGY::GenLodBase.

◆ _write()

void InternalZGY::GenLodC::_write ( std::int32_t  lod,
const index3_t pos,
const std::shared_ptr< const DataBuffer > &  data 
)
overrideprotectedvirtual

See base class for details.

Reimplemented from InternalZGY::GenLodBase.


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