cl-hubeau


Namecl-hubeau JSON
Version 0.1.1 PyPI version JSON
download
home_pagehttps://github.com/tgrandje/cl-hubeau/
SummaryHubeau client to collect data from the different APIs
upload_time2024-07-29 15:19:04
maintainerNone
docs_urlNone
authorThomas Grandjean
requires_python<4.0,>=3.9
licenseGPL-3.0-or-later
keywords france water hydrology
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # cl-hubeau

Simple hub'eau client for python

This package is currently under active development.
Every API on [Hub'eau](hubeau.eaufrance.fr/) will be covered by this package in due time.

## Basic examples

### Piezometry

3 high level functions are available (and one class for more low level operations).

```python

from cl_hubeau.piezometry import get_all_stations, get_chronicles, get_realtime_chronicles, PiezometrySession


# Get all piezometers (uses a 30 days caching)

gdf = get_all_stations()

# Get chronicles for the first 100 piezometers (uses a 30 days caching)

df = get_chronicles(gdf["code_bss"].head(100).tolist())

# Get realtime data for the first 100 piezometers (no cache stored)

df = get_realtime_chronicles(gdf["code_bss"].head(100).tolist())

# Low level class to perform the same tasks:
# (note that the API is currently forbidding results > 20k rows and you may need inner loops)

with PiezometrySession() as session:
    df = session.get_chronicles(code_bss="07548X0009/F")
    df = session.get_stations(code_departement=['02', '59', '60', '62', '80'], format="geojson")
    df = session.get_chronicles_real_time(code_bss="07548X0009/F")

```
            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/tgrandje/cl-hubeau/",
    "name": "cl-hubeau",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.9",
    "maintainer_email": null,
    "keywords": "france, water, hydrology",
    "author": "Thomas Grandjean",
    "author_email": "thomas.grandjean@developpement-durable.gouv.fr",
    "download_url": "https://files.pythonhosted.org/packages/22/0d/29e528589e2d11206b236f06e517d1b095e6fdb6cd93ca1c2122a1daedbd/cl_hubeau-0.1.1.tar.gz",
    "platform": null,
    "description": "# cl-hubeau\n\nSimple hub'eau client for python\n\nThis package is currently under active development.\nEvery API on [Hub'eau](hubeau.eaufrance.fr/) will be covered by this package in due time.\n\n## Basic examples\n\n### Piezometry\n\n3 high level functions are available (and one class for more low level operations).\n\n```python\n\nfrom cl_hubeau.piezometry import get_all_stations, get_chronicles, get_realtime_chronicles, PiezometrySession\n\n\n# Get all piezometers (uses a 30 days caching)\n\ngdf = get_all_stations()\n\n# Get chronicles for the first 100 piezometers (uses a 30 days caching)\n\ndf = get_chronicles(gdf[\"code_bss\"].head(100).tolist())\n\n# Get realtime data for the first 100 piezometers (no cache stored)\n\ndf = get_realtime_chronicles(gdf[\"code_bss\"].head(100).tolist())\n\n# Low level class to perform the same tasks:\n# (note that the API is currently forbidding results > 20k rows and you may need inner loops)\n\nwith PiezometrySession() as session:\n    df = session.get_chronicles(code_bss=\"07548X0009/F\")\n    df = session.get_stations(code_departement=['02', '59', '60', '62', '80'], format=\"geojson\")\n    df = session.get_chronicles_real_time(code_bss=\"07548X0009/F\")\n\n```",
    "bugtrack_url": null,
    "license": "GPL-3.0-or-later",
    "summary": "Hubeau client to collect data from the different APIs",
    "version": "0.1.1",
    "project_urls": {
        "Documentation": "https://github.com/tgrandje/cl-hubeau/",
        "Homepage": "https://github.com/tgrandje/cl-hubeau/",
        "Repository": "https://github.com/tgrandje/cl-hubeau/"
    },
    "split_keywords": [
        "france",
        " water",
        " hydrology"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "868703758d0f1bc949f777b6ff79bda16cc9093ec5983fbc9103bc4c00d6a326",
                "md5": "bc53c3bf895e3298449902d64f254c68",
                "sha256": "85ecb38e651e29880483152b9019c53d68e664cf821dc32ddaf8fde9b12457e4"
            },
            "downloads": -1,
            "filename": "cl_hubeau-0.1.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "bc53c3bf895e3298449902d64f254c68",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.9",
            "size": 8116,
            "upload_time": "2024-07-29T15:19:03",
            "upload_time_iso_8601": "2024-07-29T15:19:03.266621Z",
            "url": "https://files.pythonhosted.org/packages/86/87/03758d0f1bc949f777b6ff79bda16cc9093ec5983fbc9103bc4c00d6a326/cl_hubeau-0.1.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "220d29e528589e2d11206b236f06e517d1b095e6fdb6cd93ca1c2122a1daedbd",
                "md5": "21e81fc1cfc5a65c128b31efec71a383",
                "sha256": "1846907b781804318c8623d18fc5bb88095fadb9d59635303247ce6bebe6c76a"
            },
            "downloads": -1,
            "filename": "cl_hubeau-0.1.1.tar.gz",
            "has_sig": false,
            "md5_digest": "21e81fc1cfc5a65c128b31efec71a383",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.9",
            "size": 6598,
            "upload_time": "2024-07-29T15:19:04",
            "upload_time_iso_8601": "2024-07-29T15:19:04.376500Z",
            "url": "https://files.pythonhosted.org/packages/22/0d/29e528589e2d11206b236f06e517d1b095e6fdb6cd93ca1c2122a1daedbd/cl_hubeau-0.1.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-07-29 15:19:04",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "tgrandje",
    "github_project": "cl-hubeau",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "cl-hubeau"
}
        
Elapsed time: 0.31973s