简体   繁体   中英

How to use Geoplot in Azure Functions (GEOS/PROJ issue)

I've been trying to build a python Azure function which requires Geoplot. However, when I try to deploy it I get an error message, likely due to GEOS/PROJ. Here's part of the output:

  • Downloading Cartopy-0.20.1.tar.gz (10.8 MB)
  • Installing build dependencies: started
  • Installing build dependencies: finished with status 'done'
  • Getting requirements to build wheel: started
  • ERROR: Command errored out with exit status 1:
  • Getting requirements to build wheel: finished with status 'error'
  • command: /tmp/oryx/platforms/python/3.8.12/bin/python3.8 /tmp/oryx/platforms/python/3.8.12/lib/python3.8/site-packages/pip/_vendor/pep517/_in_process.py get_requires_for_build_wheel /tmp/tmp8ki7x3mh
  • cwd: /tmp/pip-install-q5qyetv4/cartopy
  • Complete output (3 lines):
  • setup.py:117: UserWarning: Unable to determine GEOS version. Ensure you have 3.7.2 or later installed, or installation may fail.
  • warnings.warn(
  • Proj 8.0.0 must be installed.
  • ERROR: Command errored out with exit status 1: /tmp/oryx/platforms/python/3.8.12/bin/python3.8 /tmp/oryx/platforms/python/3.8.12/lib/python3.8/site-packages/pip/_vendor/pep517/_in_process.py get_requires_for_build_wheel /tmp/tmp8ki7x3mh Check the logs for full command output.

How can I use Geoplot in an Azure function?

However, when I try to deploy it I get an error message, likely due to GEOS/PROJ.

Here are few of workaround to check

  • Please make sure that you have installed GEOS/PROJ in your local.

  • If you have Anaconda in your local try the below cmdlt to install it

conda install -c conda-forge cartopy

For more information please refer below links:

SO THREAD: Install Cartopy & dependencies on Windows

MS DOC: Transform relational data with Pandas and Azure Function Apps .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM