relhum
Computes the relative humidity from temperature, specific humidity and logarithm of surface pressure (LNSP) GRIB data. LNSP is only required if the input data is specified on ECMWF model levels.
When the result is a Fieldset
the ecCodes paramId in the output is set to 157 (=relative humidity).
The computation is based on the following formula:
where:
e is the vapour pressure (see
vapour_pressure()
)emsat is the saturation vapour pressure based on the “mixed” phase (see
saturation_vapour_pressure()
)q is the specific humidity
p is the pressure
t is the temperature
Note
This function performs the same task as the Relative Humidity icon in Metview’s user interface. It accepts its parameters as keyword arguments, described below.
- relhum(**kwargs)
Computes the relative humidity from temperature and specific humidity GRIB data.
- Parameters
data (
Fieldset
) – Specifies the temperature and specific humidity input GRIB data required for the application. If the input is defined on ECMWF (hybrid/eta) model levels it must contain a Logarithm of Surface Pressure field as well (it must have the ecCodes paramId of 152).- Return type