Changeset 1163 for XIOS/trunk/src
- Timestamp:
- 06/08/17 16:57:44 (7 years ago)
- Location:
- XIOS/trunk/src/transformation
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
XIOS/trunk/src/transformation/domain_algorithm_interpolate.cpp
r1114 r1163 388 388 } 389 389 390 if (writeToFile_ && !readFromFile_) 391 writeRemapInfo(interpMapValue);392 exchangeRemapInfo(interpMapValue);390 if (writeToFile_ && !readFromFile_) writeRemapInfo(interpMapValue); 391 // exchangeRemapInfo(interpMapValue); 392 convertRemapInfo(interpMapValue) ; 393 393 394 394 delete [] globalSrc; … … 494 494 } 495 495 496 void CDomainAlgorithmInterpolate::convertRemapInfo(std::map<int,std::vector<std::pair<int,double> > >& interpMapValue) 497 { 498 CContext* context = CContext::getCurrent(); 499 CContextClient* client=context->client; 500 int clientRank = client->clientRank; 501 502 this->transformationMapping_.resize(1); 503 this->transformationWeight_.resize(1); 504 505 TransformationIndexMap& transMap = this->transformationMapping_[0]; 506 TransformationWeightMap& transWeight = this->transformationWeight_[0]; 507 508 std::map<int,std::vector<std::pair<int,double> > >::const_iterator itb = interpMapValue.begin(), it, 509 ite = interpMapValue.end(); 510 511 for (it = itb; it != ite; ++it) 512 { 513 const std::vector<std::pair<int,double> >& tmp = it->second; 514 for (int i = 0; i < tmp.size(); ++i) 515 { 516 transMap[it->first].push_back(tmp[i].first); 517 transWeight[it->first].push_back(tmp[i].second); 518 } 519 } 520 } 496 521 497 522 /*! -
XIOS/trunk/src/transformation/domain_algorithm_interpolate.hpp
r1014 r1163 44 44 void writeRemapInfo(std::map<int,std::vector<std::pair<int,double> > >&); 45 45 void exchangeRemapInfo(std::map<int,std::vector<std::pair<int,double> > >& interpMapValue); 46 void convertRemapInfo(std::map<int,std::vector<std::pair<int,double> > >& interpMapValue); 46 47 47 48 private:
Note: See TracChangeset
for help on using the changeset viewer.