Recent Releases of FAIR
FAIR - A couple of fixes
v2.2.2 fixes a bug in the direct aerosol scaling that was picking up the scale factor of precursor species, and turns off the warning and debug messages from the logging
module.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap 5 months ago
FAIR - Support for python 3.13
This release formally adds support for python
3.13 on pip
and conda
.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap 6 months ago
FAIR - New convenience functions for ensembles
v2.2 introduces new functionality so is a new minor release of fair
- the first for a while!
The biggest improvement is the ability to define emissions scenarios and parameter sets easily in importable CSV files, and makes defining custom emissions scenarios much more straightforward. This is handled by the new fill_from_csv()
method.
Large probabilistic ensemble parameter sets can be straightforwardly included thanks to the new override_defaults()
method.
An example that shows these features in action is at https://docs.fairmodel.net/en/latest/examples/calibrated_constrained_ensemble.html. There are many fewer lines of code required to run fair
than previously, and hopefully this makes the model a little more intuitive.
While it almost certainly worked before, python 3.12 is now officially supported, and code coverage has been brought up to 100%.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap 10 months ago
FAIR - Fix for species_configs file read from CSV
This version fixes an error that occurred if either CH4 or Aerosol-cloud interactions were missing from the list of species defined and the list of species configs in f.fill_species_configs()
was read in from a CSV file.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap about 1 year ago
FAIR - OHC restart fix and py3.7 dropped
An inconsistency with ocean heat content before and after a restart has now been fixed. It was not affecting results since OHC is a post-processed quantity, only reporting.
One module dependency was failing tests with python 3.7, so support for python 3.7 has been dropped.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 1 year ago
FAIR - Zenodo DOI patch
The move to the new Zenodo API made pooch
fail in the fill_from_rcmip()
convenience function. The path to the emissions files from RCMIP have been updated to directly link to URLs rather than DOIs.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 1 year ago
FAIR - xarray fix and update to documentation
xarray 2023.9.0 introduced a change that broke FaIR with python 3.9+. Following user feedback, documentation has been updated, including, most importantly, an example using the latest available calibration. The positive semi-definite RuntimeWarnings should have also disappeared when running stochastically, or at least can be disabled.
Support for python 3.6 is removed due to dependency issues, and 3.11 added.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 1 year ago
FAIR - v2.1 + documentation
v2.1.0 is an overhaul of FaIR, and includes the following:
- object-oriented design
- interactive methane lifetime
- optional internal variability
- mass parallelisation
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 2 years ago
FAIR - A new interface, and new features
v2.1.0 is an overhaul of FaIR, and includes the following:
- object-oriented design
- interactive methane lifetime
- optional internal variability
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 2 years ago
FAIR - Add module interface for the SSPs
For a number of years, the RCP scenarios have been easily importable into FaIR using something like
from fair.RCPs import rcp45
from fair.forward import fair_scm
conc, forc, temp = fair_scm(rcp45.Emissions.emissions)
You can now do the same with the SSP scenarios from CMIP6:
from fair.SSPs import ssp119
from fair.forward import fair_scm
conc, forc, temp = fair_scm(ssp119.Emissions.emissions)
The following are available: ssp119
, ssp126
, ssp245
, ssp370
, ssp370_lowNTCF
, ssp434
, ssp460
, ssp534
, ssp585
More information is available from O'Neill et al. (2016) and Riahi et al. (2017), and the IPCC's Sixth Assessment Working Group 1 report. The emissions scenarios themselves were compiled by Zeb Nicholls and Jared Lewis and available at https://doi.org/10.5281/zenodo.4589756. Please cite Nicholls et al. (2020) if you use them,
The SSPs are supplied as a convenience as the actual SSP scenarios run for AR6 were done a little differently, but will need a whole configuration change to run as it was there, so it should be noted that results will probably not agree exactly with AR6 or observed history. This is just for people who want to easily get at the scenarios without digging too much into the AR6 repository.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 3 years ago
FAIR - Restarts for Geoffroy temperature function and GIR carbon cycle
An old feature given a new lease of life.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap about 4 years ago
FAIR - Updates to ozone forcing
This micro version introduces an updated treatment to the ozone forcing, which allows for a dependence on N2O concentrations, and a temperature-dependent ozone feedback (this was previously included with the stevenson
treatment, but has now been simplified to be a linear function of temperature). The new treatment follows CMIP6 and AerChemMIP experiments:
Thornhill et al., 2021: https://acp.copernicus.org/articles/21/853/2021/acp-21-853-2021.pdf
Thornhill et al., accepted: https://acp.copernicus.org/preprints/acp-2019-1207/
Skeie et al., 2020: https://www.nature.com/articles/s41612-020-00131-0
Default coefficients that link the emissions to the CMIP6 model forcing in Skeie et al. are provided. In fair_scm()
use tropO3_forcing=thornhill-skeie
to use the new treatment.
Ozone forcing is not split into tropospheric and stratospheric components. For ease of communication with existing versions of FaIR, we maintain the forcing column indices, but all ozone forcing is put into the tropospheric bin (index 4 in 13-species FaIR, or index 31 in 45-species FaIR).
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 4 years ago
FAIR - 45-species FaIR
This version expands the multispecies version of FaIR to report 45 (previously 41) forcing species. Some fixes for running concentration driven runs with the 45-species FaIR have been implemented as well as including specified forcing and Geoffroy temperature options for inverse FaIR. scmdata
interface has been removed.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 4 years ago
FAIR - Fix for 45-species concentration driven runs
Minor version incremented to reflect bug fix that previously used 13-species indices for some species when concentration-driven. All other functionality same as 1.6.0 series.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 4 years ago
FAIR - Compatibility with scmdata-0.7.1
No other changes, just plumbing
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 4 years ago
FAIR - Delete rogue print statement
My bad.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 4 years ago
FAIR - v1.6 release candidate
Includes:
- Geoffroy two-layer temperature specification
- Reading of emissions files using the
ScmDataFrame
- setup and communication with
openscm-runner
Day to day operation unchanged from v1.5 - should be no surprises.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap almost 5 years ago
FAIR - openscm-runner alpha version
This version should contain all the right stuff to run FaIR from openscm-runner.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap almost 5 years ago
FAIR - openSCM testing
Inclusion of airborne fraction
Also testing this version with PyPI upload through openscm-runner
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap almost 5 years ago
FAIR - more plumbing for openscm-runner
Also graft the SSP data into the distribution.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap almost 5 years ago
FAIR - Additional features
This release includes:
- GIR carbon cycle (only for CO2), eliminating dependence on
scipy.root
and speeding up runtime - Two-layer temperature model from Held et al. (2010)/Geoffroy et al. (2013), allowing for ocean heat uptake to be diagnosed directly. Shout outs to Glen Harris and Zeb Nicholls
ScmDataFrame
reader, for compatibility withiiasa-climate-assessment
andopenscm-runner
to ingest scenarios from IPCC Working Group 3
Nothing here should break back-compatibility but there is now a minefield of configurations to run fair_scm
with and the interface became unmanageable a long time ago to the uninitiated. Sensible defaults will be packaged with openscm-runner
, otherwise this will be sorted out in v2.0.
Finally, python2 is no longer guaranteed to work. Python 3.5 should work but 3.6+ is recommended for future compatibility with unit handling.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap almost 5 years ago
FAIR - Add keywords to `fair_scm` call
For allowing user to modify hardwired CMIP5/AR5 emissions to forcing relationships.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap about 5 years ago
FAIR - RCMIP phase 1
Code freeze for RCMIP phase 1: www.rcmip.org
Minor fixes to aerosol, ozone and contrail forcings to specify a custom baseline.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 5 years ago
FAIR - RCMIP-interim
A few interim patches included in the trunk before the target RCMIP phase 1 release:
- Fixed Stevenson aerosol forcing in call from
fair_scm
- API keyword to turn off scaling F2x in call to
fair_scm
(we don't want this by default now, as AR6 F2x may not be the same as AR5) - Add AR6 gases molecular weights and radiative efficiencies (not included in multigas run yet)
- ValueError for attempting to infill CFCs before 1765
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 5 years ago
FAIR - Inverse FaIR
This new release of FaIR allows diagnosis of CO2 emissions from concentrations. See the fair.inverse
module for details (and also the Examples page at https://fair.readthedocs.io/en/latest/examples.html#running-in-concentration-driven-mode).
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap almost 6 years ago
FAIR - Restart consistency
The behaviour of restart_out
and restart_in
has been formalised. This allows the carbon cycle and ocean thermal response state from one run to be saved and used as boundary conditions for a second run.
One internal book-keeping change: inside FaIR, CO2 concentrations are now an absolute value rather than a difference from pre-industrial.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 6 years ago
FAIR - FaIR rename; repo restructure; GWP tool
FAIR has been renamed FaIR: the acronym has changed to reduce confusion with an existing environmental policy decision model called FAIR.
Repository has been updated to include code coverage reports, pull request / issue templates, ReadTheDocs yaml and Makefile.
A Global Warming potential calculator has also been added.
No changes to science code from earlier in the 1.3 series.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 6 years ago
FAIR - Concentration driven functionality / ensemble generator / bug fixes
Bug fixes:
- #40: some data files not included when installing
- #39 (part of): historical forcing scaling factor default time series did not have enough years
New features:
- #39: concentration driven (and forcing driven) runs now possible
- #38: ensemble generator with joint lognormal ECS/TCR distribution provided
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 6 years ago
FAIR - Small updates
Here #34 (a tool to calculate steady state emissions) and #36 (consistency in RCP naming) have been addressed. Technically this should be a minor release, rather than a patch as #34 adds functionality - we'll do semantic versioning from v2.0 I promise - but unless anything is broken the v1.3 series indicates (to me, at least!) that nothing should have changed from the GMD paper.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 6 years ago
FAIR - Multigas "final" release
Default aerosol treatment has been changed since the v1.2 series:
- organic carbon, sulfate, nitrate and VOC follow their exact radiative efficiency from Aerocom
- black carbon's radiative efficiency is lowered, to account for rapid adjustments (semi-direct effects), so that the default ERFari in 2010 is -0.45 W/m2.
Black carbon on snow now has a default efficacy of 3, to match what is specified in Smith et al. (2018).
The option to add a time-varying scaling factor for CO2 forcing in CO2-only mode has been included.
Linked documentation has also been added (not included in packaged version - hopefully...).
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap almost 7 years ago
FAIR - Time-varying forcing scalings
This minor release allows for two additional features:
- a time-varying historical scaling factor for effective radiative forcing (set
scale
to a 2D array; usingscale=None
gives the default scaling factor as an array of ones) - the ability to specify the radiative efficiencies for each aerosol and tropospheric ozone precursor separately with the
b_aero
andb_tro3
options in the call tofair_scm
.
There is also a very minor bug fix compared to v1.2.2, which relates to the setup.py
file pointing to the wrong README
.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap almost 7 years ago
FAIR - Improved aerosol/ozone relationships, varying ECS/TCR, and other changes
Welcome to the version 1.2.1 release! Several improvements to the non-CO2 forcing have been made compared to v1.1. Additionally ECS and TCR can now also be time-varying.
- Natural emissions of CH4 and N2O are fully backed-out of the RCP scenarios so that the historical concentrations match precisely up to 2005. This is desirable, because published concentration datasets (e.g. from Meinshausen et al.) represent our best estimate of the evolution of greenhouse gases and are likely to exhibit much less uncertainty than any emissions input dataset.
- Tropospheric ozone forcing relationships from Stevenson et al., 2013 have been implemented in preference to the old regression-based treatment. Also included is the effect of temperature on ozone forcing.
- Direct aerosol forcing relationships (treated as ERFari in FAIR) from Myhre et al., 2013 have been implemented in preference to the old regression-based treatment.
- Indirect aerosol forcing relationships (treated as ERFaci) are also implemented. We use a logarithmic dependence of aerosol indirect forcing on emissions. This is inspired by the simple model of Stevens 2015 based on a least-squares curve fit from the global aerosol indirect model of Ghan et al., 2013. The Ghan model emulates the results of several climate models.
- The option to scale aerosol forcing to the AR5 best estimate of -0.45W/m2 for ERFari and -0.45W/m2 for ERFaci given 2011 emissions is included as an option (true by default). Use
scaleAerosolAR5=False
in the call tofair_scm
to turn off this behaviour. - Aerosols and tropospheric ozone include an option to ensure that the forcing from 1765 to 1850 follows a trajectory between zero and the 1850 value. Anthropogenic emissions were non-zero in 1750/1765 (Skeie et al., 2011) but the RCPs start from zero. Using RCP (zero-based) values leads to forcings that are too large in 1850 relative to 1765. We therefore assume the Skeie emissions are the true "pre-industrial". If the option is turned off (set
fixPre1850RCP=False
in the call tofair_scm
), or if the date of the simulation is after 1850, then zero emissions will result in a negative tropospheric ozone / positive aerosol forcing. This is by design. - An option to include a time-varying ECS and TCR has been included by specifying
tcrecs
as a 2D array. - Default options to
fair_scm
have been changed to reflect (mostly) the ensemble setup in the GMD paper, including inclusion of natural emissions, solar and volcanic forcing, anduseMultigas=True
by default. - The code is identical to v1.2. A small change to the metadata was needed for compatibility with PyPI.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap about 7 years ago
FAIR - Dependency fixes and SCEN file support
This micro-release enables compatibility with slightly older versions of numpy (1.11+) compared to the previous release which would only work with numpy 1.13+. This would particularly affect users running with Enthought Canopy. The setup.py script has been modified to check that the user has compatible versions of numpy and scipy.
Functionality added to read in MAGICC SCEN files directly.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap about 7 years ago
FAIR - Python 3 compatibility and RCPs included in package
The previous versions 1.1 and 1.1.1 contained a few minor omissions which have been rectified in this micro release, including:
- Python 3 compatibility
- Inclusion of RCP emission files in PyPI package
- Ensuring true division when using Python 2
- Continuous integration
- automatic version tracking with versioneer, so that now the version tags on GitHub and PyPI should agree exactly!
Thanks to Robert Gieseke for doing quite a lot of the work in getting this repository up to scratch.
There are no science changes in this micro release.
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 7 years ago
FAIR - Emissions-based, multi-species FAIR simple climate model
This release allows the user to specify all greenhouse gas emissions, aerosol and ozone precursors given in the RCPs for CMIP5 (http://www.pik-potsdam.de/~mmalte/rcps/). It is back-compatible with FAIR v1.0, and can still be run in CO2-only mode.
FAIR provides GHG concentrations for 31 species, radiative forcing for 13 separate forcing components, and integrates these into temperature change since the pre-industrial era.
For further details please see the reference publication: https://www.geosci-model-dev-discuss.net/gmd-2017-266/
Climate Change - Earth and Climate Modeling
- Python
Published by chrisroadmap over 7 years ago
FAIR - Original (carbon cycle and non-CO2 radiative forcing)
Original FAIR release with carbon-cycle and non-CO2 drivers provided by a radiative forcing timeseries
Climate Change - Earth and Climate Modeling
- Python
Published by richardcode over 7 years ago