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

Unexpectedly slow when reading file which only contains a single column in the data section #584

Open
Soumya3276 opened this issue Jan 29, 2024 · 6 comments
Labels

Comments

@Soumya3276
Copy link

Soumya3276 commented Jan 29, 2024

Describe the bug
I was running lasio.read() on few files to get the STAT. value. But there is some files where no data is present in ascii section for respective Measured Depth values. But the lasio.read() not giving any error or exception. It just keeps on running.

To Reproduce
Due to security and privacy reasons I cannot upload that file (even any sample file) from my computer.
I can attach photograph of a sample file.

Expected behavior
I expected if there is some error due to las file not maintaining proper formatting or cases like these, there should be an error to indicate that. So I will be able to handle that error. (e.g. it should give value error or some other error if only one curve is present as in this case.)

Software versions (please complete the following information):

  • Python version: 3.12.1 64bit
    IMG_20240129_125702-01

  • Python distribution: Miniconda

  • lasio version (import lasio; print(lasio.__version__)) 0.31

Additional context
Add any other context about the problem here.

@Soumya3276 Soumya3276 added the bug label Jan 29, 2024
@kinverarity1
Copy link
Owner

kinverarity1 commented Jan 29, 2024

Thanks for the bug report. How many lines are in your LAS file? i.e. we can see 34 lines in your photo - how many are there in total?

@Soumya3276
Copy link
Author

Soumya3276 commented Jan 30, 2024

It has total 7700+ lines

@dagrha
Copy link
Collaborator

dagrha commented Feb 2, 2024

@Soumya3276, does lasio hang if you pass the ignore_data=True argument to lasio.read()?

@Soumya3276
Copy link
Author

Thanks for the suggestion. I will try that. One thing I have noticed if I manually delete some lines from ASCII section. It will read but it is very slow as compared to other files. Seems like time taken is directly dependent on No. of lines in ASCII section.

@Soumya3276
Copy link
Author

@Soumya3276, does lasio hang if you pass the ignore_data=True argument to lasio.read()?

ignore_data is giving out of bound error.

@kinverarity1 kinverarity1 changed the title Reader stuck for too long on a file. Unexpectedly slow when reading file which only contains a single column in the data section Mar 13, 2024
@kinverarity1
Copy link
Owner

@Soumya3276, does lasio hang if you pass the ignore_data=True argument to lasio.read()?

ignore_data is giving out of bound error.

potentially related to #580

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

No branches or pull requests

3 participants