Skip to content
Snippets Groups Projects
Commit 12669e70 authored by Geoff Cureton's avatar Geoff Cureton
Browse files

Some tweaks to the cluster submission scripts for the iff_aero, sounder2iff,...

Some tweaks to the cluster submission scripts for the iff_aero, sounder2iff, fusion_matlab and vnpaerdt packages.
parent d6b69e80
No related branches found
No related tags found
No related merge requests found
...@@ -2,6 +2,7 @@ import sys ...@@ -2,6 +2,7 @@ import sys
from datetime import datetime, timedelta from datetime import datetime, timedelta
import traceback import traceback
import logging import logging
import calendar
from flo.time import TimeInterval from flo.time import TimeInterval
from flo.ui import safe_submit_order from flo.ui import safe_submit_order
...@@ -16,29 +17,39 @@ setup_logging(2) ...@@ -16,29 +17,39 @@ setup_logging(2)
comp = FUSION_MATLAB() comp = FUSION_MATLAB()
satellite = 'snpp' satellite = 'aqua'
#satellite = 'aqua' #satellite = 'snpp'
delivery_id = '20170831-1'
delivery_id = '20170920-1'
# Specify the intervals # Specify the intervals
granule = datetime(2015, 4, 17, 0, 0) #granule = datetime(2014, 7, 6, 2, 0) # Gala Wind
granule = datetime(2015, 4, 17, 0, 0) # Bryan Baum
wedge = timedelta(seconds=1.) wedge = timedelta(seconds=1.)
intervals = [ #intervals = [
#TimeInterval(granule, granule + timedelta(hours=1) - wedge) #TimeInterval(granule, granule + timedelta(hours=1) - wedge)
TimeInterval(granule, granule + timedelta(days=1) - wedge) #TimeInterval(granule, granule + timedelta(days=1) - wedge)
] #TimeInterval(granule - timedelta(hours=1), granule + timedelta(hours=1))
#TimeInterval(datetime(2014, 7, 1, 0, 5), datetime(2014, 8, 1) - wedge)
#TimeInterval(datetime(2014, 7, 1, 0, 0), datetime(2014, 7, 1, 0, 10) - wedge)
#TimeInterval(datetime(2015, 4, 1, 0, 0), datetime(2015, 5, 1, 0, 0) - wedge)
#TimeInterval(datetime(2015, 4, 25, 13, 0), datetime(2015, 4, 25, 14, 0) - wedge)
#]
intervals = [TimeInterval(datetime(2015, 4, day), datetime(2015, 4, day, 23, 59)) for day in range(1, calendar.monthrange(2016, 4)[1]+1)]
LOG.info("Submitting intervals...") LOG.info("Submitting intervals...")
for interval in intervals: for interval in intervals:
LOG.info("Submitting interval {} -> {}".format(interval.left, interval.right)) LOG.info("Submitting interval {} -> {}".format(interval.left, interval.right))
contexts = comp.find_contexts(interval, satellite, delivery_id) contexts = comp.find_contexts(interval, satellite, delivery_id)
LOG.info("\tThere are {} contexts in this interval".format(len(contexts))) LOG.info("\tThere are {} contexts in this interval".format(len(contexts)))
contexts.sort() contexts.sort()
for context in contexts: #for context in contexts:
print context #print context
LOG.info("\tFirst context: {}".format(contexts[0])) LOG.info("\tFirst context: {}".format(contexts[0]))
LOG.info("\tLast context: {}".format(contexts[-1])) LOG.info("\tLast context: {}".format(contexts[-1]))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment