bigframes

BigQuery DataFrames -- scalable analytics and machine learning with BigQuery

Apache 2.0 121 个版本 Python >=3.10
Google LLC <bigframes-feedback@google.com>
安装
pip install bigframes
poetry add bigframes
pipenv install bigframes
conda install bigframes
描述

BigQuery DataFrames (BigFrames)

|GA| |pypi| |versions|

BigQuery DataFrames (also known as BigFrames) provides a Pythonic DataFrame and machine learning (ML) API powered by the BigQuery engine. It provides modules for many use cases, including:

  • bigframes.pandas <https://dataframes.bigquery.dev/reference/api/bigframes.pandas.html>_ is a pandas API for analytics. Many workloads can be migrated from pandas to bigframes by just changing a few imports.
  • bigframes.ml <https://dataframes.bigquery.dev/reference/index.html#ml-apis>_ is a scikit-learn-like API for ML.
  • bigframes.bigquery.ai <https://dataframes.bigquery.dev/reference/api/bigframes.bigquery.ai.html>_ are a collection of powerful AI methods, powered by Gemini.

BigQuery DataFrames is an open-source package <https://github.com/googleapis/google-cloud-python>_.

.. |GA| image:: https://img.shields.io/badge/support-GA-gold.svg :target: https://github.com/googleapis/google-cloud-python/blob/main/README.rst#general-availability .. |pypi| image:: https://img.shields.io/pypi/v/bigframes.svg :target: https://pypi.org/project/bigframes/ .. |versions| image:: https://img.shields.io/pypi/pyversions/bigframes.svg :target: https://pypi.org/project/bigframes/

Getting started with BigQuery DataFrames

The easiest way to get started is to try the BigFrames quickstart <https://cloud.google.com/bigquery/docs/dataframes-quickstart>_ in a notebook in BigQuery Studio <https://cloud.google.com/bigquery/docs/notebooks-introduction>_.

To use BigFrames in your local development environment,

  1. Run pip install --upgrade bigframes to install the latest version.

  2. Setup Application default credentials <https://cloud.google.com/docs/authentication/set-up-adc-local-dev-environment>_ for your local development environment enviroment.

  3. Create a GCP project with the BigQuery API enabled <https://cloud.google.com/bigquery/docs/sandbox>_.

  4. Use the bigframes package to query data.

.. code-block:: python

import bigframes.pandas as bpd

bpd.options.bigquery.project = your_gcp_project_id  # Optional in BQ Studio.
bpd.options.bigquery.ordering_mode = "partial"  # Recommended for performance.
df = bpd.read_gbq("bigquery-public-data.usa_names.usa_1910_2013")
print(
    df.groupby("name")
    .agg({"number": "sum"})
    .sort_values("number", ascending=False)
    .head(10)
    .to_pandas()
)

Documentation

To learn more about BigQuery DataFrames, visit these pages

  • Introduction to BigQuery DataFrames (BigFrames) <https://cloud.google.com/bigquery/docs/bigquery-dataframes-introduction>_
  • Sample notebooks <https://github.com/googleapis/google-cloud-python/tree/main/notebooks>_
  • API reference <https://dataframes.bigquery.dev/>_
  • Source code (GitHub) <https://github.com/googleapis/google-cloud-python>_

License

BigQuery DataFrames is distributed with the Apache-2.0 license <https://github.com/googleapis/google-cloud-python/blob/main/LICENSE>_.

It also contains code derived from the following third-party packages:

  • Ibis <https://ibis-project.org/>_
  • pandas <https://pandas.pydata.org/>_
  • Python <https://www.python.org/>_
  • scikit-learn <https://scikit-learn.org/>_
  • XGBoost <https://xgboost.readthedocs.io/en/stable/>_
  • SQLGlot <https://sqlglot.com/sqlglot.html>_

For details, see the third_party <https://github.com/googleapis/google-cloud-python/tree/main/third_party/bigframes_vendored>_ directory.

Contact Us

For further help and provide feedback, you can email us at bigframes-feedback@google.com <https://mail.google.com/mail/?view=cm&fs=1&tf=1&to=bigframes-feedback@google.com>_.

版本列表
2.43.0 2026-06-15
2.42.0 2026-06-09
2.41.0 2026-05-28
2.40.0 2026-05-13
2.39.0 2026-04-01
2.38.0 2026-03-16
2.37.0 2026-03-04
2.36.0 2026-02-18
2.35.0 2026-02-07
2.34.0 2026-02-05
2.33.0 2026-01-23
2.32.0 2026-01-06
2.31.0 2025-12-11
2.30.0 2025-12-03
2.29.1 2025-11-18
2.29.0 2025-11-12
2.28.0 2025-11-04
2.27.0 2025-10-27
2.26.0 2025-10-20
2.25.0 2025-10-14
2.24.0 2025-10-07
2.23.0 2025-09-29
2.22.0 2025-09-25
2.21.0 2025-09-18
2.20.0 2025-09-16
2.19.0 2025-09-09
2.18.0 2025-09-03
2.17.0 2025-08-25
2.16.0 2025-08-20
2.15.0 2025-08-11
2.14.0 2025-08-06
2.13.0 2025-07-28
2.12.0 2025-07-23
2.11.0 2025-07-15
2.10.0 2025-07-10
2.9.0 2025-07-01
2.8.0 2025-06-23
2.7.0 2025-06-16
2.6.0 2025-06-10
2.5.0 2025-06-02
2.4.0 2025-05-12
2.3.0 2025-05-06
2.2.0 2025-05-01
2.1.0 2025-04-22
2.0.0 2025-04-17
2.0.0.dev0 2025-03-31
1.42.0 2025-03-27
1.41.0 2025-03-19
1.40.0 2025-03-11
1.39.0 2025-03-05
1.38.0 2025-02-24
1.37.0 2025-02-19
1.36.0 2025-02-11
1.35.0 2025-02-04
1.34.0 2025-01-28
1.33.0 2025-01-22
1.32.0 2025-01-14
1.31.0 2025-01-06
1.30.0 2025-01-02
1.29.0 2024-12-12
1.28.0 2024-12-11
1.27.0 2024-11-18
1.26.0 2024-11-12
1.25.0 2024-10-29
1.24.0 2024-10-24
1.22.0 2024-10-09
1.21.0 2024-10-02
1.20.0 2024-09-26
1.19.0 2024-09-24
1.18.0 2024-09-18
1.17.0 2024-09-11
1.16.0 2024-09-05
1.15.0 2024-08-20
1.14.0 2024-08-14
1.13.0 2024-08-05
1.12.0 2024-07-31
1.11.1 2024-07-09
1.11.0 2024-07-01
1.10.0 2024-06-25
1.9.0 2024-06-10
1.8.0 2024-06-03
1.7.0 2024-05-21
1.6.0 2024-05-14
1.5.0 2024-05-07
1.4.0 2024-04-30
1.3.0 2024-04-22
1.2.0 2024-04-16
1.1.0 2024-04-04
1.0.0 2024-03-25
0.26.0 2024-03-20
0.25.0 2024-03-14
0.24.0 2024-03-13
0.23.0 2024-03-05
0.22.0 2024-02-27
0.21.0 2024-02-13
0.20.1 2024-02-06
0.20.0 2024-01-30
0.19.2 2024-01-22
0.19.1 2024-01-17
0.19.0 2024-01-10
0.18.0 2024-01-03
0.17.0 2023-12-14
0.16.0 2023-12-12
0.15.0 2023-11-29
0.14.1 2023-11-16
0.14.0 2023-11-15
0.13.0 2023-11-07
0.12.0 2023-11-01
0.11.0 2023-10-26
0.10.0 2023-10-19
0.9.0 2023-10-18
0.8.0 2023-10-12
0.7.0 2023-10-11
0.6.0 2023-10-04
0.5.0 2023-09-28
0.4.0 2023-09-18
0.3.0 2023-09-06
0.2.0 2023-08-17
0.1.1 2023-08-14
0.1.0 2023-08-11
0.0.0 2023-02-22