GitHub user jkbradley opened a pull request:

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

    [SPARK-14862][ML] Updated Classifiers to not require labelCol metadata

    ## What changes were proposed in this pull request?
    
    Updated Classifier, DecisionTreeClassifier, RandomForestClassifier, 
GBTClassifier to not require input column metadata.
    * They first check for metadata.
    * If numClasses is not specified in metadata, they identify the largest 
label value (up to a limit).
    
    This functionality is implemented in a new Classifier.getNumClasses method.
    
    Also
    * Updated Classifier.extractLabeledPoints to (a) check label values and (b) 
include a second version which takes a numClasses value for validity checking.
    
    ## How was this patch tested?
    
    * Unit tests in ClassifierSuite for helper methods
    * Unit tests for DecisionTreeClassifier, RandomForestClassifier, 
GBTClassifier with toy datasets lacking label metadata

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

    $ git pull https://github.com/jkbradley/spark trees-no-metadata

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

    https://github.com/apache/spark/pull/12663.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 #12663
    
----
commit 082a5af29c28ab53922a43e572f38acc9fab40b4
Author: Joseph K. Bradley <[email protected]>
Date:   2016-04-25T17:34:10Z

    Updated Classifier, DecisionTreeClassifier, RandomForestClassifier, 
GBTClassifier to not require input column metadata

commit 94e206f0e98f0a2d398de71f808008a9acb711f1
Author: Joseph K. Bradley <[email protected]>
Date:   2016-04-25T17:42:01Z

    added tests for GBT, RF.  cleanups

----


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