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/09/08 04:15:33 UTC

[GitHub] jeremiedb edited a comment on issue #12428: [R] mx.io.CSVIter not loading labels in version 1.3.0

jeremiedb edited a comment on issue #12428: [R] mx.io.CSVIter not loading labels in version 1.3.0
URL: https://github.com/apache/incubator-mxnet/issues/12428#issuecomment-419610774
 
 
   Interesting! Really looks like a bug when the last label axis is set to 1. 
   As a quick turnaround, what about dropping the 1 axis for all data and label in the csv.iter and perform a reshape within the model architecture?
   
   Something like:
   
   ```
   iter <- mx.io.CSVIter(data_csv = "data.csv",
                         data_shape = c(3,3),
                         label_csv = "label.csv",
                         label_shape = c(3,3),
                         batch.size = 2)
   
   data <- mx.symbol.Variable("data")
   data <- mx.symbol.reshape(data, shape = c(3,1,3,0))
   
   label <- mx.symbol.Variable("label")
   label <- mx.symbol.reshape(label, shape = c(3,3,1,0))
   ...
   loss <- mx.symbol.LinearRegressionOutput(data = model, label = label)
   ```

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