Description
The geojson2h3 library includes a set of utilities for conversion between GeoJSON objects and H3 hexagon indexes, using uber H3 and GeoJSON.
go-geojson2h3 alternatives and similar packages
Based on the "Go Tools" category.
Alternatively, view go-geojson2h3 alternatives based on common mentions on social networks and blogs.
-
JuiceFS
JuiceFS is a distributed POSIX file system built on top of Redis and S3. -
OctoLinker
OctoLinker โ Links together, what belongs together -
JSON-to-Go
Translates JSON into a Go type in your browser instantly (original) -
gb
An easy to use project based build tool for the Go programming language. -
go-critic
The most opinionated Go source code linter for code audit. -
kube-prompt
An interactive kubernetes client featuring auto-complete. -
The Go Play Space
Advanced Go Playground frontend written in Go, with syntax highlighting, turtle graphics mode, and more -
Peanut
๐บ Deploy Databases and Services Easily for Development and Testing Pipelines. -
golang-tutorials
Golang Tutorials. Learn Golang from Scratch with simple examples. -
xdg-go
Go implementation of the XDG Base Directory Specification and XDG user directories -
rts
RTS: request to struct. Generates Go structs from JSON server responses. -
typex
[TOOL/CLI] - Filter and examine Go type structures, interfaces and their transitive dependencies and relationships. Export structural types as TypeScript value object or bare type representations. -
golang-ipc
Golang Inter-process communication library for Window, Mac and Linux. -
Viney's go-cache
A flexible multi-layer Go caching library to deal with in-memory and shared cache by adopting Cache-Aside pattern. -
gothanks
GoThanks automatically stars Go's official repository and your go.mod github dependencies, providing a simple way to say thanks to the maintainers of the modules you use and the contributors of Go itself. -
zb
an opinionated repo based tool for linting, testing and building go source -
go-lock
go-lock is a lock library implementing read-write mutex and read-write trylock without starvation -
goroutines
It is an efficient, flexible, and lightweight goroutine pool. It provides an easy way to deal with concurrent tasks with limited resource. -
gotestdox
A tool for formatting Go test results as readable documentation -
terminal-Task
Terminal tasks todo with reminder tool for geek -
version
Go package to present your CLI version with an upgrade notice. -
PDF to Image Converter Using Golang
This project will help you to convert PDF file to IMAGE using golang. -
An exit strategy for go routines.
An exit strategy for go routines -
go-james
James is your butler and helps you to create, build, debug, test and run your Go projects -
generator-go-lang
A Yeoman generator to get new Go projects started. -
Paymail Inspector
:money_with_wings: CLI app for interacting with paymail service providers -
docs
Automatically generate RESTful API documentation for GO projects - aligned with Open API Specification standard -
go-sanitize
:bathtub: Golang library of simple to use sanitation functions -
gomodrun
The forgotten go tool that executes and caches binaries included in go.mod files. -
rescached
[mirror] Resolver (DNS) cache daemon. See https://sr.ht/~shulhan/rescached [Moved to: https://github.com/shuLhan/rescached] -
channelize
A websocket framework to manage outbound streams. Allowing to have multiple channels per connection that includes public and private channels. -
go-whatsonchain
:link: Unofficial golang implementation for the WhatsOnChain API -
Proofable
General purpose proving framework for certifying digital assets to public blockchains -
modver
Compare two versions of a Go module to check the version-number change required (major, minor, or patchlevel), according to semver rules. -
ciiigo
[mirror] Go static website generator with asciidoc markup language -
go-preev
:link: Unofficial golang implementation for the Preev API -
redispubsub
Redis Streams queue driver for https://godoc.org/gocloud.dev/pubsub package -
retry
Small, full-featured, 100% test-covered retry package for golang. -
go-slices
Helper functions for the manipulation of slices of all types in Go -
IP2Location.io Command Line
IP2Location.io command line to query IP geolocation data from IP2Location.io API
WorkOS - The modern identity platform for B2B SaaS
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of go-geojson2h3 or a related project?
README
go-geojson2h3
The geojson2h3
library includes a set of utilities for conversion between GeoJSON Objects:
- Point, MultiPoint,
- LineString, MultiLineString
- Polygon,MultiPolygon
- GeometryCollection
- Feature,FeatureCollection
- Circle
and H3 hexagon indexes, using: H3-GO and GeoJSON
Installation
$ go get github.com/mmadfox/go-geojson2h3
API
// ToH3 converts a GeoJSON objects to a list of hexagons with specified resolution.
ToH3(resolution int, o geojson.Object) (indexes []h3.H3Index, err error)
// ToFeatureCollection converts a set of hexagons to a GeoJSON `FeatureCollection`
// with the set outline(s). The feature's geometry type will be `Polygon`.
ToFeatureCollection(indexes []h3.H3Index) (*geojson.FeatureCollection, error)
Examples
- [Point, MultiPoint](examples/point.go)
- [LineString, MultiLineString](examples/line.go)
- [Polygon,MultiPolygon](examples/polygon.go)
- [GeometryCollection](examples/collection.go)
- [Feature,FeatureCollection](examples/feature.go)
- [Circle](examples/circle.go)
- [Rect](examples/rect.go)
package main
import (
"fmt"
"github.com/mmadfox/go-geojson2h3"
"github.com/tidwall/geojson"
"github.com/uber/h3-go/v3"
)
func main() {
resolution := 9
object, err := geojson.Parse(`{"type":"FeatureCollection","features":[{"type":"Feature","properties":{"shape":"Polygon","name":"Unnamed Layer","category":"default"},"geometry":{"type":"Polygon","coordinates":[[[-73.901303,40.756892],[-73.893924,40.743755],[-73.871476,40.756278],[-73.863378,40.764175],[-73.871444,40.768467],[-73.879852,40.760014],[-73.885515,40.764045],[-73.891522,40.761054],[-73.901303,40.756892]]]},"id":"a6ca1b7e-9ddf-4425-ad07-8a895f7d6ccf"}]}`, nil)
if err != nil {
panic(err)
}
indexes, err := geojson2h3.ToH3(resolution, object)
if err != nil {
panic(err)
}
for _, index := range indexes {
fmt.Printf("h3index: %s\n", h3.ToString(index))
}
featureCollection, err := geojson2h3.ToFeatureCollection(indexes)
if err != nil {
panic(err)
}
fmt.Println("Polyfill:")
fmt.Println(featureCollection.JSON())
}
Contributing
Pull requests and Github issues are welcome. Please include tests for new work, and keep the library test coverage at 90-100%.