Eric Kansa is a user on octodon.social. You can follow them or interact with them if you have an account anywhere in the fediverse. If you don't, you can sign up here.

I have an urgent and annoying need to run some Node.js code to fix GeoJSON polygons to conform to the "right-hand rule", but I'm a Python person. Anyone have experience integrating Node.js and Python?

I'm wondering if it would just be easier to port that code into Python. I expect the need to fix GeoJSON again in the future, so this will come up again. Sadly, I'm not well versed in Node.js enough to really understand how the geojson-rewind code works.

I'm also not a totally awesome programmer. I'd much rather use someone else's code than my own, since I'm sure someone else would do it better.

@ekansa the algorithm is pretty simple to determine if they're inside out stackoverflow.com/a/1165943 .

Eric Kansa @ekansa

@fenwick67 Thanks. Made some progress on my problem inspired by this, and implemented in Python.

Work in progress here: github.com/ekansa/open-context

· Web · 0 · 1