[ 
https://issues.apache.org/jira/browse/SPARK-3903?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15960531#comment-15960531
 ] 

Nick Pentreath commented on SPARK-3903:
---------------------------------------

I think given the move to DataFrames, and that we can load {{libsvm}} in DF, 
this can be closed?

> Create general data loading method for LabeledPoints
> ----------------------------------------------------
>
>                 Key: SPARK-3903
>                 URL: https://issues.apache.org/jira/browse/SPARK-3903
>             Project: Spark
>          Issue Type: Improvement
>          Components: ML
>    Affects Versions: 1.3.0
>            Reporter: Joseph K. Bradley
>            Priority: Minor
>
> Proposal: Provide a more general data loading function for LabeledPoints.
> * load multiple data files (e.g., train + test), and ensure they have the 
> same number of features (determined based on a scan of the data)
> * use same function for multiple input formats
> Proposed function format (in MLUtils), with default parameters:
> {code}
> def loadLabeledPointsFiles(
>     sc: SparkContext,
>     paths: Seq[String],
>     numFeatures = -1,
>     vectorFormat = "auto",
>     numPartitions = sc.defaultMinPartitions): Seq[RDD[LabeledPoint]]
> {code}
> About the parameters:
> * paths: list of paths to data files or folders with data files
> * vectorFormat options: dense/sparse/auto
> * numFeatures, numPartitions: same behavior as loadLibSVMFile
> Return value: Order of RDDs follows the order of the paths.
> Note: This is named differently from loadLabeledPoints for 2 reasons:
> * different argument order (following loadLibSVMFile)
> * different return type



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to