https://github.com/flango-dev/django-polars
High performance dataframes with Django ORM integration.
https://github.com/flango-dev/django-polars
ddd django domain-driven-design python repository-pattern rust
Last synced: about 1 year ago
JSON representation
High performance dataframes with Django ORM integration.
- Host: GitHub
- URL: https://github.com/flango-dev/django-polars
- Owner: flango-dev
- License: mit
- Created: 2024-06-14T14:25:09.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-06-27T18:52:14.000Z (almost 2 years ago)
- Last Synced: 2024-11-18T16:06:04.289Z (over 1 year ago)
- Topics: ddd, django, domain-driven-design, python, repository-pattern, rust
- Language: Python
- Homepage:
- Size: 12.7 KB
- Stars: 4
- Watchers: 2
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
README
# django-polars
Like [django-pandas](https://github.com/chrisdev/django-pandas/) but [way faster](https://pola.rs/posts/benchmarks/), with support for [parallel DataFrame processing](https://docs.pola.rs/user-guide/migration/pandas/#polars-has-more-support-for-parallel-operations-than-pandas) and [larger-than-memory DataFrame processing](https://docs.pola.rs/user-guide/lazy/execution/#execution-on-larger-than-memory-data).
Uses [polars](https://github.com/pola-rs/polars) under the hood.
## Usage
Head over to test code in `tests/test_*`.
Conceptually `polars` differs from `pandas`.
E.g. [`polars` does not have a multi-index/index](https://docs.pola.rs/user-guide/migration/pandas/#polars-does-not-have-a-multi-indexindex)
and a different behavior w.r.t. [missing data](https://docs.pola.rs/user-guide/migration/pandas/#missing-data).
As a consequence `django-polars` will not be API-compatible with `django-pandas`.
Refer to the [migration from `pandas` user guide](https://docs.pola.rs/user-guide/migration/pandas/) for more information.
## Limitations
- Reading a `DataFrame` via `django_polars.io.read_frame(...)` with an [asynchronous connection is unstable ATM](https://docs.pola.rs/api/python/stable/reference/api/polars.read_database.html#polars-read-database).
## Contribution
We appreciate [contributions](https://github.com/flango-dev/django-polars/blob/main/CONTRIBUTING.md).