Closed jimmielin closed 5 days ago
Updated history field list with new CCPP field names:
***************** HISTORY FIELD LIST ******************
TROP_P Pa avg tropopause_air_pressure
TROP_T K avg tropopause_air_temperature
TROP_Z m avg tropopause_geopotential_height_wrt_surface
TROP_DZ m avg geopotential_height_difference_between_atmosphere_layer_and_tropopause
TROP_PD probability avg probability_distribution_of_tropopause_vertical_layer_index
TROP_FD probability avg tropopause_found
TROPP_P Pa avg tropopause_air_pressure_from_lapse_rate_method
TROPP_T K avg tropopause_air_temperature_from_lapse_rate_method
TROPP_Z m avg tropopause_geopotential_height_wrt_surface_from_lapse_rate_method
TROPP_DZ m avg geopotential_height_difference_between_atmosphere_layer_and_tropopause_from_lapse_rate_method
TROPP_PD probability avg probability_distribution_of_tropopause_vertical_layer_index_from_lapse_rate_method
TROPP_FD probability avg tropopause_found_from_lapse_rate_method
TROPF_P Pa avg tropopause_air_pressure_from_cold_point_method
TROPF_T K avg tropopause_air_temperature_from_cold_point_method
TROPF_Z m avg tropopause_geopotential_height_wrt_surface_from_cold_point_method
TROPF_DZ m avg geopotential_height_difference_between_atmosphere_layer_and_tropopause_from_cold_point_method
TROPF_PD probability avg probability_distribution_of_tropopause_vertical_layer_index_from_cold_point_method
TROPF_FD probability avg tropopause_found_from_cold_point_method
TROPC_P Pa avg tropopause_air_pressure_from_climatological_method
TROPC_T K avg tropopause_air_temperature_from_climatological_method
TROPC_Z m avg tropopause_geopotential_height_wrt_surface_from_climatological_method
TROPC_DZ m avg geopotential_height_difference_between_atmosphere_layer_and_tropopause_from_climatological_method
TROPC_PD probability avg probability_distribution_of_tropopause_vertical_layer_index_from_climatological_method
TROPC_FD probability avg tropopause_found_from_climatological_method
hstobie_trop fraction of ins vertical_layer_index_lower_bound_from_hybrid_stobie_linoz_with_climatological_backup_method_for_stratospheric_chemistry
hstobie_linoz fraction of ins vertical_layer_index_lower_bound_from_hybrid_stobie_linoz_with_climatological_backup_method_for_linearized_ozone_chemistry
hstobie_tropop fraction of ins tropopause_vertical_layer_index_from_hybrid_stobie_linoz_with_climatological_backup_method_for_chemistry
*************** END HISTORY FIELD LIST ****************
Thanks @nusbaume for your review comments. I have updated standard names and updated comments throughout to address your comments, and requested a re-review.
Tests on Derecho show changes here are b4b with the original PR.
There is one exception for fillvalue
as I'm not quite sure where we would set its value after defining it in the registry for it to be available in both the CCPP physics and cam_history_support
. I noted an alternative approach in the PR comment thread. Could you and @peverwhee perhaps provide some additional guidance? Thank you!
Thanks @nusbaume for the review! I've committed your suggested change.
Can I push the big green button to merge in the pull request into Will hold off until the CAM PR is reviewed!development
now or are there any steps to complete? https://github.com/ESCOMP/atmospheric_physics/wiki/Tagging-Instructions mentions a tag should be made as well but I don't see any development tags, tags seem to be made based on main
. Thanks!
Thanks @cacraigucar, comment updated (also in CAM-SIMA) and standard name for tropp_p_loc
changed to tropopause_air_pressure_from_climatology_dataset
.
I ended up adding OPTIONAL
back to the tropopause_findChemTrop
and tropopause_findWithBackup
subroutines (these are not the main CCPP tropopause_find_run
run subroutine) to address an incompatibility with CAM where state%zm
is unavailable (Infinity) in SMS_D_Ld5.f19_f19_mg17.PC4.derecho_intel.cam-cam4_port5d.GC.aux_cam_intel
and interpolation to the optional (but unused) argument tropZ
would lead to a floating invalid error.
Re-running the tests now to see if tests pass now with this change.
Hi @cacraigucar I ran the regression tests with the CCPP-ized tropopause_find. Tests on Izumi NAG match pre-existing failures; GNU all passed as expected. All tests on Derecho match pre-existing failures except for the SMS FCHIST_GC
test:
➜ aux_cam_intel_20240925232609 ./cs.status.aux_cam_intel_20240925232609 | testgrep
aux_cam_intel_20240925232609: 63 tests
ERP_Ln9.f09_f09_mg17.FCSD_HCO.derecho_intel.cam-outfrq9s (Overall: FAIL) details:
FAIL ERP_Ln9.f09_f09_mg17.FCSD_HCO.derecho_intel.cam-outfrq9s COMPARE_base_rest
SMS_D_Ln9_P1280x1.ne0CONUSne30x8_ne0CONUSne30x8_mt12.FCHIST.derecho_intel.cam-outfrq9s (Overall: PEND) details:
PEND SMS_D_Ln9_P1280x1.ne0CONUSne30x8_ne0CONUSne30x8_mt12.FCHIST.derecho_intel.cam-outfrq9s SHAREDLIB_BUILD
SMS_Ld1.f09_f09_mg17.FCHIST_GC.derecho_intel.cam-outfrq1d (Overall: DIFF) details:
FAIL SMS_Ld1.f09_f09_mg17.FCHIST_GC.derecho_intel.cam-outfrq1d BASELINE /glade/campaign/cesm/community/amwg/cam_baselines/cam6_4_035_intel: DIFF
Upon further investigation of the FCHIST_GC
test output, the results of the FCHIST_GC
match the baselines of cam6_4_034_intel
(and cam6_4_036_intel
) but not cam6_4_035_intel
; the cam6_4_035
changelog marks FCHIST_GC
as a pre-existing failure but I'm not aware of the SMS test for FCHIST_GC failing before. Maybe there was a machine hiccup when running the cam6_4_035 tests that resulted in a DIFF.
When I ran this only cam6_4_035
was tagged and not cam6_4_036
. Given that we will run the regression tests again when merging the CAM PR, and results on cam6_4_035 look as expected, I would suggest we could merge into atmospheric_physics
first then run the CAM tests again when ready for a tag?
Thanks!
Implements CCPP-compliant tropopause_find.
Major changes to code
This is my first time doing this, so please feel free to suggest alternative approaches!
Standard CCPP-ization procedures, metadata, explicit use of fields instead of physics state, only passing active
:ncol
fields, ... was made.tropopause_find
accepted "primary" and "backup" methods for finding the tropopause. All the methods known to be used in CAM are now calculated at the same time in thetropopause_find_run
main driver routine; it calls the underlying logic as appropriate with and populates the appropriate standard name physics fields. Because the same physical quantities for tropopause level, height, pressure, temperature, etc. using different methods are used throughout the CAM physics and simultaneously output in the history tape, the same standard names with a suffix are used to differentiate between these quantities computed by different methods. e.g.,The naming should probably be changed! I'm open to suggestions.
tropopause_read_file
, which provides climatological data used as the default "backup" method to compute the tropopause (tropp_p_loc
andtropp_days
), has been moved to a utility module in CAM-SIMA to read, regrid, and provide this climatology to the CCPP-ized physics; it also removeslchnk
indexing since they're no longer used in CAM-SIMA.tropopause_find used to accept (
optional
) arguments for returningtropT
,tropZ
,tropP
(tropopause temperature, height, and pressure) which are no longer optional per the CAM-SIMA port guide.A "shim" in current CAM's
tropopause.F90
was made to use the CCPP-ized routines, but preserve all existing behavior and functionality (b4b) as expected in current CAM. In CAM-SIMA all of this are not needed.Smaller changes
get_curr_calday()
is now provided in the registry asfractional_calendar_days_on_end_of_current_timestep
Outstanding issues/notes
Tropopause_find cannot be tested using snapshots within CAM-SIMA: In regular CAM,
tropopause_find
itself does not update physics state/tendencies; its use in regular CAM is just providing the tropopause level, height, pressure, and temperature to the calling physics package; a final run oftropopause_output
will then write out to history the computed tropopause properties using the primary method. This means if snapshots cannot verify whattropopause_find
is doing within CAM-SIMA.How to make standard names for the same physical quantities computed using different methods that have to co-exist in one model run
Answer check
For existing CAM
QPC6
(which uses CLUBB that usestropopause_find
) answers match bit-for-bit for history (h0i
) and snapshot files before and afterclubb_tend_cam
. I can run more detailed regression tests for the CAM tag.For CAM-SIMA
Tricky way to verify answers
We can validate the answer fields of
TROP_P
,TROP_T
, andTROP_Z
can be against the output of CAM by running CAM-SIMA from a CAM snapshot and using history to write out these fields (instantaneously) at the first timestep. Note thatndens
has to be set to1
in CAM (fordouble
) output, and auser_set
snapshot should be taken for use beforetropopause_output
inphyspkg.F90
for use inncdata
.