welly icon indicating copy to clipboard operation
welly copied to clipboard

Problem with formatting of output from `to_las`

Open mycarta opened this issue 6 years ago • 4 comments

I load a bunch of LAS files using project. I then create a UWI from Well Name using regex and replace nan values in gaps using numpy. Finally I export to LAS using w.to_las for each well (in a loop).

The resulting LAS files have issues with STOP and STEP (all files) which now have too many digits (and not coresponding to actuals in the file.

ORIGINAL INPUT LAS HEADER and top/bottom rows: Screen Shot 2019-03-09 at 2 26 55 PM

OUTPUT LAS HEADER and top/bottom rows: Screen Shot 2019-03-09 at 2 28 22 PM

mycarta avatar Feb 22 '19 15:02 mycarta

Hey @mycarta -- what version of lasio do you have installed? I'm not sure if this is happening with the latest, I'm not seeing it here with a quick test.

kinverarity1 avatar Feb 23 '19 08:02 kinverarity1

@Kent, I have 0.23 installed:

image

mycarta avatar Feb 25 '19 14:02 mycarta

OK thanks, I'll have to dig deeper to try and reproduce it.

Get Outlook for Androidhttps://aka.ms/ghei36


From: Matteo Niccoli [email protected] Sent: Tuesday, February 26, 2019 1:13:08 AM To: agile-geoscience/welly Cc: Kent Inverarity; Comment Subject: Re: [agile-geoscience/welly] Problem with formatting of output from to_las (#107)

@kenthttps://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fkent&data=02%7C01%7C%7Cf673ad131cd04444bae608d69b2f901e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636867025924936404&sdata=kXC4Uz%2FvOVyXzk%2BMwm9trIl9h8pxVGCx7E2PYMypZY8%3D&reserved=0, I have 0.23 installed:

[image]https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fuser-images.githubusercontent.com%2F7424763%2F53344857-e520dd00-38d0-11e9-853e-ad0e54c7bb13.png&data=02%7C01%7C%7Cf673ad131cd04444bae608d69b2f901e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636867025924946421&sdata=rNRAo8kSGqDFdWBk6KAfq9Ddu5uNs2cuAtgSjvgxxvA%3D&reserved=0

— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fagile-geoscience%2Fwelly%2Fissues%2F107%23issuecomment-467036545&data=02%7C01%7C%7Cf673ad131cd04444bae608d69b2f901e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636867025924956432&sdata=%2BOampa9jAQsxh%2B2BtvOVUQfvp39klNtkqivTkFCIJcs%3D&reserved=0, or mute the threadhttps://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAEUPa6ecwD_UfWYvbqh30DtA4nBVDsNlks5vQ_Z7gaJpZM4bJ3m2&data=02%7C01%7C%7Cf673ad131cd04444bae608d69b2f901e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C636867025924966430&sdata=sbZuHm4eoYft1v4tTa9XEH5pSXoR1bsAxLh22xsWsMk%3D&reserved=0.

kinverarity1 avatar Feb 25 '19 19:02 kinverarity1

I've confirmed that this is an issue with welly. Both the Well and Project workflows are affected in the same way.

See two example files here for reproducing it: 6038187_las_files.zip The only difference is that one has had the data section truncated (and the STOP depth correctly adjusted).

The truncated input file has:

STRT.M             0.05  :FIRST INDEX VALUE
STOP.M             0.35  :LAST INDEX VALUE
STEP.M        0.050  :STEP

And the full input file has:

STRT.M             0.05  :FIRST INDEX VALUE
STOP.M           136.60  :LAST INDEX VALUE
STEP.M        0.050  :STEP

Example code:

import welly

for testfn in ("6038187_full.las", "6038187_trunc.las"):

    w = welly.Well.from_las(testfn)
    w.to_las(testfn + "_via_Well.las")

    p = welly.Project.from_las(testfn)
    for pw in p:
        pw.to_las(testfn + "_via_Project.las")

Outputs are here: 6038187-outputs.zip

The Well.to_las() output files both have incorrect STOP and STEP values in the header. The STRT values are correct.

The truncated example LAS file output is:

STRT.m                      0.05 : START DEPTH
STOP.m        0.3499999999999999 : STOP DEPTH
STEP.m       0.04999999999999999 : STEP

And the full example output is:

STRT.m                      0.05 : START DEPTH
STOP.m         136.5999999999922 : STOP DEPTH
STEP.m      0.049999999999997144 : STEP

It looks like welly is estimating both STOP and STEP and underestimating both by a (very small) error which is a function of the range of depths in the file.

kinverarity1 avatar Mar 07 '19 23:03 kinverarity1