pygbif
Making the data of the Global Biodiversity Information Facility API accessible via Python.
https://github.com/gbif/pygbif
Category: Biosphere
Sub Category: Biodiversity Data Access and Management
Keywords
api biodiversity data ecology gbif
Keywords from Contributors
lifewatch oscibio biodiversity-informatics occurrence species spocc taxonomies weather jekyll biodiversity-standards
Last synced: about 15 hours ago
JSON representation
Repository metadata
GBIF Python client
- Host: GitHub
- URL: https://github.com/gbif/pygbif
- Owner: gbif
- License: mit
- Created: 2014-12-31T05:36:27.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2025-12-04T13:02:59.000Z (20 days ago)
- Last Synced: 2025-12-05T07:43:59.546Z (19 days ago)
- Topics: api, biodiversity, data, ecology, gbif
- Language: Python
- Homepage: https://pygbif.readthedocs.io/en/latest/
- Size: 22.2 MB
- Stars: 135
- Watchers: 15
- Forks: 36
- Open Issues: 34
- Releases: 13
-
Metadata Files:
- Readme: README.rst
- Changelog: Changelog.rst
- Contributing: .github/CONTRIBUTING.md
- License: LICENSE
README.rst
pygbif
======
|pypi| |docs| |ghactions| |coverage| |black|
Python client for the `GBIF API `_
`Source on GitHub at gbif/pygbif `_
Other GBIF clients:
* R: `rgbif`, `ropensci/rgbif `_
* Ruby: `gbifrb`, `sckott/gbifrb `_
* PHP: `php-gbif`, `restelae/php-gbif `_
Contributing: `CONTRIBUTING.md `_
Installation
============
Stable from pypi
.. code-block:: console
pip install pygbif
Development version
.. code-block:: console
[sudo] pip install git+git://github.com/gbif/pygbif.git#egg=pygbif
`pygbif` is split up into modules for each of the major groups of API methods.
* Registry - Datasets, Nodes, Installations, Networks, Organizations
* Species - Taxonomic names
* Occurrences - Occurrence data, including the download API
* Maps - Maps, get raster maps from GBIF as png or mvt
You can import the entire library, or each module individually as needed.
In addition there is a utils module, currently with one method: `wkt_rewind`, and
a `caching` method to manage whether HTTP requests are cached or not. See `?pygbif.caching`.
Registry module
===============
registry module API:
* `organizations`
* `nodes`
* `networks`
* `installations`
* `datasets`
* `dataset_metrics`
* `dataset_suggest`
* `dataset_search`
Example usage:
.. code-block:: python
from pygbif import registry
registry.dataset_metrics(uuid='3f8a1297-3259-4700-91fc-acc4170b27ce')
Species module
==============
species module API:
* `name_backbone`
* `name_suggest`
* `name_usage`
* `name_lookup`
* `name_parser`
Example usage:
.. code-block:: python
from pygbif import species
species.name_suggest(q='Puma concolor')
Occurrences module
==================
occurrences module API:
* `search`
* `get`
* `get_verbatim`
* `get_fragment`
* `count`
* `count_basisofrecord`
* `count_year`
* `count_datasets`
* `count_countries`
* `count_schema`
* `count_publishingcountries`
* `download`
* `download_meta`
* `download_list`
* `download_get`
* `download_citation`
* `download_describe`
* `download_sql`
Example usage:
.. code-block:: python
from pygbif import occurrences as occ
occ.search(taxonKey = 3329049)
occ.get(key = 252408386)
occ.count(isGeoreferenced = True)
occ.download('basisOfRecord = PRESERVED_SPECIMEN')
occ.download('taxonKey = 3119195')
occ.download('decimalLatitude > 50')
occ.download_list(user = "sckott", limit = 5)
occ.download_meta(key = "0000099-140929101555934")
occ.download_get("0000066-140928181241064")
occ.download_citation("0002526-241107131044228")
occ.download_describe("simpleCsv")
occ.download_sql("SELECT gbifid,countryCode FROM occurrence WHERE genusKey = 2435098")
Maps module
===========
maps module API:
* `map`
Example usage:
.. code-block:: python
from pygbif import maps
out = maps.map(taxonKey = 212, year = 1998, bin = "hex",
hexPerTile = 30, style = "classic-noborder.poly")
out.response
out.path
out.img
out.plot()
.. image:: https://github.com/gbif/pygbif/raw/master/gbif_map.png
:width: 25%
utils module
============
utils module API:
* `wkt_rewind`
Example usage:
.. code-block:: python
from pygbif import utils
x = 'POLYGON((144.6 13.2, 144.6 13.6, 144.9 13.6, 144.9 13.2, 144.6 13.2))'
utils.wkt_rewind(x)
Contributors
============
* `Scott Chamberlain `_
* `Robert Forkel `_
* `Jan Legind `_
* `Stijn Van Hoey `_
* `Peter Desmet `_
* `Nicolas Noé `_
Meta
====
* License: MIT, see `LICENSE file `_
* Please note that this project is released with a `Contributor Code of Conduct `_. By participating in this project you agree to abide by its terms.
.. |pypi| image:: https://img.shields.io/pypi/v/pygbif.svg
:target: https://pypi.python.org/pypi/pygbif
.. |docs| image:: https://readthedocs.org/projects/pygbif/badge/?version=latest
:target: http://pygbif.rtfd.org/
.. |ghactions| image:: https://github.com/gbif/pygbif/workflows/Python/badge.svg
:target: https://github.com/gbif/pygbif/actions?query=workflow%3APython
.. |coverage| image:: https://codecov.io/gh/gbif/pygbif/branch/master/graph/badge.svg?token=frXPREGk1D
:target: https://codecov.io/gh/gbif/pygbif
.. |black| image:: https://img.shields.io/badge/code%20style-black-000000.svg
:target: https://github.com/psf/black
Owner metadata
- Name: Global Biodiversity Information Facility
- Login: gbif
- Email:
- Kind: organization
- Description:
- Website: https://www.gbif.org
- Location: Copenhagen, Denmark
- Twitter:
- Company:
- Icon url: https://avatars.githubusercontent.com/u/1963797?v=4
- Repositories: 288
- Last ynced at: 2024-04-14T06:45:04.085Z
- Profile URL: https://github.com/gbif
GitHub Events
Total
- Create event: 14
- Release event: 1
- Issues event: 12
- Watch event: 24
- Delete event: 17
- Issue comment event: 9
- Push event: 31
- Pull request review comment event: 12
- Pull request review event: 7
- Pull request event: 29
- Fork event: 8
Last Year
- Issues event: 11
- Watch event: 21
- Delete event: 11
- Issue comment event: 8
- Push event: 23
- Pull request review comment event: 9
- Pull request review event: 2
- Pull request event: 24
- Fork event: 7
- Create event: 10
Committers metadata
Last synced: 9 days ago
Total Commits: 298
Total Committers: 18
Avg Commits per committer: 16.556
Development Distribution Score (DDS): 0.329
Commits in past year: 6
Committers in past year: 2
Avg Commits per committer in past year: 3.0
Development Distribution Score (DDS) in past year: 0.333
| Name | Commits | |
|---|---|---|
| Scott Chamberlain | m****s@g****m | 200 |
| Cecilie Svenningsen | 5****e | 31 |
| stijnvanhoey | s****y@g****m | 15 |
| John Waller | j****r@g****m | 12 |
| John Waller | f****2@k****k | 8 |
| Matthew Blissett | m****t@g****g | 8 |
| Nicolas Noé | n****e@i****e | 7 |
| Marie Grosjean | m****n@g****g | 4 |
| Peter Desmet | p****k@g****m | 4 |
| Daniel Lusk | d****k@p****t | 1 |
| Keenan Ganz | 3****z | 1 |
| Ryan Vandersmith | r****h@g****m | 1 |
| dependabot-preview[bot] | 2****] | 1 |
| lucbettaieb | l****b@g****m | 1 |
| gbifnorway | g****t@n****o | 1 |
| Fabian-Robert Stöter | f****r@i****r | 1 |
| marcowyzajomc | 1****c | 1 |
| xrotwang | x****g@g****m | 1 |
Committer domains:
- gbif.org: 2
- inria.fr: 1
- nhm.uio.no: 1
- posteo.net: 1
- inbo.be: 1
- ku.dk: 1
Issue and Pull Request metadata
Last synced: 12 days ago
Total issues: 110
Total pull requests: 86
Average time to close issues: 8 months
Average time to close pull requests: about 2 months
Total issue authors: 37
Total pull request authors: 18
Average comments per issue: 1.95
Average comments per pull request: 1.14
Merged pull request: 45
Bot issues: 1
Bot pull requests: 19
Past year issues: 8
Past year pull requests: 12
Past year average time to close issues: about 21 hours
Past year average time to close pull requests: 26 days
Past year issue authors: 6
Past year pull request authors: 2
Past year average comments per issue: 0.13
Past year average comments per pull request: 0.5
Past year merged pull request: 2
Past year bot issues: 0
Past year bot pull requests: 9
Top Issue Authors
- sckott (37)
- CecSve (15)
- jhnwllr (8)
- faroit (6)
- niconoe (5)
- MattBlissett (3)
- bwakkie (2)
- dfloer (2)
- nleguillarme (2)
- abubelinha (2)
- nickynicolson (2)
- laurabrenskelle (1)
- data-biodiversity-aq (1)
- s-kganz (1)
- ManonGros (1)
Top Pull Request Authors
- jhnwllr (24)
- dependabot[bot] (18)
- CecSve (16)
- dluks (4)
- sckott (4)
- bbrangeo (4)
- s-kganz (2)
- lucbettaieb (2)
- niconoe (2)
- peterdesmet (2)
- marcowyzajomc (1)
- xrotwang (1)
- jlegind (1)
- rvanasa (1)
- stijnvanhoey (1)
Top Issue Labels
- downloads (18)
- enhancement (4)
- docs (3)
- bug (3)
- from-email (2)
- later (1)
Top Pull Request Labels
- dependencies (19)
- python (9)
- downloads (1)
Package metadata
- Total packages: 2
-
Total downloads:
- pypi: 12,294 last-month
- Total docker downloads: 8,425
- Total dependent packages: 3 (may contain duplicates)
- Total dependent repositories: 24 (may contain duplicates)
- Total versions: 29
- Total maintainers: 2
pypi.org: pygbif
Python client for GBIF
- Homepage: http://github.com/gbif/pygbif
- Documentation: https://pygbif.readthedocs.io/
- Licenses: MIT
- Latest release: 0.6.6 (published about 1 month ago)
- Last Synced: 2025-12-20T22:02:46.331Z (4 days ago)
- Versions: 15
- Dependent Packages: 3
- Dependent Repositories: 24
- Downloads: 12,294 Last month
- Docker Downloads: 8,425
-
Rankings:
- Docker downloads count: 1.239%
- Dependent repos count: 2.981%
- Dependent packages count: 3.271%
- Average: 4.921%
- Downloads: 6.198%
- Stargazers count: 7.559%
- Forks count: 8.277%
- Maintainers (2)
proxy.golang.org: github.com/gbif/pygbif
- Homepage:
- Documentation: https://pkg.go.dev/github.com/gbif/pygbif#section-documentation
- Licenses: mit
- Latest release: v0.6.6 (published about 1 month ago)
- Last Synced: 2025-12-20T22:02:48.709Z (4 days ago)
- Versions: 14
- Dependent Packages: 0
- Dependent Repositories: 0
-
Rankings:
- Dependent packages count: 5.395%
- Average: 5.576%
- Dependent repos count: 5.758%
Dependencies
- appdirs >=1.4.3
- codecov *
- geojson_rewind *
- geomet *
- matplotlib *
- pytest *
- pytest-cov *
- requests >2.7
- requests-cache *
- shapely >=1.5.13
- sphinx_issues *
- vcrpy *
- appdirs >=1.4.3
- geojson_rewind *
- geomet *
- matplotlib *
- requests >2.7
- requests-cache *
- actions/checkout v2 composite
- actions/setup-python v2 composite
- actions/checkout v3 composite
- actions/setup-python v3 composite
- appdirs >=1.4.3
- codecov *
- geojson_rewind *
- geomet *
- matplotlib *
- pytest *
- pytest-cov *
- requests >2.7
- requests-cache *
- shapely >=1.5.13
- sphinx_issues *
- urllib3 ==1.26.14
- vcrpy ==4.2.1
Score: 17.96081293330638