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/05 11:41:09 UTC

[GitHub] HuichuanLiu opened a new issue #11149: Unreasonable performance of resnext models provided in model_zoo, evaluated by score.py

HuichuanLiu opened a new issue #11149: Unreasonable performance of resnext models provided in model_zoo, evaluated by score.py
URL: https://github.com/apache/incubator-mxnet/issues/11149
 
 
   Note: Providing complete information in the most concise form is the best way to get help. This issue template serves as the checklist for essential information to most of the technical issues and bug reports. For non-technical issues and feature requests, feel free to present the information in what you believe is the best form.
   
   For Q & A and discussion, please start a discussion thread at https://discuss.mxnet.io 
   
   ## Description
   I used the incubator-mxnet/example/image-classification/score.py to evaluate resnext-50、resnext-101、resnext-101-64d,but none of them reached a reasonable result.
   ```
   python score.py --model imagenet1k-resnext-50 --gpus 2 --data-val /data3/liuhuichuan/Data/imagenet/imagenet1k-val.rec
   
   INFO:root:Finished with 439.479926 images per second
   INFO:root:('accuracy', 0.00011988491048593351)
   INFO:root:('top_k_accuracy_5', 0.0020580242966751917)
   ```
   ```
   python score.py --model imagenet1k-resnext-101 --gpus 2 --data-val /data3/liuhuichuan/Data/imagenet/imagenet1k-val.rec
   
   INFO:root:Finished with 270.428020 images per second
   INFO:root:('accuracy', 7.9923273657289009e-05)
   INFO:root:('top_k_accuracy_5', 0.0022778132992327367)
   
   ```
   ```
   python score.py --model imagenet1k-resnext-101-64x4d --gpus 2 --data-val /data3/liuhuichuan/Data/imagenet/imagenet1k-val.rec
   
   INFO:root:Finished with 160.059377 images per second
   INFO:root:('accuracy', 0.48345588235294118)
   INFO:root:('top_k_accuracy_5', 0.6939338235294118)
   ```
   However, the resnet-101 model works perfectly well
   ```
   python score.py --model imagenet1k-resnet-101 --gpus 2 --data-val /data3/liuhuichuan/Data/imagenet/imagenet1k-val.rec
   
   INFO:root:Finished with 383.548030 images per second
   INFO:root:('accuracy', 0.76856218030690537)
   INFO:root:('top_k_accuracy_5', 0.93300431585677746)
   ```
   It seems the ResNeXt models are not appropriately trained or something(preprocess?) does not fit the model in score.py?
   
   ## 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/liuhuichuan/anaconda3/envs/i3d_mxn/lib/python3.6/site-packages/pip
   ----------MXNet Info-----------
   Version      : 1.1.0
   Directory    : /home/liuhuichuan/anaconda3/envs/i3d_mxn/lib/python3.6/site-packages/mxnet
   Commit Hash   : 07a83a0325a3d782513a04f47d711710972cb144
   ----------System Info----------
   Platform     : Linux-4.4.0-62-generic-x86_64-with-debian-stretch-sid
   system       : Linux
   node         : jf-gpu003
   release      : 4.4.0-62-generic
   version      : #83-Ubuntu SMP Wed Jan 18 14:10:15 UTC 2017
   ----------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:    8
   Socket(s):             2
   NUMA node(s):          2
   Vendor ID:             GenuineIntel
   CPU family:            6
   Model:                 79
   Model name:            Intel(R) Xeon(R) CPU E5-2620 v4 @ 2.10GHz
   Stepping:              1
   CPU MHz:               1236.867
   CPU max MHz:           3000.0000
   CPU min MHz:           1200.0000
   BogoMIPS:              4201.09
   Virtualization:        VT-x
   L1d cache:             32K
   L1i cache:             32K
   L2 cache:              256K
   L3 cache:              20480K
   NUMA node0 CPU(s):     0-7,16-23
   NUMA node1 CPU(s):     8-15,24-31
   Flags:                 fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx pdpe1gb rdtscp lm constant_tsc arch_perfmon pebs bts rep_good nopl xtopology nonstop_tsc aperfmperf eagerfpu pni pclmulqdq dtes64 monitor ds_cpl vmx smx est tm2 ssse3 sdbg fma cx16 xtpr pdcm pcid dca sse4_1 sse4_2 x2apic movbe popcnt tsc_deadline_timer aes xsave avx f16c rdrand lahf_lm abm 3dnowprefetch epb intel_pt tpr_shadow vnmi flexpriority ept vpid fsgsbase tsc_adjust bmi1 hle avx2 smep bmi2 erms invpcid rtm cqm rdseed adx smap xsaveopt cqm_llc cqm_occup_llc cqm_mbm_total cqm_mbm_local dtherm ida arat pln pts
   ----------Network Test----------
   Setting timeout: 10
   Timing for MXNet: https://github.com/apache/incubator-mxnet, DNS: 0.0259 sec, LOAD: 1.6091 sec.
   Timing for Gluon Tutorial(en): http://gluon.mxnet.io, DNS: 0.0223 sec, LOAD: 1.3577 sec.
   Timing for Gluon Tutorial(cn): https://zh.gluon.ai, DNS: 0.0249 sec, LOAD: 2.8521 sec.
   Timing for FashionMNIST: https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/gluon/dataset/fashion-mnist/train-labels-idx1-ubyte.gz, DNS: 0.3443 sec, LOAD: 1.3495 sec.
   Timing for PYPI: https://pypi.python.org/pypi/pip, DNS: 0.0243 sec, LOAD: 5.4109 sec.
   Timing for Conda: https://repo.continuum.io/pkgs/free/, DNS: 0.0222 sec, LOAD: 0.9340 sec.
   ```
   
   Package used (Python/R/Scala/Julia):
   (I'm using ...)
   
   For Scala user, please provide:
   1. Java version: (`java -version`)
   2. Maven version: (`mvn -version`)
   3. Scala runtime if applicable: (`scala -version`)
   
   For R user, please provide R `sessionInfo()`:
   
   ## Build info (Required if built from source)
   Installed from pip of python3.6
   Compiler (gcc/clang/mingw/visual studio):
   
   MXNet commit hash:
   a48480b706763203a294cb76eb8916517ff214c1
   Build config:
   (Paste the content of config.mk, or the build command.)
   
   ## Error Message:
   (Paste the complete error message, including stack trace.)
   
   ## 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. pack val files in local directory instead of redownloading,It shouldn't be a problem because the resnet uses the same .rec and works well.
   ```
   # if [ ! -e ILSVRC2012_img_val.tar ]; then
   #     wget $1
   # fi
   # mkdir -p val
   # tar -xf ILSVRC2012_img_val.tar -C val
   wget http://data.mxnet.io/models/imagenet/resnet/val.lst -O imagenet1k-val.lst
   
   CUR_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
   MX_DIR=${CUR_DIR}/../../../
   
   python ${CUR_DIR}/../../../tools/im2rec.py --resize 256 --quality 90 --num-thread 16 imagenet1k-val my_path_to_store_imagenet_val_data/
   
   # rm -rf val
   ```
   2. run score.py in incubator-mxnet/example/image-classification
   ```
   python score.py --model imagenet1k-resnext-101-64x4d --gpus 2 --data-val /data3/liuhuichuan/Data/imagenet/imagenet1k-val.rec
   ```
   ## What have you tried to solve it?
   
   1. switch the git branch from mater to v1.2.0 but nothing changed.
   

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