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

Incorporate global VIIRS 30s vegetation type data #698

Closed
GeorgeGayno-NOAA opened this issue Sep 30, 2022 · 30 comments · Fixed by #699
Closed

Incorporate global VIIRS 30s vegetation type data #698

GeorgeGayno-NOAA opened this issue Sep 30, 2022 · 30 comments · Fixed by #699
Assignees
Labels
enhancement New feature or request

Comments

@GeorgeGayno-NOAA
Copy link
Collaborator

GeorgeGayno-NOAA commented Sep 30, 2022

To save memory and to speed up the creation of model grids, the original VIIRS 30 second vegetation data was upscaled to 0.03, 0.05 and 0.1-degree resolution. The upscaling was done by accumulating the raw data in each lower-res grid box, then picking the predominate category. A CONUS version of the original high-res data was also created. All files are found under fix/sfc_climo

  • vegetation_type.viirs.igbp.0.03.nc (global 0.03-degree)
  • vegetation_type.viirs.igbp.0.05.nc (global 0.05-degree)
  • vegetation_type.viirs.igbp.0.1.nc (global 0.1-degree)
  • vegetation_type.viirs.igbp.conus.0.01.nc (CONUS 0.01-degree)

To support larger regional grids that cover North America, the regional group needs UFS_UTILS to work with the original high-resolution global dataset.

@GeorgeGayno-NOAA
Copy link
Collaborator Author

GeorgeGayno-NOAA commented Oct 3, 2022

Copy the original data file (from @barlage) from Hera:
/scratch1/NCEPDEV/stmp2/Michael.Barlage/data/viirs_surface_type/NESDIS_VIIRS_SfcType.nc

to WCOSS2 (Cactus):
/lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/viirs.veg/viirs_surface_type

@GeorgeGayno-NOAA
Copy link
Collaborator Author

GeorgeGayno-NOAA commented Oct 3, 2022

Recovered a program from a defunct branch that will convert the raw file to a version readable by ufs_utils. The program, build script and run script are on WCOSS2 (Cactus) here:
/lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/viirs.veg

@GeorgeGayno-NOAA
Copy link
Collaborator Author

GeorgeGayno-NOAA commented Oct 3, 2022

The program was run twice to create global and NH (5S to 90N) files. The files were placed on WCOSS2 (Cactus) here:
/lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/viirs.veg/sfc_climo

@yangfanglin
Copy link
Contributor

@GeorgeGayno-NOAA George, could you please work with @KateFriedman-NOAA to add the data to the "fix" archive on all EMC supported platforms ? Thanks

@GeorgeGayno-NOAA
Copy link
Collaborator Author

GeorgeGayno-NOAA commented Oct 3, 2022

To test the new data, I recreated the ./fix/sfc_climo in another directory (on Cactus):

clogin01@ /lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/UFS_UTILS/fix\ $ ls -l
total 8
lrwxrwxrwx 1 george.gayno global   54 Sep 23 15:43 am -> /lfs/h2/emc/global/save/emc.global/FIX/fix/am/20220805
-rwxr-xr-x 1 george.gayno global 1590 Sep 23 15:42 link_fixdirs.sh
lrwxrwxrwx 1 george.gayno global   56 Sep 23 15:43 orog -> /lfs/h2/emc/global/save/emc.global/FIX/fix/orog/20220805
lrwxrwxrwx 1 george.gayno global   73 Oct  3 13:48 sfc_climo -> /lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/viirs.veg/sfc_climo

Then, added the new vegetation files and linked to the other input surface files as needed:

clogin01@ /lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/viirs.veg/sfc_climo\ $ ls -l
total 1394168
lrwxrwxrwx 1 george.gayno global        74 Oct  3 13:50 facsf.1.0.nc -> /lfs/h2/emc/global/save/emc.global/FIX/fix/sfc_climo/20220805/facsf.1.0.nc
lrwxrwxrwx 1 george.gayno global        89 Oct  3 13:51 maximum_snow_albedo.0.05.nc -> /lfs/h2/emc/global/save/emc.global/FIX/fix/sfc_climo/20220805/maximum_snow_albedo.0.05.nc
lrwxrwxrwx 1 george.gayno global        79 Oct  3 13:51 slope_type.1.0.nc -> /lfs/h2/emc/global/save/emc.global/FIX/fix/sfc_climo/20220805/slope_type.1.0.nc
lrwxrwxrwx 1 george.gayno global        91 Oct  3 13:51 snowfree_albedo.4comp.0.05.nc -> /lfs/h2/emc/global/save/emc.global/FIX/fix/sfc_climo/20220805/snowfree_albedo.4comp.0.05.nc
lrwxrwxrwx 1 george.gayno global        87 Oct  3 13:52 soil_type.statsgo.0.05.nc -> /lfs/h2/emc/global/save/emc.global/FIX/fix/sfc_climo/20220805/soil_type.statsgo.0.05.nc
lrwxrwxrwx 1 george.gayno global        94 Oct  3 13:52 substrate_temperature.2.6x1.5.nc -> /lfs/h2/emc/global/save/emc.global/FIX/fix/sfc_climo/20220805/substrate_temperature.2.6x1.5.nc
lrwxrwxrwx 1 george.gayno global        91 Oct  3 13:52 vegetation_greenness.0.144.nc -> /lfs/h2/emc/global/save/emc.global/FIX/fix/sfc_climo/20220805/vegetation_greenness.0.144.nc
-rw-r--r-- 1 george.gayno emc    934174930 Oct  3 12:59 vegetation_type.viirs.igbp.0.01.nc
-rw-r--r-- 1 george.gayno emc    493414946 Oct  3 13:02 vegetation_type.viirs.igbp.nh.0.01.nc

GeorgeGayno-NOAA added a commit to GeorgeGayno-NOAA/UFS_UTILS that referenced this issue Oct 3, 2022
@barlage
Copy link
Collaborator

barlage commented Oct 3, 2022

@GeorgeGayno-NOAA is there a naming convention for 30" data, e.g., vegetation_type.viirs.igbp.30s.nc, since this isn't technically 0.01deg?

for future reference, did you use chop.f90 to add the attributes and lat/lon/corners info needed in the global surface type data file as well as the NA cutout?

@GeorgeGayno-NOAA
Copy link
Collaborator Author

@GeorgeGayno-NOAA is there a naming convention for 30" data, e.g., vegetation_type.viirs.igbp.30s.nc, since this isn't technically 0.01deg?

I can name them as '30s' is you like.

for future reference, did you use chop.f90 to add the attributes and lat/lon/corners info needed in the global surface type data file as well as the NA cutout?

Yes, I added some attributes and corner point lat/lons. The latter are needed by the ESMF regridding.

@GeorgeGayno-NOAA GeorgeGayno-NOAA changed the title Incorporate global VIIRS 0.01-degree vegetation type data Incorporate global VIIRS 30s vegetation type data Oct 3, 2022
GeorgeGayno-NOAA added a commit to GeorgeGayno-NOAA/UFS_UTILS that referenced this issue Oct 3, 2022
@GeorgeGayno-NOAA GeorgeGayno-NOAA added the enhancement New feature or request label Oct 3, 2022
@GeorgeGayno-NOAA
Copy link
Collaborator Author

The branch was tested on Cactus using 03c5790. A large, North American regional grid was created using the new NH/30s file. The grid driver script was modified as follows:

diff --git a/driver_scripts/driver_grid.wcoss2.sh b/driver_scripts/driver_grid.wcoss2.sh
index c37b98e3..4ebdb6dd 100755
--- a/driver_scripts/driver_grid.wcoss2.sh
+++ b/driver_scripts/driver_grid.wcoss2.sh
@@ -4,7 +4,7 @@
 #PBS -e log
 #PBS -q debug
 #PBS -A GFS-DEV
-#PBS -l walltime=00:15:00
+#PBS -l walltime=00:20:00
 #PBS -N make_grid
 #PBS -l select=1:ncpus=24:mem=100GB
 
@@ -73,7 +73,7 @@ export gtype=regional_esg           # 'uniform', 'stretch', 'nest',
                                # 'regional_gfdl', 'regional_esg'
 export make_gsl_orog=false     # 'true' if user needs 'oro' files for GSL
                                # orographic drag suite
-export veg_type_src="modis.igbp.0.05" #  veg type data.
+export veg_type_src="viirs.igbp.nh.30s" #  veg type data.
                                 # For viirs-based vegetation type data, set to:
                                 # 1) "viirs.igbp.0.05" for global 5km data
                                 # 2) "viirs.igbp.0.1" for global 10km data

The output model grid vegetation files were and examined using ncview and looked correct.

@GeorgeGayno-NOAA
Copy link
Collaborator Author

The above test was repeated using the new global 30s data. The grid driver script was modified as follows:

 #PBS -A GFS-DEV
-#PBS -l walltime=00:15:00
+#PBS -l walltime=00:25:00
 #PBS -N make_grid
-#PBS -l select=1:ncpus=24:mem=100GB
+#PBS -l select=1:ncpus=24:mem=200GB
 
 #-----------------------------------------------------------------------
 # Driver script to create a cubic-sphere based model grid on WCOSS2.
@@ -73,7 +73,7 @@ export gtype=regional_esg           # 'uniform', 'stretch', 'nest',
                                # 'regional_gfdl', 'regional_esg'
 export make_gsl_orog=false     # 'true' if user needs 'oro' files for GSL
                                # orographic drag suite
-export veg_type_src="modis.igbp.0.05" #  veg type data.
+export veg_type_src="viirs.igbp.30s" #  veg type data.
                                 # For viirs-based vegetation type data, set to:
                                 # 1) "viirs.igbp.0.05" for global 5km data
                                 # 2) "viirs.igbp.0.1" for global 10km data
@@ -131,8 +131,8 @@ fi

The output model grid vegetation files were identical to those from the first test as expected.

@GeorgeGayno-NOAA
Copy link
Collaborator Author

All grid_gen regression tests passed. Will create a PR.

@GeorgeGayno-NOAA
Copy link
Collaborator Author

Does anyone want to test my branch before the merge? I have the new data on WCOSS2. But I can set it up on another machine if needed.

GeorgeGayno-NOAA added a commit to GeorgeGayno-NOAA/UFS_UTILS that referenced this issue Oct 4, 2022
@barlage
Copy link
Collaborator

barlage commented Oct 4, 2022

@GeorgeGayno-NOAA I pointed @BenjaminBlake-NOAA to your new dataset. I believe he will give it a test for the North American RRFS domain.

GeorgeGayno-NOAA added a commit to GeorgeGayno-NOAA/UFS_UTILS that referenced this issue Oct 4, 2022
@GeorgeGayno-NOAA
Copy link
Collaborator Author

@GeorgeGayno-NOAA I pointed @BenjaminBlake-NOAA to your new dataset. I believe he will give it a test for the North American RRFS domain.

@BenjaminBlake-NOAA I will need to help you set up your test.

@BenjaminBlake-NOAA
Copy link

@GeorgeGayno-NOAA Sounds good, I was planning to use the SRW app workflow to regenerate the surface climo fix files. But if it makes more sense to use the UFS_UTILS driver scripts I'm happy to do that as well.

@KateFriedman-NOAA
Copy link
Collaborator

All, let me know when you're ready for me to pull new fix files into the primary fix set. Thanks! :)

@GeorgeGayno-NOAA
Copy link
Collaborator Author

@GeorgeGayno-NOAA Sounds good, I was planning to use the SRW app workflow to regenerate the surface climo fix files. But if it makes more sense to use the UFS_UTILS driver scripts I'm happy to do that as well.

Ben, test however you want. Just be sure to link to the new data (./sfc_climo). On Cactus:

clogin05@ /lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/UFS_UTILS/fix\ $ ls -l
total 8
lrwxrwxrwx 1 george.gayno global   54 Oct  3 19:59 am -> /lfs/h2/emc/global/save/emc.global/FIX/fix/am/20220805
-rwxr-xr-x 1 george.gayno global 1590 Sep 23 15:42 link_fixdirs.sh
lrwxrwxrwx 1 george.gayno global   56 Oct  3 19:59 orog -> /lfs/h2/emc/global/save/emc.global/FIX/fix/orog/20220805
lrwxrwxrwx 1 george.gayno global   73 Oct  3 13:48 sfc_climo -> /lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/viirs.veg/sfc_climo

@GeorgeGayno-NOAA
Copy link
Collaborator Author

GeorgeGayno-NOAA commented Oct 4, 2022

All, let me know when you're ready for me to pull new fix files into the primary fix set. Thanks! :)

Kate, there are three new files - vegetation_type.viirs.igbp.30s.nc, vegetation_type.viirs.igbp.nh.30s.nc and vegetation_type.viirs.igbp.conus.30s.nc And the latter should replace the vegetation_type.viirs.igbp.conus.0.01.nc file.

The new files are on Cactus here: /lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/viirs.veg/sfc_climo

Wait until Ben is finished with his testing before doing anything.

@BenjaminBlake-NOAA
Copy link

@GeorgeGayno-NOAA I created new surface climo fix files for the RRFS_NA_3km grid yesterday and am waiting to hear back from a colleague if the new files look good.

@GeorgeGayno-NOAA
Copy link
Collaborator Author

GeorgeGayno-NOAA commented Oct 11, 2022

Per recommendation of @barlage, I added the compression step for all new files:

ncks -O -4 -L 1 vegt.nc vegt.compressed.nc

This step was added to the run.sh script on Cactus: /lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/viirs.veg. And the files in /lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/viirs.veg/sfc_climo were updated.

@GeorgeGayno-NOAA
Copy link
Collaborator Author

New files must also be available for the community at: https://noaa-ufs-srw-pds.s3.amazonaws.com/index.html#fix/fix_sfc_climo/

GeorgeGayno-NOAA added a commit to GeorgeGayno-NOAA/UFS_UTILS that referenced this issue Oct 13, 2022
GeorgeGayno-NOAA added a commit to GeorgeGayno-NOAA/UFS_UTILS that referenced this issue Oct 14, 2022
GeorgeGayno-NOAA added a commit to GeorgeGayno-NOAA/UFS_UTILS that referenced this issue Oct 14, 2022
@GeorgeGayno-NOAA
Copy link
Collaborator Author

@KateFriedman-NOAA There are three new vegetation files that need to be hosted on each machine in the FIX/fix/sfc_climo/ directory. There are on Cactus here: /lfs/h2/emc/global/noscrub/George.Gayno/ufs_utils.git/UFS_UTILS/fix/sfc_climo.new

  • vegetation_type.viirs.igbp.30s.nc
  • vegetation_type.viirs.igbp.conus.30s.nc
  • vegetation_type.viirs.igbp.nh.30s.nc

You can remove the "vegetation_type.viirs.igbp.conus.0.01.nc" file. But create a link with that name that points to the "vegetation_type.viirs.igbp.conus.30s.nc" file (for backwards compatibility). Thank you!

@WalterKolczynski-NOAA
Copy link
Contributor

I think we'd prefer not to make the symlink unless there is a compelling reason otherwise. Now that we are versioning fix directories in the workflow, the sfc_climo fix version will update at the same time as the scripts change the filename. Versions with the old filename would still point to the old sfc_climo fix directory that have the old file.

@KateFriedman-NOAA
Copy link
Collaborator

@GeorgeGayno-NOAA I have copied the three new fix files into a new sfc_climo timestamp subfolder (20221017) and removed the requested file (without making a symlink). See here on Cactus:

/lfs/h2/emc/global/noscrub/emc.global/FIX/fix/sfc_climo/20221017

If this looks good to you I'll rsync it to the other platforms and then update sfc_climo_ver in fix.ver in the develop branch. Any there any script updates that need to go along with updating sfc_climo_ver=20221017?

@WalterKolczynski-NOAA
Copy link
Contributor

https://github.com/ufs-community/UFS_UTILS/blob/develop/fix/link_fixdirs.sh in UFS_UTILS should have the default fix version updated, so any stand-alone testing is also updated.

GeorgeGayno-NOAA added a commit to GeorgeGayno-NOAA/UFS_UTILS that referenced this issue Oct 17, 2022
@GeorgeGayno-NOAA
Copy link
Collaborator Author

https://github.com/ufs-community/UFS_UTILS/blob/develop/fix/link_fixdirs.sh in UFS_UTILS should have the default fix version updated, so any stand-alone testing is also updated.

Done at b8ae8c1.

@GeorgeGayno-NOAA
Copy link
Collaborator Author

@GeorgeGayno-NOAA I have copied the three new fix files into a new sfc_climo timestamp subfolder (20221017) and removed the requested file (without making a symlink). See here on Cactus:

/lfs/h2/emc/global/noscrub/emc.global/FIX/fix/sfc_climo/20221017

Perfect. Thanks.

If this looks good to you I'll rsync it to the other platforms and then update sfc_climo_ver in fix.ver in the develop branch. Any there any script updates that need to go along with updating sfc_climo_ver=20221017?

The workflow does not create grids, correct? It points to the pre-existing data in the 'orog' directory, right? If so, your workflow is unaffected.

@GeorgeGayno-NOAA
Copy link
Collaborator Author

@KateFriedman-NOAA As a heads up, there is another issue open (#702) that will add new sfc_climo files. You can also place these additional files in 20221017. Details to come.

@GeorgeGayno-NOAA
Copy link
Collaborator Author

@KateFriedman-NOAA Please rsync the data to the other platforms we support.

@KateFriedman-NOAA
Copy link
Collaborator

I have rsync'd the new 20221017 sfc_climo subfolder to the supported platforms. Will add the additional files when provided.

Let me know when you're ready for global-workflow to change sfc_climo_ver=20221017 and move to the updated UFS_UTILS hash. Thanks!

GeorgeGayno-NOAA added a commit that referenced this issue Oct 19, 2022
New high-resolution (30 sec.) North American and global files
were added to the 'fixed' directory in a new version directory.
All script comments and 'readthedocs' were updated. The 
link_fixdirs.sh script was updated to point at the latest version
of the sfc_climo subdirectory.

Fixes #698.
@GeorgeGayno-NOAA
Copy link
Collaborator Author

I have rsync'd the new 20221017 sfc_climo subfolder to the supported platforms. Will add the additional files when provided.

Let me know when you're ready for global-workflow to change sfc_climo_ver=20221017 and move to the updated UFS_UTILS hash. Thanks!

The default in UFS_UTILS link_fixdirs.sh was changed to 20221017.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants