Skip to content
Snippets Groups Projects
  • Davies Liu's avatar
    5743c647
    [SPARK-12981] [SQL] extract Pyhton UDF in physical plan · 5743c647
    Davies Liu authored
    ## What changes were proposed in this pull request?
    
    Currently we extract Python UDFs into a special logical plan EvaluatePython in analyzer, But EvaluatePython is not part of catalyst, many rules have no knowledge of it , which will break many things (for example, filter push down or column pruning).
    
    We should treat Python UDFs as normal expressions, until we want to evaluate in physical plan, we could extract them in end of optimizer, or physical plan.
    
    This PR extract Python UDFs in physical plan.
    
    Closes #10935
    
    ## How was this patch tested?
    
    Added regression tests.
    
    Author: Davies Liu <davies@databricks.com>
    
    Closes #12127 from davies/py_udf.
    5743c647
    History
    [SPARK-12981] [SQL] extract Pyhton UDF in physical plan
    Davies Liu authored
    ## What changes were proposed in this pull request?
    
    Currently we extract Python UDFs into a special logical plan EvaluatePython in analyzer, But EvaluatePython is not part of catalyst, many rules have no knowledge of it , which will break many things (for example, filter push down or column pruning).
    
    We should treat Python UDFs as normal expressions, until we want to evaluate in physical plan, we could extract them in end of optimizer, or physical plan.
    
    This PR extract Python UDFs in physical plan.
    
    Closes #10935
    
    ## How was this patch tested?
    
    Added regression tests.
    
    Author: Davies Liu <davies@databricks.com>
    
    Closes #12127 from davies/py_udf.
tests.py 59.08 KiB