{"id":26554158,"url":"https://github.com/hideba/flatcitybuf","last_synced_at":"2025-03-22T09:50:46.645Z","repository":{"id":271695260,"uuid":"850698463","full_name":"HideBa/flatcitybuf","owner":"HideBa","description":"CityJSON encoding with FlatBuffers","archived":false,"fork":false,"pushed_at":"2025-03-18T09:32:09.000Z","size":2753,"stargazers_count":2,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-18T10:34:40.606Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","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/HideBa.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":"2024-09-01T14:30:06.000Z","updated_at":"2025-03-18T09:32:14.000Z","dependencies_parsed_at":"2025-01-09T10:48:16.121Z","dependency_job_id":"37294081-67b9-4de6-ae8b-2d3eabdc4849","html_url":"https://github.com/HideBa/flatcitybuf","commit_stats":null,"previous_names":["hideba/flatcitybuf"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HideBa%2Fflatcitybuf","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HideBa%2Fflatcitybuf/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HideBa%2Fflatcitybuf/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/HideBa%2Fflatcitybuf/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/HideBa","download_url":"https://codeload.github.com/HideBa/flatcitybuf/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244937743,"owners_count":20535124,"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":[],"created_at":"2025-03-22T09:50:46.160Z","updated_at":"2025-03-22T09:50:46.630Z","avatar_url":"https://github.com/HideBa.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# flatcitybuf\n\na cloud-optimized binary format for storing and retrieving 3d city models based on the cityjson standard.\n\n## overview\n\nflatcitybuf combines the semantic richness of cityjson with the performance benefits of flatbuffers binary serialization and spatial indexing techniques. it addresses several limitations of existing cityjson formats:\n\n- **performance**: enables zero-copy access to specific city objects without parsing the entire file\n- **cloud optimization**: supports http range requests for partial data retrieval\n- **spatial indexing**: implements a packed r-tree for efficient spatial queries\n- **attribute indexing**: uses binary search trees for fast attribute-based filtering\n- **size efficiency**: reduces file sizes by 50-70% compared to text-based formats\n\nbenchmarks show flatcitybuf is 10-20× faster in data retrieval compared to cityjsonseq.\n\n## getting started\n\n### prerequisites\n\n- rust toolchain (cargo, rustc)\n- for wasm builds: wasm-pack\n\n### build\n\nbuild the core library and cli:\n\n```bash\ncargo build --workspace --all-features --exclude fcb_wasm\n```\n\nbuild the wasm module:\n\n```bash\ncargo build -p fcb_wasm --target wasm32-unknown-unknown\n# or\ncd wasm \u0026\u0026 wasm-pack build --target web --debug --out-dir ../../ts\n```\n\n### usage examples\n\nserialize cityjson to flatcitybuf:\n\n```bash\ncargo run -p fcb_cli ser -i path/to/input.city.jsonl -o path/to/output.fcb\n```\n\ndeserialize flatcitybuf to cityjson:\n\n```bash\ncargo run -p fcb_cli deser -i path/to/input.fcb -o path/to/output.city.jsonl\n```\n\nget information about a flatcitybuf file:\n\n```bash\ncargo run -p fcb_cli info -i path/to/file.fcb\n```\n\n### run benchmarks\n\n```bash\ncargo bench -p fcb_core --bench read\n```\n\n## project structure\n\n- **fcb_core**: core library for reading and writing flatcitybuf files\n- **fcb_cli**: command-line interface for converting between cityjson and flatcitybuf\n- **bst**: binary search tree implementation for attribute indexing\n- **packed_rtree**: packed r-tree implementation for spatial indexing\n- **fcb_wasm**: webassembly bindings for browser usage\n\n## acknowledgements\n\nthis project incorporates code from [flatgeobuf](https://github.com/flatgeobuf/flatgeobuf/tree/master), copyright (c) 2018, björn harrtell, licensed under the bsd 2-clause license.\n\nthe flatbuffers schema for citybuf feature format is originally authored by tu delft 3d geoinformation group, ravi peters (3dgi), balazs dukai (3dgi).\n\n## references\n\n- [cityjson specification](https://github.com/cityjson/cityjson-spec)\n- [flatbuffers](https://github.com/google/flatbuffers)\n- [citybuf](https://github.com/ylannl/citybuf)\n- [flatgeobuf](https://github.com/flatgeobuf/flatgeobuf)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhideba%2Fflatcitybuf","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhideba%2Fflatcitybuf","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhideba%2Fflatcitybuf/lists"}