Created
May 15, 2021 09:55
-
-
Save kinverarity1/aaf3459c3fa3eeafe127c9011c15c835 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"cells": [ | |
{ | |
"cell_type": "code", | |
"execution_count": 1, | |
"id": "suburban-nirvana", | |
"metadata": {}, | |
"outputs": [], | |
"source": [ | |
"from sys import stdout\n", | |
"import lasio.examples\n", | |
"import logging" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": 2, | |
"id": "increasing-radius", | |
"metadata": { | |
"scrolled": true | |
}, | |
"outputs": [], | |
"source": [ | |
"las = lasio.examples.open(\"2.0/sample_2.0.las\")" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": 3, | |
"id": "raised-thermal", | |
"metadata": { | |
"scrolled": false | |
}, | |
"outputs": [ | |
{ | |
"name": "stdout", | |
"output_type": "stream", | |
"text": [ | |
"~Version ---------------------------------------------------\n", | |
"VERS. 2.0 : CWLS log ASCII Standard -VERSION 2.0\n", | |
"WRAP. NO : ONE LINE PER DEPTH STEP\n", | |
"~Well ------------------------------------------------------\n", | |
"STRT.M 1670.0 : START DEPTH\n", | |
"STOP.M 1669.75 : STOP DEPTH\n", | |
"STEP.M -0.125 : STEP\n", | |
"NULL. -999.25 : NULL VALUE\n", | |
"COMP. ANY OIL COMPANY INC. : COMPANY\n", | |
"WELL. AAAAA_2 : WELL\n", | |
"FLD . WILDCAT : FIELD\n", | |
"LOC . 12-34-12-34W5M : LOCATION\n", | |
"PROV. ALBERTA : PROVINCE\n", | |
"SRVC. ANY LOGGING COMPANY INC. : SERVICE COMPANY\n", | |
"DATE. 13-DEC-86 : LOG DATE\n", | |
"UWI . 100123401234W500 : UNIQUE WELL ID\n", | |
"~Curve Information -----------------------------------------\n", | |
"DEPT.M : 1 DEPTH\n", | |
"DT .US/M 60 520 32 00 : 2 SONIC TRANSIT TIME\n", | |
"RHOB.K/M3 45 350 01 00 : 3 BULK DENSITY\n", | |
"NPHI.V/V 42 890 00 00 : 4 NEUTRON POROSITY\n", | |
"SFLU.OHMM 07 220 04 00 : 5 SHALLOW RESISTIVITY\n", | |
"SFLA.OHMM 07 222 01 00 : 6 SHALLOW RESISTIVITY\n", | |
"ILM .OHMM 07 120 44 00 : 7 MEDIUM RESISTIVITY\n", | |
"ILD .OHMM 07 120 46 00 : 8 DEEP RESISTIVITY\n", | |
"~Params ----------------------------------------------------\n", | |
"MUD . GEL CHEM : MUD TYPE\n", | |
"BHT .DEGC 35.5 : BOTTOM HOLE TEMPERATURE\n", | |
"BS .MM 200.0 : BIT SIZE\n", | |
"FD .K/M3 1000.0 : FLUID DENSITY\n", | |
"MATR. SAND : NEUTRON MATRIX\n", | |
"MDEN. 2710.0 : LOGGING MATRIX DENSITY\n", | |
"RMF .OHMM 0.216 : MUD FILTRATE RESISTIVITY\n", | |
"DFD .K/M3 1525.0 : DRILL FLUID DENSITY\n", | |
"~Other -----------------------------------------------------\n", | |
"Note: The logging tools became stuck at 625 metres causing the data\n", | |
"between 625 metres and 615 metres to be invalid.\n", | |
"~ASCII------------------------------------------------------\n", | |
" 1670.00000 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n", | |
" 1669.87500 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n", | |
" 1669.75000 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n" | |
] | |
} | |
], | |
"source": [ | |
"# logging.basicConfig(level=logging.DEBUG)\n", | |
"las.write(stdout, mnemonics_header=False, data_section_header=\"~ASCII\")#, len_numeric_field=4, fmt=\"%02.0f\")" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": 4, | |
"id": "searching-teaching", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"name": "stdout", | |
"output_type": "stream", | |
"text": [ | |
"~Version ---------------------------------------------------\n", | |
"VERS. 2.0 : CWLS log ASCII Standard -VERSION 2.0\n", | |
"WRAP. NO : ONE LINE PER DEPTH STEP\n", | |
"~Well ------------------------------------------------------\n", | |
"STRT.M 1670.0 : START DEPTH\n", | |
"STOP.M 1669.75 : STOP DEPTH\n", | |
"STEP.M -0.125 : STEP\n", | |
"NULL. -999.25 : NULL VALUE\n", | |
"COMP. ANY OIL COMPANY INC. : COMPANY\n", | |
"WELL. AAAAA_2 : WELL\n", | |
"FLD . WILDCAT : FIELD\n", | |
"LOC . 12-34-12-34W5M : LOCATION\n", | |
"PROV. ALBERTA : PROVINCE\n", | |
"SRVC. ANY LOGGING COMPANY INC. : SERVICE COMPANY\n", | |
"DATE. 13-DEC-86 : LOG DATE\n", | |
"UWI . 100123401234W500 : UNIQUE WELL ID\n", | |
"~Curve Information -----------------------------------------\n", | |
"DEPT.M : 1 DEPTH\n", | |
"DT .US/M 60 520 32 00 : 2 SONIC TRANSIT TIME\n", | |
"RHOB.K/M3 45 350 01 00 : 3 BULK DENSITY\n", | |
"NPHI.V/V 42 890 00 00 : 4 NEUTRON POROSITY\n", | |
"SFLU.OHMM 07 220 04 00 : 5 SHALLOW RESISTIVITY\n", | |
"SFLA.OHMM 07 222 01 00 : 6 SHALLOW RESISTIVITY\n", | |
"ILM .OHMM 07 120 44 00 : 7 MEDIUM RESISTIVITY\n", | |
"ILD .OHMM 07 120 46 00 : 8 DEEP RESISTIVITY\n", | |
"~Params ----------------------------------------------------\n", | |
"MUD . GEL CHEM : MUD TYPE\n", | |
"BHT .DEGC 35.5 : BOTTOM HOLE TEMPERATURE\n", | |
"BS .MM 200.0 : BIT SIZE\n", | |
"FD .K/M3 1000.0 : FLUID DENSITY\n", | |
"MATR. SAND : NEUTRON MATRIX\n", | |
"MDEN. 2710.0 : LOGGING MATRIX DENSITY\n", | |
"RMF .OHMM 0.216 : MUD FILTRATE RESISTIVITY\n", | |
"DFD .K/M3 1525.0 : DRILL FLUID DENSITY\n", | |
"~Other -----------------------------------------------------\n", | |
"Note: The logging tools became stuck at 625 metres causing the data\n", | |
"between 625 metres and 615 metres to be invalid.\n", | |
"~ASCII DEPT DT RHOB NPHI SFLU SFLA ILM ILD\n", | |
" 1670.00000 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n", | |
" 1669.87500 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n", | |
" 1669.75000 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n" | |
] | |
} | |
], | |
"source": [ | |
"las.write(stdout, mnemonics_header=True, data_section_header=\"~ASCII\")#, len_numeric_field=4, fmt=\"%02.0f\")" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": 6, | |
"id": "supposed-chrome", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"name": "stdout", | |
"output_type": "stream", | |
"text": [ | |
"~Version ---------------------------------------------------\n", | |
"VERS. 2.0 : CWLS log ASCII Standard -VERSION 2.0\n", | |
"WRAP. NO : ONE LINE PER DEPTH STEP\n", | |
"~Well ------------------------------------------------------\n", | |
"STRT.M 1670.0 : START DEPTH\n", | |
"STOP.M 1669.75 : STOP DEPTH\n", | |
"STEP.M -0.125 : STEP\n", | |
"NULL. -999.25 : NULL VALUE\n", | |
"COMP. ANY OIL COMPANY INC. : COMPANY\n", | |
"WELL. AAAAA_2 : WELL\n", | |
"FLD . WILDCAT : FIELD\n", | |
"LOC . 12-34-12-34W5M : LOCATION\n", | |
"PROV. ALBERTA : PROVINCE\n", | |
"SRVC. ANY LOGGING COMPANY INC. : SERVICE COMPANY\n", | |
"DATE. 13-DEC-86 : LOG DATE\n", | |
"UWI . 100123401234W500 : UNIQUE WELL ID\n", | |
"~Curve Information -----------------------------------------\n", | |
"DEPT.M : 1 DEPTH\n", | |
"DT .US/M 60 520 32 00 : 2 SONIC TRANSIT TIME\n", | |
"RHOB.K/M3 45 350 01 00 : 3 BULK DENSITY\n", | |
"NPHI.V/V 42 890 00 00 : 4 NEUTRON POROSITY\n", | |
"SFLU.OHMM 07 220 04 00 : 5 SHALLOW RESISTIVITY\n", | |
"SFLA.OHMM 07 222 01 00 : 6 SHALLOW RESISTIVITY\n", | |
"ILM .OHMM 07 120 44 00 : 7 MEDIUM RESISTIVITY\n", | |
"ILD .OHMM 07 120 46 00 : 8 DEEP RESISTIVITY\n", | |
"~Params ----------------------------------------------------\n", | |
"MUD . GEL CHEM : MUD TYPE\n", | |
"BHT .DEGC 35.5 : BOTTOM HOLE TEMPERATURE\n", | |
"BS .MM 200.0 : BIT SIZE\n", | |
"FD .K/M3 1000.0 : FLUID DENSITY\n", | |
"MATR. SAND : NEUTRON MATRIX\n", | |
"MDEN. 2710.0 : LOGGING MATRIX DENSITY\n", | |
"RMF .OHMM 0.216 : MUD FILTRATE RESISTIVITY\n", | |
"DFD .K/M3 1525.0 : DRILL FLUID DENSITY\n", | |
"~Other -----------------------------------------------------\n", | |
"Note: The logging tools became stuck at 625 metres causing the data\n", | |
"between 625 metres and 615 metres to be invalid.\n", | |
"~A DEPT DT RHOB NPHI SFLU SFLA ILM ILD\n", | |
" 1670.00000 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n", | |
" 1669.87500 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n", | |
" 1669.75000 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n" | |
] | |
} | |
], | |
"source": [ | |
"las.write(stdout, mnemonics_header=True, data_section_header=\"~A\")" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": 7, | |
"id": "excited-entertainment", | |
"metadata": {}, | |
"outputs": [ | |
{ | |
"name": "stdout", | |
"output_type": "stream", | |
"text": [ | |
"~Version ---------------------------------------------------\n", | |
"VERS. 2.0 : CWLS log ASCII Standard -VERSION 2.0\n", | |
"WRAP. NO : ONE LINE PER DEPTH STEP\n", | |
"~Well ------------------------------------------------------\n", | |
"STRT.M 1670.0 : START DEPTH\n", | |
"STOP.M 1669.75 : STOP DEPTH\n", | |
"STEP.M -0.125 : STEP\n", | |
"NULL. -999.25 : NULL VALUE\n", | |
"COMP. ANY OIL COMPANY INC. : COMPANY\n", | |
"WELL. AAAAA_2 : WELL\n", | |
"FLD . WILDCAT : FIELD\n", | |
"LOC . 12-34-12-34W5M : LOCATION\n", | |
"PROV. ALBERTA : PROVINCE\n", | |
"SRVC. ANY LOGGING COMPANY INC. : SERVICE COMPANY\n", | |
"DATE. 13-DEC-86 : LOG DATE\n", | |
"UWI . 100123401234W500 : UNIQUE WELL ID\n", | |
"~Curve Information -----------------------------------------\n", | |
"DEPT.M : 1 DEPTH\n", | |
"DT .US/M 60 520 32 00 : 2 SONIC TRANSIT TIME\n", | |
"RHOB.K/M3 45 350 01 00 : 3 BULK DENSITY\n", | |
"NPHI.V/V 42 890 00 00 : 4 NEUTRON POROSITY\n", | |
"SFLU.OHMM 07 220 04 00 : 5 SHALLOW RESISTIVITY\n", | |
"SFLA.OHMM 07 222 01 00 : 6 SHALLOW RESISTIVITY\n", | |
"ILM .OHMM 07 120 44 00 : 7 MEDIUM RESISTIVITY\n", | |
"ILD .OHMM 07 120 46 00 : 8 DEEP RESISTIVITY\n", | |
"~Params ----------------------------------------------------\n", | |
"MUD . GEL CHEM : MUD TYPE\n", | |
"BHT .DEGC 35.5 : BOTTOM HOLE TEMPERATURE\n", | |
"BS .MM 200.0 : BIT SIZE\n", | |
"FD .K/M3 1000.0 : FLUID DENSITY\n", | |
"MATR. SAND : NEUTRON MATRIX\n", | |
"MDEN. 2710.0 : LOGGING MATRIX DENSITY\n", | |
"RMF .OHMM 0.216 : MUD FILTRATE RESISTIVITY\n", | |
"DFD .K/M3 1525.0 : DRILL FLUID DENSITY\n", | |
"~Other -----------------------------------------------------\n", | |
"Note: The logging tools became stuck at 625 metres causing the data\n", | |
"between 625 metres and 615 metres to be invalid.\n", | |
"~A----------------------------------------------------------\n", | |
" 1670.00000 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n", | |
" 1669.87500 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n", | |
" 1669.75000 123.45000 2550.00000 0.45000 123.45000 123.45000 110.20000 105.60000\n" | |
] | |
} | |
], | |
"source": [ | |
"las.write(stdout, mnemonics_header=False, data_section_header=\"~A\")" | |
] | |
}, | |
{ | |
"cell_type": "code", | |
"execution_count": null, | |
"id": "neutral-radical", | |
"metadata": {}, | |
"outputs": [], | |
"source": [] | |
} | |
], | |
"metadata": { | |
"kernelspec": { | |
"display_name": "Python [conda env:dev]", | |
"language": "python", | |
"name": "conda-env-dev-py" | |
}, | |
"language_info": { | |
"codemirror_mode": { | |
"name": "ipython", | |
"version": 3 | |
}, | |
"file_extension": ".py", | |
"mimetype": "text/x-python", | |
"name": "python", | |
"nbconvert_exporter": "python", | |
"pygments_lexer": "ipython3", | |
"version": "3.9.2" | |
} | |
}, | |
"nbformat": 4, | |
"nbformat_minor": 5 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment