Skip to content

Commit

Permalink
Move adding of increments to postProcess
Browse files Browse the repository at this point in the history
  • Loading branch information
CoryMartin-NOAA committed Mar 4, 2024
1 parent e06ecd2 commit 0925e94
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 6 deletions.
2 changes: 1 addition & 1 deletion scripts/exglobal_aero_analysis_post.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@

# Instantiate the aerosol analysis task
AeroAnl = AerosolAnalysis(config)
#AeroAnl.postProcess()
AeroAnl.postProcess()
19 changes: 14 additions & 5 deletions ush/python/pygfs/task/aero_analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,20 @@ def execute(self: Analysis) -> None:

pass

@logit(logger)
def postProcess(self: Analysis) -> None:
"""Post process a global aerosol analysis
This method will post process a global aerosol analysis using JEDI.
This includes:
- applying the increments to the original RESTART files
- if applicable, regridding the analysis to the ensemble resolution
"""
# ---- add increments to RESTART files
logger.info('Adding increments to RESTART files')
self._add_fms_cube_sphere_increments()

@logit(logger)
def finalize(self: Analysis) -> None:
"""Finalize a global aerosol analysis
Expand All @@ -135,7 +149,6 @@ def finalize(self: Analysis) -> None:
- tarring up output diag files and place in ROTDIR
- copying the generated YAML file from initialize to the ROTDIR
- copying the guess files to the ROTDIR
- applying the increments to the original RESTART files
- moving the increment files to the ROTDIR
"""
Expand Down Expand Up @@ -180,10 +193,6 @@ def finalize(self: Analysis) -> None:
bkglist.append([src, dest])
FileHandler({'copy': bkglist}).sync()

# ---- add increments to RESTART files
logger.info('Adding increments to RESTART files')
self._add_fms_cube_sphere_increments()

# ---- move increments to ROTDIR
logger.info('Moving increments to ROTDIR')
template = f'aeroinc.{to_fv3time(self.task_config.current_cycle)}.fv_tracer.res.tile{{tilenum}}.nc'
Expand Down

0 comments on commit 0925e94

Please sign in to comment.