Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot find proj.db #8

Open
Pommespapst opened this issue May 15, 2019 · 2 comments
Open

Cannot find proj.db #8

Pommespapst opened this issue May 15, 2019 · 2 comments

Comments

@Pommespapst
Copy link

When importing bw2regional I get the following error messages:

proj_create: Cannot find proj.db
proj_create: no database context specified
ERROR 4: Unable to open EPSG support file gcs.csv. Try setting the GDAL_DATA environment variable to point to the directory containing EPSG csv files.
proj_create: Cannot find proj.db
proj_create: no database context specified
Unable to open EPSG support file gcs.csv. Try setting the GDAL_DATA environment variable to point to the directory containing EPSG csv files.

@Pommespapst
Copy link
Author

It seems that the path to the proj library is not set during installation. Adding the following lines before the import statement resolved the issue:

import os
os.environ["PROJ_LIB"] = r"C:\Programs\miniconda\envs\BrightwayConda\Library\share"

The path must point to the "proj" folder. If the folder is not contained in the above directory, try one of these:
os.environ['PROJ_LIB'] = r'c:\Users\username\AppData\Local\conda\conda\envs\envname\Library\share'
os.environ['PROJ_LIB'] = '<path_to_anaconda>/share/proj'
os.environ['PROJ_LIB'] = r'C:\Users(xxxx)\AppData\Local\Continuum\anaconda3\pkgs\proj4-5.1.0-hfa6e2cd_1\Library\share'

@janceviciusjulius
Copy link

Hello. What about "ERROR 1: PROJ: proj_create: no database context specified" while running gdal_merge.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants