forked from szy21/pycles_GCM
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathGrid.pxd
More file actions
102 lines (72 loc) · 1.86 KB
/
Grid.pxd
File metadata and controls
102 lines (72 loc) · 1.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
cimport ParallelMPI
cimport Restart
cdef extern from "grid.h":
struct DimStruct:
int dims
int [3] n
int [3] ng
int [3] nl
int [3] nlg
int [3] indx_lo_g
int [3] indx_lo
int npd
int npl
int npg
int gw
int [3] nbuffer
int [3] ghosted_stride
double [3] dx
double [3] dxi
double zp_half_0
double zp_0
double * met;
double * met_half;
double * imet;
double * imet_half;
double * metl;
double * metl_half;
double * imetl;
double * imetl_half
double * dzpl_half
double * dzpl
double * zpl_half
double * zpl
cdef class Grid:
cdef:
DimStruct dims
bint stretch
double stretch_scale
double [:] x
double [:] x_half
double [:] y
double [:] y_half
double [:] z
double [:] z_half
double [:] xl
double [:] xl_half
double [:] yl
double [:] yl_half
double [:] zl
double [:] zl_half
double [:] zp
double [:] zp_half
double [:] zpl
double [:] zpl_half
double [:] dzp
double [:] dzp_half
double [:] dzpl
double [:] dzpl_half
double [:] met;
double [:] met_half;
double [:] imet;
double [:] imet_half;
double [:] metl;
double [:] metl_half;
double [:] imetl;
double [:] imetl_half;
void compute_global_dims(self)
void compute_local_dims(self,ParallelMPI.ParallelMPI Parallel)
void compute_coordinates(self)
cpdef extract_local(self, double [:] global_array, int dim)
cpdef extract_local_ghosted(self, double [:] global_array, int dim)
cpdef restart(self, Restart.Restart Re)