Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
MVCM
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
Paolo Veglio
MVCM
Commits
db130a1c
Commit
db130a1c
authored
7 months ago
by
Paolo Veglio
Browse files
Options
Downloads
Patches
Plain Diff
new entrypoint functions for delivery
parent
b3950f85
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
run_prep.py
+109
-0
109 additions, 0 deletions
run_prep.py
run_tests.py
+54
-0
54 additions, 0 deletions
run_tests.py
with
163 additions
and
0 deletions
run_prep.py
0 → 100644
+
109
−
0
View file @
db130a1c
"""
Main call for MVCM.
"""
import
argparse
from
pkg_resources
import
get_distribution
# type: ignore
from
mvcm.main_prep_only
import
main
if
__name__
==
"
__main__
"
:
_VERSION
=
get_distribution
(
"
mvcm
"
).
version
parser
=
argparse
.
ArgumentParser
(
prog
=
"
MVCM
"
,
description
=
""
)
parser
.
add_argument
(
"
--satellite
"
,
help
=
"
satellite name, not case-sensitive. Available options: [snpp, ]
"
,
choices
=
[
"
snpp
"
,
],
)
parser
.
add_argument
(
"
--sensor
"
,
help
=
"
sensor name, not case-sensitive. Available options: [viirs, ]
"
,
choices
=
[
"
viirs
"
,
],
)
parser
.
add_argument
(
"
--path
"
,
help
=
"
path where the data is stored
"
)
parser
.
add_argument
(
"
--l1b
"
,
help
=
"
level 1b file name
"
)
parser
.
add_argument
(
"
--geolocation
"
,
help
=
"
geolocation file name
"
)
parser
.
add_argument
(
"
--hires-l1b
"
,
help
=
"
VIIRS IMG02 file name
"
)
parser
.
add_argument
(
"
--hires-geo
"
,
help
=
"
VIIRS IMG03 file name
"
)
parser
.
add_argument
(
"
-t
"
,
"
--threshold
"
,
help
=
"
thresholds file name
"
)
parser
.
add_argument
(
"
--atmos-1
"
,
help
=
"
file name of the first GEOS-IT file for atmospheric parameters
"
,
)
parser
.
add_argument
(
"
--atmos-2
"
,
help
=
"
file name of the second GEOS-IT file for atmospheric parameters
"
,
)
parser
.
add_argument
(
"
--land
"
,
help
=
"
file name of GEOS-IT land parameters
"
)
parser
.
add_argument
(
"
--ocean
"
,
help
=
"
file name of GEOS-IT ocean parameters
"
)
parser
.
add_argument
(
"
--constants
"
,
help
=
"
file name of GEOS-IT constants
"
)
parser
.
add_argument
(
"
--ndvi
"
,
help
=
"
NDVI file name
"
)
parser
.
add_argument
(
"
--sst
"
,
help
=
"
Sea surface temperature file name
"
)
parser
.
add_argument
(
"
--eco
"
,
help
=
"
Ecosystem file
"
)
parser
.
add_argument
(
"
-o
"
,
"
--out
"
,
help
=
"
output file name
"
)
parser
.
add_argument
(
"
-V
"
,
"
--version
"
,
action
=
"
version
"
,
version
=
_VERSION
,
help
=
"
print version and exit
"
,
)
parser
.
add_argument
(
"
-v
"
,
"
--verbose
"
,
action
=
"
count
"
,
default
=
1
,
help
=
"
print verbose information
"
)
parser
.
add_argument
(
"
-d
"
,
"
--debug
"
,
action
=
"
store_true
"
,
help
=
"
activate debug mode
"
)
parser
.
add_argument
(
"
--hires-only
"
,
action
=
"
store_true
"
,
help
=
"
run only high resolution code
"
)
parser
.
add_argument
(
"
-x
"
,
"
--mvcm-exe-path
"
,
help
=
"
path to mvcm executable
"
)
parser
.
add_argument
(
"
--mvcm-thresholds
"
,
help
=
"
thresholds file name for operational MVCM
"
,
default
=
None
)
args
=
parser
.
parse_args
()
satellite
=
args
.
satellite
or
"
snpp
"
sensor
=
args
.
sensor
or
"
viirs
"
data_path
=
args
.
path
mod02
=
args
.
l1b
mod03
=
args
.
geolocation
img02
=
args
.
hires_l1b
or
None
img03
=
args
.
hires_geo
or
None
threshold_file
=
args
.
threshold
geos_atm_1
=
args
.
atmos_1
geos_atm_2
=
args
.
atmos_2
geos_land
=
args
.
land
geos_ocean
=
args
.
ocean
constants
=
args
.
constants
ndvi_file
=
args
.
ndvi
sst_file
=
args
.
sst
eco_file
=
args
.
eco
out_file
=
args
.
out
verbose
=
args
.
verbose
or
False
debug
=
args
.
debug
or
False
main
(
satellite
=
satellite
,
sensor
=
sensor
,
data_path
=
data_path
,
mod02
=
mod02
,
mod03
=
mod03
,
img02
=
img02
,
img03
=
img03
,
threshold_file
=
threshold_file
,
geos_atm_1
=
geos_atm_1
,
geos_atm_2
=
geos_atm_2
,
geos_land
=
geos_land
,
geos_ocean
=
geos_ocean
,
geos_constants
=
constants
,
ndvi_file
=
ndvi_file
,
eco_file
=
eco_file
,
out_file
=
out_file
,
verbose
=
verbose
,
debug
=
debug
,
exe_path
=
args
.
mvcm_exe_path
,
hires_only
=
args
.
hires_only
,
mvcm_threshold_file
=
args
.
mvcm_thresholds
,
)
This diff is collapsed.
Click to expand it.
run_tests.py
0 → 100644
+
54
−
0
View file @
db130a1c
"""
Main call for MVCM.
"""
import
argparse
from
pkg_resources
import
get_distribution
# type: ignore
from
mvcm.main_tests_only
import
main
if
__name__
==
"
__main__
"
:
_VERSION
=
get_distribution
(
"
mvcm
"
).
version
parser
=
argparse
.
ArgumentParser
(
prog
=
"
MVCM
"
,
description
=
""
)
parser
.
add_argument
(
"
--data
"
,
help
=
(
"
file name and path containing satellite data and ancillary
"
"
data interpolated to sensor resolution
"
),
)
parser
.
add_argument
(
"
--pixel-type
"
,
help
=
"
file name and path containing all info on pixel and scene type
"
)
parser
.
add_argument
(
"
-t
"
,
"
--threshold
"
,
help
=
"
thresholds file name
"
)
parser
.
add_argument
(
"
-v
"
,
"
--verbose
"
,
action
=
"
count
"
,
default
=
1
,
help
=
"
print verbose information
"
)
parser
.
add_argument
(
"
-o
"
,
"
--out
"
,
help
=
"
output file name
"
)
parser
.
add_argument
(
"
-d
"
,
"
--debug
"
,
action
=
"
store_true
"
,
help
=
"
activate debug mode
"
)
parser
.
add_argument
(
"
-H
"
,
"
--hires
"
,
action
=
"
store_true
"
,
help
=
"
run using hires data
"
)
parser
.
add_argument
(
"
-V
"
,
"
--version
"
,
action
=
"
version
"
,
version
=
_VERSION
,
help
=
"
print version and exit
"
,
)
args
=
parser
.
parse_args
()
threshold_file
=
args
.
threshold
out_file
=
args
.
out
verbose
=
args
.
verbose
or
False
debug
=
args
.
debug
or
False
use_hires
=
args
.
hires
or
False
main
(
threshold_file
=
threshold_file
,
input_data
=
args
.
data
,
pixel_data
=
args
.
pixel_type
,
out_file
=
out_file
,
verbose
=
verbose
,
debug
=
debug
,
use_hires
=
use_hires
,
)
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