The power of duckdb with the ease of pandas
Project description
Lazy Pandas
Lazy Pandas is a Python library that simplifies the use duckdb wrapping the pandas API. This library is not a pandas replacement, but a way to use the pandas API with DuckDB. Pandas is awesome and adopted by many people, but it is not the best tool for datasets that do not fit in memory. So why not give the power of duckdb to pandas users?
Installation
To install Lazy Pandas, you can use pip:
pip install lazy-pandas
Usage
Here is a basic example of how to use Lazy Pandas:
import lazy_pandas as lp
df = lp.read_csv(location, parse_dates=["pickup_datetime"])
df = df[["pickup_datetime", "passenger_count"]]
df["pickup_date"] = df["pickup_datetime"].dt.date
df = df.sort_values("pickup_date")
df = df.collect() # Materialize the lazy DataFrame to a pandas DataFrame
Features
- Lazy evaluation
- SQL support
- Support for DuckDB extensions (e.g., Delta, Iceberg, etc.)
Contribution
Contributions are welcome! Feel free to open issues and pull requests.
License
This project is licensed under the MIT License - see the LICENSE file for details.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file lazy_pandas-0.1.0.tar.gz.
File metadata
- Download URL: lazy_pandas-0.1.0.tar.gz
- Upload date:
- Size: 316.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6b3bffb92946f794b11c3b6dbf2e829592bb7f6ef0d955dd13a771073c99e167
|
|
| MD5 |
b9d0a52b34074bf9e27078686671469d
|
|
| BLAKE2b-256 |
fd604fb2da6f9ca9611fb8b456c56507227a71799c8be3b83ded79f04eaf714e
|
Provenance
The following attestation bundles were made for lazy_pandas-0.1.0.tar.gz:
Publisher:
pipeline.yaml on mariotaddeucci/lazy-pandas
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
lazy_pandas-0.1.0.tar.gz -
Subject digest:
6b3bffb92946f794b11c3b6dbf2e829592bb7f6ef0d955dd13a771073c99e167 - Sigstore transparency entry: 163734085
- Sigstore integration time:
-
Permalink:
mariotaddeucci/lazy-pandas@d33997de6161d5d57d281de9a460765ffd1612ed -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/mariotaddeucci
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pipeline.yaml@d33997de6161d5d57d281de9a460765ffd1612ed -
Trigger Event:
push
-
Statement type:
File details
Details for the file lazy_pandas-0.1.0-py3-none-any.whl.
File metadata
- Download URL: lazy_pandas-0.1.0-py3-none-any.whl
- Upload date:
- Size: 18.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.0.1 CPython/3.12.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
83499936537d49fd3acd6ee44fb5a8646c5db017a4fbe8b777814424b30b06ab
|
|
| MD5 |
7a8b474ccb3684a03203c6cc31b38e45
|
|
| BLAKE2b-256 |
49bef4f578d4bdf3ee312e46e0f2632cea5b19c001b40cffa9d12d412e572bc2
|
Provenance
The following attestation bundles were made for lazy_pandas-0.1.0-py3-none-any.whl:
Publisher:
pipeline.yaml on mariotaddeucci/lazy-pandas
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
lazy_pandas-0.1.0-py3-none-any.whl -
Subject digest:
83499936537d49fd3acd6ee44fb5a8646c5db017a4fbe8b777814424b30b06ab - Sigstore transparency entry: 163734089
- Sigstore integration time:
-
Permalink:
mariotaddeucci/lazy-pandas@d33997de6161d5d57d281de9a460765ffd1612ed -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/mariotaddeucci
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
pipeline.yaml@d33997de6161d5d57d281de9a460765ffd1612ed -
Trigger Event:
push
-
Statement type: