Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add LinearRegression.predict_explain() to generate ML.EXPLAIN_PREDICT columns #1190

Merged
merged 20 commits into from
Dec 16, 2024

Conversation

arwas11
Copy link
Contributor

@arwas11 arwas11 commented Dec 5, 2024

Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:

  • Make sure to open an issue as a bug/issue before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
  • Ensure the tests and linter pass
  • Code coverage does not decrease (if any source code was changed)
  • Appropriate docs were updated (if necessary)
    • predict_Explain: screen/BmpXWdueDEz9K9P

Fixes #379743762 🦕

@arwas11 arwas11 requested review from tswast and GarrettWu December 5, 2024 17:56
@product-auto-label product-auto-label bot added size: m Pull request size is medium. api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. labels Dec 5, 2024
@arwas11 arwas11 force-pushed the b377366612-ml-explain-predict branch from 289a978 to e58a0e7 Compare December 5, 2024 20:21
@product-auto-label product-auto-label bot added size: s Pull request size is small. and removed size: m Pull request size is medium. labels Dec 5, 2024
@arwas11 arwas11 requested a review from tswast December 10, 2024 16:42
@arwas11 arwas11 changed the title feat: add LinearRegression.predict_explain to generate predict explain columns feat: add LinearRegression.predict_explain to generate ML.EXPLAIN_PREDICT columns Dec 10, 2024
@arwas11 arwas11 marked this pull request as ready for review December 10, 2024 20:44
@arwas11 arwas11 requested review from a team as code owners December 10, 2024 20:44
@arwas11 arwas11 requested a review from GarrettWu December 10, 2024 20:44
@arwas11 arwas11 changed the title feat: add LinearRegression.predict_explain to generate ML.EXPLAIN_PREDICT columns feat: add LinearRegression.predict_explain() to generate ML.EXPLAIN_PREDICT columns Dec 10, 2024
tests/system/small/ml/test_linear_model.py Show resolved Hide resolved
bigframes/ml/sql.py Show resolved Hide resolved
bigframes/ml/linear_model.py Outdated Show resolved Hide resolved
bigframes/ml/linear_model.py Outdated Show resolved Hide resolved
tests/system/small/ml/test_linear_model.py Show resolved Hide resolved
bigframes/ml/sql.py Show resolved Hide resolved
@product-auto-label product-auto-label bot added size: m Pull request size is medium. and removed size: s Pull request size is small. labels Dec 16, 2024
@arwas11 arwas11 requested review from GarrettWu and tswast December 16, 2024 21:06
@arwas11 arwas11 changed the title feat: add LinearRegression.predict_explain() to generate ML.EXPLAIN_PREDICT columns feat: add LinearRegression.predict_explain() to generate ML.EXPLAIN_PREDICT columns Dec 16, 2024
@tswast
Copy link
Collaborator

tswast commented Dec 16, 2024

Doctest failed, but doesn't appear to be related:

FAILED third_party/bigframes_vendored/pandas/core/frame.py::frame.DataFrame.update
_______________________ [doctest] frame.DataFrame.update _______________________
[gw1] linux -- Python 3.12.0 /tmpfs/src/github/python-bigquery-dataframes/.nox/doctest/bin/python
4066 
4067             >>> import bigframes.pandas as bpd
4068             >>> bpd.options.display.progress_bar = None
4069 
4070             >>> df = bpd.DataFrame({'A': [1, 2, 3],
4071             ...                    'B': [400, 500, 600]})
4072             >>> new_df = bpd.DataFrame({'B': [4, 5, 6],
4073             ...                        'C': [7, 8, 9]})
4074             >>> df.update(new_df)
4075             >>> df
UNEXPECTED EXCEPTION: BadRequest('GET [https://bigquery.googleapis.com/bigquery/v2/projects/bigframes-testing/queries/a0e298c3-d88a-43a3-8ee8-06454d818cbe?maxResults=0&location=US&prettyPrint=false](https://www.google.com/url?q=https://bigquery.googleapis.com/bigquery/v2/projects/bigframes-testing/queries/a0e298c3-d88a-43a3-8ee8-06454d818cbe?maxResults%3D0%26location%3DUS%26prettyPrint%3Dfalse&sa=D): The job encountered an internal error during execution and was unable to complete successfully.')

@tswast tswast merged commit e13eca2 into main Dec 16, 2024
21 of 22 checks passed
@tswast tswast deleted the b377366612-ml-explain-predict branch December 16, 2024 22:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: bigquery Issues related to the googleapis/python-bigquery-dataframes API. size: m Pull request size is medium.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants