Uh oh!
There was an error while loading. Please reload this page.
[POC][DONOTMERGE] Explore transpilation yet again spark 14083 but this time with some python too - #53547
Closed
holdenk wants to merge 25 commits into
Conversation
…o transpilation and what not. Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
… resolution checker sad. We could do it "earlier" but I'm also thinking maybe doing this Scala side is not "the way" but it feels "close" so I want to get it working for at least a binary operator and then we can experiment with doing it Python side next. Counter intuitively I think the typing Python side might actually be better here (although tbf depends on if lib/ast.py is typed which I have not checked but I suspect it is). Co-authored-by: Holden Karau <holden@pigscanfly.ca>
…trings (oops) Co-authored-by: Holden Karau <holden@pigscanfly.ca>
… upgrade our types for us maybe? Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
… is not an expr which is what we want but we should add some tests for non convertible UDF-> convertible UDF -> non convertible UDF. Co-authored-by: Holden Karau <holden@pigscanfly.ca>
…cala (my bad) Co-authored-by: Holden Karau <holden@pigscanfly.ca>
…tion of the trait so we can call it in the UDF Expression swap. Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
…3-but-this-time-with-some-python-too Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
… for Python to provide the catalyst expr too. Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
…ythonFunction. Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
Co-authored-by: Holden Karau <holden@pigscanfly.ca>
holdenkforce-pushed
the
explore-transpilation-yet-again-SPARK-14083-but-this-time-with-some-python-too
branch
from
December 19, 2025 20:33
54d3915 to
facade3Comparedongjoon-hyun
marked this pull request as draft
February 25, 2026 23:10
asf-gitbox-commits pushed a commit
that referenced
this pull request
Aug 3, 2026
…ation with python ### What changes were proposed in this pull request? This is the first PR adding initial transpilation from Python to Catalyst and the framework for others to plug in different transpilers which can target other targets. This replaces #53547 and is the first PR as part of the transpilation SPIP https://docs.google.com/document/d/1cHc6tiR4yO3hppTzrK1F1w9RwyEPMvaeEuL2ub2LURg/edit?tab=t.0#heading=h.iz92aps6qbo5 ### Why are the changes needed? Python UDF performance has been a perinial challenge in Spark, and while PyArrow makes the data copy slightly less expensive it's still much slower than native code. Additionally, Python UDF usage has increased substantailly with Pandas on Spark and it is especially hard for folks to write catalyst expressions here. ### Does this PR introduce _any_ user-facing change? New configuration flags are user visible (default to off). ### How was this patch tested? New unit tests that trigger always and hypothesis tests that trigger only selectively. ### Was this patch authored or co-authored using generative AI tooling? Hypothesis teests were generated by Claude 4.7, eq semantics null and truthiness w/claude 4.6, GH code review (unknown backing model) on itiial draft). snake camel swap with sonnet. Closes#56327 from holdenk/r3-SPARK-55206-transpilation-minimal-functional-impl-python. Lead-authored-by: Holden Karau <holden@pigscanfly.ca> Co-authored-by: Holden Karau <holden.karau@snowflake.com> Signed-off-by: Holden Karau <holden.karau@snowflake.com>
asf-gitbox-commits pushed a commit
that referenced
this pull request
Aug 3, 2026
…ation with python ### What changes were proposed in this pull request? This is the first PR adding initial transpilation from Python to Catalyst and the framework for others to plug in different transpilers which can target other targets. This replaces #53547 and is the first PR as part of the transpilation SPIP https://docs.google.com/document/d/1cHc6tiR4yO3hppTzrK1F1w9RwyEPMvaeEuL2ub2LURg/edit?tab=t.0#heading=h.iz92aps6qbo5 ### Why are the changes needed? Python UDF performance has been a perinial challenge in Spark, and while PyArrow makes the data copy slightly less expensive it's still much slower than native code. Additionally, Python UDF usage has increased substantailly with Pandas on Spark and it is especially hard for folks to write catalyst expressions here. ### Does this PR introduce _any_ user-facing change? New configuration flags are user visible (default to off). ### How was this patch tested? New unit tests that trigger always and hypothesis tests that trigger only selectively. ### Was this patch authored or co-authored using generative AI tooling? Hypothesis teests were generated by Claude 4.7, eq semantics null and truthiness w/claude 4.6, GH code review (unknown backing model) on itiial draft). snake camel swap with sonnet. Closes#56327 from holdenk/r3-SPARK-55206-transpilation-minimal-functional-impl-python. Lead-authored-by: Holden Karau <holden@pigscanfly.ca> Co-authored-by: Holden Karau <holden.karau@snowflake.com> Signed-off-by: Holden Karau <holden.karau@snowflake.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
[POC][DONOTMERGE] Explore transpilation yet again spark 14083 but this time with some python too