Skip to main content

Orso

Orso is a shared DataFrame library for Opteryx and Mabel.

PyPI Latest Release Downloads codecov Documentation

Overview

Orso is not intended to compete with Polars or Pandas (or your favorite bear DataFrame technology), instead it is developed as a common layer for Mabel and Opteryx.

Key Use Cases:

  • In Opteryx, Orso provides most of the database Cursor functionality
  • In Mabel, Orso provides the data schema and validation functionality

Orso DataFrames are row-based, driven by their initial target use-case as the WAL for Mabel and Cursor for Opteryx. Each row in an Orso DataFrame can be quickly converted to a Tuple of values, a Dictionary, or a byte representation.

Installation

Install Orso from PyPI:

pip install orso

Quick Start

Creating a DataFrame

import orso

# Create from list of dictionaries
df = orso.DataFrame([
    {'name': 'Alice', 'age': 30, 'city': 'New York'},
    {'name': 'Bob', 'age': 25, 'city': 'San Francisco'},
    {'name': 'Charlie', 'age': 35, 'city': 'Chicago'}
])

print(f"Created DataFrame with {df.rowcount} rows and {df.columncount} columns")

Displaying Data

# Display the DataFrame
print(df.display())

# Convert to different formats
arrow_table = df.arrow()  # PyArrow Table
pandas_df = df.pandas()   # Pandas DataFrame

Working with Schema

# Access column names
print("Columns:", df.column_names)

# Access schema information  
print("Schema:", df.schema)

Converting Between Formats

# From PyArrow
import pyarrow as pa
arrow_table = pa.table({'x': [1, 2, 3], 'y': ['a', 'b', 'c']})
orso_df = orso.DataFrame.from_arrow(arrow_table)

# To Pandas
pandas_df = orso_df.pandas()

Features

  • Lightweight: Minimal overhead for tabular data operations
  • Row-based: Optimized for row-oriented operations
  • Interoperable: Easy conversion to/from PyArrow, Pandas
  • Schema-aware: Built-in data validation and type checking
  • Fast serialization: Efficient conversion to bytes, tuples, and dictionaries

API Reference

DataFrame Class

The main DataFrame class provides the following key methods:

  • DataFrame(dictionaries=None, *, rows=None, schema=None) - Constructor
  • display(limit=5, colorize=True, show_types=True) - Pretty print the DataFrame
  • arrow(size=None) - Convert to PyArrow Table
  • pandas(size=None) - Convert to Pandas DataFrame
  • from_arrow(tables) - Create DataFrame from PyArrow Table(s)
  • fetchall() - Get all rows as list of Row objects
  • collect() - Materialize the DataFrame
  • append(other) - Append another DataFrame
  • distinct() - Get unique rows

Properties

  • rowcount - Number of rows
  • columncount - Number of columns
  • column_names - List of column names
  • schema - Schema information

Development

Building from Source

# Clone the repository
git clone https://github.com/mabel-dev/orso.git
cd orso

# Install dependencies
pip install -r requirements.txt
pip install -r tests/requirements.txt

# Build Cython extensions
make compile

# Run tests
make test

Contributing

Orso is part of the Mabel ecosystem. Contributions are welcome! Please ensure:

  1. All tests pass: make test
  2. Code follows the project style: make lint
  3. New features include appropriate tests
  4. Documentation is updated for API changes

Performance Benchmarking

Orso includes a comprehensive performance benchmark suite to compare different versions:

# Run full benchmark suite
python tests/test_benchmark_suite.py

# Compare two versions
python tests/test_benchmark_suite.py -o baseline.json
# <switch version>
python tests/test_benchmark_suite.py -o current.json -c baseline.json

See BENCHMARK_SUITE.md for detailed documentation.

License

License

Orso is licensed under Apache 2.0 unless explicitly indicated otherwise.

Status

Status

Orso is in beta. Beta means different things to different people, to us, being beta means:

  • Interfaces are generally stable but may still have breaking changes
  • Unit tests are not reliable enough to capture breaks to functionality
  • Bugs are likely to exist in edge cases
  • Code may not be tuned for performance

As such, we really don't recommend using Orso in critical applications.

  • Opteryx - SQL query engine for data files
  • Mabel - Data processing framework

Metadata

Release files for orso 0.0.246

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for orso 0.0.246
File Size Uploaded
orso-0.0.246.tar.gz 373.1 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for orso 0.0.246
File
orso-0.0.246-cp314-cp314-win_amd64.whl CPython 3.14 CPython 3.14 Windows x86-64 Details
orso-0.0.246-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.14 CPython 3.14 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
orso-0.0.246-cp314-cp314-macosx_10_15_universal2.whl CPython 3.14 CPython 3.14 macOS 10.15+ universal2 (ARM64, x86-64) Details
orso-0.0.246-cp313-cp313-win_amd64.whl CPython 3.13 CPython 3.13 Windows x86-64 Details
orso-0.0.246-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.13 CPython 3.13 Linux glibc 2.28+ x86-64, Linux glibc 2.17+ x86-64 Details
orso-0.0.246-cp313-cp313-macosx_10_15_universal2.whl CPython 3.13 CPython 3.13 macOS 10.15+ universal2 (ARM64, x86-64) Details
orso-0.0.246-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details
orso-0.0.246-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
orso-0.0.246-cp312-cp312-macosx_10_15_universal2.whl CPython 3.12 CPython 3.12 macOS 10.15+ universal2 (ARM64, x86-64) Details
orso-0.0.246-cp311-cp311-win_amd64.whl CPython 3.11 CPython 3.11 Windows x86-64 Details
orso-0.0.246-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
orso-0.0.246-cp311-cp311-macosx_10_15_universal2.whl CPython 3.11 CPython 3.11 macOS 10.15+ universal2 (ARM64, x86-64) Details
orso-0.0.246-cp310-cp310-win_amd64.whl CPython 3.10 CPython 3.10 Windows x86-64 Details
orso-0.0.246-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64, Linux glibc 2.28+ x86-64 Details
orso-0.0.246-cp310-cp310-macosx_10_15_universal2.whl CPython 3.10 CPython 3.10 macOS 10.15+ universal2 (ARM64, x86-64) Details

Total release size: 7.9 MB

Release files / orso-0.0.246.tar.gz

Download URL orso-0.0.246.tar.gz
Size 373.1 kB
Tags Source
SHA-256 checksum
How to use checksums
fc771560b4c10ec71b13a0531f7e1981b10e577ec2bece7f128874b477a7a925
BLAKE2b-256 checksum
How to use checksums
0ae136e70238f6ffeaab0e1655d0516b4a6413b4b3ce42a7336496c3b92802bd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp314-cp314-win_amd64.whl

Download URL orso-0.0.246-cp314-cp314-win_amd64.whl
Size 192.5 kB
Tags CPython 3.14 Windows x86-64
SHA-256 checksum
How to use checksums
ce4d2144b2c854436c2edd33e5eaa106af201f35530fee7e01b4704469f21420
BLAKE2b-256 checksum
How to use checksums
6e46d9b88503e886bdc11aaa4f0130d41f10da940ee3d3ebc22821b925b109bd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL orso-0.0.246-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 984.9 kB
Tags CPython 3.14 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
bc9fd07f1a1d6dd7e4304fb5819b97cc2d4ed6f0db25ed776f7cb79b2f58645a
BLAKE2b-256 checksum
How to use checksums
79b9728f445a19fe78d0980204af1ff3bcaf8961ac102a65291d006396ad383b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp314-cp314-macosx_10_15_universal2.whl

Download URL orso-0.0.246-cp314-cp314-macosx_10_15_universal2.whl
Size 340.4 kB
Tags CPython 3.14 macOS 10.15+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
bc1c539350ba534ad69562265767a03a558aee5bbbff56080ec8e712b82801a0
BLAKE2b-256 checksum
How to use checksums
5151a2a3f00b0e4ae938abb1d35df89e9c91afc94efb86bcc8a0d86445555031
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp313-cp313-win_amd64.whl

Download URL orso-0.0.246-cp313-cp313-win_amd64.whl
Size 189.3 kB
Tags CPython 3.13 Windows x86-64
SHA-256 checksum
How to use checksums
1766b4a934d5bed29487b025ce9a62201b8b0d078da395861eca1e5ac7fde3ac
BLAKE2b-256 checksum
How to use checksums
00c04197ba497b7007a380781d920a91ee60a588daf2d6b02dc1c43f37aeb58b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL orso-0.0.246-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 996.3 kB
Tags CPython 3.13 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
94a7c91c4ccbae168e212d2add51f99a35749c32f8be904de73aa26b0933debb
BLAKE2b-256 checksum
How to use checksums
71e249b2588c39e2b9e45721e45ec4c7a69ff6e25821faf129809ff7f5c63596
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp313-cp313-macosx_10_15_universal2.whl

Download URL orso-0.0.246-cp313-cp313-macosx_10_15_universal2.whl
Size 340.6 kB
Tags CPython 3.13 macOS 10.15+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
9ccd1fb7eb744a74836a4b8cd6fcbbcffbbc1fb89e34f45eddf80ba3c940f40e
BLAKE2b-256 checksum
How to use checksums
0d4e8158cd7520080c710ea17f81ea1af3221a759427120783f6deabec8b0ba6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp312-cp312-win_amd64.whl

Download URL orso-0.0.246-cp312-cp312-win_amd64.whl
Size 189.7 kB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
15c73d1cf233561d3bf3ba8efd16ffc62ddb8803552cd20a6dd598322e30489f
BLAKE2b-256 checksum
How to use checksums
1e9d7e41dc798f56c1159b826de9d124489a754375bf0dd98371516a379f7b06
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL orso-0.0.246-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 1.0 MB
Tags CPython 3.12 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
eea312fd6b578da80c6e398877dea6e3d0d8318eb3c5def0a8c67b2dbfac0e03
BLAKE2b-256 checksum
How to use checksums
99773f2f3fdbdf82becb7d3a4a5f3e7c5098571eedcceea83135375eee460827
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp312-cp312-macosx_10_15_universal2.whl

Download URL orso-0.0.246-cp312-cp312-macosx_10_15_universal2.whl
Size 339.8 kB
Tags CPython 3.12 macOS 10.15+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
7ce9409023a5a2197cd99eb74ad4a9461de0edb61a0eec12084db1ee25ee688e
BLAKE2b-256 checksum
How to use checksums
7c45f261450b785845188dc962ad249fd7b6a49dc731a0116261bd84f74933c3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp311-cp311-win_amd64.whl

Download URL orso-0.0.246-cp311-cp311-win_amd64.whl
Size 196.2 kB
Tags CPython 3.11 Windows x86-64
SHA-256 checksum
How to use checksums
717d52fd6fa8dea5ccfd2aa9725ae3b15aa0a703618042e6e317a83e75b55894
BLAKE2b-256 checksum
How to use checksums
3f523a1e0945523d5e47f12865b599619aec111b811dd5de7e6c8fe331848327
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL orso-0.0.246-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 960.8 kB
Tags CPython 3.11 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
ef776655db523391a576f9d6ac9f404b8e27b946968edcbc7c0cb695d808e7e8
BLAKE2b-256 checksum
How to use checksums
0cbaf4c6a99733dfb60401bd6e76cf59110a77cae286659e4bbe422d149b9cb3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp311-cp311-macosx_10_15_universal2.whl

Download URL orso-0.0.246-cp311-cp311-macosx_10_15_universal2.whl
Size 344.3 kB
Tags CPython 3.11 macOS 10.15+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
b7f02c299615c8f97de2dc7f527c078a2af050db95ab8e49f94cac3175e00648
BLAKE2b-256 checksum
How to use checksums
388dfc436c3dc08ec421c489d4b5f30296d0b7fb1130c75b01b1048ac1aa99f4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp310-cp310-win_amd64.whl

Download URL orso-0.0.246-cp310-cp310-win_amd64.whl
Size 196.6 kB
Tags CPython 3.10 Windows x86-64
SHA-256 checksum
How to use checksums
cec06e55cc36bb700f01a76e206d6b95973a206deed5570d78099b0b7a0075e4
BLAKE2b-256 checksum
How to use checksums
abe822f2ac2b9065009bfbe5ec1d17733e667b555ce8dba6c3a7f347e0c34d0c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl

Download URL orso-0.0.246-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.manylinux_2_28_x86_64.whl
Size 917.5 kB
Tags CPython 3.10 Linux glibc 2.17+ x86-64 Linux glibc 2.28+ x86-64
SHA-256 checksum
How to use checksums
f91e7728e7dc375a96810274422c1cb561793dc4eddf72ed251f53920713e3c0
BLAKE2b-256 checksum
How to use checksums
acc4d460264bc36a569587d23e981178a84e5f4c5953d48f73d50130aea39693
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / orso-0.0.246-cp310-cp310-macosx_10_15_universal2.whl

Download URL orso-0.0.246-cp310-cp310-macosx_10_15_universal2.whl
Size 347.9 kB
Tags CPython 3.10 macOS 10.15+ universal2 (ARM64, x86-64)
SHA-256 checksum
How to use checksums
d713250028f47a6583b0a64abea5919bb6f401770a1f736f89de3eec639152c7
BLAKE2b-256 checksum
How to use checksums
7b98d8b44742f9393a8963896fde4c5b914142cdcb3c7ec727b0a730b13758d5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release history Release notifications | RSS feed

This release

0.0.246 This release

16 release files

0.0.16

2 release files

0.0.15

2 release files

0.0.14

2 release files

0.0.12

2 release files

0.0.11

2 release files

0.0.10

2 release files

0.0.9

2 release files

0.0.8

2 release files

0.0.7

2 release files

0.0.6

2 release files

0.0.5

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

2 release files

0.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page