The resulting file for a 3-day cascadia1 forecast with bio and carbon is 327 MB, vs. 214 MB for EACH of the history files. This means we are eventually pushing 47x less to azure. For testing on my mac run in ipython as run make_forcing_main.py -d 2017.05.18 """ import os import sys fpth = os.path.abspath('../') if fpth not in sys.path: sys.path.append(fpth) import forcing_functions as ffun Ldir, Lfun = ffun.intro() # ****************** CASE-SPECIFIC CODE ***************** from datetime import datetime start_time = datetime.now() import netCDF4 as nc import zrfun import numpy as np print(' - Creating surface file for ' + Ldir['date_string']) f_string = 'f' + Ldir['date_string'] #%% create the surface NetCDF file # input files
""" This creates and poulates directories for ROMS runs on gaggle. It is designed to work with the "BLANK" version of the .in file, replacing things like $whatever$ with meaningful values. """ import os import sys fpth = os.path.abspath('../../') if fpth not in sys.path: sys.path.append(fpth) import forcing_functions as ffun Ldir, Lfun = ffun.intro() #import netCDF4 as nc #import numpy as np from datetime import datetime, timedelta fdt = datetime.strptime(Ldir['date_string'], '%Y.%m.%d') fdt_yesterday = fdt - timedelta(1) print('- dot_in.py creating files for LiveOcean for ' + Ldir['date_string']) gtag = Ldir['gtag'] gtagex = gtag + '_' + Ldir['ex_name'] EX_NAME = Ldir['ex_name'].upper() #### USER DEFINED VALUES #### # which ROMS code to use roms_name = 'LO_ROMS'