pygdal | setuptools friendly version of standard GDAL python bindings
kandi X-RAY | pygdal Summary
kandi X-RAY | pygdal Summary
Virtualenv and setuptools friendly version of standard GDAL python bindings
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of pygdal
pygdal Key Features
pygdal Examples and Code Snippets
Community Discussions
Trending Discussions on pygdal
QUESTION
gdal is correctly installed on my global system's python 3.5 packages. But now I'm trying to pip install gdal on my python 3.6 virtual environment, but I receive multiple errors.
After activating the virtual environment, I've tried the following:
pip install pygdal
orpip3 install pygdal
Error received:ERROR: Failed building wheel for pygdal
Tried following this guide, but the commands stated there are outdated
I've also tried this solution and this which failed
Installed older gdal versions but also didn't work.
Tried
pip3 install GDAL==$(gdal-config --version)
and I get the same error
I use
Ubuntu 16.04 and pip 21.0.1. Venv was created using virtualenv --python=/usr/bin/python3.6 my_venv
ANSWER
Answered 2021-Feb-03 at 13:19EDIT: This answer pertains more to Windows than Ubuntu, but may have something useful.
Try downloading a wheel from here: https://www.lfd.uci.edu/~gohlke/pythonlibs/#gdal
Note the "cp##" in the middle - that should match your Python version. If you are running Python 3.6 then you should see "cp36" in the file name (a "cp37" in the name means the wheel will fail). Also pay attention to the amd64 and win32 to be sure you have the correct version to match your Python virtual environment.
I'm on Windows instead of Ubuntu, but this was my process:
- Open command prompt with cmd
- Copy the path to activate.bat in the virtual environment from Windows Explorer (hold shift down, right-click on file, choose "copy as path")
- Paste path into control panel and hit enter. You should see an indicator that you are in virtual environment.
- Copy the path to the wheel you downloaded to the clipboard using the same shift key trick.
- Type 'pip install ' then paste the wheel path from your clipboard (or type it all out manually)
As an aside, I ended up with gdal installed within the osgeo module. I tried several things before I got here, but I'm pretty sure that happened with my installation from the wheel. In Python, I now use
QUESTION
I'm trying to create a Django app in a docker container. The app would use a postgres db with postgis extension, which I have in another database. I'm trying to solve this using docker-compose but can not get it working.
I can get the app working without the container with the database containerized just fine. I can also get the app working in a container using a sqlite db (so a file included without external container dependencies). Whatever I do, it can't find the database.
My docker-compose file:
...ANSWER
Answered 2020-Mar-17 at 20:42you can not use localhost for the docker containers, it will be pointing to the container itself, not to the host of the containers. Instead switch to use the service name.
to fix the issue, change your env to
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install pygdal
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page