Ignore:
Timestamp:
11/02/15 11:46:25 (9 years ago)
Author:
mhnguyen
Message:

Implementing the reading of attributes of an axis from a file

+) 3d grid can be read directly from a file
+) Clean some redundant codes
+) Add new attribute declaration that allows to output only desired attributes

Test
+) On Curie
+) test_remap passes and result is correct

File:
1 edited

Legend:

Unmodified
Added
Removed
  • XIOS/trunk/src/transformation/domain_algorithm_interpolate.cpp

    r753 r775  
    7878    bool isNorthPole = false; 
    7979    bool isSouthPole = false; 
    80     if (poleValue == std::abs(domainSrc_->lat_start)) isNorthPole = true; 
    81     if (poleValue == std::abs(domainSrc_->lat_end)) isSouthPole = true; 
     80    if (std::abs(poleValue - std::abs(domainSrc_->lat_start)) < NumTraits<double>::epsilon()) isNorthPole = true; 
     81    if (std::abs(poleValue - std::abs(domainSrc_->lat_end)) < NumTraits<double>::epsilon()) isSouthPole = true; 
    8282 
    8383    nVertexSrc = constNVertex; 
     
    121121    bool isNorthPole = false; 
    122122    bool isSouthPole = false; 
    123     if (poleValue == std::abs(domainDest_->lat_start)) isNorthPole = true; 
    124     if (poleValue == std::abs(domainDest_->lat_end)) isSouthPole = true; 
     123    if (std::abs(poleValue - std::abs(domainDest_->lat_start)) < NumTraits<double>::epsilon()) isNorthPole = true; 
     124    if (std::abs(poleValue - std::abs(domainDest_->lat_end)) < NumTraits<double>::epsilon()) isSouthPole = true; 
    125125    if (isNorthPole && (0 == domainDest_->jbegin.getValue())) 
    126126    { 
Note: See TracChangeset for help on using the changeset viewer.