Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,54 @@ version of bigframes (https://github.com/googleapis/python-bigquery-dataframes)
and is intended to be a minimal wrapper on top of Ibis without any of the pandas
features that make bigframes more complex.

## Installation

LeanFrame is available on [PyPI](https://pypi.org/project/leanframe/).

```
pip install leanframe
```

Also, install the dependencies for an Ibis backend, such as

```
pip install 'ibis-framework[bigquery]'
```

## Usage

To start using LeanFrame, first create a Session from an Ibis backend, such as
[DuckDB (local)](https://ibis-project.org/backends/duckdb) or [BigQuery (Google
Cloud)](https://ibis-project.org/backends/bigquery).

```python
import ibis
import leanframe

connection = ibis.bigquery.connect(
project_id="your-project-id",
)
session = leanframe.Session(connection)
```

Create a DataFrame from a table.

```python
df = session.read_sql_table("bigquery-public-data.usa_names.usa_1910_2013")
```

Perform pandas operations.

```
TODO
```

Get your results as a pandas DataFrame.

```python
pddf = df.to_pandas()
```

## Disclaimer

This is a personal project. Does not reflect my employer.
2 changes: 1 addition & 1 deletion leanframe/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.

__version__ = "0.0.1"
__version__ = "0.2.0"
6 changes: 4 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,23 +1,25 @@
[project]
name = "leanframe"
version = "0.1.0"
version = "0.2.0"
description = "LeanFrame is a pandas-like API built on top of Ibis."
readme = "README.md"
requires-python = ">=3.11"
dependencies = [
"pandas >=2.2.0",
"pyarrow >=15.0.2",
"ibis-framework>=11.0.0,<12.0.0",
"pyopenssl>=26.1.0",
]

[dependency-groups]
dev = [
"ibis-framework[duckdb]>=10.6.0",
"ibis-framework[bigquery,duckdb]>=10.6.0",
"ipython>=8.37.0",
"mypy>=1.17.1",
"pandas-stubs>=2.3.0.250703",
"pytest>=8.4.1",
"ruff>=0.12.4",
"twine>=6.2.0",
]

[build-system]
Expand Down
Loading
Loading