{"id":19565452,"url":"https://github.com/ouranosinc/xclim","last_synced_at":"2025-05-14T15:06:17.957Z","repository":{"id":37301181,"uuid":"142608764","full_name":"Ouranosinc/xclim","owner":"Ouranosinc","description":"Library of derived climate variables, ie climate indicators, based on xarray. ","archived":false,"fork":false,"pushed_at":"2025-04-11T15:22:58.000Z","size":63122,"stargazers_count":353,"open_issues_count":53,"forks_count":64,"subscribers_count":15,"default_branch":"main","last_synced_at":"2025-04-12T01:55:33.779Z","etag":null,"topics":["anuclim","climate-analysis","climate-science","dask","icclim","netcdf4","python","xarray","xclim"],"latest_commit_sha":null,"homepage":"https://xclim.readthedocs.io/en/stable/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Ouranosinc.png","metadata":{"files":{"readme":"README.rst","changelog":"CHANGELOG.rst","contributing":"CONTRIBUTING.rst","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":"SECURITY.md","support":"docs/support.rst","governance":null,"roadmap":null,"authors":"AUTHORS.rst","dei":null,"publiccode":null,"codemeta":null,"zenodo":".zenodo.json"}},"created_at":"2018-07-27T18:02:20.000Z","updated_at":"2025-04-11T15:23:01.000Z","dependencies_parsed_at":"2023-09-21T19:33:31.279Z","dependency_job_id":"a2aa842e-8324-4efc-8fee-3eb8a3f75a4d","html_url":"https://github.com/Ouranosinc/xclim","commit_stats":{"total_commits":7091,"total_committers":58,"mean_commits":"122.25862068965517","dds":0.6264278663094063,"last_synced_commit":"e4aca673ffb3e3e5e29d8247e6231b84ae2b8a1c"},"previous_names":[],"tags_count":87,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ouranosinc%2Fxclim","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ouranosinc%2Fxclim/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ouranosinc%2Fxclim/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Ouranosinc%2Fxclim/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Ouranosinc","download_url":"https://codeload.github.com/Ouranosinc/xclim/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248505867,"owners_count":21115354,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["anuclim","climate-analysis","climate-science","dask","icclim","netcdf4","python","xarray","xclim"],"created_at":"2024-11-11T05:26:53.451Z","updated_at":"2025-04-12T01:55:52.200Z","avatar_url":"https://github.com/Ouranosinc.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"===============================================================\nxclim: Climate services library |logo| |logo-dark| |logo-light|\n===============================================================\n\n+----------------------------+-----------------------------------------------------+\n| Versions                   | |pypi| |conda| |versions|                           |\n+----------------------------+-----------------------------------------------------+\n| Documentation and Support  | |docs| |discussions|                                |\n+----------------------------+-----------------------------------------------------+\n| Open Source                | |license| |ossf-score| |zenodo| |pyOpenSci| |joss|  |\n+----------------------------+-----------------------------------------------------+\n| Coding Standards           | |ruff| |pre-commit| |ossf-bp| |fossa|               |\n+----------------------------+-----------------------------------------------------+\n| Development Status         | |status| |build| |coveralls|                        |\n+----------------------------+-----------------------------------------------------+\n\n`xclim` is an operational Python library for climate services, providing numerous climate-related indicator tools\nwith an extensible framework for constructing custom climate indicators, statistical downscaling and bias\nadjustment of climate model simulations, as well as climate model ensemble analysis tools.\n\n`xclim` is built using `xarray`_ and can seamlessly benefit from the parallelization handling provided by `dask`_.\nIts objective is to make it as simple as possible for users to perform typical climate services data treatment workflows.\nLeveraging `xarray` and `dask`, users can easily bias-adjust climate simulations over large spatial domains or compute indices from large climate datasets.\n\nFor example, the following would compute monthly mean temperature from daily mean temperature:\n\n.. code-block:: python\n\n    import xclim\n    import xarray as xr\n\n    ds = xr.open_dataset(filename)\n    tg = xclim.atmos.tg_mean(ds.tas, freq=\"MS\")\n\nFor applications where metadata and missing values are important to get right, `xclim` provides a class for each index\nthat validates inputs, checks for missing values, converts units and assigns metadata attributes to the output.\nThis also provides a mechanism for users to customize the indices to their own specifications and preferences.\n`xclim` currently provides over 150 indices related to mean, minimum and maximum daily temperature, daily precipitation,\nstreamflow and sea ice concentration, numerous bias-adjustment algorithms, as well as a dedicated module for ensemble analysis.\n\n.. _xarray: https://docs.xarray.dev/\n.. _dask: https://docs.dask.org/\n\nQuick Install\n-------------\n`xclim` can be installed from PyPI:\n\n.. code-block:: shell\n\n    $ pip install xclim\n\nor from Anaconda (conda-forge):\n\n.. code-block:: shell\n\n    $ conda install -c conda-forge xclim\n\nDocumentation\n-------------\nThe official documentation is at https://xclim.readthedocs.io/\n\nHow to make the most of xclim: `Basic Usage Examples`_ and `In-Depth Examples`_.\n\n.. _Basic Usage Examples: https://xclim.readthedocs.io/en/stable/notebooks/usage.html\n.. _In-Depth Examples: https://xclim.readthedocs.io/en/stable/notebooks/index.html\n\nConventions\n-----------\nIn order to provide a coherent interface, `xclim` tries to follow different sets of conventions. In particular, input data should follow the `CF conventions`_ whenever possible for variable attributes. Variable names are usually the ones used in `CMIP6`_, when they exist.\n\nHowever, `xclim` will *always* assume the temporal coordinate is named \"time\". If your data uses another name (for example: \"T\"), you can rename the variable with:\n\n.. code-block:: python\n\n    ds = ds.rename(T=\"time\")\n\n`xclim` employs `black`_-like code formatting style, a modified `ruff`_ linting configuration, and (mostly) adheres to the `NumPy docstring`_ style. For more information on coding and development conventions, see the `Contributing Guidelines`_.\n\n.. _black: https://black.readthedocs.io/en/stable/\n.. _ruff: https://docs.astral.sh/ruff/\n.. _CF Conventions: http://cfconventions.org/\n.. _CMIP6: https://clipc-services.ceda.ac.uk/dreq/mipVars.html\n.. _NumPy docstring: https://numpydoc.readthedocs.io/en/stable/format.html\n\nContributing to xclim\n---------------------\n`xclim` is in active development and is being used in production by climate services specialists around the world.\n\n* If you're interested in participating in the development of `xclim` by suggesting new features, new indices or report bugs, please leave us a message on the `issue tracker`_.\n    * If you have a support/usage question or would like to translate `xclim` to a new language, be sure to check out the existing |discussions| first!\n\n* If you would like to contribute code or documentation (which is greatly appreciated!), check out the `Contributing Guidelines`_ before you begin!\n\n.. _issue tracker: https://github.com/Ouranosinc/xclim/issues\n.. _Contributing Guidelines: https://github.com/Ouranosinc/xclim/blob/main/CONTRIBUTING.rst\n\nHow to cite this library\n------------------------\nIf you wish to cite `xclim` in a research publication, we kindly ask that you refer to our article published in The Journal of Open Source Software (`JOSS`_): https://doi.org/10.21105/joss.05415\n\nTo cite a specific version of `xclim`, the bibliographical reference information can be found through `Zenodo`_\n\n.. _JOSS: https://joss.theoj.org/\n.. _Zenodo: https://doi.org/10.5281/zenodo.2795043\n\nLicense\n-------\nThis is free software: you can redistribute it and/or modify it under the terms of the `Apache License 2.0`_. A copy of this license is provided in the code repository (`LICENSE`_).\n\n.. _Apache License 2.0: https://opensource.org/license/apache-2-0/\n.. _LICENSE: https://github.com/Ouranosinc/xclim/blob/main/LICENSE\n\nEnergy and Carbon Usage\n-----------------------\nThe `xclim` development team is interested in thoroughly testing our software while also reducing the environmental impact of the software we develop.\nThis repository uses the `ECO-CI`_ tool to estimate and track the energy use and carbon emissions of our continuous integration workflows.\n\n+---------------------------------------------------------------------------------------+\n| `ECO-CI`_ Energy Use and Carbon Emissions from CI Workflows (since November 2024)     |\n+------------------+------------------+-------------------------------------------------+\n| Testing suite    | Energy Usage     | |energy-last| |energy-average| |energy-total|   |\n|                  +------------------+-------------------------------------------------+\n| (*main* branch)  | Carbon Emissions | |carbon-last| |carbon-average| |carbon-total|   |\n+------------------+------------------+-------------------------------------------------+\n\nCredits\n-------\n`xclim` development is funded through Ouranos_, Environment and Climate Change Canada (ECCC_), the `Fonds vert`_ and the Fonds d'électrification et de changements climatiques (FECC_), the Canadian Foundation for Innovation (CFI_), and the Fonds de recherche du Québec (FRQ_).\n\nThis package was created with Cookiecutter_ and the `audreyfeldroy/cookiecutter-pypackage`_ project template.\n\n.. _audreyfeldroy/cookiecutter-pypackage: https://github.com/audreyfeldroy/cookiecutter-pypackage/\n.. _CFI: https://www.innovation.ca/\n.. _Cookiecutter: https://github.com/cookiecutter/cookiecutter/\n.. _ECCC: https://www.canada.ca/en/environment-climate-change.html\n.. _ECO-CI: https://www.green-coding.io/\n.. _FECC: https://www.environnement.gouv.qc.ca/ministere/fonds-electrification-changements-climatiques/index.htm\n.. _Fonds vert: https://www.environnement.gouv.qc.ca/ministere/fonds-vert/index.htm\n.. _FRQ: https://frq.gouv.qc.ca/\n.. _Ouranos: https://www.ouranos.ca/\n\n.. |pypi| image:: https://img.shields.io/pypi/v/xclim.svg\n        :target: https://pypi.python.org/pypi/xclim\n        :alt: Python Package Index Build\n\n.. |conda| image:: https://img.shields.io/conda/vn/conda-forge/xclim.svg\n        :target: https://anaconda.org/conda-forge/xclim\n        :alt: Conda-forge Build Version\n\n.. |discussions| image:: https://img.shields.io/badge/GitHub-Discussions-blue\n        :target: https://github.com/Ouranosinc/xclim/discussions\n        :alt: Static Badge\n\n.. |build| image:: https://github.com/Ouranosinc/xclim/actions/workflows/main.yml/badge.svg\n        :target: https://github.com/Ouranosinc/xclim/actions/workflows/main.yml\n        :alt: Build Status\n\n.. |coveralls| image:: https://coveralls.io/repos/github/Ouranosinc/xclim/badge.svg\n        :target: https://coveralls.io/github/Ouranosinc/xclim\n        :alt: Coveralls\n\n.. |docs| image:: https://readthedocs.org/projects/xclim/badge\n        :target: https://xclim.readthedocs.io/en/latest\n        :alt: Documentation Status\n\n.. |zenodo| image:: https://zenodo.org/badge/142608764.svg\n        :target: https://zenodo.org/badge/latestdoi/142608764\n        :alt: DOI\n\n.. |pyOpenSci| image:: https://tinyurl.com/y22nb8up\n        :target: https://github.com/pyOpenSci/software-review/issues/73\n        :alt: pyOpenSci\n\n.. |joss| image:: https://joss.theoj.org/papers/10.21105/joss.05415/status.svg\n        :target: https://doi.org/10.21105/joss.05415\n        :alt: JOSS\n\n.. |license| image:: https://img.shields.io/github/license/Ouranosinc/xclim.svg\n        :target: https://github.com/Ouranosinc/xclim/blob/main/LICENSE\n        :alt: License\n\n.. |ossf-bp| image:: https://bestpractices.coreinfrastructure.org/projects/6041/badge\n        :target: https://bestpractices.coreinfrastructure.org/projects/6041\n        :alt: Open Source Security Foundation Best Practices\n\n.. |ossf-score| image:: https://api.securityscorecards.dev/projects/github.com/Ouranosinc/xclim/badge\n        :target: https://securityscorecards.dev/viewer/?uri=github.com/Ouranosinc/xclim\n        :alt: Open Source Security Foundation Scorecard\n\n.. |fossa| image:: https://app.fossa.com/api/projects/git%2Bgithub.com%2FOuranosinc%2Fxclim.svg?type=shield\n        :target: https://app.fossa.com/projects/git%2Bgithub.com%2FOuranosinc%2Fxclim?ref=badge_shield\n        :alt: FOSSA\n\n.. |logo| image:: https://raw.githubusercontent.com/Ouranosinc/xclim/main/docs/logos/xclim-logo-small-light.png\n        :target: https://github.com/Ouranosinc/xclim\n        :alt: Xclim\n        :class: xclim-logo-small no-theme\n\n.. |logo-light| image:: https://raw.githubusercontent.com/Ouranosinc/xclim/main/docs/logos/empty.png\n        :target: https://github.com/Ouranosinc/xclim\n        :alt:\n        :class: xclim-logo-small only-light-inline\n\n.. |logo-dark| image:: https://raw.githubusercontent.com/Ouranosinc/xclim/main/docs/logos/empty.png\n        :target: https://github.com/Ouranosinc/xclim\n        :alt:\n        :class: xclim-logo-small only-dark-inline\n\n.. |pre-commit| image:: https://results.pre-commit.ci/badge/github/Ouranosinc/xclim/main.svg\n        :target: https://results.pre-commit.ci/latest/github/Ouranosinc/xclim/main\n        :alt: pre-commit.ci status\n\n.. |ruff| image:: https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json\n        :target: https://github.com/astral-sh/ruff\n        :alt: Ruff\n\n.. |status| image:: https://www.repostatus.org/badges/latest/active.svg\n        :target: https://www.repostatus.org/#active\n        :alt: Project Status: Active – The project has reached a stable, usable state and is being actively developed.\n\n.. |versions| image:: https://img.shields.io/pypi/pyversions/xclim.svg\n        :target: https://pypi.python.org/pypi/xclim\n        :alt: Supported Python Versions\n\n..\n    Energy Metrics by https://github.com/green-coding-solutions/eco-ci-energy-estimation\n\n.. |energy-total| image:: https://api.green-coding.io/v1/ci/badge/get?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\u0026mode=totals\n        :target: https://metrics.green-coding.io/ci.html?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\n        :alt: Energy Consumption (Total)\n\n.. |energy-last| image:: https://api.green-coding.io/v1/ci/badge/get?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\n        :target: https://metrics.green-coding.io/ci.html?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\n        :alt: Energy Consumption (Last run)\n\n.. |energy-average| image:: https://api.green-coding.io/v1/ci/badge/get?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\u0026mode=avg\u0026duration_days=90\n        :target: https://metrics.green-coding.io/ci.html?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\n        :alt: Energy Consumption (Last 90 days moving average)\n\n.. |carbon-total| image:: https://api.green-coding.io/v1/ci/badge/get?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\u0026mode=totals\u0026metric=carbon\n        :target: https://metrics.green-coding.io/ci.html?repo=Ouranosinc/xclim\u0026branch=festive-indices\u0026workflow=5828641\n        :alt: Carbon Emissions (Total)\n\n.. |carbon-last| image:: https://api.green-coding.io/v1/ci/badge/get?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\u0026metric=carbon\n        :target: https://metrics.green-coding.io/ci.html?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\n        :alt: Carbon Emissions (Last run)\n\n.. |carbon-average| image:: https://api.green-coding.io/v1/ci/badge/get?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\u0026mode=avg\u0026duration_days=90\u0026metric=carbon\n        :target: https://metrics.green-coding.io/ci.html?repo=Ouranosinc/xclim\u0026branch=main\u0026workflow=5828641\n        :alt: Carbon Emissions (Last 90 days moving average)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fouranosinc%2Fxclim","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fouranosinc%2Fxclim","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fouranosinc%2Fxclim/lists"}