Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
mpim-sw
cdo
Commits
c6c1c852
Commit
c6c1c852
authored
Mar 26, 2008
by
Uwe Schulzweida
Browse files
cdilib update
parent
89a0c020
Changes
4
Hide whitespace changes
Inline
Side-by-side
src/Copy.c
View file @
c6c1c852
...
...
@@ -2,7 +2,7 @@
This file is part of CDO. CDO is a collection of Operators to
manipulate and analyse Climate model Data.
Copyright (C) 2003-200
7
Uwe Schulzweida, Uwe.Schulzweida@zmaw.de
Copyright (C) 2003-200
8
Uwe Schulzweida, Uwe.Schulzweida@zmaw.de
See COPYING file for copying and redistribution conditions.
This program is free software; you can redistribute it and/or modify
...
...
src/Writegrid.c
View file @
c6c1c852
...
...
@@ -2,7 +2,7 @@
This file is part of CDO. CDO is a collection of Operators to
manipulate and analyse Climate model Data.
Copyright (C) 2003-200
7
Uwe Schulzweida, Uwe.Schulzweida@zmaw.de
Copyright (C) 2003-200
8
Uwe Schulzweida, Uwe.Schulzweida@zmaw.de
See COPYING file for copying and redistribution conditions.
This program is free software; you can redistribute it and/or modify
...
...
src/grid.c
View file @
c6c1c852
...
...
@@ -1723,6 +1723,7 @@ void writeNCgrid(const char *gridfile, int gridID, int *grid_imask)
int
gridtype
;
int
gridsize
;
double
*
vals
;
char
units
[
128
];
gridtype
=
gridInqType
(
gridID
);
...
...
@@ -1746,6 +1747,14 @@ void writeNCgrid(const char *gridfile, int gridID, int *grid_imask)
{
}
gridInqYunits
(
gridID
,
units
);
if
(
strncmp
(
units
,
"degrees"
,
7
)
==
0
)
units
[
7
]
=
0
;
else
if
(
strncmp
(
units
,
"radian"
,
6
)
==
0
)
units
[
6
]
=
0
;
else
cdoWarning
(
"Unknown units supplied for grid!"
);
/* create netCDF dataset for this grid */
nce
(
nc_create
(
gridfile
,
NC_CLOBBER
,
&
nc_file_id
));
...
...
@@ -1791,14 +1800,14 @@ void writeNCgrid(const char *gridfile, int gridID, int *grid_imask)
nce
(
nc_def_var
(
nc_file_id
,
"grid_center_lat"
,
xtype
,
ndims
,
nc_dims_id
,
&
nc_gridlat_id
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridlat_id
,
"units"
,
7
,
"degrees"
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridlat_id
,
"units"
,
strlen
(
units
),
units
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridlat_id
,
"bounds"
,
15
,
"grid_corner_lat"
));
/* define grid center longitude array */
nce
(
nc_def_var
(
nc_file_id
,
"grid_center_lon"
,
xtype
,
ndims
,
nc_dims_id
,
&
nc_gridlon_id
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridlon_id
,
"units"
,
7
,
"degrees"
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridlon_id
,
"units"
,
strlen
(
units
),
units
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridlon_id
,
"bounds"
,
15
,
"grid_corner_lon"
));
/* define grid mask */
...
...
@@ -1826,13 +1835,13 @@ void writeNCgrid(const char *gridfile, int gridID, int *grid_imask)
nce
(
nc_def_var
(
nc_file_id
,
"grid_corner_lat"
,
xtype
,
ndims
,
nc_dims_id
,
&
nc_gridclat_id
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridclat_id
,
"units"
,
7
,
"degrees"
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridclat_id
,
"units"
,
strlen
(
units
),
units
));
/* define grid corner longitude array */
nce
(
nc_def_var
(
nc_file_id
,
"grid_corner_lon"
,
xtype
,
ndims
,
nc_dims_id
,
&
nc_gridclon_id
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridclon_id
,
"units"
,
7
,
"degrees"
));
nce
(
nc_put_att_text
(
nc_file_id
,
nc_gridclon_id
,
"units"
,
strlen
(
units
),
units
));
/* end definition stage */
...
...
src/modules.c
View file @
c6c1c852
...
...
@@ -364,7 +364,7 @@ void *Wct(void *argument);
#define VertintOperators {"ml2pl", "ml2hl"}
#define VertstatOperators {"vertmin", "vertmax", "vertsum", "vertmean", "vertavg", "vertvar", "vertstd"}
#define WindOperators {"uv2dv", "uv2dvl", "dv2uv", "dv2uvl", "dv2ps"}
#define WritegridOperators {"writegrid"
, "gridarea"
}
#define WritegridOperators {"writegrid"}
#define WriterandomOperators {"writerandom"}
#define YhourstatOperators {"yhourmin", "yhourmax", "yhoursum", "yhourmean", "yhouravg", "yhourvar", "yhourstd"}
/* RQ */
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment