Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GPM IMERG #84

Merged
merged 5 commits into from
Mar 8, 2024
Merged

GPM IMERG #84

merged 5 commits into from
Mar 8, 2024

Conversation

feng045
Copy link
Collaborator

@feng045 feng045 commented Feb 24, 2024

This PR is based on #81 with the following major updates:

  1. A new approach of movement direction (in movement_speed.py) was implemented by @feliperiosg. Now 0/360 (degrees) is for north, 90 for east, 180 for south, and 270 for west. When computing x-y vectors from this angles, sines are cosines work just fine. If the pf/feature is not moving, the angle/direction is nan (that is, when the movement speed is zero). also the speed now is not interpolated (which previously caused having unrealistic zero or nan speeds).
  2. Corrected a bug in /pyflextrkr/movement_speed.py where the last track movement calculation is missing.
  3. Added movement calculation to Tb-only MCS tracking using tracked Tb field (in runscripts/run_mcs_tb.py).
  4. Added parameters in config/config_himawari_mcs_example.yml for calculating movements, and updated config/demo_mcs_himawari.sh to include downloading example Himawari data.
  5. Added an input argument (--figname_type) in /Analysis/plot_subset_tbpf_mcs_tracks_demo.py to control the output image naming format. By default, this argument is set to ‘date_time’, which uses date_time as image output names. Setting this argument to ‘sequence’ will use ordinal pattern (e.g., figbasename00001.png) as output names.
  6. Added an option in Analysis/plot_subset_tb_mcs_tracks_demo.py to auto determine figure aspect ratio if map_extent is specified.
  7. Added Notebooks/plot_himawari_single_track_stats.ipynb to demonstrate plotting a single MCS track statistics from Himawari Tb-only MCS tracking.

The following changes were implemented by @feliperiosg:

  1. README.md now offers an alternative on how to install PyFLEXTRKR via conda from the requirements.txt file.
  2. Explicit 'utf-8' encoding in the setup.py file.
  3. Instances (only in GPM IMERG-related files) of 'dims' in xarray objects, e.g., "ds_in.dims[...]" were replaced to "ds_in.sizes[...]", avoiding the "FutureWarning: The return type of Dataset.dims will be...". (PyFLEXTRKR also runs in python=3.11.7 (both Linux and Windows). This might enable too supporting later versions of xarray, which was probably the cause of the aforementioned warning.) the "UserWarning: Converting non-nanosecond precision datetime values to nanosecond precision..." was also taken care of. (basetime[:nfiles].astype("datetime64[ns]") in line 611 of gettracks.py)
  4. How the coordinates are arranged at the end of function "subset_ds_geolimit" (in ft_utilities.py) allows now to simply apply (and rightly retrieve the lat-lon order) of land-sea masks downloaded from GES DISC.
    (as it was before, PyFLEXTRKR crashed in pf-rain fraction over land and sea, because the "shape" of the numpy, i.e., lat-lon was transposed).

feliperiosg and others added 4 commits February 2, 2024 23:10
1. Corrected a bug in /pyflextrkr/movement_speed.py where the last track movement calculation is missing.

2. Added an input argument (--figname_type) in /Analysis/plot_subset_tbpf_mcs_tracks_demo.py to control the output image naming format. By default, this argument is set to ‘date_time’, which uses date_time as image output names. Setting this argument to ‘sequence’ will use ordinal pattern (e.g., figbasename00001.png) as output names.

3. Commented out previous changes in /config/demo_mcs_imerg.sh, leaving them as examples.
1. Added a step in runscripts/run_mcs_tb.py to call movement_speed() function to calculate movement using tracked Tb.
2. Added parameters in config/config_himawari_mcs_example.yml for calculating movements.
3. Updated config/demo_mcs_himawari.sh to include downloading example Himawari data.
4. Added options in Analysis/plot_subset_tb_mcs_tracks_demo.py to auto determine figure aspect ratio if map_extent is specified.
5. Added Notebooks/plot_himawari_single_track_stats.ipynb to demonstrate plotting a single MCS track statistics from Himawari Tb-only MCS tracking.
1. Added optional calls to preprocess WRF data and regrid output tracking masks in /runscripts/run_mcs_tbpf_saag.py.
2. Added a config and a slurm script example to run MCS tracking following the SAAG MCS tracking intercomparison protocol, using a simplified definition of MCS using collocated Tb and precipitation:
- /config/config_mcs_saag_example.yml
- /slurm/slurm_mcs_saag_example.sh
@feng045 feng045 merged commit 40dcb8d into FlexTRKR:main Mar 8, 2024
@feng045 feng045 deleted the gpm_imerg branch October 24, 2024 03:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants