Skip to main content

A function to facilitate loading well log data, in las or dlis format, as dataframe.

Project description

log2frame

import log2frame

A function to read well log data in LAS, LIS and DLIS formats and extract curves data as DataFrame.

The curves and header data are stored in an instance of Log class, designed to hold this data and operate with it. If multiple log files are read together, the Log instances are packed in a Pack instance, designed to hold Log instances and operate with them.

unit-aware mode

When simpandas is installed, log2frame can preserve curve units and index units through the use_simpandas option.

  • log2frame.read(path, use_simpandas=False) returns plain pandas-backed Log instances.
  • log2frame.read(path, use_simpandas=True) uses simpandas.SimDataFrame when available.
  • If use_simpandas is omitted, the package defaults to the installed simpandas setting.

to read log files

Simply call the function read() with the path or path pattern as argument:

a single log file

To load a single .las, .lis or .dlis file. The function will return a Log instance containing the data:

  • log2frame.read( path_to_file )

several files in a folder

To load several files at once. In this case the read() function will return a Pack instance containing a Log instance for each log file:

  • log2frame.read( path_to_folder_containing_files/*.* ) By default, any invalid file will be ignored, thus, there is no problem to have other files in the same folder as the log files.

several files recursively

To read files recursively in subdirectories, use the appropriate fnmatch pattern:

  • log2frame.read( path_to_folder_containing_files/**/*.* )

further examples and details

Please refer to the Jupyter notebook log2frame_demo for further examples and details on how to use log2frame.
The sample data is publicly available at NLOG.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

log2frame-0.2.1.tar.gz (19.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

log2frame-0.2.1-py3-none-any.whl (19.5 kB view details)

Uploaded Python 3

File details

Details for the file log2frame-0.2.1.tar.gz.

File metadata

  • Download URL: log2frame-0.2.1.tar.gz
  • Upload date:
  • Size: 19.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for log2frame-0.2.1.tar.gz
Algorithm Hash digest
SHA256 a32a8aada4d3587e1e10a4825b9fe2bed9f78b00661dd81af6f9172228fd0657
MD5 589d5ca4ac7441f28d8f2347ed283a77
BLAKE2b-256 9b32dbe6cefc562447c069b8a054f95b47dbff1963a825dc31e4cafb438f9771

See more details on using hashes here.

File details

Details for the file log2frame-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: log2frame-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 19.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for log2frame-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f079a491a29be98aa1ccf2208a2fb1f48bec28bac5f1119929d4679d3c06b533
MD5 6bfeb9bac39e773e4066ed188231177f
BLAKE2b-256 015e8507d268d4d63c320f3b6c037d00e5936051b5e4c1013e262375c136a0f8

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page