{"id":32178350,"url":"https://github.com/mpas-dev/geometric_features","last_synced_at":"2025-10-21T20:53:51.339Z","repository":{"id":3554662,"uuid":"41449790","full_name":"MPAS-Dev/geometric_features","owner":"MPAS-Dev","description":"This repository houses geometric features relevant for climate science.","archived":false,"fork":false,"pushed_at":"2025-10-09T17:15:32.000Z","size":109473,"stargazers_count":24,"open_issues_count":4,"forks_count":25,"subscribers_count":17,"default_branch":"main","last_synced_at":"2025-10-21T20:53:36.902Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/MPAS-Dev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2015-08-26T21:04:07.000Z","updated_at":"2025-10-09T17:14:03.000Z","dependencies_parsed_at":"2024-07-18T22:49:03.175Z","dependency_job_id":"105dfe2d-a5f1-40d3-ae84-9157e830a033","html_url":"https://github.com/MPAS-Dev/geometric_features","commit_stats":{"total_commits":345,"total_committers":8,"mean_commits":43.125,"dds":0.2811594202898551,"last_synced_commit":"711a7b3a3a5df12dbb4bd1a5cdc9b95655dd428b"},"previous_names":[],"tags_count":31,"template":false,"template_full_name":null,"purl":"pkg:github/MPAS-Dev/geometric_features","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MPAS-Dev%2Fgeometric_features","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MPAS-Dev%2Fgeometric_features/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MPAS-Dev%2Fgeometric_features/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MPAS-Dev%2Fgeometric_features/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/MPAS-Dev","download_url":"https://codeload.github.com/MPAS-Dev/geometric_features/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/MPAS-Dev%2Fgeometric_features/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":280333496,"owners_count":26312845,"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","status":"online","status_checked_at":"2025-10-21T02:00:06.614Z","response_time":58,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2025-10-21T20:53:50.184Z","updated_at":"2025-10-21T20:53:51.319Z","avatar_url":"https://github.com/MPAS-Dev.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"This repository houses definitions of geometric features. These features\ncan include regions, transects, and points, described in geojson format.\nFor example, here are some regions for Antarctica.\n![alt text](https://cloud.githubusercontent.com/assets/4179064/12921663/93282b64-cf4e-11e5-9260-a78dfadc4459.png \"Antarctica regions\")\n\n## Documentation\n\n[http://mpas-dev.github.io/geometric_features/main/](http://mpas-dev.github.io/geometric_features/main/)\n\n## Contributors\n\nData for regions has been derived from sources listed in the\n[contributors file](contributors/CONTRIBUTORS.md) as specified\nvia the `author` field in each `geojson` file.\n\n## Quick Start\n\nThe python `geometric_features` package can be used to help maintain and use\nthis repository. Several example scripts that make use of the package can be\nfound in the `examples` directory.  Each of the classes and functions that make\nup the package have extensive documentation.  More user-level documentation\nwill be added shortly.\n\nTo use geometric features, you can install it in a conda environment:\n```bash\nconda create -n geometric_features -c conda-forge python=3.13 geometric_features\nconda activate geometric_features\n```\n\nTo develop `geometric_features` (e.g. to add new features), create and activate\n an environment with all of the required dependencies:\n```bash\nconda create -y -n mpas_dev --file dev-spec.txt\nconda activate mpas_dev\npython -m pip install --no-deps --no-build-isolation -e .\n```\n\nA typical workflow will look like:\n* Create a `GeometricFeatures` object and point it to a location where you have\n  stored (or would like to store) geometry data.\n  - `gf = GeometricFeatures(localCache='./geometric_data')`\n* Read in one or more `FeatureCollection`s from the `geojson` files in the\n  `geometric_data` directory.\n  - `fcArctic = gf.read('ocean', 'region', featureNames=['Arctic Ocean'])`\n  - `fcAtlantic = gf.read('ocean', 'region', tags=['Atlantic_Basin'])`\n* Edit features:\n  - Merge, combine, tag, mask out or simplify the features, see below.\n  - Use the `shapely` package to edit the geometry in more sophisticated ways\n* Visualize features:\n  - `fc.plot(projection='cyl')`\n* Split feature collection back into individual features for inclusion in the\n  repo:\n  - `gf.split(fc)`\n\nAvailable functionality includes:\n* `fc.merge(other)` - Merge two feature collection together.\n* `fc.combine()` - Combine features into a single feature.\n* `fc.difference()` - Mask features using shapes in a second feature file.\n* `fc.fix_antimeridian()` - Split a feature at the antimeridian (+/- 180 longitude). The resulting feature has all points between -180 and 180 lon.\n* `fc.set_group_name()` - Set the \"groupName\" property of the `FeatureCollection`\n* `fc.tag()` - Add one or more tags to the \"tag\" property of each feature in a collection.  This can be useful for reading back a collection of features with that tag.\n\n**IMPORTANT:** Always use the `gf.split(fc)` script when placing features into\nthe `geometric_data` directory. This will help everyone maintain the\nrepository, and allow tools to parse them cleanly.\n\nMany of this functionality can also be accessed with a command-line interface:\n```bash\nmerge_features\ncombine_features\ndifference_features\nset_group_name\nsplit_features\nsimplify_features\ntag_features\nplot_features\n```\nUse the `-h` flag to find out more.\n\nAn example workflow to read in, plot and write out a set of features is\n```python\n#!/usr/bin/env python\n\nfrom geometric_features import GeometricFeatures\nimport matplotlib.pyplot as plt\n\n# create a GeometricFeatures object that points to a local cache of geometric\n# data and knows which branch of geometric_feature to use to download\n# missing data\ngf = GeometricFeatures(cacheLocation='./geometric_data')\n\n# read in a FeatureCollection containing all ocean regions in the Atlantic\n# basin\nfcAtlantic = gf.read(componentName='ocean', objectType='region',\n                     tags=['Atlantic_Basin'])\n\nfcAtlantic.plot('cyl')\nplt.title('Atlantic merged')\n\n# combine them all into a single feature\nfcAtlantic = fcAtlantic.combine(featureName='Atlantic_Basin')\nfcAtlantic.plot('cyl')\nplt.title('Atlantic combined')\n\n# make another feature containing the regions in Filchner-Ronne Ice Shelf\nfcFilchnerRonne = gf.read(componentName='iceshelves', objectType='region',\n                          featureNames=['Filchner_1', 'Filchner_2',\n                                        'Filchner_3', 'Ronne_1', 'Ronne_2'])\nfcFilchnerRonne.plot('southpole')\nplt.title('Filchner-Ronne')\n\n\n# make one more collection of all the IMBIE basins in West Antarctica\nfcWestAntarctica = gf.read(componentName='landice', objectType='region',\n                           tags=['WestAntarcticaIMBIE'])\n\nfcWestAntarctica.plot('southpole')\nplt.title('West Antarctica')\n\nfcWestAntarctica.to_geojson('west_antarctica.geojson')\nplt.show()\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmpas-dev%2Fgeometric_features","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmpas-dev%2Fgeometric_features","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmpas-dev%2Fgeometric_features/lists"}