Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

WRF immediately segfaults - Must choose a microphysics that provides effective radii

andythewxman

New member
I am attempting to run WRF using the following physics configuration. Real completes fine, but wrf fails immediately with a segmentation fault. It appears to be something with the has_reqc (needs to be set to 1) but I am not sure how/where I go to set that. It does not seem to be set automatically. Any ideas are greatly appreciated.

1698096159174.png
Screenshot 2023-10-23 at 4.21.03 PM.png
 
Thank you for your reply. Please see attached.

Just for reference, this configuration worked with WRF 3.8, but continues to fail while trying to transition to WRF 4.5.1.
 

Attachments

  • namelist.input
    8.4 KB · Views: 6
Please find the following piece of code in phys/module_physics_init.F and add the line in red font to it. Then recompile WRF and run the case again. Let me know whether it works.

Code:
!..Added G. Thompson to determine if we will compute and pass radiative


!.. effective radii of cloud water, ice, and snow.  Currently ONLY properly


!.. connected if using Physics options Thompson-MP and RRTMG-LW/SW.


! 10/2014: T. Mansell added support for NSSL_2MOM options


   has_reqc = 0


   has_reqi = 0


   has_reqs = 0


   IF ( config_flags%use_mp_re .EQ. 1 ) THEN


   if (( (config_flags%ra_lw_physics .eq. RRTMG_LWSCHEME ) .or. &


#if( BUILD_RRTMG_FAST == 1)


         (config_flags%ra_lw_physics .eq. RRTMG_LWSCHEME_FAST ) .or. &


#endif


#if( BUILD_RRTMK == 1)


         (config_flags%ra_lw_physics .eq. RRTMK_LWSCHEME  ) .or. &


#endif


         (config_flags%ra_lw_physics .eq. goddardlwscheme ) ) .and. &


       ( (config_flags%ra_sw_physics .eq. RRTMG_SWSCHEME ) .or. &


#if( BUILD_RRTMG_FAST == 1)


         (config_flags%ra_sw_physics .eq. RRTMG_SWSCHEME_FAST ) .or. &


#endif


#if( BUILD_RRTMK == 1)


         (config_flags%ra_sw_physics .eq. RRTMK_SWSCHEME ) .or. &


#endif

         (config_flags%ra_sw_physics .eq. goddardswscheme ) ) .and. &


        (config_flags%mp_physics  .eq. THOMPSON .or.        &


         config_flags%mp_physics  .eq. THOMPSONAERO .or.    &


         config_flags%mp_physics  .eq. NSSL_2MOM .or.       &


         config_flags%mp_physics  .eq. NSSL_2MOMG .or.      &


         config_flags%mp_physics  .eq. NSSL_2MOMCCN .or.    &


         config_flags%mp_physics  .eq. WSM3SCHEME .or.      &


         config_flags%mp_physics  .eq. WSM5SCHEME .or.      &


         config_flags%mp_physics  .eq. WSM6SCHEME .or.      &


         config_flags%mp_physics  .eq. WSM7SCHEME .or.      &


         config_flags%mp_physics  .eq. WDM5SCHEME .or.      &


         config_flags%mp_physics  .eq. WDM6SCHEME .or.      &


         config_flags%mp_physics  .eq. WDM7SCHEME .or.      &


         config_flags%mp_physics  .eq. morr_two_moment  .or.  &


         config_flags%mp_physics  .eq. nuwrf4icescheme .or. &


         config_flags%mp_physics  .eq. JENSEN_ISHMAEL .or.  &


         config_flags%mp_physics  .eq. P3_1CATEGORY .or.    &


         config_flags%mp_physics  .eq. P3_1CATEGORY_NC .or. &


         config_flags%mp_physics  .eq. P3_2CATEGORY .or.    &


         config_flags%mp_physics  .eq. P3_1CAT_3MOM   ) ) then    ! P3


      has_reqc = 1


      has_reqi = 1


      has_reqs = 1


   endif
 
Somehow the color was removed. The line you should add is (it is included in the above piece of code in my previous post):

config_flags%mp_physics .eq. morr_two_moment .or. &
 
Thank you. I will give that a try and reply once I have a chance to run a test. Is this a bug in the baseline, or is this something that I would have accidentally done on my end during my transition to WRF 4.5.1?
 
It appears that I have made it past my initial error, but now I am hitting another seg fault a little later on.
According to gdb, the issue is occurring in opt_cloud$module_ra_goddard. I haven't looked into it too much yet, but I just wanted to circle back on our original conversation.Screenshot 2023-10-25 at 9.46.46 AM.png
 
Good morning! I wanted to follow up and see if anyone has had a chance to look into this issue further. I have tried some troubleshooting but have not been able to find a solution. Thank you in advance for any updates you can provide.
 
I have set mp_physics = 2 (Purdue Lin) and encountered the following message in rsl.out.0000:

"""
d01 2022-05-20_12:30:00 Must choose a microphysics that provides effective radii.
...
d01 2022-05-20_12:45:00 Must choose a microphysics that provides effective radii.
...
""""

The namelist.input I used is attached, and I have created a post regarding this issue (WARNING: Goddard radiation and Goddard 4ice microphysics are not used together).
Although it appears that the WRF model runs correctly and I did not encounter a segmentation fault, I would like to know if there is anything incorrect in the output.
 

Attachments

  • namelist.input
    6.9 KB · Views: 0
Top