You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mxnet.apache.org by gi...@git.apache.org on 2017/08/02 17:52:20 UTC

[GitHub] piiswrong commented on a change in pull request #7093: add variational dropout to gluon ptb example

piiswrong commented on a change in pull request #7093: add variational dropout to gluon ptb example
URL: https://github.com/apache/incubator-mxnet/pull/7093#discussion_r130948380
 
 

 ##########
 File path: example/gluon/word_language_model/train.py
 ##########
 @@ -70,8 +87,19 @@ def batchify(data, batch_size):
 
 
 ntokens = len(corpus.dictionary)
-model = model.RNNModel(args.model, ntokens, args.emsize, args.nhid,
-                       args.nlayers, args.dropout, args.tied)
+assert (not args.vardrop_out and not args.vardrop_state) or args.use_cell, \
+       'variational dropout is only available in cell API.'
+if not args.use_cell:
 
 Review comment:
   This looks too complicated for an example. not sure if we should add more comment or split it into to examples
 
----------------------------------------------------------------
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