Github user koertkuipers commented on the issue:

    https://github.com/apache/spark/pull/13526
  
    if they chain like that then i think i know how to do the optimization.
    
    but do they? look for example at dataset.groupByKey(...).mapValues(...)
    
    Dataset[T].groupByKey[K] uses function T => K and creates
    KeyValueGroupedDataset[K, T]
    
    KeyValueGroupedDataset[K, T].mapValues[W] uses function T => W and creates
    KeyValueGroupedDataset[K, W]
    
    so i have T => K and then T => W
    
    
    On Thu, Oct 20, 2016 at 8:26 PM, Wenchen Fan <[email protected]>
    wrote:
    
    > 2 chained AppendColumns will have 2 functions: T => U and U => W, so we
    > can combine them this way:
    > convert UnsafeRow to T
    > apply func to T to generate U
    > apply func to U to generate W
    > convert W to UnsafeRow
    > append the new UnsafeRow to the original one
    >
    > —
    > You are receiving this because you were mentioned.
    > Reply to this email directly, view it on GitHub
    > <https://github.com/apache/spark/pull/13526#issuecomment-255263458>, or 
mute
    > the thread
    > 
<https://github.com/notifications/unsubscribe-auth/AAyIJL19KTgysYd5dRAsDtIseY0jwlm3ks5q2AbLgaJpZM4IvEGP>
    > .
    >



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

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

Reply via email to