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
3e1abfed
Commit
3e1abfed
authored
3 years ago
by
tomrink
Browse files
Options
Downloads
Patches
Plain Diff
minor stuff
parent
8a365ffc
No related branches found
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/deeplearning/icing_cnn.py
+7
-6
7 additions, 6 deletions
modules/deeplearning/icing_cnn.py
with
7 additions
and
6 deletions
modules/deeplearning/icing_cnn.py
+
7
−
6
View file @
3e1abfed
...
@@ -2,7 +2,7 @@ import tensorflow as tf
...
@@ -2,7 +2,7 @@ import tensorflow as tf
import
tensorflow_addons
as
tfa
import
tensorflow_addons
as
tfa
from
util.setup
import
logdir
,
modeldir
,
cachepath
,
now
from
util.setup
import
logdir
,
modeldir
,
cachepath
,
now
from
util.util
import
homedir
,
EarlyStop
,
normalize
,
make_for_full_domain_predict
from
util.util
import
homedir
,
EarlyStop
,
normalize
,
make_for_full_domain_predict
from
util.geos_nav
import
GEOSNavigation
from
util.geos_nav
import
GEOSNavigation
,
get_navigation
import
os
,
datetime
import
os
,
datetime
import
numpy
as
np
import
numpy
as
np
...
@@ -958,7 +958,7 @@ def run_restore_static(filename_l1b, filename_l2, ckpt_dir_s_path):
...
@@ -958,7 +958,7 @@ def run_restore_static(filename_l1b, filename_l2, ckpt_dir_s_path):
return
cm_avg
return
cm_avg
def
run_evaluate_static
(
filename
,
ckpt_dir_s_path
,
prob_thresh
=
0.5
,
domain
=
'
FD
'
):
def
run_evaluate_static
(
filename
,
ckpt_dir_s_path
,
prob_thresh
=
0.5
,
satellite
=
'
GOES16
'
,
domain
=
'
FD
'
):
data_dct
,
ll
,
cc
=
make_for_full_domain_predict
(
filename
,
name_list
=
train_params
,
domain
=
domain
)
data_dct
,
ll
,
cc
=
make_for_full_domain_predict
(
filename
,
name_list
=
train_params
,
domain
=
domain
)
ckpt_dir_s
=
os
.
listdir
(
ckpt_dir_s_path
)
ckpt_dir_s
=
os
.
listdir
(
ckpt_dir_s_path
)
prob_s
=
[]
prob_s
=
[]
...
@@ -992,10 +992,11 @@ def run_evaluate_static(filename, ckpt_dir_s_path, prob_thresh=0.5, domain='FD')
...
@@ -992,10 +992,11 @@ def run_evaluate_static(filename, ckpt_dir_s_path, prob_thresh=0.5, domain='FD')
ice_cc
=
cc
[
ice_mask
]
ice_cc
=
cc
[
ice_mask
]
ice_ll
=
ll
[
ice_mask
]
ice_ll
=
ll
[
ice_mask
]
if
domain
==
'
CONUS
'
:
# if domain == 'CONUS':
nav
=
GEOSNavigation
(
sub_lon
=-
75.0
,
CFAC
=
5.6E-05
,
COFF
=-
0.101332
,
LFAC
=-
5.6E-05
,
LOFF
=
0.128212
,
num_elems
=
2500
,
num_lines
=
1500
)
# nav = GEOSNavigation(sub_lon=-75.0, CFAC=5.6E-05, COFF=-0.101332, LFAC=-5.6E-05, LOFF=0.128212, num_elems=2500, num_lines=1500)
elif
domain
==
'
FD
'
:
# elif domain == 'FD':
nav
=
GEOSNavigation
(
sub_lon
=-
75.0
,
CFAC
=
5.6E-05
,
COFF
=-
0.151844
,
LFAC
=-
5.6E-05
,
LOFF
=
0.151844
,
num_elems
=
5424
,
num_lines
=
5424
)
# nav = GEOSNavigation(sub_lon=-75.0, CFAC=5.6E-05, COFF=-0.151844, LFAC=-5.6E-05, LOFF=0.151844, num_elems=5424, num_lines=5424)
nav
=
get_navigation
(
satellite
,
domain
)
ice_lons
=
[]
ice_lons
=
[]
ice_lats
=
[]
ice_lats
=
[]
for
k
in
range
(
ice_cc
.
shape
[
0
]):
for
k
in
range
(
ice_cc
.
shape
[
0
]):
...
...
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