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

Add metadata for BIOS ancillaries #3

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

SeanBryan51
Copy link
Contributor

@SeanBryan51 SeanBryan51 commented Oct 21, 2024

This change adds metadata to the BIOS gridinfo file as per discussions in CABLE-LSM/CABLE#406.

@SeanBryan51 SeanBryan51 force-pushed the add-bios-provenance-information branch from 849e94a to 32b6740 Compare October 21, 2024 01:31
@SeanBryan51 SeanBryan51 force-pushed the add-bios-provenance-information branch from 5e4b9c4 to 1d50098 Compare October 21, 2024 01:49
@SeanBryan51 SeanBryan51 changed the title Add bios provenance information Add metadata for BIOS ancillaries Oct 21, 2024
@SeanBryan51 SeanBryan51 force-pushed the add-bios-provenance-information branch from 1d50098 to e52d9dd Compare October 21, 2024 03:33
@SeanBryan51 SeanBryan51 force-pushed the add-bios-provenance-information branch from e52d9dd to 813e66f Compare October 21, 2024 04:12
@SeanBryan51
Copy link
Contributor Author

SeanBryan51 commented Oct 21, 2024

Here is a before and after diff of the header file changes (ignoring history logs) (NOW OUTDATED):

diff -u <(ncdump -h gridinfo_out_main.nc | sed '/Mon Oct 21/d') <(ncdump -h gridinfo_out_add-bios-provenance-information.nc | sed '/Mon Oct 21/d')
--- /dev/fd/63	2024-10-21 17:08:37.446300304 +1100
+++ /dev/fd/62	2024-10-21 17:08:37.446300304 +1100
@@ -1,4 +1,4 @@
-netcdf gridinfo_out_main {
+netcdf gridinfo_out_add-bios-provenance-information {
 dimensions:
 	latitude = 670 ;
 	longitude = 813 ;
@@ -147,57 +147,91 @@
 		crs:spatial_ref = "GEOGCS[\"GDA94\",DATUM[\"Geocentric_Datum_of_Australia_1994\",SPHEROID[\"GRS 1980\",6378137,298.257222101,AUTHORITY[\"EPSG\",\"7019\"]],AUTHORITY[\"EPSG\",\"6283\"]],PRIMEM[\"Greenwich\",0,AUTHORITY[\"EPSG\",\"8901\"]],UNIT[\"degree\",0.0174532925199433,AUTHORITY[\"EPSG\",\"9122\"]],AXIS[\"Latitude\",NORTH],AXIS[\"Longitude\",EAST],AUTHORITY[\"EPSG\",\"4283\"]]" ;
 		crs:GeoTransform = "112.925 0.05 0 -10.075 0 -0.05 " ;
 	float silt(latitude, longitude) ;
-		silt:long_name = "GDAL Band Number 1" ;
+		silt:long_name = "UM soil texture - silt fraction" ;
 		silt:_FillValue = -9999.f ;
 		silt:grid_mapping = "crs" ;
+		silt:units = "1" ;
+		silt:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		silt:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float clay(latitude, longitude) ;
-		clay:long_name = "GDAL Band Number 1" ;
+		clay:long_name = "UM soil texture - clay fraction" ;
 		clay:_FillValue = -9999.f ;
 		clay:grid_mapping = "crs" ;
+		clay:units = "1" ;
+		clay:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		clay:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float sand(latitude, longitude) ;
 		sand:_FillValue = -9999.f ;
 		sand:grid_mapping = "crs" ;
-		sand:long_name = "GDAL Band Number 1" ;
+		sand:long_name = "UM soil texture - sand fraction" ;
+		sand:units = "1" ;
+		sand:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		sand:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float css(latitude, longitude) ;
-		css:long_name = "GDAL Band Number 1" ;
+		css:long_name = "Soil specific heat capacity" ;
 		css:_FillValue = -9999.f ;
 		css:grid_mapping = "crs" ;
+		css:units = "J/kg/K" ;
+		css:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		css:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float sfc(latitude, longitude) ;
-		sfc:long_name = "GDAL Band Number 1" ;
+		sfc:long_name = "VOL SMC AT CRIT PT" ;
 		sfc:_FillValue = -9999.f ;
 		sfc:grid_mapping = "crs" ;
+		sfc:units = "m3 m-3" ;
+		sfc:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		sfc:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float rhosoil(latitude, longitude) ;
-		rhosoil:long_name = "GDAL Band Number 1" ;
+		rhosoil:long_name = "SOIL BULK DENSITY" ;
 		rhosoil:_FillValue = -9999.f ;
 		rhosoil:grid_mapping = "crs" ;
+		rhosoil:units = "kg/m^3" ;
+		rhosoil:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		rhosoil:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float bch(latitude, longitude) ;
 		bch:_FillValue = -9999.f ;
 		bch:grid_mapping = "crs" ;
-		bch:long_name = "GDAL Band Number 1" ;
+		bch:long_name = "CLAPP-HORNBERGER B COEFFICIENT" ;
+		bch:units = "1" ;
+		bch:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		bch:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float hyds(latitude, longitude) ;
 		hyds:_FillValue = -9999.f ;
 		hyds:grid_mapping = "crs" ;
-		hyds:long_name = "GDAL Band Number 1" ;
+		hyds:long_name = "SAT SOIL CONDUCTIVITY" ;
+		hyds:units = "m/s" ;
+		hyds:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		hyds:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float ssat(latitude, longitude) ;
 		ssat:_FillValue = -9999.f ;
 		ssat:grid_mapping = "crs" ;
-		ssat:long_name = "GDAL Band Number 1" ;
+		ssat:long_name = "VOL SMC AT SATURATION" ;
+		ssat:units = "1" ;
+		ssat:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		ssat:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float swilt(latitude, longitude) ;
 		swilt:_FillValue = -9999.f ;
 		swilt:grid_mapping = "crs" ;
-		swilt:long_name = "GDAL Band Number 1" ;
+		swilt:long_name = "VOL SMC AT WILTING" ;
+		swilt:units = "1" ;
+		swilt:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		swilt:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	float sucs(latitude, longitude) ;
 		sucs:_FillValue = -9999.f ;
 		sucs:grid_mapping = "crs" ;
-		sucs:long_name = "GDAL Band Number 1" ;
+		sucs:long_name = "SATURATED SOIL WATER SUCTION" ;
+		sucs:units = "m" ;
+		sucs:comment = "Data provided from the Atlas of Australian Soils (digital)" ;
+		sucs:references = "https://doi.org/10.25919/5df03e991672d and https://publications.csiro.au/publications/publication/PIlegacy:889" ;
 	int mvg(latitude, longitude) ;
 		mvg:_FillValue = -9999 ;
 		mvg:grid_mapping = "crs" ;
-		mvg:long_name = "GDAL Band Number 1" ;
+		mvg:long_name = "NVIS major vegetation group (v5.0)" ;
 	float c4frac(latitude, longitude) ;
-		c4frac:long_name = "GDAL Band Number 1" ;
+		c4frac:long_name = "Fractional cover of C4 grass" ;
 		c4frac:_FillValue = -9999.f ;
 		c4frac:grid_mapping = "crs" ;
+		c4frac:units = "1" ;
 
 // global attributes:
 		:title = "CABLE gridinfo file reconciled with CRU forcing" ;
@@ -210,7 +244,7 @@
 			"/home/189/sb8430/gists/regrid_aus_05x05_to_005x005.sh: Clip to Australian region and subsample from 0.5 degrees resolution to 0.05 degrees using nearest neighbour interpolation. 21.10.2024\n",
 			"One iveg and patchfrac dimension added for savanna-tiling. L. Nieradzik 11/2015" ;
 		:map_file = "map_05x05_to_005x005_neareststod.nc" ;
-		:input_file = "gridinfo_out_main.nc" ;
+		:input_file = "gridinfo_out_add-bios-provenance-information.nc" ;
 			"Wed May 31 00:52:23 2023: ncrename -v Band1,c4_grass_frac_cov c4_grass_frac_cov.nc\n",
 			"Wed May 31 00:31:01 2023: GDAL CreateCopy( c4_grass_frac_cov.nc, ... )\n",
 			"Wed May 31 00:52:32 2023: ncrename -v Band1,nvis5pre1750grp nvis5pre1750grp.nc\n",

@SeanBryan51 SeanBryan51 marked this pull request as ready for review October 21, 2024 06:11
@AlisonBennett
Copy link

A few notes from me:

  1. Could we be consistent in whether the long_name is capitalised or non-capitalised? Clay, silt, sand, specific heat capacity, NVIS major vegetation group, and C4 grass fractional cover are all in sentance-case with the remainder in upper case.
  2. Also the unit convention is inconsistent: I think unit of "VOL SMC AT CRIT PT" should changed from "m3 m-3" to "m^3/m^3" (if I've interpreted that correctly)
  3. Update NVIS major vegetation group (v5.0) to include:
    - mvg:comment Data provided from National Vegetation Information System (NVIS)
    - mvg:references https://www.dcceew.gov.au/environment/land/native-vegetation/national-vegetation-information-system/data-products#mvg5
  4. Can we find the reference for C4 grass fractional cover? My understanding is that these are developed from the approach in [Donohue et al 2009](https:// doi. org/ 10. 1111/j. 1365- 2486. 2008. 01746. x) but it would be nice to confirm that before putting it in the code. Perhaps @har917 can help with this?

@SeanBryan51
Copy link
Contributor Author

@AlisonBennett Thanks for taking a look. I've set the sfc units to 1 so that it is consistent with the other dimensionless variables. The long_name descriptions are now in upper case. Waiting on @har917 to confirm the references for c4frac.

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