grib2netcdf: naming of variables: fix entries in cfVarName.def which start with a digit

This commit is contained in:
Shahram Najm 2013-07-22 14:06:46 +01:00
parent f1340999c2
commit 3d6ebcfaf3
4 changed files with 81 additions and 81 deletions

View File

@ -2280,7 +2280,7 @@
indicatorOfParameter = 48 ;
}
#10 metre wind gust difference
'10fgdiff' = {
'fgdiff10' = {
table2Version = 200 ;
indicatorOfParameter = 49 ;
}
@ -2620,7 +2620,7 @@
indicatorOfParameter = 122 ;
}
#10 metre wind gust in the last 6 hours difference
'10fg6diff' = {
'fg6diff10' = {
table2Version = 200 ;
indicatorOfParameter = 123 ;
}
@ -2825,17 +2825,17 @@
indicatorOfParameter = 164 ;
}
#10 metre U wind component difference
'10udiff' = {
'udiff10' = {
table2Version = 200 ;
indicatorOfParameter = 165 ;
}
#10 metre V wind component difference
'10vdiff' = {
'vdiff10' = {
table2Version = 200 ;
indicatorOfParameter = 166 ;
}
#2 metre temperature difference
'2tdiff' = {
'difft2' = {
table2Version = 200 ;
indicatorOfParameter = 167 ;
}
@ -3030,7 +3030,7 @@
indicatorOfParameter = 206 ;
}
#10 metre wind speed difference
'10sidiff' = {
'sidiff10' = {
table2Version = 200 ;
indicatorOfParameter = 207 ;
}
@ -3605,12 +3605,12 @@
indicatorOfParameter = 141 ;
}
#100 metre U wind component anomaly
'100ua' = {
'ua100' = {
table2Version = 171 ;
indicatorOfParameter = 6 ;
}
#100 metre V wind component anomaly
'100va' = {
'va100' = {
table2Version = 171 ;
indicatorOfParameter = 7 ;
}
@ -7830,7 +7830,7 @@
indicatorOfParameter = 27 ;
}
#10 metre wind gust in the last 3 hours
'10fg3' = {
'fg310' = {
table2Version = 228 ;
indicatorOfParameter = 28 ;
}
@ -7955,7 +7955,7 @@
indicatorOfParameter = 245 ;
}
#100 metre wind speed
'100si' = {
'si100' = {
table2Version = 228 ;
indicatorOfParameter = 249 ;
}
@ -8200,7 +8200,7 @@
indicatorOfParameter = 48 ;
}
#10 metre wind gust gradient
'10fggrd' = {
'fggrd10' = {
table2Version = 129 ;
indicatorOfParameter = 49 ;
}
@ -8540,7 +8540,7 @@
indicatorOfParameter = 122 ;
}
#10 metre wind gust in the last 6 hours gradient
'10fg6grd' = {
'fg6grd10' = {
table2Version = 129 ;
indicatorOfParameter = 123 ;
}
@ -8745,22 +8745,22 @@
indicatorOfParameter = 164 ;
}
#10 metre U wind component gradient
'10ugrd' = {
'ugrd10' = {
table2Version = 129 ;
indicatorOfParameter = 165 ;
}
#10 metre V wind component gradient
'10vgrd' = {
'vgrd10' = {
table2Version = 129 ;
indicatorOfParameter = 166 ;
}
#2 metre temperature gradient
'2tgrd' = {
'grd2t' = {
table2Version = 129 ;
indicatorOfParameter = 167 ;
}
#2 metre dewpoint temperature gradient
'2dgrd' = {
'grd2d' = {
table2Version = 129 ;
indicatorOfParameter = 168 ;
}
@ -8955,7 +8955,7 @@
indicatorOfParameter = 206 ;
}
#10 metre wind speed gradient
'10sigrd' = {
'sigrd10' = {
table2Version = 129 ;
indicatorOfParameter = 207 ;
}
@ -10830,7 +10830,7 @@
indicatorOfParameter = 255 ;
}
#10 metre wind gust during averaging time
'10fgrea' = {
'fgrea10' = {
table2Version = 160 ;
indicatorOfParameter = 49 ;
}
@ -11065,7 +11065,7 @@
indicatorOfParameter = 243 ;
}
#10 metre wind speed
'10wsrea' = {
'wsrea10' = {
table2Version = 160 ;
indicatorOfParameter = 246 ;
}
@ -11655,7 +11655,7 @@
indicatorOfParameter = 48 ;
}
#10 metre wind gust anomaly
'10fga' = {
'fga10' = {
table2Version = 171 ;
indicatorOfParameter = 49 ;
}
@ -11950,22 +11950,22 @@
indicatorOfParameter = 164 ;
}
#10 metre U wind component anomaly
'10ua' = {
'ua10' = {
table2Version = 171 ;
indicatorOfParameter = 165 ;
}
#10 metre V wind component anomaly
'10va' = {
'va10' = {
table2Version = 171 ;
indicatorOfParameter = 166 ;
}
#2 metre temperature anomaly
'2ta' = {
't2a' = {
table2Version = 171 ;
indicatorOfParameter = 167 ;
}
#2 metre dewpoint temperature anomaly
'2da' = {
'd2a' = {
table2Version = 171 ;
indicatorOfParameter = 168 ;
}
@ -12155,7 +12155,7 @@
indicatorOfParameter = 206 ;
}
#10 metre wind speed anomaly
'10ua' = {
'ua10' = {
table2Version = 171 ;
indicatorOfParameter = 207 ;
}
@ -13125,7 +13125,7 @@
indicatorOfParameter = 229 ;
}
#2 metre dewpoint temperature difference
'2ddiff' = {
'ddiff2' = {
table2Version = 200 ;
indicatorOfParameter = 168 ;
}
@ -15430,12 +15430,12 @@
indicatorOfParameter = 136 ;
}
#100 metre U wind component
'100u' = {
'u100' = {
table2Version = 228 ;
indicatorOfParameter = 246 ;
}
#100 metre V wind component
'100v' = {
'v100' = {
table2Version = 228 ;
indicatorOfParameter = 247 ;
}

View File

@ -1,6 +1,6 @@
# Automatically generated by create_def.pl from database param@wrep-db-misc-prod, do not edit
#10 metre wind gust in the last 3 hours
'10fg3' = {
'fg310' = {
discipline = 0 ;
parameterCategory = 2 ;
parameterNumber = 22 ;

View File

@ -1664,7 +1664,7 @@
parameterNumber = 48 ;
}
#10 metre wind gust difference
'10fgdiff' = {
'fgdiff10' = {
discipline = 192 ;
parameterCategory = 200 ;
parameterNumber = 49 ;
@ -2072,7 +2072,7 @@
parameterNumber = 122 ;
}
#10 metre wind gust in the last 6 hours difference
'10fg6diff' = {
'fg6diff10' = {
discipline = 192 ;
parameterCategory = 200 ;
parameterNumber = 123 ;
@ -2318,19 +2318,19 @@
parameterNumber = 164 ;
}
#10 metre U wind component difference
'10udiff' = {
'udiff10' = {
discipline = 192 ;
parameterCategory = 200 ;
parameterNumber = 165 ;
}
#10 metre V wind component difference
'10vdiff' = {
'vdiff10' = {
discipline = 192 ;
parameterCategory = 200 ;
parameterNumber = 166 ;
}
#2 metre temperature difference
'2tdiff' = {
'difft2' = {
discipline = 192 ;
parameterCategory = 200 ;
parameterNumber = 167 ;
@ -2564,7 +2564,7 @@
parameterNumber = 206 ;
}
#10 metre wind speed difference
'10sidiff' = {
'sidiff10' = {
discipline = 192 ;
parameterCategory = 200 ;
parameterNumber = 207 ;
@ -3032,13 +3032,13 @@
parameterNumber = 141 ;
}
#100 metre U wind component anomaly
'100ua' = {
'ua100' = {
discipline = 192 ;
parameterCategory = 171 ;
parameterNumber = 6 ;
}
#100 metre V wind component anomaly
'100va' = {
'va100' = {
discipline = 192 ;
parameterCategory = 171 ;
parameterNumber = 7 ;
@ -8010,7 +8010,7 @@
lengthOfTimeRange = 3 ;
}
#10 metre wind gust in the last 3 hours
'10fg3' = {
'fg310' = {
discipline = 192 ;
parameterCategory = 228 ;
parameterNumber = 28 ;
@ -8094,7 +8094,7 @@
parameterNumber = 248 ;
}
#100 metre wind speed
'100si' = {
'si100' = {
discipline = 192 ;
parameterCategory = 228 ;
parameterNumber = 249 ;
@ -8460,7 +8460,7 @@
parameterNumber = 48 ;
}
#10 metre wind gust gradient
'10fggrd' = {
'fggrd10' = {
discipline = 192 ;
parameterCategory = 129 ;
parameterNumber = 49 ;
@ -8868,7 +8868,7 @@
parameterNumber = 122 ;
}
#10 metre wind gust in the last 6 hours gradient
'10fg6grd' = {
'fg6grd10' = {
discipline = 192 ;
parameterCategory = 129 ;
parameterNumber = 123 ;
@ -9114,25 +9114,25 @@
parameterNumber = 164 ;
}
#10 metre U wind component gradient
'10ugrd' = {
'ugrd10' = {
discipline = 192 ;
parameterCategory = 129 ;
parameterNumber = 165 ;
}
#10 metre V wind component gradient
'10vgrd' = {
'vgrd10' = {
discipline = 192 ;
parameterCategory = 129 ;
parameterNumber = 166 ;
}
#2 metre temperature gradient
'2tgrd' = {
'grd2t' = {
discipline = 192 ;
parameterCategory = 129 ;
parameterNumber = 167 ;
}
#2 metre dewpoint temperature gradient
'2dgrd' = {
'grd2d' = {
discipline = 192 ;
parameterCategory = 129 ;
parameterNumber = 168 ;
@ -9366,7 +9366,7 @@
parameterNumber = 206 ;
}
#10 metre wind speed gradient
'10sigrd' = {
'sigrd10' = {
discipline = 192 ;
parameterCategory = 129 ;
parameterNumber = 207 ;
@ -11632,7 +11632,7 @@
parameterNumber = 255 ;
}
#10 metre wind gust during averaging time
'10fgrea' = {
'fgrea10' = {
discipline = 192 ;
parameterCategory = 160 ;
parameterNumber = 49 ;
@ -11914,7 +11914,7 @@
parameterNumber = 243 ;
}
#10 metre wind speed
'10wsrea' = {
'wsrea10' = {
discipline = 192 ;
parameterCategory = 160 ;
parameterNumber = 246 ;
@ -12622,7 +12622,7 @@
parameterNumber = 48 ;
}
#10 metre wind gust anomaly
'10fga' = {
'fga10' = {
discipline = 192 ;
parameterCategory = 171 ;
parameterNumber = 49 ;
@ -12976,25 +12976,25 @@
parameterNumber = 164 ;
}
#10 metre U wind component anomaly
'10ua' = {
'ua10' = {
discipline = 192 ;
parameterCategory = 171 ;
parameterNumber = 165 ;
}
#10 metre V wind component anomaly
'10va' = {
'va10' = {
discipline = 192 ;
parameterCategory = 171 ;
parameterNumber = 166 ;
}
#2 metre temperature anomaly
'2ta' = {
't2a' = {
discipline = 192 ;
parameterCategory = 171 ;
parameterNumber = 167 ;
}
#2 metre dewpoint temperature anomaly
'2da' = {
'd2a' = {
discipline = 192 ;
parameterCategory = 171 ;
parameterNumber = 168 ;
@ -13222,7 +13222,7 @@
parameterNumber = 206 ;
}
#10 metre wind speed anomaly
'10ua' = {
'ua10' = {
discipline = 192 ;
parameterCategory = 171 ;
parameterNumber = 207 ;
@ -14386,7 +14386,7 @@
parameterNumber = 229 ;
}
#2 metre dewpoint temperature difference
'2ddiff' = {
'ddiff2' = {
discipline = 192 ;
parameterCategory = 200 ;
parameterNumber = 168 ;
@ -17273,13 +17273,13 @@
parameterNumber = 136 ;
}
#100 metre U wind component
'100u' = {
'u100' = {
discipline = 192 ;
parameterCategory = 228 ;
parameterNumber = 246 ;
}
#100 metre V wind component
'100v' = {
'v100' = {
discipline = 192 ;
parameterCategory = 228 ;
parameterNumber = 247 ;

View File

@ -518,7 +518,7 @@ static void save_all_requests(FILE *f, const request *r)
/* Not used for the moment
static void print_one_request(const request *r)
{
save_one_request(stdout, r);
save_one_request(stdout, r);
}
*/
@ -601,11 +601,11 @@ static err handle_to_request(request *r, grib_handle* g)
}
/*
Assert(grib_get_long(g, "validityDate", &l ) == 0);
set_value(r, "validityDate", "%ld", l);
Assert(grib_get_long(g, "validityDate", &l ) == 0);
set_value(r, "validityDate", "%ld", l);
Assert(grib_get_long(g, "validityTime", &l ) == 0);
set_value(r, "validityTime", "%ld", l);
Assert(grib_get_long(g, "validityTime", &l ) == 0);
set_value(r, "validityTime", "%ld", l);
*/
len = sizeof(value);
@ -734,7 +734,7 @@ typedef struct fieldset {
#define MISSING_FIELD(f) ((f)->missing)
#define FIELD_HAS_BITMAP(f) ((f)->bitmap)
#define FASTNEW(type) (type*)calloc(sizeof(type),1)
#define FASTNEW(type) (type*)calloc(sizeof(type),1)
#define grib_context_free(ctx,x) grib_context_free(ctx,x)
*/
@ -1623,7 +1623,7 @@ static hypercube *new_hypercube(const request *r)
memset(h->set, 1, count);
/* This is expensive, but makes the iterator with only
those parameters found as axis */
those parameters found as axis */
h->iterator = empty_request(0);
for(n = 0; n < NUMBER(axis); ++n)
if((val = get_value(h->r, axis[n].name, 0)) != NULL)
@ -2401,11 +2401,11 @@ static void scale_bitmap(double *vals, long n, void *data, dataset_t *subset)
nc_type nctype = subset->att.nctype;
/*
if(!subset->bitmap)
{
grib_context_log(ctx,GRIB_LOG_DEBUG,"No scale of bitmap required");
return;
}
if(!subset->bitmap)
{
grib_context_log(ctx,GRIB_LOG_DEBUG,"No scale of bitmap required");
return;
}
*/
switch(nctype)
@ -2470,11 +2470,11 @@ static void scale(double *vals, long n, void *data, dataset_t *g)
double add_offset = g->add_offset;
/*
if(!subset->scale)
{
grib_context_log(ctx,GRIB_LOG_DEBUG,"No scale required");
return;
}
if(!subset->scale)
{
grib_context_log(ctx,GRIB_LOG_DEBUG,"No scale required");
return;
}
*/
switch(nctype)
@ -3127,7 +3127,7 @@ static void paramtable(const char *p, long *param, long *table, boolean paramIdM
*table = atol(++p);
/* This version is grib_api... It should rely on what grib_api returns,
either param.table or paramId
either param.table or paramId
*/
if(paramIdMode)
{
@ -3175,7 +3175,7 @@ static void find_nc_attributes(const request *subset_r, const request *user_r, n
request *cfg = (request *) config_r;
boolean is_param = strcmp(split, "param") == 0;
/* Only use this parameter in the name if there is more
than one value in the original request or if param */
than one value in the original request or if param */
boolean setname = ((count_values(data_r, split) > 1) || (is_param && set_param_as_name));
while(cfg)
@ -3197,7 +3197,7 @@ static void find_nc_attributes(const request *subset_r, const request *user_r, n
paramtable(dataval, &dataparam, &datatable, false);
/* If it is not param and they're EXACTLY equal or
being param, they're the same parameter and table */
being param, they're the same parameter and table */
if((!is_param && (strcmp(dataval, cfgval) == 0)) || (is_param && (dataparam == cfgparam) && (datatable == cfgtable || (datatable == 0 && (cfgtable == 128)))))
{
const char *val = NULL;
@ -3252,11 +3252,11 @@ static void find_nc_attributes(const request *subset_r, const request *user_r, n
}
}
/* NetCDF does not allow variable names to start with a digit */
if(!isalpha(att->name[0]))
{
char buf[1024];
sprintf(buf,"v%s",att->name);
sprintf(buf,"p%s",att->name);
strcpy(att->name,buf);
}
@ -3835,8 +3835,8 @@ int grib_tool_finalise_action(grib_runtime_options* options)
printf("%s: Found %d GRIB field%s in %d file%s.\n", grib_tool_name, fs->count, fs->count>1?"s":"", files, files > 1 ? "s" : "");
/*
grib_context_log(ctx, GRIB_LOG_INFO, "Request representing %d fields ", fs->count);
print_all_requests(data_r);
grib_context_log(ctx, GRIB_LOG_INFO, "Request representing %d fields ", fs->count);
print_all_requests(data_r);
*/
/* Split the SOURCE from request into as many datasets as specified */