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

Loading horizon #1

Open
timaou01 opened this issue Mar 19, 2015 · 4 comments
Open

Loading horizon #1

timaou01 opened this issue Mar 19, 2015 · 4 comments

Comments

@timaou01
Copy link

Dear Joe Kington,

Thank you very much for sharing your code, experience and knowledge.
Your code and presentation are really helpful,useful and interesting for me.
I have successfully loaded and viewed the 3D volume, however, when I try to load horizon, I get the the following error:
I will be very grateful to you for any assistance or hint.

Mohammed


EOFError Traceback (most recent call last)
in ()
4 import scipy.ndimage
5
----> 6 hor = geoprobe.horizon('C:\Users\Desktop\Python\scipy2014-3d_seismic-master\scipy2014-3d_seismic-master\data\Horizons\channels_smoothed.hzn')
7 vol = geoprobe.volume('C:\Users\Desktop\Python\scipy2014-3d_seismic-master\scipy2014-3d_seismic-master\data\Volumes\example.vol')
8 data = vol.load()

C:\Users\AppData\Local\Enthought\Canopy32\User\lib\site-packages\geoprobe-0.3-py2.7.egg\geoprobe\horizon.pyc in init(self, _args, *_kwargs)
77 # and make a horizon object by reading from disk
78 if (len(args) == 1) and isinstance(args[0], basestring):
---> 79 self._readHorizon(args[0])
80
81 # Otherwise, pass the args on to _make_horizon_from_data for

C:\Users\AppData\Local\Enthought\Canopy32\User\lib\site-packages\geoprobe-0.3-py2.7.egg\geoprobe\horizon.pyc in _readHorizon(self, filename)
106 ' horizon')
107
--> 108 self.data = self._file.readAll()
109
110 # Surface and line attributes

C:\Users\AppData\Local\Enthought\Canopy32\User\lib\site-packages\geoprobe-0.3-py2.7.egg\geoprobe\horizon.pyc in readAll(self)
451 # Read lines section
452 line_info = [None]
--> 453 self.numlines = self.readSectionHeader()
454 for i in xrange(self.numlines):
455 line_info.append(self.readLineHeader())

C:\Users\AppData\Local\Enthought\Canopy32\User\lib\site-packages\geoprobe-0.3-py2.7.egg\geoprobe\horizon.pyc in readSectionHeader(self)
423
424 def readSectionHeader(self):
--> 425 return self.readBinary(self._sectionHdrFmt)
426
427 def readLineHeader(self):

C:\Users\AppData\Local\Enthought\Canopy32\User\lib\site-packages\geoprobe-0.3-py2.7.egg\geoprobe\common.pyc in readBinary(self, fmt)
65 # Reading beyond the end of the file just returns ''
66 if len(data) != size:
---> 67 raise EOFError('End of file reached')
68 data = struct.unpack(fmt, data)
69

EOFError: End of file reached

@joferkington
Copy link
Owner

Judging from the error being raised, it looks like the horizon file isn't the size it should be.

Is it possible that the downloaded horizon was corrupted or truncated in some way? The file size for that horizon should be 1757.238 Kb.

You might try redownloading that particular file or re-cloning the repository.

If that doesn't fix it, I'm at a bit of a loss... It could be a 32-bit vs 64-bit issue (It looks like you might be running a 32-bit version of python?), but I don't understand why that would cause this particular problem. I haven't tested it with recent versions of the libraries involved, but python-geoprobe should work just fine on a 32-bit install.

@timaou01
Copy link
Author

Thank you very much for your prompt answer.
The size of the file I am using is 1,731 kb (as it is in the repository, I've downloaded it again).
So, it might be the 32bit vs 64bit. In fact, I am using 32bit but please be informed that the volume loading was successful and it can be displayed very normally.
Is it possible to generate another horizon from that volume using geo-probe? If not, how can I convert segy(for the data) and txt(for horizons) formats to readable formats by geoprobe(.hzn, .vol).

Your assistance and kindness is highly appreciated.

@timaou01
Copy link
Author

timaou01 commented May 3, 2015

Dear Mr. Kington,
I would just like to ask how can one load a segy-formatted data into geoprobe. Or how to to convert segy to a readable format by geoprobe.

Thank you in advance for your kind assistance. It is highly appreciated.

Mohammed.

@Andersongeofisco
Copy link

Andersongeofisco commented Sep 7, 2018

I would like to know too. How do I convert segy to .vol Format? Do you know @timaou01

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

3 participants