aodn / imos-toolbox

Graphical tool for QC'ing and NetCDF'ing oceanographic datasets
GNU General Public License v3.0
46 stars 31 forks source link

feat(Preprocessing): allow multi var names in aquatrackapp #616

Closed ocehugo closed 4 years ago

ocehugo commented 4 years ago

This commit remove previous warning message and put a simple logic handler for multi vars in the aquatracka pre-processing function.

The multi-var case should be quite rare but happens during tests since we create fake voltage variables in structures with CPHL data already.

lbesnard commented 4 years ago

@ocehugo in case of a multivar case, is there a variable attribute added somewhere to help users know what are the differences between _1 and _2 ? or is this kind of information just not available?

ocehugo commented 4 years ago

@lbesnard,

short answer: this is handled by the comment attribute.

long answer: This function only adds one chla variable. The problem is to find the correct name to avoid name clashes, since the receiving structure may already have CPHL, or CPHL_2, etc.

The above code just make sure that, if we got any CPHL_[N] already, the preprocessed variable will be stored as CPHL_[N+1] with the proper comment (located at commentsAquatracka variable)