{"id":20751776,"url":"https://github.com/clarisma/geodesk","last_synced_at":"2025-04-05T12:06:15.996Z","repository":{"id":109590511,"uuid":"454366109","full_name":"clarisma/geodesk","owner":"clarisma","description":"Fast and storage-efficient spatial database engine for OpenStreetMap data","archived":false,"fork":false,"pushed_at":"2025-03-27T11:22:58.000Z","size":701,"stargazers_count":143,"open_issues_count":56,"forks_count":4,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-03-29T11:08:16.746Z","etag":null,"topics":["database","geodesk","geospatial","gis","openstreetmap"],"latest_commit_sha":null,"homepage":"https://docs.geodesk.com/java","language":"Java","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/clarisma.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}},"created_at":"2022-02-01T11:45:10.000Z","updated_at":"2025-03-27T11:23:03.000Z","dependencies_parsed_at":"2023-09-21T19:25:12.664Z","dependency_job_id":"ece3ee49-a99c-4a93-8304-3d01c3d59c6a","html_url":"https://github.com/clarisma/geodesk","commit_stats":{"total_commits":165,"total_committers":2,"mean_commits":82.5,"dds":"0.10909090909090913","last_synced_commit":"d67e9c094f1db28ae67c51d4ef24ed3ec12e942a"},"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clarisma%2Fgeodesk","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clarisma%2Fgeodesk/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clarisma%2Fgeodesk/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/clarisma%2Fgeodesk/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/clarisma","download_url":"https://codeload.github.com/clarisma/geodesk/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247332604,"owners_count":20921853,"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":["database","geodesk","geospatial","gis","openstreetmap"],"created_at":"2024-11-17T08:38:11.730Z","updated_at":"2025-04-05T12:06:15.954Z","avatar_url":"https://github.com/clarisma.png","language":"Java","funding_links":[],"categories":["数据库","Libraries"],"sub_categories":["Java"],"readme":"\u003cimg src=\"https://docs.geodesk.com/img/github-header.png\"\u003e\n\n\nGeoDesk is a fast and storage-efficient geospatial database for OpenStreetMap data. Also available [for C++](https://github.com/clarisma/libgeodesk) and [for Python](https://github.com/clarisma/geodesk-py).\n\n## Why GeoDesk?\n\n- **Small storage footprint** \u0026mdash; GeoDesk's GOL files are only 20% to 50% larger than the original OSM data in PBF format \u0026mdash; that's less than a tenth of the storage consumed by a traditional SQL-based database.\n\n- **Fast queries** \u0026mdash; typically 50 times faster than SQL. \n\n- **Fast to get started** \u0026mdash; Converting `.osm.pbf` data to a GOL is 20 times faster than an import into an SQL database. Alternatively, download pre-made data tiles for just the regions you need and automatically assemble them into a GOL.\n\n- **Intuitive API** \u0026mdash; No need for object-relational mapping; GeoDesk queries return `Node`, `Way` and `Relation` objects. Quickly discover tags, way-nodes and relation members. Get a feature's `Geometry`, measure its length/area. \n \n- **Proper handling of relations** \u0026mdash; (Traditional geospatial databases deal with geometric shapes and require workarounds to support this unique and powerful aspect of OSM data.)\n\n- **Seamless integration with the Java Topology Suite (JTS)** for advanced geometric operations, such as buffer, union, simplify, convex and concave hulls, Voronoi diagrams, and much more.\n\n- **Modest hardware requirements** \u0026mdash; If it can run a 64-bit JVM, it'll run GeoDesk.\n \n## Get Started\n\n### Maven\n\nInclude this dependency in your project's `pom.xml`:\n\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003ecom.geodesk\u003c/groupId\u003e\n    \u003cartifactId\u003egeodesk\u003c/artifactId\u003e\n    \u003cversion\u003e1.0.2\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\nAlternatively, to build the latest version from source:\n\n```\ngit clone https://github.com/clarisma/geodesk.git\ncd geodesk\nmvn install\n```\n\n### Example Application\n\n```java\nimport com.geodesk.feature.*;\nimport com.geodesk.geom.*;\n\npublic class PubsExample\n{\n    public static void main(String[] args)\n    {\n        FeatureLibrary library = new FeatureLibrary(\n            \"switzerland.gol\");                          // 1\n        \n        for(Feature pub: library                         // 2\n            .select(\"na[amenity=pub]\")                   // 3\n            .in(Box.ofWSEN(8.53,47.36,8.55,47.38)))      // 4\n        {\n            System.out.println(pub.stringValue(\"name\")); // 5\n        }\n        \n        library.close();                                 // 6\n    }\n}\n```\n\nWhat's going on here?\n\n1. We're opening a feature library (`switzerland.gol`)\n\n2. We iterate through all the features ...\n\n3. ... that are pubs ([GeoDesk query language](https://docs.geodesk.com/goql) \u0026mdash; *similar to MapCSS*)\n\n4. ... in downtown Zurich (*bounding box with West/South/East/North coordinates*).\n\n5. We print the name of each pub.\n\n6. We close the library.\n\nThat's it, you've created your first GeoDesk application! \n\n### More Examples\n\nFind all movie theaters within 500 meters from a given point:\n\n```java\nFeatures movieTheaters = library\n    .select(\"na[amenity=cinema]\")\n    .maxMetersFromLonLat(500, myLon, myLat);\n```\n\n*Remember, OSM uses British English for its terminology.*\n\nDiscover the bus routes that traverse a given street:\n\n```java\nfor(Feature route: street.parents(\"[route=bus]\"))\n{\n    System.out.format(\"- %s from %s to %s\",\n        route.stringValue(\"ref\"),\n        route.stringValue(\"from\"),\n        route.stringValue(\"To\"));\n}\n```\n\nCount the number of entrances of a building:\n\n```java\nint numberOfEntrances = building.nodes(\"[entrance]\").size();\n```\n\n## Documentation\n\n- [GeoDesk Developer's Guide](https://docs.geodesk.com/java)\n- [API Reference](https://apidocs.geodesk.com/v1)\n\n## Related Repositories\n\n- [gol-tool](http://www.github.com/clarisma/gol-tool) \u0026mdash; command-line utility for building, maintaining and querying GOL files\n- [geodesk-examples](http://www.github.com/clarisma/geodesk-examples) \u0026mdash; example applications\n- [geodesk-tests](http://www.github.com/clarisma/geodesk-tests) \u0026mdash; integration tests\n- [libgeodesk](https://github.com/clarisma/libgeodesk) \u0026mdash; GeoDesk for C++ \n- [geodesk-py](https://github.com/clarisma/geodesk-py) \u0026mdash; GeoDesk for Python\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclarisma%2Fgeodesk","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fclarisma%2Fgeodesk","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fclarisma%2Fgeodesk/lists"}