oturns / geosnap

The Geospatial Neighborhood Analysis Package
https://oturns.github.io/geosnap-guide
BSD 3-Clause "New" or "Revised" License
241 stars 32 forks source link

Google Colab install geosnap error #184 #369

Closed swagluke closed 1 year ago

swagluke commented 1 year ago

Description of the bug

Trying to install geosnap on Google Colab but running into issue with "Building wheels for collected packages: tables" I've tried following command to fix the issue but without any luck.

  1. I've confirmed that tables is installed properly. (3.8.1.dev0) - !pip install tables --upgrade
  2. Upgrading wheel and setuptools - !pip install wheel setuptools pip --upgrade
  3. Upgrading cmake - !pip install cmake --upgrade

Environment

Paste the code that reproduces the issue here:

`!pip install geosnap`

Paste the error message (if applicable):

Created wheel for pandana: filename=pandana-0.6.1-cp310-cp310-linux_x86_64.whl size=1851096 sha256=e524fa6c06a5d4fa2fa9ad88a8e770443f4db2dc6548d75e7a10f983be9af42f
  Stored in directory: /root/.cache/pip/wheels/e7/4b/71/360fe3ffe9d5822e4d35b07a9938f0b074056b43a0040b373a
  error: subprocess-exited-with-error

  × python setup.py bdist_wheel did not run successfully.
  │ exit code: 1
  ╰─> See above for output.

  note: This error originates from a subprocess, and is likely not a problem with pip.
  Building wheel for tables (setup.py) ... error
  ERROR: Failed building wheel for tables
  Running setup.py clean for tables
Successfully built matplotlib cenpy pandana
Failed to build tables
ERROR: Could not build wheels for tables, which is required to install pyproject.toml-based projects
knaaptime commented 1 year ago

thanks for raising this, though I honestly don't think there's a fix on our end. Ultimately this is an issue with the tables package, not geosnap

Colab tends to cause headaches because it requires pip and doesn't play nicely with conda (if I were you, I'd request anaconda support over there). Pip is pretty unreliable (for exactly this reason), so we only support conda installs for users. I'm going to close this as out of scope, since it seems specific to colab+pip, though feel free to reopen if you run into problems using the recommended install route. Maybe give codespaces or binder a try instead if you need to run in the cloud

swagluke commented 1 year ago

Thank you for the fast response. I retried it today with Google Colab and it's working now. Not sure if Colab had a recent system update or not.

knaaptime commented 1 year ago

i think you can thank @smmaurer for that. I think he got a new release of pandana out the door that fixes the outdated tables dependency

anyway, glad its working for you!

jGaboardi commented 1 year ago

xref: https://github.com/UDST/pandana/pull/183, https://github.com/UDST/pandana/pull/186