4 #include <vapor/BlkMemMgr.h>
121 DataMgrV3_0(
string format,
size_t mem_size,
int nthreads = 0);
136 virtual int Initialize(
const std::vector <string> &files);
149 virtual std::vector <string> GetDataVarNames()
const;
168 virtual std::vector <string> GetDataVarNames(
int ndim,
bool spatial)
const;
180 virtual std::vector <string> GetCoordVarNames()
const;
195 virtual std::vector <string> GetCoordVarNames(
int ndim,
bool spatial)
const;
209 timecoords = _timeCoordinates;
269 bool IsTimeVarying(
string varname)
const;
283 bool IsCompressed(
string varname)
const;
298 int GetNumTimeSteps(
string varname)
const;
315 int GetNumRefLevels(
string varname)
const;
332 int GetCRatios(
string varname, std::vector <size_t> &cratios)
const;
353 size_t ts,
string varname,
int level,
int lod,
bool lock=
false
384 size_t ts,
string varname,
int level,
int lod,
385 std::vector <double> min, std::vector <double> max,
bool lock=
false
389 size_t ts,
string varname,
int level,
int lod,
390 std::vector <size_t> min, std::vector <size_t> max,
bool lock=
false
404 int GetVariableExtents(
405 size_t ts,
string varname,
int level,
406 std::vector <double> &min , std::vector <double> &max
416 virtual int GetDimLensAtLevel(
417 string varname,
int level,
bool spatial,
418 std::vector <size_t> &dims_at_level,
419 std::vector <size_t> &bs_at_level
459 virtual bool VariableExists(
487 int NewPipeline(PipeLine *pipeline);
496 void RemovePipeline(
string name);
507 bool IsVariableDerived(
string varname)
const;
518 bool IsVariableNative(
string varname)
const;
525 void PurgeVariable(
string varname);
533 BlkExts(
const std::vector <size_t> &bmin,
const std::vector <size_t> &bmax);
536 const std::vector <size_t> &bcoord,
537 const std::vector <double> &min,
538 const std::vector <double> &max
542 const std::vector <double> &min,
543 const std::vector <double> &max,
544 std::vector <size_t> &bmin,
545 std::vector <size_t> &bmax
548 friend std::ostream &operator<<(
549 std::ostream &o,
const BlkExts &b
554 std::vector <size_t> _bmin;
555 std::vector <size_t> _bmax;
556 std::vector < std::vector < double > > _mins;
557 std::vector < std::vector < double > > _maxs;
570 size_t ts, std::vector <string> varnames,
int level,
int lod,
string key,
571 const std::vector <size_t> &values
574 size_t ts,
string varname,
int level,
int lod,
string key,
575 const std::vector <size_t> &values
577 std::vector <string> varnames;
578 varnames.push_back(varname);
579 Set(ts, varnames, level, lod, key, values);
583 size_t ts, std::vector <string> varnames,
int level,
int lod,
string key,
584 std::vector <size_t> &values
588 size_t ts,
string varname,
int level,
int lod,
string key,
589 std::vector <size_t> &values
591 std::vector <string> varnames;
592 varnames.push_back(varname);
593 return Get(ts, varnames, level, lod, key, values);
597 size_t ts, std::vector <string> varnames,
int level,
int lod,
string key
600 size_t ts,
string varname,
int level,
int lod,
string key
602 std::vector <string> varnames;
603 varnames.push_back(varname);
604 PurgeSize_t(ts, varnames, level, lod, key);
608 size_t ts, std::vector <string> varnames,
int level,
int lod,
string key,
609 const std::vector <double> &values
612 size_t ts,
string varname,
int level,
int lod,
string key,
613 const std::vector <double> &values
615 std::vector <string> varnames;
616 varnames.push_back(varname);
617 Set(ts, varnames, level, lod, key, values);
621 size_t ts, std::vector <string> varnames,
int level,
int lod,
string key,
622 std::vector <double> &values
626 size_t ts,
string varname,
int level,
int lod,
string key,
627 std::vector <double> &values
629 std::vector <string> varnames;
630 varnames.push_back(varname);
631 return Get(ts, varnames, level, lod, key, values);
635 size_t ts, std::vector <string> varnames,
int level,
int lod,
string key
638 size_t ts,
string varname,
int level,
int lod,
string key
640 std::vector <string> varnames;
641 varnames.push_back(varname);
642 PurgeDouble(ts, varnames, level, lod, key);
646 _cacheSize_t.clear();
647 _cacheDouble.clear();
650 static string _make_hash(
651 string key,
size_t ts, std::vector <string> cvars,
int level,
int lod
656 std::map <string, std::vector <size_t> > _cacheSize_t;
657 std::map <string, std::vector <double> > _cacheDouble;
668 std::vector <double> _timeCoordinates;
675 std::vector <size_t> bmin;
676 std::vector <size_t> bmax;
682 std::list <region_t> _regionsList;
684 VAPoR::BlkMemMgr *_blk_mem_mgr;
687 std::vector <PipeLine *> _PipeLines;
690 VarInfoCache _varInfoCache;
691 std::map <string, BlkExts> _blkExtsCache;
694 string varname, std::vector <string> &scvars,
string &tcvar
697 int _get_time_coordinates(std::vector <double> &timecoords);
701 const std::vector <size_t> &min,
702 const std::vector <size_t> &max,
703 const std::vector <size_t> &dims,
704 const std::vector <float *> &blkvec,
705 const std::vector <size_t> &bs,
706 const std::vector <size_t> &bmin,
707 const std::vector <size_t> &bmax
712 const std::vector <size_t> &min,
713 const std::vector <size_t> &max,
714 const std::vector <size_t> &dims,
715 const std::vector <float *> &blkvec,
716 const std::vector <size_t> &bs,
717 const std::vector <size_t> &bmin,
718 const std::vector <size_t> &bmax
723 const std::vector <size_t> &min,
724 const std::vector <size_t> &max,
725 const std::vector <size_t> &dims,
726 const std::vector <float *> &blkvec,
727 const std::vector < std::vector <size_t > > &bsvec,
728 const std::vector < std::vector <size_t > > &bminvec,
729 const std::vector < std::vector <size_t > > &bmaxvec
732 int _find_bounding_grid(
733 size_t ts,
string varname,
int level,
int lod,
734 std::vector <double> min, std::vector <double> max,
735 std::vector <size_t> &min_ui, std::vector <size_t> &max_ui
743 const vector <size_t> &min,
744 const vector <size_t> &max,
745 vector <string> &varnames,
746 vector < vector <size_t > > &dimsvec,
747 vector < vector <size_t > > &dims_at_levelvec,
748 vector < vector <size_t > > &bsvec,
749 vector < vector <size_t > > &bs_at_levelvec,
750 vector < vector <size_t > > &bminvec,
751 vector < vector <size_t > > &bmaxvec
768 std::vector <size_t> min,
769 std::vector <size_t> max,
774 float *_get_region_from_cache(
779 const std::vector <size_t> &bmin,
780 const std::vector <size_t> &bmax,
784 float *_get_region_from_fs(
785 size_t ts,
string varname,
int level,
int lod,
786 const std::vector <size_t> &bs,
const std::vector <size_t> &bmin,
787 const std::vector <size_t> &bmax,
bool lock
797 const std::vector <size_t> &bs,
798 const std::vector <size_t> &bmin,
799 const std::vector <size_t> &bmax,
804 const std::vector <string> &varnames,
807 const std::vector < std::vector <size_t > > &bsvec,
808 const std::vector < std::vector <size_t> > &bminvec,
809 const std::vector < std::vector <size_t> > &bmaxvec,
810 std::vector <float *> &blkvec
813 void _unlock_blocks(
const float *blks);
815 std::vector <string> _get_native_variables()
const;
816 std::vector <string> _get_derived_variables()
const;
818 float *_alloc_region(
823 std::vector <size_t> bmin,
824 std::vector <size_t> bmax,
825 std::vector <size_t> bs,
836 std::vector <size_t> bmin,
837 std::vector <size_t> bmax
841 void _free_var(
string varname);
843 int _level_correction(
string varname,
int &level)
const;
844 int _lod_correction(
string varname,
int &lod)
const;
void GetTimeCoordinates(std::vector< double > &timecoords) const
Base class for storing variable metadata.
Coordinate variable metadata.
virtual string GetMapProjection() const
A cache based data reader.