Modern diag_manager: Add standard_name and coordinates attributes + minor bug fixes#1176
Conversation
| !> Save the file name in the file_list | ||
| file_list%file_name(file_count) = trim(diag_yaml%diag_files(file_count)%file_fname)//c_null_char | ||
| !! The diag_table is not case sensitive (so we are saving it as lowercase) | ||
| file_list%file_name(file_count) = lowercase(trim(diag_yaml%diag_files(file_count)%file_fname)//c_null_char) |
There was a problem hiding this comment.
Why would we impose this? Why can't users have capital letters in the file names?
| variable_list%var_name(var_count) = trim(diag_yaml%diag_fields(var_count)%var_varname)//& | ||
| ":"//trim(diag_yaml%diag_fields(var_count)%var_module)//c_null_char | ||
| !! The diag_table is not case sensitive (so we are saving it as lowercase) | ||
| variable_list%var_name(var_count) = lowercase(variable_list%var_name(var_count)) |
There was a problem hiding this comment.
Why can't users have a capital letter for the var name? I always think of temperature as T and time as t
There was a problem hiding this comment.
They can have capital letters.
This is for when we are searching for the variable name in the diag_table.yaml. The old diag manager was not case sensitive. So in the register_diag_field call the variable name could be "Temperature", and in the diag_table.yaml "TEMPERATURE" or whatever. Without this the code won't be able to find the variable because "Temperature" != "TEMPERATURE"
The variable_list is the sorted list of variables, in the diag_yaml it saved at whatever is in the diag_table.yaml
|
|
||
| indices = fms_find_my_string(variable_list%var_pointer, size(variable_list%var_pointer), & | ||
| & trim(diag_field_name)//":"//trim(module_name)//c_null_char) | ||
| & lowercase(trim(diag_field_name))//":"//lowercase(trim(module_name)//c_null_char)) |
There was a problem hiding this comment.
This one I actually agree with because the actual modules are all lower case (i think)
…inor bug fixes (NOAA-GFDL#1176) * make diag_table search not case sensitive * Fix possible string issue in get_time_string * write the coordinate and standard name attribute to the field
…inor bug fixes (NOAA-GFDL#1176) * make diag_table search not case sensitive * Fix possible string issue in get_time_string * write the coordinate and standard name attribute to the field
…s + minor bug fixes (NOAA-GFDL#1176)
…s + minor bug fixes (NOAA-GFDL#1176)
…s + minor bug fixes (NOAA-GFDL#1176)
Description
standard_nameandcoordinates(this is used for field in the unstructured grid) attributes for fieldFixes # (issue)
How Has This Been Tested?
CI
Checklist:
make distcheckpasses