I wish to import a filtered ERT dataset so that i can visualize the datapoints removed. However i have trouble importing the dataset.
On an issue posted on this page earlier on this date i succesfully imported raw ERT data with the following code:
dataset=pg.physics.ert.load("/Users/Isabe/Desktop/Procesering af ERT/1. felttur/Gradient XL_2-2023-06-29-172138.dat")
However i get an error message when i try to import the filtered data with this code:
datafiltered=pg.physics.ert.load("/Users/Isabe/Desktop/Filtrering af ERT data/Check filter 1.txt")
It is very possible that there is some issue with the data files themselves, as the filtered data file is not 100% similar to the original datafile. I have e.g. removed the IP-columns. In the two following pictures you can see the differance.
I am a fairly inexperienced programmer, and I am attepting to make the filtered datafile as similar to the original as possible, but I could use a hand to understand why the .txt file are not able to import, so I can figure out what changes to make.
A screenshot of the .dat file of the raw data that was succesfully imported
A screenshot of the .txt. file of the filtered data that was not able to import
Your environment
OS : Windows
CPU(s) : 8
Machine : AMD64
Architecture : 64bit
RAM : 7.8 GiB
Environment : IPython
Python 3.9.18 | packaged by conda-forge | (main, Dec 23 2023, 16:29:04) [MSC
v.1929 64 bit (AMD64)]
datafiltered=pg.physics.ert.load("/Users/Isabe/Desktop/Filtrering af ERT data/Check filter 1.txt")
### Expected behavior
I expected the data to be imported succesfully like with the unfiltered data.
### Actual behavior
The filtered data was not imported succesfully, as the following error message was given.
04/03/24 - 15:51:58 - pyGIMLi - INFO - could not read unified data format for ERT ... try res2dinv
04/03/24 - 15:51:58 - pyGIMLi - INFO - could not read res2dinv ... try Ascii columns
04/03/24 - 15:51:58 - pyGIMLi - INFO - Failed importing Ascii column file. Consider using pybert.
04/03/24 - 15:51:58 - pyGIMLi - INFO - No electrode positions found!
Traceback (most recent call last):
File ~\anaconda3\envs\pg\lib\site-packages\spyder_kernels\py3compat.py:356 in compat_exec
exec(code, globals, locals)
File c:\users\isabe\desktop\filtrering af ert data\visualisering af datafiltrering i pygimli.py:27
datafiltered=pg.physics.ert.load("/Users/Isabe/Desktop/Filtrering af ERT data/Check filter 1.txt")
File ~\anaconda3\envs\pg\lib\site-packages\pygimli\physics\ert\importData.py:48 in load
data = pb.importData(fileName)
AttributeError: module 'pybert' has no attribute 'importData'
> If possible, please add one or more labels to your issue, e.g. if you expect that your issue is rather a question than a problem with the code, please add the label "question".
Problem description
I wish to import a filtered ERT dataset so that i can visualize the datapoints removed. However i have trouble importing the dataset.
On an issue posted on this page earlier on this date i succesfully imported raw ERT data with the following code: dataset=pg.physics.ert.load("/Users/Isabe/Desktop/Procesering af ERT/1. felttur/Gradient XL_2-2023-06-29-172138.dat")
However i get an error message when i try to import the filtered data with this code: datafiltered=pg.physics.ert.load("/Users/Isabe/Desktop/Filtrering af ERT data/Check filter 1.txt")
It is very possible that there is some issue with the data files themselves, as the filtered data file is not 100% similar to the original datafile. I have e.g. removed the IP-columns. In the two following pictures you can see the differance.
I am a fairly inexperienced programmer, and I am attepting to make the filtered datafile as similar to the original as possible, but I could use a hand to understand why the .txt file are not able to import, so I can figure out what changes to make.
A screenshot of the .dat file of the raw data that was succesfully imported
A screenshot of the .txt. file of the filtered data that was not able to import
Your environment
OS : Windows CPU(s) : 8 Machine : AMD64 Architecture : 64bit RAM : 7.8 GiB Environment : IPython
Python 3.9.18 | packaged by conda-forge | (main, Dec 23 2023, 16:29:04) [MSC v.1929 64 bit (AMD64)]
Steps to reproduce
import pygimli as pg import pybert as pb
datafiltered=pg.physics.ert.load("/Users/Isabe/Desktop/Filtrering af ERT data/Check filter 1.txt")
04/03/24 - 15:51:58 - pyGIMLi - INFO - could not read unified data format for ERT ... try res2dinv 04/03/24 - 15:51:58 - pyGIMLi - INFO - could not read res2dinv ... try Ascii columns 04/03/24 - 15:51:58 - pyGIMLi - INFO - Failed importing Ascii column file. Consider using pybert. 04/03/24 - 15:51:58 - pyGIMLi - INFO - No electrode positions found! Traceback (most recent call last):
File ~\anaconda3\envs\pg\lib\site-packages\spyder_kernels\py3compat.py:356 in compat_exec exec(code, globals, locals)
File c:\users\isabe\desktop\filtrering af ert data\visualisering af datafiltrering i pygimli.py:27 datafiltered=pg.physics.ert.load("/Users/Isabe/Desktop/Filtrering af ERT data/Check filter 1.txt")
File ~\anaconda3\envs\pg\lib\site-packages\pygimli\physics\ert\importData.py:48 in load data = pb.importData(fileName)
AttributeError: module 'pybert' has no attribute 'importData'