You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "ueshin (via GitHub)" <gi...@apache.org> on 2024/07/10 20:50:31 UTC
[PR] [SPARK-48459][CONNECT][PYTHON][FOLLOWUP] Ignore to_plan from with_origin [spark]
ueshin opened a new pull request, #47284:
URL: https://github.com/apache/spark/pull/47284
### What changes were proposed in this pull request?
Ignores `connect.Column.to_plan` from `with_origin`.
### Why are the changes needed?
Capturing call site on `connect.Column.to_plan` takes long time when creating proto plans if there are many `connect.Column` objects, although the call sites on `connect.Column.to_plan` are not necessary.
E.g.,
```py
from pyspark.sql import functions as F
df = createDataFrame()
def schema():
return df.select(*([F.col("a"), F.col("b"), F.col("c"), F.col("d")] * 10)).schema
benchmark(schema)
```
<img width="1109" alt="Screenshot 2024-07-10 at 13 40 33" src="https://github.com/apache/spark/assets/506656/776978ce-bef9-47ef-b4a5-0d206683736d">
The total function calls / duration for this is:
- before
```
28393570 function calls (28381720 primitive calls) in 3.450 seconds
```
- after
```
109970 function calls (98120 primitive calls) in 0.184 seconds
```
### Does this PR introduce _any_ user-facing change?
No.
### How was this patch tested?
The existing tests.
### Was this patch authored or co-authored using generative AI tooling?
No.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
Re: [PR] [SPARK-48459][CONNECT][PYTHON][FOLLOWUP] Ignore to_plan from with_origin [spark]
Posted by "HyukjinKwon (via GitHub)" <gi...@apache.org>.
HyukjinKwon closed pull request #47284: [SPARK-48459][CONNECT][PYTHON][FOLLOWUP] Ignore to_plan from with_origin
URL: https://github.com/apache/spark/pull/47284
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
Re: [PR] [SPARK-48459][CONNECT][PYTHON][FOLLOWUP] Ignore to_plan from with_origin [spark]
Posted by "HyukjinKwon (via GitHub)" <gi...@apache.org>.
HyukjinKwon commented on PR #47284:
URL: https://github.com/apache/spark/pull/47284#issuecomment-2221815121
Merged to master.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org