shaharkadmiel / pySW4

Setup, run, post process, and visualize numerical simulations. Primarily SW4
http://shaharkadmiel.github.com/pySW4
GNU General Public License v3.0
28 stars 14 forks source link

New install with gdal-config not found #16

Closed ArthurRodgers closed 2 years ago

ArthurRodgers commented 5 years ago

I'm trying to install pySW4 on a new HPC system using pip. I can't use conda on this machine. I'm getting errors where pip can't find gdal-config.

I installed gdal-build-debug (0.1.0) OK I tried to install pygdal and GDAL, but these also fail, needing the gdal-config

The last bit of output is:

    raise gdal_config_error(e)
__main__.gdal_config_error: [Errno 2] No such file or directory: 'gdal-config': 'gdal-config'

----------------------------------------

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-p75q863m/gdal/

I've run into problems with this on laptop running conda, but I've been able to work around with conda updates. Do you have any suggestions?

shaharkadmiel commented 5 years ago

Hi Artie,

GDAL has always been problematic. The error you are seeing comes from GDAL, not from pySW4. It used to be that GDAL install via conda was problematic and pip actually solved it. I guess it is the other way around now.

What you could do in the meantime untill you get gdal properly installed (you should be able to do python -c 'import gdal; print(gdal.VersionInfo())' and see the gdal version, not an error) is install pySW4 without any dependencies and use it without the gdal functionality. This means that you will be able to read SW4 outputs and other things that don't require gdal.

To do this, type:

pip install --no-deps https://github.com/shaharkadmiel/pySW4/archive/master.zip

Once gdal is installed, pySW4 will simply use it when needed.

Sorry I couldn't be more of help...

ArthurRodgers commented 5 years ago

Hi Shahar –

Thanks. I’m learning a lot on how python works by doing this.

Is there a specific gdal version I should target?

Thanks, Artie

From: Shahar Shani-Kadmiel notifications@github.com Reply-To: shaharkadmiel/pySW4 reply@reply.github.com Date: Tuesday, December 18, 2018 at 12:51 AM To: shaharkadmiel/pySW4 pySW4@noreply.github.com Cc: Arthur Rodgers rodgers7@llnl.gov, Author author@noreply.github.com Subject: Re: [shaharkadmiel/pySW4] New install with gdal-config not found (#16)

Hi Artie,

GDAL has always been problematic. The error you are seeing comes from GDAL, not from pySW4. It used to be that GDAL install via conda was problematic and pip actually solved it. I guess it is the other way around now.

What you could do in the meantime untill you get gdal properly installed (you should be able to do python -c 'import gdal; print(gdal.VersionInfo())' and see the gdal version, not an error) is install pySW4 without any dependencies and use it without the gdal functionality. This means that you will be able to read SW4 outputs and other things that don't require gdal.

To do this, type:

pip install --no-deps https://github.com/shaharkadmiel/pySW4/archive/master.zip

Once gdal is installed, pySW4 will simply use it when needed.

Sorry I couldn't be more of help...

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/shaharkadmiel/pySW4/issues/16#issuecomment-448143587, or mute the threadhttps://github.com/notifications/unsubscribe-auth/APW-cP9wRXICrtIZWva090b08Ar_jCuIks5u6KyCgaJpZM4ZXwjV.

ArthurRodgers commented 5 years ago

Hi Shahar –

The system I’m working on has no gdal, so I’ll need to talk to sys admin/python manager for some help getting that set-up. Evertytime I try to install GDAL or pygdal it can’t find gdal-config

FYI, I’m trying to build environment on a new cluster at LLNL. I need to move my post-processing workflow where the data resides. I’m generating ~ 1GB of SAC files for each simulation and I need to measure ground motion intensities, compare with GMM’s, etc… I have been processing data on my laptop, but this is becoming too cumbersome. I also want to parallelize processing to speed it up

I use pySW4 to query the rfile of the USGS SFBA model

Thanks, Artie From: Arthur Rodgers rodgers7@llnl.gov Date: Tuesday, December 18, 2018 at 6:56 AM To: shaharkadmiel/pySW4 reply@reply.github.com, shaharkadmiel/pySW4 pySW4@noreply.github.com Cc: Author author@noreply.github.com Subject: Re: [shaharkadmiel/pySW4] New install with gdal-config not found (#16)

Hi Shahar –

Thanks. I’m learning a lot on how python works by doing this.

Is there a specific gdal version I should target?

Thanks, Artie

From: Shahar Shani-Kadmiel notifications@github.com Reply-To: shaharkadmiel/pySW4 reply@reply.github.com Date: Tuesday, December 18, 2018 at 12:51 AM To: shaharkadmiel/pySW4 pySW4@noreply.github.com Cc: Arthur Rodgers rodgers7@llnl.gov, Author author@noreply.github.com Subject: Re: [shaharkadmiel/pySW4] New install with gdal-config not found (#16)

Hi Artie,

GDAL has always been problematic. The error you are seeing comes from GDAL, not from pySW4. It used to be that GDAL install via conda was problematic and pip actually solved it. I guess it is the other way around now.

What you could do in the meantime untill you get gdal properly installed (you should be able to do python -c 'import gdal; print(gdal.VersionInfo())' and see the gdal version, not an error) is install pySW4 without any dependencies and use it without the gdal functionality. This means that you will be able to read SW4 outputs and other things that don't require gdal.

To do this, type:

pip install --no-deps https://github.com/shaharkadmiel/pySW4/archive/master.zip

Once gdal is installed, pySW4 will simply use it when needed.

Sorry I couldn't be more of help...

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/shaharkadmiel/pySW4/issues/16#issuecomment-448143587, or mute the threadhttps://github.com/notifications/unsubscribe-auth/APW-cP9wRXICrtIZWva090b08Ar_jCuIks5u6KyCgaJpZM4ZXwjV.

shaharkadmiel commented 5 years ago

I would say go for the latest stable version available which is 2.3.2. Have an admin install from source https://trac.osgeo.org/gdal/wiki/DownloadSource, or use the package manager of choice on the LLNL system.

Then you should be able to do the pip install gdal as you've tried before. Note BTW, that the current package available from pip is indeed 2.3.2:


$ pip search gdal
GDAL (2.3.2)                   - GDAL: Geospatial Data Abstraction Library
'''
ArthurRodgers commented 5 years ago

Hi Shahar –

OK, thanks. That’s what I would have guessed, but wanted to make sure.

I’ve email python lead admin on Livermore Computing and I’ll forward your message. I think he’ll have to run install with higher access to system

Best, Artie

From: Shahar Shani-Kadmiel notifications@github.com Reply-To: shaharkadmiel/pySW4 reply@reply.github.com Date: Tuesday, December 18, 2018 at 8:20 AM To: shaharkadmiel/pySW4 pySW4@noreply.github.com Cc: Arthur Rodgers rodgers7@llnl.gov, Author author@noreply.github.com Subject: Re: [shaharkadmiel/pySW4] New install with gdal-config not found (#16)

I would say go for the latest stable version available which is 2.3.2. Have an admin install from source https://trac.osgeo.org/gdal/wiki/DownloadSource, or use the package manager of choice on the LLNL system.

Then you should be able to do the pip install gdal as you've tried before. Note BTW, that the current package available from pip is indeed 2.3.2:

$ pip search gdal

GDAL (2.3.2) - GDAL: Geospatial Data Abstraction Library

'''

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/shaharkadmiel/pySW4/issues/16#issuecomment-448278510, or mute the threadhttps://github.com/notifications/unsubscribe-auth/APW-cFzi56RYwA5cdyoLl7qkCmjhhOHEks5u6RWfgaJpZM4ZXwjV.