GitHub user jbencook opened a pull request:

    https://github.com/apache/spark/pull/3764

    [SPARK-4860][pyspark][sql] speeding up `sample()` and `takeSample()`

    This PR modifies the python `SchemaRDD` to use `sample()` and 
`takeSample()` from Scala instead of the slower python implementations from 
`rdd.py`. This is worthwhile because the `Row`'s are already serialized as Java 
objects.
    
    In order to use the faster `takeSample()`, a `takeSampleToPython()` method 
was implemented in `SchemaRDD.scala` following the pattern of 
`collectToPython()`.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/jbencook/spark master

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/3764.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #3764
    
----
commit 020cbdf8814d25121a909b634f908dc8c41bd739
Author: jbencook <[email protected]>
Date:   2014-12-22T16:40:49Z

    [SPARK-4860][pyspark][sql] using Scala implementations of `sample()` and 
`takeSample()`

----


---
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