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/06/27 20:19:55 UTC
[GitHub] liyujiel opened a new issue #11427: LSTM model parallel example can
not run
liyujiel opened a new issue #11427: LSTM model parallel example can not run
URL: https://github.com/apache/incubator-mxnet/issues/11427
For Q & A and discussion, please start a discussion thread at https://discuss.mxnet.io
## Description
lstm_ptb.py example under model-parallel can not be stop
Since perp number becomes large and makes overflow (?)
## Environment info (Required)
```
----------Python Info----------
Version : 3.6.4
Compiler : GCC 7.2.0
Build : ('default', 'Jan 16 2018 18:10:19')
Arch : ('64bit', '')
------------Pip Info-----------
Version : 9.0.1
Directory : /home/ubuntu/anaconda3/lib/python3.6/site-packages/pip
----------MXNet Info-----------
/home/ubuntu/anaconda3/lib/python3.6/site-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype from `float` to `np.floating` is deprecated. In future, it will be treated as `np.float64 == np.dtype(float).type`.
from ._conv import register_converters as _register_converters
Version : 1.3.0
Directory : /home/ubuntu/anaconda3/lib/python3.6/site-packages/mxnet
Commit Hash : 5550c0afe4b202c573a1cc0e2387447c8a888769
----------System Info----------
Platform : Linux-4.4.0-1061-aws-x86_64-with-debian-stretch-sid
system : Linux
node : ip-172-31-25-194
release : 4.4.0-1061-aws
version : #70-Ubuntu SMP Fri May 25 21:47:34 UTC 2018
----------Hardware Info----------
machine : x86_64
processor : x86_64
Architecture: x86_64
CPU op-mode(s): 32-bit, 64-bit
Byte Order: Little Endian
CPU(s): 32
On-line CPU(s) list: 0-31
Thread(s) per core: 2
Core(s) per socket: 16
Socket(s): 1
NUMA node(s): 1
Vendor ID: GenuineIntel
CPU family: 6
Model: 79
Model name: Intel(R) Xeon(R) CPU E5-2686 v4 @ 2.30GHz
Stepping: 1
CPU MHz: 2638.710
CPU max MHz: 3000.0000
CPU min MHz: 1200.0000
BogoMIPS: 4600.08
Hypervisor vendor: Xen
Virtualization type: full
L1d cache: 32K
L1i cache: 32K
L2 cache: 256K
L3 cache: 46080K
NUMA node0 CPU(s): 0-31
Flags: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ht syscall nx pdpe1gb rdtscp lm constant_tsc rep_good nopl xtopology nonstop_tsc aperfmperf eagerfpu pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm abm 3dnowprefetch invpcid_single kaiser fsgsbase bmi1 hle avx2 smep bmi2 erms invpcid rtm rdseed adx xsaveopt
----------Network Test----------
Setting timeout: 10
Timing for MXNet: https://github.com/apache/incubator-mxnet, DNS: 0.0020 sec, LOAD: 0.3481 sec.
Timing for Gluon Tutorial(en): http://gluon.mxnet.io, DNS: 0.1498 sec, LOAD: 0.4179 sec.
Timing for Gluon Tutorial(cn): https://zh.gluon.ai, DNS: 0.2098 sec, LOAD: 0.3887 sec.
Timing for FashionMNIST: https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/gluon/dataset/fashion-mnist/train-labels-idx1-ubyte.gz, DNS: 0.0034 sec, LOAD: 0.1856 sec.
Timing for PYPI: https://pypi.python.org/pypi/pip, DNS: 0.0026 sec, LOAD: 0.0966 sec.
Timing for Conda: https://repo.continuum.io/pkgs/free/, DNS: 0.0029 sec, LOAD: 0.0287 sec.
```
Package used (Python/R/Scala/Julia):
Python 3.6
## Build info (Required if built from source)
Compiler (gcc/clang/mingw/visual studio):
MXNet commit hash:
ced119b4ff1564c00393b178e2e220a62fccabd3
Build config:
(Paste the content of config.mk, or the build command.)
## Error Message:
/home/ubuntu/incubator-mxnet/example/model-parallel/lstm/lstm.py:384: RuntimeWarning: overflow encountered in exp
epoch_counter, toc - tic, train_nll / nbatch, np.exp(train_nll / nbatch)))
Iter [28] Train: Time: 13.611 sec, NLL=4611973.869, Perp=inf
Iter [56] Train: Time: 24.805 sec, NLL=5223608.518, Perp=inf
Iter [84] Train: Time: 35.852 sec, NLL=5176472.672, Perp=inf
Iter [112] Train: Time: 46.921 sec, NLL=5076527.570, Perp=inf
Iter [140] Train: Time: 58.017 sec, NLL=5165189.315, Perp=inf
....
## Minimum reproducible example
(If you are using your own code, please provide a short script that reproduces the error. Otherwise, please provide link to the existing example.)
## Steps to reproduce
(Paste the commands you ran that produced the error.)
1.
2.
## What have you tried to solve it?
1. line 205 in bucket_io.py file for TypeError:
bucket_n_batches.append(int(len(self.data[i]) / self.batch_size))
2. try reposition following reset command in lstm.py line 430:
X_val_batch.reset()
X_train_batch.reset()
3. add if condition in lstm.py line 426:
if last_perp - 1.0 < perp and not math.isinf(perp):
----------------------------------------------------------------
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