Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
python
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
Container 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
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Tom Rink
python
Commits
bfde6dba
Commit
bfde6dba
authored
1 year ago
by
tomrink
Browse files
Options
Downloads
Patches
Plain Diff
snapshot...
parent
eb25e054
Branches
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
modules/util/util.py
+13
-13
13 additions, 13 deletions
modules/util/util.py
with
13 additions
and
13 deletions
modules/util/util.py
+
13
−
13
View file @
bfde6dba
...
...
@@ -1024,8 +1024,8 @@ def prepare_evaluate(h5f, name_list, satellite='GOES16', domain='FD', res_fac=1,
w_y
=
16
i_0
=
0
j_0
=
0
s_x
=
int
(
w_x
/
res_fac
)
s_y
=
int
(
w_y
/
res_fac
)
s_x
=
w_x
/
/
res_fac
s_y
=
w_y
/
/
res_fac
geos
,
xlen
,
xmin
,
xmax
,
ylen
,
ymin
,
ymax
=
get_cartopy_crs
(
satellite
,
domain
)
if
satellite
==
'
H08
'
:
...
...
@@ -1039,16 +1039,16 @@ def prepare_evaluate(h5f, name_list, satellite='GOES16', domain='FD', res_fac=1,
i_0
=
taiwan_i0
j_0
=
taiwan_j0
n_x
=
int
(
xlen
/
s_x
)
-
1
n_y
=
int
(
ylen
/
s_y
)
-
1
r_x
=
xlen
-
(
n_x
*
s_x
)
x_d
=
0
if
r_x
>=
w_x
else
int
((
w_x
-
r_x
)
/
s_x
)
n_x
-=
x_d
n_x
=
(
xlen
//
s_x
)
n_y
=
(
ylen
//
s_y
)
r_y
=
ylen
-
(
n_y
*
s_y
)
y_d
=
0
if
r_y
>=
w_y
else
int
((
w_y
-
r_y
)
/
s_y
)
n_y
-=
y_d
# r_x = xlen - (n_x * s_x)
# x_d = 0 if r_x >= w_x else int((w_x - r_x)/s_x)
# n_x -= x_d
#
# r_y = ylen - (n_y * s_y)
# y_d = 0 if r_y >= w_y else int((w_y - r_y)/s_y)
# n_y -= y_d
ll
=
[(
offset
+
j_0
)
+
j
*
s_y
for
j
in
range
(
n_y
)]
cc
=
[(
offset
+
i_0
)
+
i
*
s_x
for
i
in
range
(
n_x
)]
...
...
@@ -1069,8 +1069,8 @@ def prepare_evaluate(h5f, name_list, satellite='GOES16', domain='FD', res_fac=1,
solzen
=
get_grid_values
(
h5f
,
'
solar_zenith_angle
'
,
j_0
,
i_0
,
None
,
num_j
=
ylen
,
num_i
=
xlen
)
satzen
=
get_grid_values
(
h5f
,
'
sensor_zenith_angle
'
,
j_0
,
i_0
,
None
,
num_j
=
ylen
,
num_i
=
xlen
)
solzen
=
solzen
[
0
:
(
n_y
-
1
)
*
s_y
:
s_y
,
0
:
(
n_x
-
1
)
*
s_x
:
s_x
]
satzen
=
satzen
[
0
:
(
n_y
-
1
)
*
s_y
:
s_y
,
0
:
(
n_x
-
1
)
*
s_x
:
s_x
]
solzen
=
solzen
[
0
:
n_y
*
s_y
:
s_y
,
0
:
n_x
*
s_x
:
s_x
]
satzen
=
satzen
[
0
:
n_y
*
s_y
:
s_y
,
0
:
n_x
*
s_x
:
s_x
]
return
grd_dct_n
,
solzen
,
satzen
,
ll
,
cc
...
...
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