I was following this tutorial http://mxnet.io/tutorials/r/fiveMinutesNeuralNetwork.html#regression Everything worked accordingly but when I changed:
fc1 <- mx.symbol.FullyConnected(data, num_hidden=1)
to
fc1 <- mx.symbol.FullyConnected(data, num_hidden=2)
And among the stacks of error logs I thought may be this is the most interesting:
Error in exec$update.arg.arrays(arg.arrays, match.name, skip.null) :
[20:22:59] src/ndarray/ndarray.cc:239: Check failed: from.shape() == to->shape()
shape mismatchfrom.shape = (20,) to.shape=(20,2)
How do I diagnose this problem?
Here is the output of sessionInfo():
R version 3.3.3 RC (2017-02-27 r72279)
Platform: x86_64-pc-linux-gnu (64-bit)
Running under: Ubuntu 14.04.5 LTS
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8 LC_PAPER=en_US.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] mlbench_2.1-1 mxnet_0.9.5
loaded via a namespace (and not attached):
[1] igraph_1.0.1 Rcpp_0.12.10 rstudioapi_0.6 magrittr_1.5 munsell_0.4.3 colorspace_1.3-2
[7] viridisLite_0.2.0 R6_2.2.0 brew_1.0-6 stringr_1.2.0 plyr_1.8.4 dplyr_0.5.0
[13] visNetwork_1.0.3 Rook_1.1-1 tools_3.3.3 grid_3.3.3 gtable_0.2.0 DBI_0.6
[19] influenceR_0.1.0 DiagrammeR_0.9.0 htmltools_0.3.5 lazyeval_0.2.0 digest_0.6.12 assertthat_0.1
[25] tibble_1.2 gridExtra_2.2.1 RColorBrewer_1.1-2 ggplot2_2.2.1 codetools_0.2-8 htmlwidgets_0.8
[31] viridis_0.4.0 rgexf_0.15.3 stringi_1.1.3 scales_0.4.1 XML_3.98-1.6 jsonlite_1.3