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 2020/01/22 23:14:41 UTC

[GitHub] [incubator-mxnet] access2rohit opened a new issue #17411: topk() takes more memory

access2rohit opened a new issue #17411: topk() takes more memory
URL: https://github.com/apache/incubator-mxnet/issues/17411
 
 
   ## Description
   topk() takes more memory than the supplied input.
   
   ### Error Message
   ```
   Memory Error
   ```
   ## To Reproduce
   
   ```
           b = create_2d_tensor(rows=LARGE_X, columns=SMALL_Y)
           k = nd.topk(b, k=10, axis=0, dtype=np.int64)
           assert np.sum(k.asnumpy() == (LARGE_X - 1)) == SMALL_Y
           ind, val = mx.nd.topk(b, k=3, axis=0, dtype=np.int64, ret_typ="both",
                                 is_ascend=False)
   ```
   ### Steps to reproduce
   Run the above script on MXNet built from master
   
   ## Environment
   
   We recommend using our script for collecting the diagnositc information. Run the following command and paste the outputs below:
   ```
   curl --retry 10 -s https://raw.githubusercontent.com/dmlc/gluon-nlp/master/tools/diagnose.py | python
   
   # paste outputs here
   
   ----------Python Info----------
   Version      : 3.6.4
   Compiler     : GCC 7.2.0
   Build        : ('default', 'Jan 16 2018 18:10:19')
   Arch         : ('64bit', '')
   ------------Pip Info-----------
   Version      : 18.0
   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.6.0
   Directory    : /home/ubuntu/incubator-mxnet/python/mxnet
   Num GPUs     : 0
   Hashtag not found. Not installed from pre-built package.
   ----------System Info----------
   Platform     : Linux-4.4.0-1098-aws-x86_64-with-debian-stretch-sid
   system       : Linux
   node         : ip-172-31-82-110
   release      : 4.4.0-1098-aws
   version      : #109-Ubuntu SMP Fri Nov 8 09:30:18 UTC 2019
   ----------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:               2699.984
   CPU max MHz:           3000.0000
   CPU min MHz:           1200.0000
   BogoMIPS:              4600.06
   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 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.0022 sec, LOAD: 0.5111 sec.
   Timing for GluonNLP GitHub: https://github.com/dmlc/gluon-nlp, DNS: 0.0007 sec, LOAD: 0.3350 sec.
   Timing for GluonNLP: http://gluon-nlp.mxnet.io, DNS: 0.0973 sec, LOAD: 0.2595 sec.
   Timing for D2L: http://d2l.ai, DNS: 0.0936 sec, LOAD: 0.0044 sec.
   Timing for D2L (zh-cn): http://zh.d2l.ai, DNS: 0.0249 sec, LOAD: 0.1220 sec.
   Timing for FashionMNIST: https://repo.mxnet.io/gluon/dataset/fashion-mnist/train-labels-idx1-ubyte.gz, DNS: 0.1407 sec, LOAD: 0.3436 sec.
   Timing for PYPI: https://pypi.python.org/pypi/pip, DNS: 0.0027 sec, LOAD: 0.0983 sec.
   Timing for Conda: https://repo.continuum.io/pkgs/free/, DNS: 0.0037 sec, LOAD: 0.0303 sec.
   ```
   

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to 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