Ignore:
Timestamp:
04/17/20 18:55:28 (4 years ago)
Author:
ymipsl
Message:

Some update on XIOS_COUPLING branch...

YM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_ym/XIOS_COUPLING/src/node/grid.cpp

    r1869 r1870  
    3333      , writtenDataSize_(0), numberWrittenIndexes_(0), totalNumberWrittenIndexes_(0), offsetWrittenIndexes_(0) 
    3434      , connectedDataSize_(), connectedServerRank_(), connectedServerRankRead_(), connectedDataSizeRead_() 
    35           , isDataDistributed_(true), isCompressible_(false) 
     35            , isCompressible_(false) 
    3636      , transformations_(0), isTransformed_(false) 
    3737      , axisPositionInGrid_(), hasDomainAxisBaseRef_(false) 
     
    5454      , writtenDataSize_(0), numberWrittenIndexes_(0), totalNumberWrittenIndexes_(0), offsetWrittenIndexes_(0) 
    5555      , connectedDataSize_(), connectedServerRank_(), connectedServerRankRead_(), connectedDataSizeRead_() 
    56           , isDataDistributed_(true), isCompressible_(false) 
     56            , isCompressible_(false) 
    5757      , transformations_(0), isTransformed_(false) 
    5858      , axisPositionInGrid_(), hasDomainAxisBaseRef_(false) 
     
    9696     if (!isScalarGrid()) 
    9797     { 
    98        std::vector<int> dataNindex = getDistributionClient()->getDataNIndex(); 
     98       std::vector<int> dataNindex = getClientDistribution()->getDataNIndex(); 
    9999       for (int i = 0; i < dataNindex.size(); ++i) retvalue *= dataNindex[i];        
    100100     } 
     
    128128     for (size_t i = 0; i < axisList.size(); ++i) 
    129129     { 
    130        std::map<int, StdSize> axisAttBuffSize = axisList[i]->getAttributesBufferSize(client, getGlobalDimension(),axisPositionInGrid_[i]); 
     130       std::map<int, StdSize> axisAttBuffSize = axisList[i]->getAttributesBufferSize(client, getGlobalDimension(),getAxisPositionInGrid()[i]); 
    131131       for (it = axisAttBuffSize.begin(), itE = axisAttBuffSize.end(); it != itE; ++it) 
    132132       { 
     
    202202   CATCH_DUMP_ATTR 
    203203    
     204 
     205   void CGrid::computeAxisPositionInGrid(void) 
     206   { 
     207     axisPositionInGrid_.resize(0); 
     208     int idx = 0; 
     209     for (int i = 0; i < axis_domain_order.numElements(); ++i) 
     210     { 
     211       int elementDimension = axis_domain_order(i); 
     212       if (1 == elementDimension) 
     213       { 
     214         axisPositionInGrid_.push_back(idx); 
     215         ++idx; 
     216       } 
     217       else if (2 == elementDimension) idx += 2; 
     218     } 
     219   } 
     220 
    204221   void CGrid::checkAttributesAfterTransformation() 
    205222   TRY 
     
    207224      setAxisList(); 
    208225      std::vector<CAxis*> axisListP = this->getAxis(); 
    209       if (!axisListP.empty()) 
    210       { 
    211         int idx = 0; 
    212         axisPositionInGrid_.resize(0); 
    213         for (int i = 0; i < axis_domain_order.numElements(); ++i) 
    214         { 
    215           int elementDimension = axis_domain_order(i); 
    216           if (1 == elementDimension) 
    217           { 
    218             axisPositionInGrid_.push_back(idx); 
    219             ++idx; 
    220           } 
    221           else if (2 == elementDimension) idx += 2; 
    222         } 
    223  
    224         for (int i = 0; i < axisListP.size(); ++i) 
    225         { 
    226           axisListP[i]->checkAttributesOnClientAfterTransformation(getGlobalDimension(),axisPositionInGrid_[i]); 
    227         } 
    228       } 
    229  
     226      for (int i = 0; i < axisListP.size(); ++i) 
     227        axisListP[i]->checkAttributesOnClientAfterTransformation(getGlobalDimension(), getAxisPositionInGrid()[i]); 
     228    
    230229      setDomainList(); 
    231230      std::vector<CDomain*> domListP = this->getDomains(); 
     
    568567      if (!axisListP.empty()) 
    569568      { 
    570         int idx = 0; 
    571         axisPositionInGrid_.resize(0); 
    572         for (int i = 0; i < axis_domain_order.numElements(); ++i) 
    573         { 
    574           int elementDimension = axis_domain_order(i); 
    575           if (1 == elementDimension) 
    576           { 
    577             axisPositionInGrid_.push_back(idx); 
    578             ++idx; 
    579           } 
    580           else if (2 == elementDimension) idx += 2; 
    581         } 
    582  
    583569        for (int i = 0; i < axisListP.size(); ++i) 
    584570        { 
    585571          if (sendAtt) 
    586             axisListP[i]->sendCheckedAttributes(getGlobalDimension(),axisPositionInGrid_[i]); 
     572            axisListP[i]->sendCheckedAttributes(getGlobalDimension(),getAxisPositionInGrid()[i]); 
    587573          else 
    588574            axisListP[i]->checkAttributesOnClient(); 
     
    634620 
    635621      size_t nbWritten = 0, indGlo; 
    636       CDistributionClient::GlobalLocalDataMap& globalDataIndex = getDistributionClient()->getGlobalDataIndexOnClient(); 
     622      CDistributionClient::GlobalLocalDataMap& globalDataIndex = getClientDistribution()->getGlobalDataIndexOnClient(); 
    637623      CDistributionClient::GlobalLocalDataMap::const_iterator itb = globalDataIndex.begin(), 
    638624                                                              ite = globalDataIndex.end(), it;     
     
    651637      { 
    652638        numberWrittenIndexes_ = nbWritten; 
    653         if (isDataDistributed_) 
     639        if (isDataDistributed()) 
    654640        { 
    655641          CContext* context = CContext::getCurrent();       
     
    688674   void CGrid::computeGridIndexToFileServer(CContextClient* client) 
    689675   { 
    690      if (isScalarGrid()) 
    691      { 
    692        computeClientIndexScalarGrid(); 
    693        computeConnectedClientsScalarGrid(client); 
    694      } 
    695      else 
    696      { 
    697        computeClientIndex(); 
    698        computeConnectedClients(client); 
    699      } 
    700  
     676     if (isScalarGrid()) computeConnectedClientsScalarGrid(client); 
     677     else computeConnectedClients(client); 
     678     
    701679     // compute indices for client/server transfer for domain 
    702680     for (const auto& domainId : domList_) CDomain::get(domainId)->computeConnectedClients(client); 
     
    705683     // compute indices for client/server transfer for axis 
    706684     std::vector<CAxis*> axisList = this->getAxis(); 
    707      std::vector<int> axisPosInGrid ; 
    708      // compute axis position in grid      
    709      int idx=0 ; 
    710      for (int i = 0 ; i < axis_domain_order.numElements(); ++i) 
    711      { 
    712        if (axis_domain_order(i) == 0)  idx += 0 ; 
    713        else if (axis_domain_order(i) == 1) { axisPosInGrid.push_back(idx) ; ++idx; } 
    714        else if (axis_domain_order(i) == 2) idx += 2; 
    715      } 
    716      for(int i=0 ; i<axisList.size(); i++) axisList[i] -> computeConnectedClients(client, getGlobalDimension(),axisPositionInGrid_[i]) ; 
     685     for(int i=0 ; i<axisList.size(); i++) axisList[i] -> computeConnectedClients(client, getGlobalDimension(),getAxisPositionInGrid()[i]) ; 
    717686   } 
    718687   //--------------------------------------------------------------- 
     
    740709     else 
    741710     { 
    742        CDistributionClient* clientDistribution = getDistributionClient() ; 
     711       CDistributionClient* clientDistribution = getClientDistribution() ; 
    743712       const std::vector<int>& localDataIndex = clientDistribution->getLocalDataIndexOnClient() ; 
    744713       int nbStoreIndex = localDataIndex.size() ; 
     
    759728     else 
    760729     { 
    761        CDistributionClient* clientDistribution = getDistributionClient() ; 
     730       CDistributionClient* clientDistribution = getClientDistribution() ; 
    762731       const std::vector<bool>& localMaskIndex = clientDistribution->getLocalMaskIndexOnClient() ; 
    763732       int nbMaskIndex = localMaskIndex.size() ; 
     
    767736   } 
    768737 
    769    /* 
    770      Compute the global index and its local index taking account mask and data index. 
    771      These global indexes will be used to compute the connection of this client (sender) to its servers (receivers) 
    772      (via function computeConnectedClient) 
    773      These global indexes also correspond to data sent to servers (if any) 
    774    */ 
    775    void CGrid::computeClientIndex() 
    776    TRY 
    777    { 
    778      if (computeClientIndex_done_) return ; 
    779  
    780      CContext* context = CContext::getCurrent(); 
    781      int rank = context-> getIntraCommRank(); 
    782  
    783      auto clientDistribution = getDistributionClient(); 
    784      // Get local data index on client 
    785      int nbStoreIndex = clientDistribution->getLocalDataIndexOnClient().size(); 
    786      int nbStoreGridMask = clientDistribution->getLocalMaskIndexOnClient().size(); 
    787      // nbStoreGridMask = nbStoreIndex if grid mask is defined, and 0 otherwise 
    788      storeIndex_client_.resize(nbStoreIndex); 
    789      storeMask_client_.resize(nbStoreGridMask); 
    790      for (int idx = 0; idx < nbStoreIndex; ++idx) storeIndex_client_(idx) = (clientDistribution->getLocalDataIndexOnClient())[idx]; 
    791      for (int idx = 0; idx < nbStoreGridMask; ++idx) storeMask_client_(idx) = (clientDistribution->getLocalMaskIndexOnClient())[idx]; 
    792  
    793      if (0 == serverDistribution_) isDataDistributed_= clientDistribution->isDataDistributed(); 
    794      else 
    795      { 
    796         // Mapping global index received from clients to the storeIndex_client_ 
    797         CDistributionClient::GlobalLocalDataMap& globalDataIndex = clientDistribution->getGlobalDataIndexOnClient(); 
    798         CDistributionClient::GlobalLocalDataMap::const_iterator itGloe = globalDataIndex.end(); 
    799         map<int, CArray<size_t, 1> >::iterator itb = outGlobalIndexFromClient_.begin(), 
    800                                                ite = outGlobalIndexFromClient_.end(), it; 
    801  
    802         for (it = itb; it != ite; ++it) 
     738 
     739  void CGrid::computeOutLocalIndexStoreOnClient(void) 
     740  { 
     741    if (computeOutLocalIndexStoreOnClient_done_) return ; 
     742    else computeOutLocalIndexStoreOnClient_done_=true ; 
     743 
     744    if (isScalarGrid()) 
     745    { 
     746        auto& outGlobalIndexFromClient  = getOutGlobalIndexFromClient(); 
     747        auto itb = outGlobalIndexFromClient.begin(), ite = outGlobalIndexFromClient.end() ; 
     748        for (auto it = itb; it != ite; ++it) 
    803749        { 
    804750          int rank = it->first; 
    805           CArray<size_t,1>& globalIndex = outGlobalIndexFromClient_[rank]; 
     751          CArray<size_t,1>& globalIndex = outGlobalIndexFromClient[rank]; 
    806752          outLocalIndexStoreOnClient_.insert(make_pair(rank, CArray<size_t,1>(globalIndex.numElements()))); 
    807753          CArray<size_t,1>& localIndex = outLocalIndexStoreOnClient_[rank]; 
    808           size_t nbIndex = 0; 
    809  
    810           // Keep this code for this moment but it should be removed (or moved to DEBUG) to improve performance 
    811           for (size_t idx = 0; idx < globalIndex.numElements(); ++idx) 
    812           { 
    813             if (itGloe != globalDataIndex.find(globalIndex(idx))) 
    814             { 
    815               ++nbIndex; 
    816             } 
    817           } 
    818  
    819           if (nbIndex != localIndex.numElements()) 
    820                ERROR("void CGrid::computeClientIndex()", 
    821                   << "Number of local index on client is different from number of received global index" 
    822                   << "Rank of sent client " << rank <<"." 
    823                   << "Number of local index " << nbIndex << ". " 
    824                   << "Number of received global index " << localIndex.numElements() << "."); 
    825  
    826           nbIndex = 0; 
    827           for (size_t idx = 0; idx < globalIndex.numElements(); ++idx) 
    828           { 
    829             if (itGloe != globalDataIndex.find(globalIndex(idx))) 
    830             { 
    831               localIndex(idx) = globalDataIndex[globalIndex(idx)]; 
    832             } 
    833           } 
     754          if (1 != globalIndex.numElements()) 
     755            ERROR("void CGrid::computeClientIndexScalarGrid()", 
     756              << "Something wrong happened. " 
     757              << "Number of received global index on scalar grid should equal to 1"  
     758              << "Number of received global index " << globalIndex.numElements() << "."); 
     759 
     760          localIndex(0) = globalIndex(0); 
    834761        } 
    835       } 
    836       computeClientIndex_done_ = true ; 
    837    } 
    838    CATCH_DUMP_ATTR 
     762    } 
     763    else 
     764    { 
     765      CDistributionClient::GlobalLocalDataMap& globalDataIndex = getClientDistribution()->getGlobalDataIndexOnClient(); 
     766      CDistributionClient::GlobalLocalDataMap::const_iterator itGloe = globalDataIndex.end(); 
     767      auto& outGlobalIndexFromClient  = getOutGlobalIndexFromClient(); 
     768      auto itb = outGlobalIndexFromClient.begin(), ite = outGlobalIndexFromClient.end() ; 
     769     
     770      for (auto it = itb; it != ite; ++it) 
     771      { 
     772         int rank = it->first; 
     773         CArray<size_t,1>& globalIndex = outGlobalIndexFromClient[rank]; 
     774         outLocalIndexStoreOnClient_.insert(make_pair(rank, CArray<size_t,1>(globalIndex.numElements()))); 
     775         CArray<size_t,1>& localIndex = outLocalIndexStoreOnClient_[rank]; 
     776         size_t nbIndex = 0; 
     777 
     778        // Keep this code for this moment but it should be removed (or moved to DEBUG) to improve performance 
     779        for (size_t idx = 0; idx < globalIndex.numElements(); ++idx) 
     780          if (itGloe != globalDataIndex.find(globalIndex(idx))) ++nbIndex; 
     781 
     782        if (nbIndex != localIndex.numElements()) 
     783             ERROR("void CGrid::computeClientIndex()", 
     784                 << "Number of local index on client is different from number of received global index" 
     785                 << "Rank of sent client " << rank <<"." 
     786                 << "Number of local index " << nbIndex << ". " 
     787                 << "Number of received global index " << localIndex.numElements() << "."); 
     788 
     789        nbIndex = 0; 
     790        for (size_t idx = 0; idx < globalIndex.numElements(); ++idx) 
     791          if (itGloe != globalDataIndex.find(globalIndex(idx))) 
     792            localIndex(idx) = globalDataIndex[globalIndex(idx)]; 
     793      } 
     794    } 
     795  } 
     796 
     797  bool CGrid::isDataDistributed(void)  
     798  {  
     799    return getClientDistribution()->isDataDistributed() ; 
     800  } 
    839801 
    840802   /*! 
     
    845807   { 
    846808     if (computeConnectedClients_done_.count(client)!=0) return ; 
     809     else  computeConnectedClients_done_.insert(client) ; 
    847810 
    848811     CContext* context = CContext::getCurrent(); 
     
    868831          if (client->isServerLeader()) 
    869832          { 
    870             size_t ssize = getDistributionClient()->getLocalDataIndexOnClient().size(); 
     833            size_t ssize = getClientDistribution()->getLocalDataIndexOnClient().size(); 
    871834            const std::list<int>& ranks = client->getRanksServerLeader(); 
    872835            for (std::list<int>::const_iterator itRank = ranks.begin(), itRankEnd = ranks.end(); itRank != itRankEnd; ++itRank) 
     
    899862         computeIndexByElement(indexServerOnElement, client, globalIndexOnServer_[receiverSize]); 
    900863 
    901        const CDistributionClient::GlobalLocalDataMap& globalLocalIndexSendToServer = getDistributionClient()->getGlobalLocalDataSendToServer(); 
     864       const CDistributionClient::GlobalLocalDataMap& globalLocalIndexSendToServer = getClientDistribution()->getGlobalLocalDataSendToServer(); 
    902865       CDistributionClient::GlobalLocalDataMap::const_iterator iteGlobalLocalIndexMap = globalLocalIndexSendToServer.end(), itGlobalLocalIndexMap; 
    903866       CClientServerMapping::GlobalIndexMap::const_iterator iteGlobalMap, itbGlobalMap, itGlobalMap; 
     
    956919       nbSenders_[receiverSize] = CClientServerMapping::computeConnectedClients(receiverSize, client->clientSize, client->intraComm, connectedServerRank_[receiverSize]); 
    957920     } 
    958      computeConnectedClients_done_.insert(client) ; 
    959921   } 
    960922   CATCH_DUMP_ATTR 
     
    975937     if (isScalarGrid()) 
    976938     { 
    977        computeClientIndexScalarGrid(); 
     939       //computeClientIndexScalarGrid(); 
    978940       if (context->getServiceType()==CServicesManager::CLIENT || context->getServiceType()==CServicesManager::GATHERER) 
    979941       { 
     
    983945     else 
    984946     { 
    985        computeClientIndex(); 
     947       //computeClientIndex(); 
    986948       if (context->getServiceType()==CServicesManager::CLIENT || context->getServiceType()==CServicesManager::GATHERER) 
    987949       { 
     
    14301392   TRY 
    14311393   { 
    1432       const std::vector<int>& localMaskedDataIndex = getDistributionClient()->getLocalMaskedDataIndexOnClient(); 
     1394      const std::vector<int>& localMaskedDataIndex = getClientDistribution()->getLocalMaskedDataIndexOnClient(); 
    14331395      const int size = localMaskedDataIndex.size(); 
    14341396      for(int i = 0; i < size; ++i) out(localMaskedDataIndex[i]) = data[i]; 
     
    14361398   CATCH 
    14371399 
    1438   void CGrid::computeClientIndexScalarGrid() 
    1439   TRY 
    1440   { 
    1441     if (computeClientIndexScalarGrid_done_) return ; 
    1442  
    1443     CContext* context = CContext::getCurrent();     
    1444     { 
    1445       int rank = context->intraCommRank_; 
    1446  
    1447       auto clientDistribution = getDistributionClient(); 
    1448  
    1449       storeIndex_client_.resize(1); 
    1450       storeIndex_client_(0) = 0;       
    1451  
    1452       if (0 != serverDistribution_) 
    1453       { 
    1454         map<int, CArray<size_t, 1> >::iterator itb = outGlobalIndexFromClient_.begin(), 
    1455                                                ite = outGlobalIndexFromClient_.end(), it; 
    1456         for (it = itb; it != ite; ++it) 
    1457         { 
    1458           int rank = it->first; 
    1459           CArray<size_t,1>& globalIndex = outGlobalIndexFromClient_[rank]; 
    1460           outLocalIndexStoreOnClient_.insert(make_pair(rank, CArray<size_t,1>(globalIndex.numElements()))); 
    1461           CArray<size_t,1>& localIndex = outLocalIndexStoreOnClient_[rank]; 
    1462           if (1 != globalIndex.numElements()) 
    1463             ERROR("void CGrid::computeClientIndexScalarGrid()", 
    1464               << "Something wrong happened. " 
    1465               << "Number of received global index on scalar grid should equal to 1"  
    1466               << "Number of received global index " << globalIndex.numElements() << "."); 
    1467  
    1468           localIndex(0) = globalIndex(0); 
    1469         } 
    1470       } 
    1471     } 
    1472     computeClientIndexScalarGrid_done_ = true ; 
    1473   } 
    1474   CATCH_DUMP_ATTR 
    1475  
     1400   
    14761401  void CGrid::computeConnectedClientsScalarGrid(CContextClient* client) 
    14771402  TRY 
     
    15231448      } 
    15241449    } 
    1525     isDataDistributed_ = false; 
     1450    
    15261451    computeConnectedClientsScalarGrid_done_.insert(client) ; 
    15271452  } 
     
    15671492 
    15681493          listMsg.push_back(CMessage()); 
    1569           listMsg.back() << getId( )<< isDataDistributed_ << isCompressible_ << listOutIndex.back(); 
     1494          listMsg.back() << getId( )<< isCompressible_ << listOutIndex.back(); 
    15701495 
    15711496          event.push(rank, 1, listMsg.back()); 
     
    16111536      list<CMessage> listMsg; 
    16121537      list<CArray<size_t,1> > listOutIndex; 
    1613       const CDistributionClient::GlobalLocalDataMap& globalLocalIndexSendToServer = getDistributionClient()->getGlobalLocalDataSendToServer(); 
     1538      const CDistributionClient::GlobalLocalDataMap& globalLocalIndexSendToServer = getClientDistribution()->getGlobalLocalDataSendToServer(); 
    16141539      CDistributionClient::GlobalLocalDataMap::const_iterator itbIndex = globalLocalIndexSendToServer.begin(), itIndex, 
    16151540                                                              iteIndex = globalLocalIndexSendToServer.end(); 
     
    16391564 
    16401565            listMsg.push_back(CMessage()); 
    1641             listMsg.back() << getId() << isDataDistributed_ << isCompressible_ << listOutIndex.back(); 
     1566            listMsg.back() << getId() << isCompressible_ << listOutIndex.back(); 
    16421567 
    16431568            event.push(*itRank, 1, listMsg.back()); 
     
    17071632          storeIndex_fromSrv_.insert(make_pair(rank, CArray<int,1>(outLocalIndexToServer))); 
    17081633          listMsg.push_back(CMessage()); 
    1709           listMsg.back() << getId() << isDataDistributed_ << isCompressible_ << listOutIndex.back(); 
     1634          listMsg.back() << getId() << isCompressible_ << listOutIndex.back(); 
    17101635 
    17111636          event.push(rank, nbSenders_[receiverSize][rank], listMsg.back()); 
     
    17661691      CBufferIn& buffer = *buffers[n]; 
    17671692 
    1768       buffer >> isDataDistributed_ >> isCompressible_; 
     1693      buffer >> isCompressible_; 
    17691694      size_t dataSize = 0; 
    17701695 
     
    20541979  CATCH_DUMP_ATTR 
    20551980 
    2056   CDistributionClient* CGrid::getDistributionClient() 
     1981  CDistributionClient* CGrid::getClientDistribution() 
    20571982  TRY 
    20581983  { 
     
    20711996    else if (0 != client) 
    20721997    { 
    2073       return  (isDataDistributed_ ||  (1 != client->clientSize) || (1 != client->serverSize)); 
     1998      return  (isDataDistributed() ||  (1 != client->clientSize) || (1 != client->serverSize)); 
    20741999    } 
    20752000    else 
    2076       return isDataDistributed_;     
     2001      return isDataDistributed();     
    20772002  } 
    20782003  CATCH_DUMP_ATTR 
     
    21782103   CATCH_DUMP_ATTR 
    21792104 
     2105 
     2106  void CGrid::sendGridToFileServer(CContextClient* client) 
     2107  { 
     2108    if (sendGridToFileServer_done_.count(client)!=0) return ; 
     2109    else sendGridToFileServer_done_.insert(client) ; 
     2110 
     2111    StdString gridDefRoot("grid_definition"); 
     2112    CGridGroup* gridPtr = CGridGroup::get(gridDefRoot); 
     2113    gridPtr->sendCreateChild(this->getId(),client); 
     2114    this->sendAllAttributesToServer(client); 
     2115    this->sendAllDomains(client); 
     2116    this->sendAllAxis(client); 
     2117    this->sendAllScalars(client); 
     2118  } 
     2119 
    21802120   /*! 
    21812121   \brief Send a message to create a domain on server side 
     
    27942734  { 
    27952735    std::vector<CDomain*> domList = this->getVirtualDomainGroup()->getAllChildren(); 
    2796     int dSize = domList.size(); 
    2797     for (int i = 0; i < dSize; ++i) 
    2798     { 
    2799       sendAddDomain(domList[i]->getId(),contextClient); 
    2800       domList[i]->sendAllAttributesToServer(contextClient); 
     2736    for (auto domain : domList) 
     2737    { 
     2738      sendAddDomain(domain->getId(),contextClient); 
     2739      domain->sendDomainToFileServer(contextClient); 
    28012740    } 
    28022741  } 
     
    28102749  { 
    28112750    std::vector<CAxis*> aList = this->getVirtualAxisGroup()->getAllChildren(); 
    2812     int aSize = aList.size(); 
    2813  
    2814     for (int i = 0; i < aSize; ++i) 
     2751    for (int i=0; i<aList.size() ; ++i) 
    28152752    { 
    28162753      sendAddAxis(aList[i]->getId(),contextClient); 
    2817       aList[i]->sendAllAttributesToServer(contextClient); 
     2754      aList[i]->sendAxisToFileServer(contextClient, getGlobalDimension(), getAxisPositionInGrid()[i]); 
    28182755    } 
    28192756  } 
     
    28272764  { 
    28282765    std::vector<CScalar*> sList = this->getVirtualScalarGroup()->getAllChildren(); 
    2829     int sSize = sList.size(); 
    2830  
    2831     for (int i = 0; i < sSize; ++i) 
    2832     { 
    2833       sendAddScalar(sList[i]->getId(),contextClient); 
    2834       sList[i]->sendAllAttributesToServer(contextClient); 
     2766    for (auto scalar : sList) 
     2767    { 
     2768      sendAddScalar(scalar->getId(),contextClient); 
     2769      scalar->sendScalarToFileServer(contextClient); 
    28352770    } 
    28362771  } 
Note: See TracChangeset for help on using the changeset viewer.