2010YOUY01 commented on issue #18319:
URL: https://github.com/apache/datafusion/issues/18319#issuecomment-3794189969

   > > [@sdf-jkl](https://github.com/sdf-jkl) that sounds great. IMO, preimage 
sounds misleading for something that's using interval containment to simplify a 
predicate, but maybe there will be other types of functions that can be 
reversed.
   > 
   > The preimage terminology is from ClickHouse and I believe it refers to 
https://en.wikipedia.org/wiki/Image_(mathematics)#Inverse_image .
   > 
   > If you have a better suggestion on terminology perhaps we can change it 
before we release 53.0.0
   
   I think this is terminology bloat: we’re introducing a new term to describe 
an already well-known concept, and this might cause confusions.
   
   Fundamentally, this is just expression simplification. The difference is 
that traditional expression-simplification routines aim to reduce computation 
cost, while in the “preimage” case the simplification is done to enable 
predicate pruning. Here, we can tolerate slightly slower evaluation if it makes 
pruning possible. (and this issue's simplification case both made compute fast, 
and pruning possible)
   
   Perhaps we should simply call it `simplify_expr()` or 
`simplify_expr_for_pruning()`, and mention that this is equivalent to what 
ClickHouse calls a “preimage.”


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to