Ignore:
Timestamp:
08/25/15 16:52:45 (9 years ago)
Author:
rlacroix
Message:

Add support for indexed output.

If the new field attribute "indexed_output" is set to true and a mask is defined (either at grid, domain or axis level), the indexed data will be outputed instead of the full data with missing values.

See http://cfconventions.org/Data/cf-conventions/cf-conventions-1.5/build/cf-conventions.html#compression-by-gathering for more information.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/trunk/src/node/domain.hpp

    r667 r676  
    4747         typedef CDomainAttributes SuperClassAttribute; 
    4848 
    49       public : 
     49      public: 
    5050 
    5151         typedef CDomainAttributes RelAttributes; 
     
    7070         void checkAttributesOnClientAfterTransformation(); 
    7171 
     72         void checkEligibilityForCompressedOutput(void); 
     73 
    7274         void sendCheckedAttributes(); 
    7375 
     
    7678         TransMapTypes getAllTransformations(); 
    7779 
    78       public : 
     80      public: 
    7981         const std::set<StdString> & getRelFiles(void) const; 
    8082         bool IsWritten(const StdString & filename) const; 
     83         bool isWrittenCompressed(const StdString& filename) const; 
     84 
     85         const std::vector<int>& getIndexesToWrite(void) const; 
     86         int getNumberWrittenIndexes() const; 
     87         int getTotalNumberWrittenIndexes() const; 
     88         int getOffsetWrittenIndexes() const; 
     89 
    8190         bool isEmpty(void) const; 
    8291         bool isDistributed(void) const; 
    83  
     92         bool isCompressible(void) const; 
    8493 
    8594         int global_zoom_ibegin, global_zoom_ni; 
     
    104113        vector< vector<int> > j_indSrv ; // for each server, j global index to send 
    105114 
    106       public : 
     115      public: 
    107116         /// Mutateur /// 
    108117         void addRelFile(const StdString & filename); 
     118         void addRelFileCompressed(const StdString& filename); 
    109119         void completeLonLatClient(void); 
    110120         void sendServerAttribut(void) ; 
     
    159169         void sendLonLat(); 
    160170 
    161        private : 
     171       private: 
    162172         bool isChecked; 
    163          std::set<StdString> relFiles; 
     173         std::set<StdString> relFiles, relFilesCompressed; 
    164174         bool isClientChecked; // Verify whether all attributes of domain on the client side are good 
    165175         bool isClientAfterTransformationChecked; 
     
    167177         std::map<int,int> nbConnectedClients_; // Mapping of number of communicating client to a server 
    168178         std::map<int, vector<size_t> > indSrv_; // Global index of each client sent to server 
     179         std::map<int, vector<int> > indWrittenSrv_; // Global written index of each client sent to server 
     180         std::vector<int> indexesToWrite; 
     181         int numberWrittenIndexes_, totalNumberWrittenIndexes_, offsetWrittenIndexes_; 
    169182         std::vector<int> connectedServerRank_; 
    170183         bool isDistributed_; 
     184         //! True if and only if the data defined on the domain can be outputted in a compressed way 
     185         bool isCompressible_; 
    171186         TransMapTypes transformationMap_; 
    172187         std::vector<int> nGlobDomain_; 
Note: See TracChangeset for help on using the changeset viewer.