diff --git a/jobs/JGLOBAL_AERO_ANALYSIS_INITIALIZE b/jobs/JGLOBAL_AERO_ANALYSIS_INITIALIZE index 921b1458b2..5c0f76de8c 100755 --- a/jobs/JGLOBAL_AERO_ANALYSIS_INITIALIZE +++ b/jobs/JGLOBAL_AERO_ANALYSIS_INITIALIZE @@ -25,7 +25,8 @@ YMD=${PDY} HH=${cyc} declare_from_tmpl -rx \ RUN=${GDUMP} YMD=${gPDY} HH=${gcyc} declare_from_tmpl -rx \ COMIN_ATMOS_RESTART_PREV:COM_ATMOS_RESTART_TMPL \ - COMIN_CHEM_BMAT_PREV:COM_CHEM_BMAT_TMPL + COMIN_CHEM_BMAT_PREV:COM_CHEM_BMAT_TMPL \ + COMIN_CHEM_ANALYSIS_PREV:COM_CHEM_ANALYSIS_TMPL ############################################################### # Run relevant script diff --git a/parm/config/gfs/config.aeroanlgenb b/parm/config/gfs/config.aeroanlgenb index d1f0ed10bd..e17e6dbad1 100644 --- a/parm/config/gfs/config.aeroanlgenb +++ b/parm/config/gfs/config.aeroanlgenb @@ -12,17 +12,17 @@ export JEDI_CONFIG_YAML="${PARMgfs}/gdas/aero_bmat_jedi_config.yaml.j2" export JCB_BASE_YAML="${PARMgfs}/gdas/aero/jcb-base.yaml.j2" export AERO_BMATRIX_STAGE_TMPL="${PARMgfs}/gdas/aero_stage_bmatrix_bkg.yaml.j2" export AERO_BMATRIX_FINALIZE_TMPL="${PARMgfs}/gdas/aero_finalize_bmatrix_bkg.yaml.j2" -export aero_diffusion_iter=10 -export aero_diffusion_horiz_len=2500e3 -export aero_diffusion_fixed_val=1.0 +export aero_diffusion_iter=200 +export aero_diffusion_horiz_len=300e3 +export aero_diffusion_fixed_val=10.0 export npx_clim_b=97 export npy_clim_b=97 export aero_diagb_weight=0.9 export aero_staticb_rescaling_factor=2.0 -export aero_diagb_rescale=20.0 +export aero_diagb_rescale=100.0 export aero_diagb_n_halo=4 export aero_diagb_n_neighbors=16 -export aero_diagb_smooth_horiz_iter=0 +export aero_diagb_smooth_horiz_iter=200 export aero_diagb_smooth_vert_iter=0 echo "END: config.aeroanlgenb" diff --git a/sorc/gdas.cd b/sorc/gdas.cd index d6097afdd4..322ce42e8c 160000 --- a/sorc/gdas.cd +++ b/sorc/gdas.cd @@ -1 +1 @@ -Subproject commit d6097afdd435fe73cc99d8ddb594c3143b72820a +Subproject commit 322ce42e8c8d0126d88d2395d196222e5224a7ba diff --git a/ush/python/pygfs/task/aero_analysis.py b/ush/python/pygfs/task/aero_analysis.py index de9360a9ac..1b95b534ae 100644 --- a/ush/python/pygfs/task/aero_analysis.py +++ b/ush/python/pygfs/task/aero_analysis.py @@ -105,17 +105,18 @@ def initialize(self) -> None: logger.debug(f"Observation files:\n{pformat(obs_dict)}") # # stage bias corrections - # logger.info(f"Staging list of bias correction files") - # bias_dict = self.jedi_dict['aeroanlvar'].render_jcb(self.task_config, 'aero_bias_staging') - # if bias_dict['copy'] is None: - # logger.info(f"No bias correction files to stage") - # else: - # bias_dict['copy'] = Jedi.remove_redundant(bias_dict['copy']) - # FileHandler(bias_dict).sync() - # logger.debug(f"Bias correction files:\n{pformat(bias_dict)}") - - # # extract bias corrections - # Jedi.extract_tar_from_filehandler_dict(bias_dict) + logger.info(f"Staging list of bias correction files") + bias_dict = self.jedi_dict['aeroanlvar'].render_jcb(self.task_config, 'aero_bias_staging') + logger.debug(bias_dict) + if bias_dict['copy'] is None: + logger.info(f"No bias correction files to stage") + else: + bias_dict['copy'] = Jedi.remove_redundant(bias_dict['copy']) + FileHandler(bias_dict).sync() + logger.debug(f"Bias correction files:\n{pformat(bias_dict)}") + + # extract bias corrections + Jedi.extract_tar_from_filehandler_dict(bias_dict) # stage CRTM fix files logger.info(f"Staging CRTM fix files from {self.task_config.CRTM_FIX_YAML}") @@ -170,7 +171,7 @@ def finalize(self) -> None: aerostat = os.path.join(self.task_config.COMOUT_CHEM_ANALYSIS, f"{self.task_config['APREFIX']}aerostat") # get list of diag files to put in tarball - diags = glob.glob(os.path.join(self.task_config['DATA'], 'diags', 'diag*nc4')) + diags = glob.glob(os.path.join(self.task_config['DATA'], 'diags', 'diag*nc')) # gzip the files first for diagfile in diags: @@ -183,13 +184,24 @@ def finalize(self) -> None: self._add_fms_cube_sphere_increments() # tar up bias correction files - # NOTE TODO + bfile = f"{self.task_config.APREFIX}aero_varbc_params.tar" + aertar = os.path.join(self.task_config.COMOUT_CHEM_ANALYSIS, bfile) + + # get lists of aerosol bias correction files to add to tarball + satlist = glob.glob(os.path.join(self.task_config.DATA, 'bc', '*satbias*nc')) # copy files back to COM logger.info(f"Copying files to COM based on {self.task_config.AERO_FINALIZE_VARIATIONAL_TMPL}") aero_var_final_list = parse_j2yaml(self.task_config.AERO_FINALIZE_VARIATIONAL_TMPL, self.task_config) FileHandler(aero_var_final_list).sync() + # tar aerosol bias correction files to ROTDIR + logger.info(f"Creating aerosol bias correction tar file {aertar}") + with tarfile.open(aertar, 'w') as aerbcor: + for satfile in satlist: + aerbcor.add(satfile, arcname=os.path.basename(satfile)) + logger.info(f"Add {aerbcor.getnames()}") + # open tar file for writing with tarfile.open(aerostat, "w") as archive: for diagfile in diags: