--- id: roffio version: "1.1.1" license: LGPL-3.0 license_treatment: copyleft maintenance: active --- # RoffIO — A (lazy) parser and writer for the Roxar Open File Format (ROFF). License: copyleft · Maintenance: active · Downloads: 120.4K/mo ## What it is and what it does Roffio is a parser and writer for Roxar Open File Format (ROFF), a structured binary and ASCII file format used primarily in geoscience applications. It provides both eager and lazy reading modes: eager read loads the entire file into a nested dictionary structure keyed by tag and tag-key names, while lazy read iterates through tags and keys on-demand, useful for extracting specific values from large files without loading everything into memory. The package handles ROFF's type system (int, float, double, bool, byte, char, and arrays thereof) and maps them to Python and numpy types. It supports files with duplicate tag names by returning lists of dictionaries when collisions occur. Binary ROFF files are automatically distinguished from ASCII variants, and endianness is managed through a filedata tag convention. The library depends on numpy for array handling and dataclasses for internal structure. Use it for: - Extract specific values from large geoscience ROFF files without loading the entire file into memory using lazy read. - Convert ROFF data to Python dictionaries for further processing or analysis in scientific workflows. - Write structured geoscience data back to ROFF format, preserving type information and tag hierarchy. - Parse binary ROFF files from legacy geoscience software and convert to modern formats. - Handle ROFF files with repeated tag names by reading them as lists of dictionaries. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Roffio reads and writes Roxar Open File Format (ROFF) files in both binary and ASCII variants, with support for lazy parsing to minimize memory and disk overhead. Yes, if you work with Roxar Open File Format data. Install friction is low, maintenance is active, and there are no known vulnerabilities. The copyleft LGPL-3.0 license is a consideration only if you plan to distribute modified versions. The Planning development status suggests the API may not be fully stable, so pin the version or monitor releases if stability is critical. ## Install pip install roffio uv add roffio poetry add roffio ## Installing RoffIO Before you install: Low install friction—pure Python wheel with only dataclasses and numpy as runtime dependencies. Active maintenance with recent commits; however, development status is marked as Planning, which may indicate the API is not yet stabilized. License in practice: Licensed under LGPL-3.0 (copyleft). Any derivative work or modification must be distributed under the same license; static linking or closed-source distribution of modified versions is not permitted. Quickstart: import roffio # Read a ROFF file contents = roffio.read("my/file.roff") value = contents["tagname"]["keyname"] # Write a ROFF file roffio.write("my/file.roff", {"tagname": {"keyname": 1.0}}) # Lazy read to avoid loading entire file with roffio.lazyread("my/file.roff") as contents: for tagname, tagkeys in contents: for keyname, value in tagkeys: print(tagname, keyname, value) Verify before relying: - Whether the Planning development status indicates breaking API changes are expected or if it is simply outdated metadata. - Performance characteristics when handling large ROFF files or deeply nested tag structures. - Whether endianness detection via the filedata tag's byteswaptest is automatic or requires manual configuration. ## Package facts - License: LGPL-3.0 (copyleft) - Python support: unspecified - Install friction: low - Maintenance: active - Downloads: 120.4K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags ROFF file parser, Roxar Open File Format, binary file format reader, lazy file parsing, geoscience data format, structured tag-based file I/O, file-format, geoscience, lazy-loading [View on SkillFed](https://skillfed.io/packages/roffio) · [View on PyPI](https://pypi.org/project/roffio/)