You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by GitBox <gi...@apache.org> on 2018/05/24 07:32:58 UTC

[GitHub] nswamy commented on a change in pull request #11045: [MXNET-471] Add Builder class for Scala Module and DataBatch to simplify construction

nswamy commented on a change in pull request #11045: [MXNET-471] Add Builder class for Scala Module and DataBatch to simplify construction
URL: https://github.com/apache/incubator-mxnet/pull/11045#discussion_r190484990
 
 

 ##########
 File path: scala-package/core/src/main/scala/org/apache/mxnet/IO.scala
 ##########
 @@ -160,6 +161,100 @@ class DataBatch(val data: IndexedSeq[NDArray],
   def provideLabel: ListMap[String, Shape] = providedLabel
 }
 
+object DataBatch {
+  /**
+   * Builder class for DataBatch.
+   */
+  class Builder() {
+    private var data: IndexedSeq[NDArray] = null
+    private var label: IndexedSeq[NDArray] = null
+    private var index: IndexedSeq[Long] = null
+    private var pad: Int = 0
+    private var bucketKey: AnyRef = null
+    private var providedData: ListMap[String, Shape] = ListMap.empty
+    private var providedLabel: ListMap[String, Shape] = ListMap.empty
 
 Review comment:
   labelShapes

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services