oggm.tasks.mb_calibration_from_geodetic_mb#
- oggm.tasks.mb_calibration_from_geodetic_mb(gdir, *, ref_period=None, write_to_gdir=True, overwrite_gdir=False, override_missing=None, informed_threestep=False, calibrate_param1='melt_f', calibrate_param2=None, calibrate_param3=None, mb_model_class=<class 'oggm.core.massbalance.MonthlyTIModel'>)[source]#
Calibrate for geodetic MB data from Hugonnet et al., 2021.
The data table can be obtained with utils.get_geodetic_mb_dataframe(). It is equivalent to the original data from Hugonnet, but has some outlier values filtered. See this notebook for more details.
The problem of calibrating many unknown parameters on geodetic data is currently unsolved. This is OGGM’s current take, based on trial and error and based on ideas from the literature.
- Parameters
- gdir
oggm.GlacierDirectory
the glacier directory to calibrate
- ref_periodstr, default: PARAMS[‘geodetic_mb_period’]
one of ‘2000-01-01_2010-01-01’, ‘2010-01-01_2020-01-01’, ‘2000-01-01_2020-01-01’. If ref_mb is set, this should still match the same format but can be any date.
- write_to_gdirbool
whether to write the results of the calibration to the glacier directory. If True (the default), this will be saved as mb_calib.json and be used by the MassBalanceModel class as parameters in subsequent tasks.
- overwrite_gdirbool
if a mb_calib.json exists, this task won’t overwrite it per default. Set this to True to enforce overwriting (i.e. with consequences for the future workflow).
- override_missingscalar
if the reference geodetic data is not available, use this value instead (mostly for testing with exotic datasets, but could be used to open the door to using other datasets).
- informed_threestepbool
the magic method Fabi found out one day before release. Overrides the calibrate_param order below.
- calibrate_param1str
in the three-step calibration, the name of the first parameter to calibrate (one of ‘melt_f’, ‘temp_bias’, ‘prcp_fac’).
- calibrate_param2str
in the three-step calibration, the name of the second parameter to calibrate (one of ‘melt_f’, ‘temp_bias’, ‘prcp_fac’). If not set and the algorithm cannot match observations, it will raise an error.
- calibrate_param3str
in the three-step calibration, the name of the third parameter to calibrate (one of ‘melt_f’, ‘temp_bias’, ‘prcp_fac’). If not set and the algorithm cannot match observations, it will raise an error.
- mb_model_classMassBalanceModel class
the MassBalanceModel to use for the calibration. Needs to use the same parameters as MonthlyTIModel (the default): melt_f, temp_bias, prcp_fac.
- gdir
- Returns
- the calibrated parameters as dict
Notes
- Files written to the glacier directory:
- mb_calib.json
A dict containing the glacier’s mass balance calibration parameters.