Giter Club home page Giter Club logo

gprpy's Introduction

GPRPy

Open-source Ground Penetrating Radar processing and visualization software. Supported by the National Science Foundation under grants EAR-1550732 and EAR-2022671

Please cite https://library.seg.org/doi/10.1190/tle39050332.1

Profile GUI

CMP/WARR GUI

Simplemost installation

In the following instructions, if you use Windows, use the comands python and pip. If you use Mac or Linux, use the commands python3 and pip3 instead.

  1. Download the GPRPy software from https://github.com/NSGeophysics/GPRPy/archive/master.zip.
    Save the file somewhere on your computer and extract the zip folder.
    As an alternative, you can install git from https://git-scm.com/, then run in a command prompt:
    git clone https://github.com/NSGeophysics/GPRPy.git
    The advantage of the latter is that you can easily update your software by running from the GPRPy folder in a command prompt:
    git pull origin master

  2. Install Python 3.7 or higher. You can obtain it for example from https://conda.io/miniconda.html

  3. Once the installation finished, open a command prompt that can run Python
    On Windows: click on Start, then enter "Anaconda Prompt", without the quotation marks into the "Search programs and files" field. On Mac or Linux, open the regular terminal.

  4. In the command prompt, change to the directory where you downloaded the GPRPy files. This is usually through a command like for example
    cd Desktop\GPRPy
    if you downloaded GPRPy directly onto your desktop. Then type the following and press enter afterward:
    python installMigration.py
    Then type the following and press enter afterward:
    pip install .
    don't forget the period "." at the end of the pip install command

Running the software

After installation, you can run the script from the Anaconda Prompt (or your Python-enabled prompt) by running either
gprpy
or
python -m gprpy

The first time you run GPRPy it could take a while to initialize. GPRPy will ask you if you want to run the profile [p] or WARR / CMP [c] user interface. Type
p
and then enter for profile, or
c
and then enter for CMP / WARR.

You can also directly select one by running either
gprpy p
or
gprpy c
or
python -m gprpy p
or
python -m gprpy c

Running automatically generated scripts

To run automatically generated scripts, open the command prompt that can run python (for example Anaconda Prompt), switch to the folder with the automatically generated script and run
python myscriptname.py
where myscriptname.py is the name of your automatically generated script.

In case of trouble

If you have several versions of python installed, for example on a Mac or Linux system, replace, in the commands shown earlier, python with python3
and
pip with pip3

If you have any troubles getting the software running, please send me an email or open an issue on GitHub and I will help you getting it running.

Uninstalling GPRPy

To uninstall GPRPy, simply run, in the (Anaconda) command prompt
pip uninstall gprpy

News

Follow @GPRPySoftware on twitter to hear about news and updates. Recent tweets:

Fixed small issue that led to multiples when picking points in profile. Thanks Marcus Pacheco for pointing it out! If you use picking in profile mode, please update to version 1.0.3 (uninstall the old version before).

— GPRPy (@GPRPySoftware) June 13, 2019

I will post updates, changes, and GPRPy news here.

— GPRPy (@GPRPySoftware) January 26, 2019

GPRPy is a free ground penetrating radar processing and visualization software developed at the University of Alabama. You can download it and install it following the instructions here: nsgeophysics.github.io/GPRPy/

— GPRPy (@GPRPySoftware) January 25, 2019

gprpy's People

Contributors

alainplattner avatar titus-casademont avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gprpy's Issues

GSSI data issues

Hi Alain,

I tried to open some of my own GSSI data (example file TEST__001.DZT attached)
with GPRPy and ran into some trouble. My own import function reads it just fine.

I'm relatively sure that your import script thinks the header of my DZT is 8 bytes larger than it really is. After some head scratching, I was able to at least rewrite gprIO_DZT.py to at least be able to reshape the array correctly. But it seems to still get the datatype wrong (or perhaps there's still a byteshift somewhere), so the profile looks kind of weird. I still can't quite figure out why this is the case. What I've done to temporarily lazily patch it is rewrite gprpy.importdata to use a function I wrote called readgssi.dzt.readdzt_gprpy that loads DZT header data and array in the same format as gprpy.toolbox.gprIO_DZT does.

Line 17 in gprpy.py:

from readgssi import dzt

Lines 87 and 88:

#self.data, self.info = gprIO_DZT.readdzt(filename)
self.data, self.info = dzt.readdzt_gprpy(filename)

However since my file did not use a DMI (this was a lake profile so it uses scans per second instead), it has no distance data attached to it. So I've also rewritten line 90 to handle a ZeroDivisionError in case scans per meter is zero in order to calculate profile position:

try:
    self.profilePos = self.info["startposition"]+np.linspace(0.0,
                                                             self.data.shape[1]/self.info["scpmeter"],
                                                             self.data.shape[1])
except ZeroDivisionError:
    self.profilePos = np.linspace(0.0, self.data.shape[1]/self.info["scpsec"],
                                  self.data.shape[1])

This seems to work reasonably well but since I haven't changed anything in the gui it still displays the plot position in meters.

I have the changes in a fork and will open a pull request if you'd like. Otherwise, take a look at how gprpy and readgssi import DZTs and see if you can figure out how they read the array differently.

Best,
Ian

SSL Version Error on Installation

Hi All

Whilst working through the installation, after successfully downloading and extracting the software I successfully run the "python installMigration.py" command but when doing the "pip install ." I get a SSLError as follows...


C:\Users\mikes\Desktop\GPRPy-master>pip install .
Processing c:\users\mikes\desktop\gprpy-master
DEPRECATION: A future pip version will change local packages to be built in-place without first copying to a temporary directory. We recommend you use --use-feature=in-tree-build to test your packages with this new behavior before it becomes the default.
pip 21.3 will remove support for this functionality. You can find discussion regarding this at pypa/pip#7555.
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:997)'))': /simple/tqdm/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:997)'))': /simple/tqdm/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:997)'))': /simple/tqdm/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:997)'))': /simple/tqdm/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:997)'))': /simple/tqdm/
Could not fetch URL https://pypi.org/simple/tqdm/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/tqdm/ (Caused by SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:997)'))) - skipping
ERROR: Could not find a version that satisfies the requirement tqdm (from gprpy) (from versions: none)
ERROR: No matching distribution found for tqdm
Could not fetch URL https://pypi.org/simple/pip/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/pip/ (Caused by SSLError(SSLError(1, '[SSL: WRONG_VERSION_NUMBER] wrong version number (_ssl.c:997)'))) - skipping


I upgraded to python 3.10.1 and am running python from an Anaconda3 command prompt. I've noticed that a lot of other users have similar errors when trying to do any pip install, but none of the suggested fixed (disable firewall and so on) have worked for me. Has anyone else had this issue and is there a fix or a workaround. I tried installing Git and running from there but it gave me exactly the same error.

Any help appreciated.

Mike

Running problem

Hi,

I downloaded GPRPy and installed my Windows10, but "gprpy" or "python -m gprpy" command is not found.
I followed simplemost installation process, and there was no error message.
My command prompt is Ubuntu 18.04.2, and python is Python 3.8.2.

Thank you in advance!
Yuji

Not an Issue Just a Question

Is this still an active project? I am new to git Hub and not sure how to contribute and track changes to code through git but I love this program. It's amazing for teaching!

This package would be so perfect for my uses if we could add a Band-pass filter and an wave-number filter.

I have downloaded and looked at the code. I could probably easily write these two filters but would have no idea how to add it to the GUI. I have always used python for scripting not GUI development.

Is this something that we could add to a new version?

Thanks,
Brady
[email protected]

errors during importing the data

Hey Alain,
Thanks for the great work of open-sourse python tools for GPR processing. I have seen your AGU poster. And I have instralled the software, and import the example data. Then I tried to some other GSSI data, some errors occurs that "UnicodeDecodeError: 'utf-8' codec can't decode byte 0xed in position 14: invalid continuation byte".
So I write this issue and ask what types of GPR data are supported in GPRpy. Is there some extra requirmentes for the input data? How about the .Rad data?

Output file format

Hi, thank you for your wonderful work!

I processed the .DZT file using gprpy. However, when I save the file, it can only save as .gpr file. Even though I changed the source python file to let it not forcely save .gpr file, still get the same output.
Do you have any suggestions on save the processed data as .DZT file or convert the .gpr file to .DZT or npy file?
Any help would be very much appreciated!!

Best,
June

Empty plot after import

After I import data, the resulting plot is empty. I know the data files are good because they work in R using RGPR. The format is GSSI. I also know the installation of GPRPy works because I found test data in another issue that works.

Data

image

There are no errors in the log. What could be wrong?

Install Issue

Hello

The install of the source code seems to work well but when I run the program an ImprtError: No module named tkinter happens each time. I have reinstalled python 3.7 (latest update) and installed the apps you recommend in your directions. Any help would be greatly appreciated.

Screenshot (46)

Pulling the GUI Plot

Just a general question, but has anyone found a method to pull the matplotlib figure from the GPRPy GUI? I would like to be able to modify the plot with annotation, lines, etc., but I cannot seem to find a way to pull the plot (not as a pdf).

What is the procedure for making 3D surfaces?

Hello, thank you for the fascinating tool.

I can't find in any of documentation how to produce a 3D surface. It says it is possible in the publications, but doesn't detail how to combine the profiles into a data cube and I can't seem to figure it out.

Thanks again!

Installation

Hi,

I got the following error when trying to install GPRPy. Looks like the cloning and downloading package is ok, but when doing pip install ., I get this error. Any idea what I am doing wrong? Do I need to set up a special environnement?

ERROR: Could not install packages due to an EnvironmentError: HTTPSConnectionPool(host='files.pythonhosted.org', port=443): Max retries exceeded with url: /packages/e7/20/8d0c4ba96a5fe62e1bcf2b8a212ccfecd67ad951e8f3e89cf147d63952aa/Pmw-2.0.1.tar.gz (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1076)')))

Thanks for your help

Bastien

Kill traces functionality

Can you implement this as a button in the GPRPy GUI? It would be nice to have the ability to remove bad traces, such as the ringing shown below at ~70m along the profile.

image

import data `.gpr` file error

python --version
Python 3.10.4

The prompt I get when I run the software supports gpr files.
Can only read dt1, DT1, hd, HD, DZT, dat, GPRhdr, rad, rd3, rd7, and gpr files

The following error occurs when I import the .gpr file.
PS F:\study\GPRPy> gprpy
Profile [p] or Common Midpoint / WARR [c]? p
Exception in Tkinter callback
Traceback (most recent call last):
File "D:\Program Files\Python3\lib\tkinter_init_.py", line 1921, in call
return self.func(*args)
File "D:\Program Files\Python3\lib\site-packages\gprpy\gprpyGUI.py", line 203, in
command=lambda : [self.loadData(proj),
File "D:\Program Files\Python3\lib\site-packages\gprpy\gprpyGUI.py", line 728, in loadData
proj.importdata(filename=filename)
File "D:\Program Files\Python3\lib\site-packages\gprpy\gprpy.py", line 176, in importdata
data, info, profilePos, twtt, history, antsep, velocity, depth, maxTopo, minTopo, threeD, data_pretopo, twtt_pretopo = pickle.load(f)
_pickle.UnpicklingError: invalid load key, '\x00'.

What should I do with it, please?

Multi-channel GSSI support and distance normalization

Hi again Alain,

I finally got around to writing a GPRPy-specific export function that will create .npy and .json files for each channel as discussed in #3.

Additionally, with regards to the X scale: starting with version 0.0.10, readgssi is capable of distance-normalizing GPR profiles. If the DZT file is accompanied by a DZG (another proprietary GSSI file that contains NMEA GPS records written in ASCII), readgssi can distance-normalize the profile and replace rhf_spm in the header with the newly calculated samples per meter value. If I assume correctly, that should allow GPRPy to properly display the distance scale.

Users can do this in a console:

from readgssi.readgssi import readgssi
readgssi(infile='TEST__002.DZT', frmt='gprpy', normalize=True)

or in a command:

readgssi -N -f gprpy -i TEST__002.DZT

I've attached example files. GPRPy should be able to read them in to look somewhat like the image below (apologies for the ringing)
TEST__002-DZTDZG.tar.xz (file too large to attach, instead hosted from my website)
TEST__002-npyjson.zip
test__002

Cheers,
Ian

import .dt files from IDS Aladdin

Dear Author,
I just tired import my data from IDS Aladdin GPR (.dt file), but your app return AttributeError: 'gprpyProfile' object has no attribute 'profilePos'. There is something wrong with my data?

Best regards,
DT

GSSI Radargrams X axis incorrect

The x-axis is starting in the negatives instead of zero for GSSI files which is affecting locations of picks, observations, etc. Is there a way to rectify this?
Screen Shot 2021-09-23 at 12 55 37 PM

MALA RD7 files

Hi,
just started working with data from our new MALA GX system using *.rd7 filetypes, but data were not displayed correctly.
In gprIO_MALA.py line 27 dtype should be np.int32 (not np.int16).

Cheers,
Erich

Issue with executing python gprpyGUI.py command

Hello,
I am trying to install GPRPy on my system. I am using Ubuntu 18.04 and miniconda with Python 3.6.6 version on it. Please take a look at the error mentioned below and let me know how to resolve it.
Traceback (most recent call last): File "gprpyGUI.py", line 13, in <module> import matplotlib as mpl File "/home/pavan/miniconda3/envs/gprMax/lib/python3.6/site-packages/matplotlib/__init__.py", line 210, in <module> if not compare_versions(numpy.__version__, __version__numpy__): AttributeError: module 'numpy' has no attribute '__version__'
Thanks in advance.
Pavan.

Align traces

Align traces results in an incorrect upward trace shift. I noted your comment that this may occur if the maximum amplitudes are not in the air wave. Do you have a solution for this, possibly a different processing method? See before and after below.

Before
align_traces_before

After
align_traces_after

No module named gprMax

Hi,
First I would thank you for sharing the new version of GPRMAX.
I followed the guidance, and the installation of the Python and GPRMAX goes smooth.
But I received an error while trying to run the gprMax simulation in pycharm but it's working in cmd
The error is shown as:
C:\Users\march\miniconda3\python.exe: No module named gprMax
C:\Users\march\miniconda3\python.exe: Error while finding module specification for 'tools.outputfiles_merge' (ModuleNotFoundError: No module named 'tools')

Best regards

How is the GPRPy input file created?

Hello,

I'm a young engineer and I'm interested in ground radar. I saw your work and wanted to try it. I did the uploads as described. However, I did not fully understand how to use it. I have a few questions that I hope you will answer;

  1. How do you create .dzt files?
  2. After creating the .dzt file, which command do you write and run at the command prompt?
  3. Do you have a .in file to create a model? Or is the input file of the model already created in .dzt?

Best regards,
Gokcen.

Documentation on how to work with GPRPy

Hi, I am just starting out on a project and specifically need python support for later work. I can't find any tutorials on how and what processing steps can be done using GPRPy.

Thanks

Input filetypes

I am in the process of choosing software to process some GPR data looking at ice thickness in Antarctica. Your suite looks great,

My data is in numpy arrays, I am trying to convert it a suitable filetype.

How is your '.gpr' arranged? Would you recommend using this format over the others options (.DT1,.DZT, .GPRhdr, .rad ).
I have waveform data and corresponding xyz location and timestamp.

I have seen the example data /exampledata/GSSI, but cant see how the DZT file is arranged, and am not sure what the two corresponding txt files are.

Thanks kindly,
arran

Sensors and Software .gpz file

Hello,

I am a graduate student and acquired my GPR lines with Sensors and Software pulseEKKO. When I exported the data from the GPR unit it downloaded as a gpz file. Is there anyway I can open this with GPRPy? Thank you!

makeDataCube

Just downloaded and installed this wonnderful and easy to use tool. Thank you Alain.
Probably there is something easy I am missing.. I noticed that in the GUI version there is no link to makeDataCube. The python script is straightforward, but I do not find any example to easy check the format of the profiles to give. Is there somewhere an example to create an interpolated DataCube from preprocessed profiles??
Thank you

Use GPRPy to plot from script?

I'm wondering if it is possible to launch GPRPy from the command-line and automatically plot a DZT file using the processing from the "write script" button?

I see that I can use the script to write a plot in a PDF, but I would prefer to plot with the GUI using a script if that is possible.

Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.