Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
Méso-NH code
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RODIER Quentin
Méso-NH code
Commits
624b9bed
Commit
624b9bed
authored
4 years ago
by
WAUTELET Philippe
Browse files
Options
Downloads
Patches
Plain Diff
Philippe 25/09/2020: add new parameters for dimensions
parent
ac64663d
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/LIB/SURCOUCHE/src/modd_field.f90
+41
-24
41 additions, 24 deletions
src/LIB/SURCOUCHE/src/modd_field.f90
src/LIB/SURCOUCHE/src/mode_io_tools_nc4.f90
+29
-0
29 additions, 0 deletions
src/LIB/SURCOUCHE/src/mode_io_tools_nc4.f90
with
70 additions
and
24 deletions
src/LIB/SURCOUCHE/src/modd_field.f90
+
41
−
24
View file @
624b9bed
...
@@ -16,7 +16,7 @@ module modd_field
...
@@ -16,7 +16,7 @@ module modd_field
use
modd_parameters
,
only
:
NGRIDUNKNOWN
,
NMNHNAMELGTMAX
,
NSTDNAMELGTMAX
use
modd_parameters
,
only
:
NGRIDUNKNOWN
,
NMNHNAMELGTMAX
,
NSTDNAMELGTMAX
use
modd_type_date
,
only
:
date_time
use
modd_type_date
,
only
:
date_time
#if
def
ined(
MNH_IOCDF4
)
#ifdef
MNH_IOCDF4
use
NETCDF
,
only
:
NF90_FILL_INT
,
NF90_FILL_REAL
use
NETCDF
,
only
:
NF90_FILL_INT
,
NF90_FILL_REAL
#endif
#endif
...
@@ -27,31 +27,48 @@ INTEGER,PARAMETER :: MAXFIELDS = 250
...
@@ -27,31 +27,48 @@ INTEGER,PARAMETER :: MAXFIELDS = 250
INTEGER
,
PARAMETER
::
TYPEUNDEF
=
-1
,
TYPEINT
=
1
,
TYPELOG
=
2
,
TYPEREAL
=
3
,
TYPECHAR
=
4
,
TYPEDATE
=
5
INTEGER
,
PARAMETER
::
TYPEUNDEF
=
-1
,
TYPEINT
=
1
,
TYPELOG
=
2
,
TYPEREAL
=
3
,
TYPECHAR
=
4
,
TYPEDATE
=
5
!
!
integer
,
parameter
::
NMNHDIM_UNKNOWN
=
-2
integer
,
parameter
::
NMNHDIM_UNKNOWN
=
-2
integer
,
parameter
::
NMNHDIM_ONE
=
10
integer
,
parameter
::
NMNHDIM_ONE
=
10
integer
,
parameter
::
NMNHDIM_COMPLEX
=
11
integer
,
parameter
::
NMNHDIM_COMPLEX
=
11
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NI
=
20
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NJ
=
21
integer
,
parameter
::
NMNHDIM_NI
=
21
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NI_U
=
22
integer
,
parameter
::
NMNHDIM_NJ
=
22
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NJ_U
=
23
integer
,
parameter
::
NMNHDIM_NI_U
=
23
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NI_V
=
24
integer
,
parameter
::
NMNHDIM_NJ_U
=
24
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NJ_V
=
25
integer
,
parameter
::
NMNHDIM_NI_V
=
25
integer
,
parameter
::
NMNHDIM_BUDGET_CART_LEVEL
=
26
integer
,
parameter
::
NMNHDIM_NJ_V
=
26
integer
,
parameter
::
NMNHDIM_BUDGET_CART_LEVEL_W
=
27
integer
,
parameter
::
NMNHDIM_LEVEL
=
27
integer
,
parameter
::
NMNHDIM_BUDGET_MASK_LEVEL
=
30
integer
,
parameter
::
NMNHDIM_LEVEL_W
=
28
integer
,
parameter
::
NMNHDIM_BUDGET_MASK_LEVEL_W
=
31
integer
,
parameter
::
NMNHDIM_TIME
=
29
integer
,
parameter
::
NMNHDIM_BUDGET_MASK_TIME
=
32
integer
,
parameter
::
NMNHDIM_BUDGET_MASK_NBUMASK
=
33
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NI
=
30
integer
,
parameter
::
NMNHDIM_BUDGET_LES_TIME
=
40
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NJ
=
31
integer
,
parameter
::
NMNHDIM_BUDGET_LES_AVG_TIME
=
41
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NI_U
=
32
integer
,
parameter
::
NMNHDIM_BUDGET_LES_LEVEL
=
42
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NJ_U
=
33
integer
,
parameter
::
NMNHDIM_BUDGET_LES_SV
=
43
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NI_V
=
34
integer
,
parameter
::
NMNHDIM_BUDGET_LES_MASK
=
44
integer
,
parameter
::
NMNHDIM_BUDGET_CART_NJ_V
=
35
integer
,
parameter
::
NMNHDIM_SPECTRA_2PTS_NI
=
50
integer
,
parameter
::
NMNHDIM_BUDGET_CART_LEVEL
=
36
integer
,
parameter
::
NMNHDIM_SPECTRA_2PTS_NJ
=
51
integer
,
parameter
::
NMNHDIM_BUDGET_CART_LEVEL_W
=
37
integer
,
parameter
::
NMNHDIM_SPECTRA_SPEC_NI
=
52
integer
,
parameter
::
NMNHDIM_SPECTRA_SPEC_NJ
=
53
integer
,
parameter
::
NMNHDIM_BUDGET_MASK_LEVEL
=
40
integer
,
parameter
::
NMNHDIM_SPECTRA_LEVEL
=
54
integer
,
parameter
::
NMNHDIM_BUDGET_MASK_LEVEL_W
=
41
integer
,
parameter
::
NMNHDIM_BUDGET_MASK_TIME
=
42
integer
,
parameter
::
NMNHDIM_BUDGET_MASK_NBUMASK
=
43
integer
,
parameter
::
NMNHDIM_BUDGET_LES_TIME
=
50
integer
,
parameter
::
NMNHDIM_BUDGET_LES_AVG_TIME
=
51
integer
,
parameter
::
NMNHDIM_BUDGET_LES_LEVEL
=
52
integer
,
parameter
::
NMNHDIM_BUDGET_LES_SV
=
53
integer
,
parameter
::
NMNHDIM_BUDGET_LES_MASK
=
54
integer
,
parameter
::
NMNHDIM_SPECTRA_2PTS_NI
=
60
integer
,
parameter
::
NMNHDIM_SPECTRA_2PTS_NJ
=
61
integer
,
parameter
::
NMNHDIM_SPECTRA_SPEC_NI
=
62
integer
,
parameter
::
NMNHDIM_SPECTRA_SPEC_NJ
=
63
integer
,
parameter
::
NMNHDIM_SPECTRA_LEVEL
=
64
integer
,
parameter
::
NMNHDIM_BUDGET_NGROUPS
=
100
! This is not a true dimension
integer
,
parameter
::
NMNHDIM_BUDGET_NGROUPS
=
100
! This is not a true dimension
integer
,
parameter
::
NMNHDIM_UNUSED
=
200
integer
,
parameter
::
NMNHDIM_UNUSED
=
200
!
!
TYPE
TFIELDPTR_C0D
TYPE
TFIELDPTR_C0D
...
@@ -133,7 +150,7 @@ type, abstract :: tfield_metadata_base
...
@@ -133,7 +150,7 @@ type, abstract :: tfield_metadata_base
INTEGER
::
NDIMS
=
0
!Number of dimensions
INTEGER
::
NDIMS
=
0
!Number of dimensions
INTEGER
,
DIMENSION
(
NMNHMAXDIMS
)
::
NDIMLIST
=
NMNHDIM_UNKNOWN
! List of dimensions of the data field
INTEGER
,
DIMENSION
(
NMNHMAXDIMS
)
::
NDIMLIST
=
NMNHDIM_UNKNOWN
! List of dimensions of the data field
!
!
#if
def
ined(
MNH_IOCDF4
)
#ifdef
MNH_IOCDF4
INTEGER
::
NFILLVALUE
=
NF90_FILL_INT
!Fill value for integer fields
INTEGER
::
NFILLVALUE
=
NF90_FILL_INT
!Fill value for integer fields
REAL
::
XFILLVALUE
=
NF90_FILL_REAL
!Fill value for real fields
REAL
::
XFILLVALUE
=
NF90_FILL_REAL
!Fill value for real fields
!NF90_FILL_REAL is the default fill value
!NF90_FILL_REAL is the default fill value
...
...
This diff is collapsed.
Click to expand it.
src/LIB/SURCOUCHE/src/mode_io_tools_nc4.f90
+
29
−
0
View file @
624b9bed
...
@@ -446,6 +446,8 @@ END SUBROUTINE IO_Iocdf_dealloc_nc4
...
@@ -446,6 +446,8 @@ END SUBROUTINE IO_Iocdf_dealloc_nc4
SUBROUTINE
IO_Vdims_fill_nc4
(
TPFILE
,
TPFIELD
,
KSHAPE
,
KVDIMS
)
SUBROUTINE
IO_Vdims_fill_nc4
(
TPFILE
,
TPFIELD
,
KSHAPE
,
KVDIMS
)
use
modd_field
,
only
:
NMNHDIM_UNKNOWN
,
NMNHDIM_ONE
,
NMNHDIM_COMPLEX
,
&
use
modd_field
,
only
:
NMNHDIM_UNKNOWN
,
NMNHDIM_ONE
,
NMNHDIM_COMPLEX
,
&
NMNHDIM_NI
,
NMNHDIM_NJ
,
NMNHDIM_NI_U
,
NMNHDIM_NJ_U
,
NMNHDIM_NI_V
,
NMNHDIM_NJ_V
,
&
NMNHDIM_LEVEL
,
NMNHDIM_LEVEL_W
,
NMNHDIM_TIME
,
&
NMNHDIM_BUDGET_CART_NI
,
NMNHDIM_BUDGET_CART_NJ
,
NMNHDIM_BUDGET_CART_NI_U
,
&
NMNHDIM_BUDGET_CART_NI
,
NMNHDIM_BUDGET_CART_NJ
,
NMNHDIM_BUDGET_CART_NI_U
,
&
NMNHDIM_BUDGET_CART_NJ_U
,
NMNHDIM_BUDGET_CART_NI_V
,
NMNHDIM_BUDGET_CART_NJ_V
,
&
NMNHDIM_BUDGET_CART_NJ_U
,
NMNHDIM_BUDGET_CART_NI_V
,
NMNHDIM_BUDGET_CART_NJ_V
,
&
NMNHDIM_BUDGET_CART_LEVEL
,
NMNHDIM_BUDGET_CART_LEVEL_W
,
&
NMNHDIM_BUDGET_CART_LEVEL
,
NMNHDIM_BUDGET_CART_LEVEL_W
,
&
...
@@ -515,6 +517,33 @@ if ( Any( tpfield%ndimlist(:) /= NMNHDIM_UNKNOWN ) ) then
...
@@ -515,6 +517,33 @@ if ( Any( tpfield%ndimlist(:) /= NMNHDIM_UNKNOWN ) ) then
case
(
NMNHDIM_COMPLEX
)
case
(
NMNHDIM_COMPLEX
)
ydimname
=
'real_imaginary'
ydimname
=
'real_imaginary'
case
(
NMNHDIM_NI
)
ydimname
=
'ni'
case
(
NMNHDIM_NJ
)
ydimname
=
'nj'
case
(
NMNHDIM_NI_U
)
ydimname
=
'ni_u'
case
(
NMNHDIM_NJ_U
)
ydimname
=
'nj_u'
case
(
NMNHDIM_NI_V
)
ydimname
=
'ni_v'
case
(
NMNHDIM_NJ_V
)
ydimname
=
'nj_v'
case
(
NMNHDIM_LEVEL
)
ydimname
=
'level'
case
(
NMNHDIM_LEVEL_W
)
ydimname
=
'level_w'
case
(
NMNHDIM_TIME
)
ydimname
=
'time'
case
(
NMNHDIM_BUDGET_CART_NI
)
case
(
NMNHDIM_BUDGET_CART_NI
)
ydimname
=
'cart_ni'
ydimname
=
'cart_ni'
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment