198808xc / Pangu-Weather

An official implementation of Pangu-Weather
1.1k stars 202 forks source link

Geopotential #61

Open oceanoff opened 5 months ago

oceanoff commented 5 months ago

Greetings and thank you for such an open-source project! I would like to clarify two questions about geopotential variable produced for 13 pressure levels output:

  1. I use 24 hrs forecast and received some negative values for 1000hPa level (March 2024) for geopotential height (m), is it reasonable?
  2. Did I understand correctly that PanGu provides geopotential height (m) - not the geopotential itself (sqr. meters/sqr. seconds) ? Thanks in advance for any update here.
oceanoff commented 5 months ago

Hi Filipp,

Our model predicts geopotential (in m^2/s^2), not height (in m). So, we did not expect to obtain negative values. Please try to debug your code and, if the problem persists, please check our sample input/output for reference.

Best, Lingxi

Thank you for quick response. Here is the 'ncdump -h' of my output produced by Pangu (24hrs): netcdf output_upper_2024-03-12-12-00 { dimensions: longitude = 1440 ; latitude = 721 ; level = 13 ; variables: float longitude(longitude) ; longitude:units = "degrees_east" ; float latitude(latitude) ; latitude:units = "degrees_north" ; float geopotential(level, latitude, longitude) ; geopotential:units = "m" ; float specific_humidity(level, latitude, longitude) ; specific_humidity:units = "kg/kg" ; float temperature(level, latitude, longitude) ; temperature:units = "K" ; float u_component_of_wind(level, latitude, longitude) ; u_component_of_wind:units = "m/s" ; float v_component_of_wind(level, latitude, longitude) ; v_component_of_wind:units = "m/s" ; }

Here is geopotential presented by "m' units. "float geopotential(level, latitude, longitude) ; geopotential:units = "m" ;"

oceanoff commented 5 months ago

@198808xc Here is a screenshot with variables (min and max) for Pangu (24hr) output. 1 : 0000-00-00 00:00:00 1 1038240 0 : -4527.2 703.12 3128.8 : geopotential Below

oceanoff commented 5 months ago

Pangu_output_1_upper

198808xc commented 5 months ago

Sorry for my oversight. Yes, our model receives and predicts geopotential height, so it may contain negative values. Please check out the sample file, input_upper.npy', which contains negative values in 1000hPa geopotential heights, i.e.input_upper[0, 0, :, :]'.

I checked your screenshot and found that the numerical distributions are quite similar to those produced by our sample data. At least from the provided information, the results look correct.

I deleted the previous post to avoid confusion.

Lingxi

oceanoff commented 5 months ago

Sorry for my oversight. Yes, our model receives and predicts geopotential height, so it may contain negative values. Please check out the sample file, input_upper.npy', which contains negative values in 1000hPa geopotential heights, i.e.input_upper[0, 0, :, :]'.

I checked your screenshot and found that the numerical distributions are quite similar to those produced by our sample data. At least from the provided information, the results look correct.

I deleted the previous post to avoid confusion.

Lingxi

Thank you for reply. I think that issue is somewhere in code that produces the Decoding for inference output (possibly). So, if we will compare 'geopotential' values and 'z' values (ERA5 product) - there are quite similar (not multiplied on Gravitational constant). Therefore - I was confused only by units 'm', actually the model produces Geopotential Energy (m^2/s^2) as you mentioned earlier. Sorry for misunderstandings. Finally we cross-checked the variables.