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
libcdi
Commits
12fee661
Commit
12fee661
authored
Oct 19, 2012
by
Uwe Schulzweida
Browse files
cleanup GRIB1 ensemble information
parent
4cc76609
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/stream_cgribex.c
View file @
12fee661
...
...
@@ -404,8 +404,13 @@ void cgribexAddRecord(int streamID, int param, int *isec1, int *isec2, double *f
varDefCompType
(
varID
,
comptype
);
if
(
isec1
[
36
]
)
varDefEnsembleInfo
(
varID
,
isec1
[
37
],
isec1
[
38
],
isec1
[
39
]);
if
(
ISEC1_LocalFLag
)
{
if
(
ISEC1_CenterID
==
78
&&
isec1
[
36
]
==
253
)
// DWD local extension
varDefEnsembleInfo
(
varID
,
isec1
[
54
],
isec1
[
53
],
isec1
[
52
]);
else
if
(
ISEC1_CenterID
==
252
&&
isec1
[
36
]
==
1
)
// MPIM local extension
varDefEnsembleInfo
(
varID
,
isec1
[
38
],
isec1
[
39
],
isec1
[
37
]);
}
if
(
lmv
)
varDefMissval
(
varID
,
FSEC3_MissVal
);
...
...
@@ -2152,9 +2157,6 @@ void cgribexDefaultSec4(int *isec4)
static
void
cgribexDefEnsembleVar
(
int
*
isec1
,
int
vlistID
,
int
varID
)
{
/* int *ensID, int *ensCount, int *forecast_type; */
int
ensID
,
ensCount
,
forecast_type
;
/* For Ensemble info */
...
...
@@ -2165,22 +2167,17 @@ void cgribexDefEnsembleVar(int *isec1, int vlistID, int varID)
//Put2Byte(isec1[38]); /* individual ensemble member */
//Put2Byte(isec1[39]); /* number of forecasts in ensemble */
if
(
!
vlistInqVarEnsemble
(
vlistID
,
varID
,
&
ensID
,
&
ensCount
,
&
forecast_type
)
)
if
(
!
vlistInqVarEnsemble
(
vlistID
,
varID
,
&
ensID
,
&
ensCount
,
&
forecast_type
)
)
{
ISEC1_LocalFLag
=
1
;
isec1
[
36
]
=
1
;
isec1
[
37
]
=
forecast_type
;
isec1
[
38
]
=
ensID
;
isec1
[
39
]
=
ensCount
;
#ifdef DBG
if
(
DBG
)
{
fprintf
(
stderr
,
"cgribexDefEnsembleVar :
\n
EnsID %d
\n
Enscount %d
\n
Forecast init type %d
\n
"
,
ensID
,
ensCount
,
forecast_type
);
}
#endif
if
(
ISEC1_CenterID
==
252
)
{
ISEC1_LocalFLag
=
1
;
isec1
[
36
]
=
1
;
isec1
[
37
]
=
forecast_type
;
isec1
[
38
]
=
ensID
;
isec1
[
39
]
=
ensCount
;
}
}
}
#endif
...
...
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