Ignore:
Timestamp:
07/19/19 15:28:33 (5 years ago)
Author:
yushan
Message:

MARK: Dynamic workflow graph developement. Branch up to date with trunk @1676. Bug fixed

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/dev/dev_trunk_omp/src/filter/file_writer_filter.cpp

    r1680 r1681  
    1919  } 
    2020 
    21   void CFileWriterFilter::onInputReady(std::vector<CDataPacketPtr> data) 
     21  void CFileWriterFilter::buildGraph(std::vector<CDataPacketPtr> data) 
    2222  { 
    2323    bool building_graph = this->tag ? data[0]->timestamp >= this->start_graph && data[0]->timestamp <= this->end_graph: false; 
     
    2929 
    3030      CWorkflowGraph::allocNodeEdge(); 
     31      StdString namestring = to_string(this->field->name); 
     32      namestring.erase(0, 6); 
     33      namestring.erase(namestring.length()-1, 1); 
    3134 
    32       CWorkflowGraph::addNode(this->filterID, "File Writer Filter \\n("+this->field->file->getId()+".nc)", 6, 0, 1, data[0]); 
     35      CWorkflowGraph::addNode(this->filterID, namestring + "\\n("+this->field->file->getId()+".nc)", 6, 0, 1, data[0]); 
    3336 
    34       // (*CWorkflowGraph::mapFilters_ptr_with_info)[this->filterID].attributes = this->field->file->recordXiosAttributes(); 
    35       (*CWorkflowGraph::mapFilters_ptr_with_info)[this->filterID].attributes = this->field->recordXiosAttributes(); 
    36       (*CWorkflowGraph::mapFilters_ptr_with_info)[this->filterID].attributes += "</br>file attributes : </br>" +this->field->file->recordXiosAttributes(); 
    37  
    38       // if(CXios::isClient) std::cout<<"CFileWriterFilter::apply filter tag = "<<this->tag<<" start = "<<start_graph<<" end = "<<end_graph<<std::endl; 
     37      (*CWorkflowGraph::mapFilters_ptr_with_info)[this->filterID].attributes = this->field->record4graphXiosAttributes(); 
     38      (*CWorkflowGraph::mapFilters_ptr_with_info)[this->filterID].attributes += "</br>file attributes : </br>" +this->field->file->record4graphXiosAttributes(); 
     39      (*CWorkflowGraph::mapFilters_ptr_with_info)[this->filterID].clusterID =1; 
     40      (*CWorkflowGraph::mapFilters_ptr_with_info)[this->filterID].distance = ++(data[0]->distance); 
    3941 
    4042      if(CXios::isClient && CWorkflowGraph::build_begin)  
     
    4749      else CWorkflowGraph::build_begin=true; 
    4850    } 
     51  } 
     52 
     53  void CFileWriterFilter::onInputReady(std::vector<CDataPacketPtr> data) 
     54  { 
     55    buildGraph(data); 
    4956     
    5057    const bool detectMissingValue = ( !field->default_value.isEmpty() && 
Note: See TracChangeset for help on using the changeset viewer.