spark-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From m...@apache.org
Subject spark git commit: [SPARK-11582][MLLIB] specifying pmml version attribute =4.2 in the root node of pmml model
Date Mon, 09 Nov 2015 16:58:50 GMT
Repository: spark
Updated Branches:
  refs/heads/master d50a66cc0 -> 9b88e1dca


[SPARK-11582][MLLIB] specifying pmml version attribute =4.2 in the root node of pmml model

The current pmml models generated do not specify the pmml version in its root node. This is
a problem when using this pmml model in other tools because they expect the version attribute
to be set explicitly. This fix adds the pmml version attribute to the generated pmml models
and specifies its value as 4.2.

Author: fazlan-nazeem <fazlann@wso2.com>

Closes #9558 from fazlan-nazeem/master.


Project: http://git-wip-us.apache.org/repos/asf/spark/repo
Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/9b88e1dc
Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/9b88e1dc
Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/9b88e1dc

Branch: refs/heads/master
Commit: 9b88e1dcad6b5b14a22cf64a1055ad9870507b5a
Parents: d50a66c
Author: fazlan-nazeem <fazlann@wso2.com>
Authored: Mon Nov 9 08:58:55 2015 -0800
Committer: Xiangrui Meng <meng@databricks.com>
Committed: Mon Nov 9 08:58:55 2015 -0800

----------------------------------------------------------------------
 .../scala/org/apache/spark/mllib/pmml/export/PMMLModelExport.scala  | 1 +
 1 file changed, 1 insertion(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/spark/blob/9b88e1dc/mllib/src/main/scala/org/apache/spark/mllib/pmml/export/PMMLModelExport.scala
----------------------------------------------------------------------
diff --git a/mllib/src/main/scala/org/apache/spark/mllib/pmml/export/PMMLModelExport.scala
b/mllib/src/main/scala/org/apache/spark/mllib/pmml/export/PMMLModelExport.scala
index c5fdecd..9267e6d 100644
--- a/mllib/src/main/scala/org/apache/spark/mllib/pmml/export/PMMLModelExport.scala
+++ b/mllib/src/main/scala/org/apache/spark/mllib/pmml/export/PMMLModelExport.scala
@@ -32,6 +32,7 @@ private[mllib] trait PMMLModelExport {
   @BeanProperty
   val pmml: PMML = new PMML
 
+  pmml.setVersion("4.2")
   setHeader(pmml)
 
   private def setHeader(pmml: PMML): Unit = {


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org


Mime
View raw message