-
Notifications
You must be signed in to change notification settings - Fork 6
PyValhalla for mac os arm #31
Comments
That'd be really nice to have a user reporting how to do it. Not sure we'd ever really have a pipeline to publish M1 binaries on PyPI as long as there's no easily accessible & free M1 runners on GHA. It can be done locally as well (build all minor Python versions separately and publish them manually), but it's painful and I can tell 100% that no one would commit to that long-term (or very soon un-commit after starting;)). |
It seems this is on the GitHub roadmap for Q4 2023 |
It seems GitHub has added support for ARM based distributions of macOS. It would be an amazing improvement to DX if Valhalla's python bindings work on ARM Macs. |
yeah, we're already using that in upstream valhalla to build. to be clear, python bindings are working for apple silicon, they're just not distributed on pypi. fwiw, it'd be better to do the packaging directly in valhalla as part of our release workflow. but that'll need quite a bit of work, especially for linux. if someone is really interested, over [email protected] I'm open for this type of commercial enquiries. |
I basically just pip installed PyValhalla for Mac Intel, built Valhalla for Mac ARM, then copied the PyValhalla site_packages stuff from python Intel env into a new python arm env and replaced it with the stuff I built (and renamed a few things until errors went away). Valhalla in ARM is a little faster, but the most significant gain is that you can run your regular python code in ARM. |
Easiest is probably to just “sudo” install all of Valhalla, which will also install the Python bindings in the right place, unless you have a strange Python setup . |
Things can get a bit messy if you have different environments (I like to use Conda) and Rosetta intel + arm environments. I had such a hard time getting it to use the exact python version I wanted I gave up and hardcoded it into the CMake in Valhalla (pro move) |
Haha yeah I can imagine. In theory I guess CMake should make it easy via some variables but I can imagine it's not necessarily working as expected always.. At least Valhalla is not relying on Rosetta stuff anymore and can be installed natively now on apple silicon. |
Hi,
I managed to hack PyValhalla to run a Mac os arm valhalla build I made a week or so ago
Once the isochrone issues I encountered are sorted, I should be able to help out with the build process for PyValhalla
Can't say I know exactly what is going on in the build scripts here, but to me it looks like the main thing to change from "build_mac.sh" would be pathing to the mac os arm location
The text was updated successfully, but these errors were encountered: