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 2017/12/12 23:11:38 UTC

[GitHub] chsin opened a new issue #9044: [scala] run_gan_mnist.sh fails

chsin opened a new issue #9044: [scala] run_gan_mnist.sh fails
URL: https://github.com/apache/incubator-mxnet/issues/9044
 
 
   ## Description
   Was able to built libmxnet.so, and successfully build the Scala package, but run_gan_mnist.sh fails.
   
   ## Environment info (Required)
   I had to change diagnose.py:113 to except IOError as e: since FileNotFoundError is only on Python 3.
   ```
   ----------Python Info----------
   ('Version      :', '2.7.13')
   ('Compiler     :', 'GCC 4.4.7 20120313 (Red Hat 4.4.7-18)')
   ('Build        :', ('default', 'Aug 11 2017 20:36:55'))
   ('Arch         :', ('64bit', 'ELF'))
   ------------Pip Info-----------
   ('Version      :', '9.0.1')
   ('Directory    :', '/scratch/cahsin/pythondir27/lib/python2.7/site-packages/pip')
   ----------MXNet Info-----------
   ('Version      :', '1.0.0')
   ('Directory    :', '/scratch/cahsin/repo/mxnet/python/mxnet')
   Hashtag not found. Not installed from pre-built package.
   ----------System Info----------
   ('Platform     :', 'Linux-4.1.12-61.1.16.el6uek.x86_64-x86_64-with-redhat-6.9-Santiago')
   ('system       :', 'Linux')
   ('node         :', 'den02kge')
   ('release      :', '4.1.12-61.1.16.el6uek.x86_64')
   ('version      :', '#2 SMP Fri Oct 21 14:23:10 PDT 2016')
   ----------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):                4
   On-line CPU(s) list:   0-3
   Thread(s) per core:    1
   Core(s) per socket:    4
   Socket(s):             1
   NUMA node(s):          1
   Vendor ID:             GenuineIntel
   CPU family:            6
   Model:                 63
   Model name:            Intel(R) Xeon(R) CPU E5-2699 v3 @ 2.30GHz
   Stepping:              2
   CPU MHz:               2294.908
   BogoMIPS:              4589.81
   Hypervisor vendor:     Xen
   Virtualization type:   full
   L1d cache:             32K
   L1i cache:             32K
   L2 cache:              256K
   L3 cache:              46080K
   NUMA node0 CPU(s):     0-3
   ----------Network Test----------
   Setting timeout: 10
   Timing for MXNet: https://github.com/apache/incubator-mxnet, DNS: 0.0050 sec, LOAD: 0.8736 sec.
   Timing for PYPI: https://pypi.python.org/pypi/pip, DNS: 0.0001 sec, LOAD: 0.3412 sec.
   Timing for FashionMNIST: https://apache-mxnet.s3-accelerate.dualstack.amazonaws.com/gluon/dataset/fashion-mnist/train-labels-idx1-ubyte.gz, DNS: 0.0000 sec, LOAD: 0.8275 sec.
   Timing for Conda: https://repo.continuum.io/pkgs/free/, DNS: 0.0012 sec, LOAD: 0.2533 sec.
   Timing for Gluon Tutorial(en): http://gluon.mxnet.io, DNS: 0.1606 sec, LOAD: 0.3929 sec.
   Timing for Gluon Tutorial(cn): https://zh.gluon.ai, DNS: 0.1115 sec, LOAD: 0.3883 sec.
   ```
   
   Package used (Python/R/Scala/Julia):
   Scala
   
   For Scala user, please provide:
   1. Java version: (`java -version`)
   ```
   bash-4.1$ java -version
   java version "1.8.0_144"
   Java(TM) SE Runtime Environment (build 1.8.0_144-b01)
   Java HotSpot(TM) 64-Bit Server VM (build 25.144-b01, mixed mode)
   ```
   2. Maven version: (`mvn -version`)
   ```
   bash-4.1$ mvn -version
   Apache Maven 3.5.0 (ff8f5e7444045639af65f6095c62210b5713f426; 2017-04-03T15:39:06-04:00)
   Maven home: /scratch/cahsin/maven/apache-maven-3.5.0
   Java version: 1.8.0_144, vendor: Oracle Corporation
   Java home: /scratch/cahsin/java/jdk1.8.0_144/jre
   Default locale: en_US, platform encoding: UTF-8
   OS name: "linux", version: "4.1.12-61.1.16.el6uek.x86_64", arch: "amd64", family: "unix"
   ```
   
   ## Build info (Required if built from source)
   
   Compiler (gcc/clang/mingw/visual studio):
   ```
   bash-4.1$ gcc --version
   gcc (GCC) 4.8.2 20140120 (Red Hat 4.8.2-15)
   Copyright (C) 2013 Free Software Foundation, Inc.
   This is free software; see the source for copying conditions.  There is NO
   warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
   ```
   
   MXNet commit hash:
   2700ddbbeef212879802f7f0c0812192ec5c2b77
   
   Build config:
   ```
   #-------------------------------------------------------------------------------
   #  Template configuration for compiling mxnet
   #
   #  If you want to change the configuration, please use the following
   #  steps. Assume you are on the root directory of mxnet. First copy the this
   #  file so that any local changes will be ignored by git
   #
   #  $ cp make/config.mk .
   #
   #  Next modify the according entries, and then compile by
   #
   #  $ make
   #
   #  or build in parallel with 8 threads
   #
   #  $ make -j8
   #-------------------------------------------------------------------------------
   
   #---------------------
   # choice of compiler
   #--------------------
   
   export CC = gcc
   export CXX = g++
   export NVCC = nvcc
   
   # whether compile with options for MXNet developer
   DEV = 0
   
   # whether compile with debug
   DEBUG = 0
   
   # whether compile with profiler
   USE_PROFILER =
   
   # whether to turn on signal handler (e.g. segfault logger)
   USE_SIGNAL_HANDLER =
   
   # the additional link flags you want to add
   ADD_LDFLAGS = -lopencv_core -lopencv_imgproc -L/scratch/cahsin/local/lib/ -lopenblas
   
   # the additional compile flags you want to add
   # where openblas .h files are
   ADD_CFLAGS = -I/scratch/cahsin/local/include/ -I/scratch/cahsin/repo/OpenBLAS/
   
   #---------------------------------------------
   # matrix computation libraries for CPU/GPU
   #---------------------------------------------
   
   # whether use CUDA during compile
   USE_CUDA = 0
   
   # add the path to CUDA library to link and compile flag
   # if you have already add them to environment variable, leave it as NONE
   # USE_CUDA_PATH = /usr/local/cuda
   USE_CUDA_PATH = NONE
   
   # whether use CuDNN R3 library
   USE_CUDNN = 0
   
   #whether to use NCCL library
   USE_NCCL = 0
   #add the path to NCCL library
   USE_NCCL_PATH = NONE
   
   # whether use opencv during compilation
   # you can disable it, however, you will not able to use
   # imbin iterator
   USE_OPENCV = 1
   
   #whether use libjpeg-turbo for image decode without OpenCV wrapper
   USE_LIBJPEG_TURBO = 0
   #add the path to libjpeg-turbo library
   USE_LIBJPEG_TURBO_PATH = NONE
   
   # use openmp for parallelization
   USE_OPENMP = 1
   
   # MKL ML Library for Intel CPU/Xeon Phi
   # Please refer to MKL_README.md for details
   
   # MKL ML Library folder, need to be root for /usr/local
   # Change to User Home directory for standard user
   # For USE_BLAS!=mkl only
   MKLML_ROOT=/usr/local
   
   # whether use MKL2017 library
   USE_MKL2017 = 0
   
   # whether use MKL2017 experimental feature for high performance
   # Prerequisite USE_MKL2017=1
   USE_MKL2017_EXPERIMENTAL = 0
   
   # whether use NNPACK library
   USE_NNPACK = 0
   
   # choose the version of blas you want to use
   # can be: mkl, blas, atlas, openblas
   # in default use atlas for linux while apple for osx
   UNAME_S := $(shell uname -s)
   ifeq ($(UNAME_S), Darwin)
   USE_BLAS = apple
   else
   USE_BLAS = openblas 
   endif
   
   # whether use lapack during compilation
   # only effective when compiled with blas versions openblas/apple/atlas/mkl
   USE_LAPACK = 1
   
   # path to lapack library in case of a non-standard installation
   USE_LAPACK_PATH =
   
   # by default, disable lapack when using MKL
   # switch on when there is a full installation of MKL available (not just MKL2017/MKL_ML)
   ifeq ($(USE_BLAS), mkl)
   USE_LAPACK = 0
   endif
   
   # add path to intel library, you may need it for MKL, if you did not add the path
   # to environment variable
   USE_INTEL_PATH = NONE
   
   # If use MKL only for BLAS, choose static link automatically to allow python wrapper
   ifeq ($(USE_MKL2017), 0)
   ifeq ($(USE_BLAS), mkl)
   USE_STATIC_MKL = 1
   endif
   else
   USE_STATIC_MKL = NONE
   endif
   
   #----------------------------
   # Settings for power and arm arch
   #----------------------------
   ARCH := $(shell uname -a)
   ifneq (,$(filter $(ARCH), armv6l armv7l powerpc64le ppc64le aarch64))
   	USE_SSE=0
   else
   	USE_SSE=1
   endif
   
   #----------------------------
   # distributed computing
   #----------------------------
   
   # whether or not to enable multi-machine supporting
   USE_DIST_KVSTORE = 0
   
   # whether or not allow to read and write HDFS directly. If yes, then hadoop is
   # required
   USE_HDFS = 0
   
   # path to libjvm.so. required if USE_HDFS=1
   LIBJVM=$(JAVA_HOME)/jre/lib/amd64/server
   
   # whether or not allow to read and write AWS S3 directly. If yes, then
   # libcurl4-openssl-dev is required, it can be installed on Ubuntu by
   # sudo apt-get install -y libcurl4-openssl-dev
   USE_S3 = 0
   
   #----------------------------
   # performance settings
   #----------------------------
   # Use operator tuning
   USE_OPERATOR_TUNING = 1
   
   # Use gperftools if found
   USE_GPERFTOOLS = 1
   
   # Use JEMalloc if found, and not using gperftools
   USE_JEMALLOC = 1
   
   #----------------------------
   # additional operators
   #----------------------------
   
   # path to folders containing projects specific operators that you don't want to put in src/operators
   EXTRA_OPERATORS =
   
   #----------------------------
   # other features
   #----------------------------
   
   # Create C++ interface package
   USE_CPP_PACKAGE = 1
   
   #----------------------------
   # plugins
   #----------------------------
   
   # whether to use caffe integration. This requires installing caffe.
   # You also need to add CAFFE_PATH/build/lib to your LD_LIBRARY_PATH
   # CAFFE_PATH = $(HOME)/caffe
   # MXNET_PLUGINS += plugin/caffe/caffe.mk
   
   # whether to use torch integration. This requires installing torch.
   # You also need to add TORCH_PATH/install/lib to your LD_LIBRARY_PATH
   # TORCH_PATH = $(HOME)/torch
   # MXNET_PLUGINS += plugin/torch/torch.mk
   
   # WARPCTC_PATH = $(HOME)/warp-ctc
   # MXNET_PLUGINS += plugin/warpctc/warpctc.mk
   
   # whether to use sframe integration. This requires build sframe
   # git@github.com:dato-code/SFrame.git
   # SFRAME_PATH = $(HOME)/SFrame
   # MXNET_PLUGINS += plugin/sframe/plugin.mk
   ```
   
   ## Error Message:
   ```
   bash-4.1$ bash run_gan_mnist.sh -1 ../../data ../../tmp
   SLF4J: Class path contains multiple SLF4J bindings.
   SLF4J: Found binding in [jar:file:/scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT.jar!/org/slf4j/impl/StaticLoggerBinder.class]
   SLF4J: Found binding in [jar:file:/scratch/cahsin/repo/mxnet/scala-package/examples/target/classes/lib/slf4j-log4j12-1.7.7.jar!/org/slf4j/impl/StaticLoggerBinder.class]
   SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
   SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]
   2017-12-12 17:54:07,654 [main] [MXNetJVM] [INFO] - Try loading mxnet-scala from native path.
   2017-12-12 17:54:07,657 [main] [MXNetJVM] [INFO] - Try loading mxnet-scala-linux-x86_64-gpu from native path.
   2017-12-12 17:54:07,658 [main] [MXNetJVM] [INFO] - Try loading mxnet-scala-linux-x86_64-cpu from native path.
   2017-12-12 17:54:07,659 [main] [MXNetJVM] [WARN] - MXNet Scala native library not found in path. Copying native library from the archive. Consider installing the library somewhere in the path (for Windows: PATH, for Linux: LD_LIBRARY_PATH), or specifying by Java cmd option -Djava.library.path=[lib path].
   2017-12-12 17:54:07,697 [main] [ml.dmlc.mxnet.util.NativeLibraryLoader] [INFO] - Loading libmxnet-scala.so from /lib/native/ copying to mxnet-scala
   [17:54:10] src/io/iter_mnist.cc:113: MNISTIter: load 60000 images, shuffle=1, shape=[100,1,28,28]
   java: symbol lookup error: /tmp/mxnet1076674076824248309/mxnet-scala: undefined symbol: cblas_sgemm
   ```
   
   ## Minimum reproducible example
   https://github.com/apache/incubator-mxnet/blob/master/scala-package/examples/scripts/run_gan_mnist.sh
   
   ## Steps to reproduce
   1. make -j4
   2. make scalapkg
   ```
   bash-4.1$ make scalapkg
   Makefile:224: WARNING: Significant performance increases can be achieved by installing and enabling gperftools or jemalloc development packages
   (cd /scratch/cahsin/repo/mxnet/scala-package; \
       mvn package -Plinux-x86_64-cpu -Dcxx="g++" \
         -Dcflags="-DMSHADOW_FORCE_STREAM -Wall -Wsign-compare -O3 -DNDEBUG=1 -I/scratch/cahsin/repo/mxnet/mshadow/ -I/scratch/cahsin/repo/mxnet/dmlc-core/include -fPIC -I/scratch/cahsin/repo/mxnet/nnvm/include -I/scratch/cahsin/repo/mxnet/dlpack/include -Iinclude -funroll-loops -Wno-unused-variable -Wno-unused-parameter -Wno-unknown-pragmas -Wno-unused-local-typedefs -msse3 -DMSHADOW_USE_CUDA=0 -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 -I/scratch/cahsin/local/include/opencv -I/scratch/cahsin/local/include   -fopenmp -DMXNET_USE_OPERATOR_TUNING=1 -DMXNET_USE_LAPACK -I/scratch/cahsin/local/include/ -I/scratch/cahsin/repo/OpenBLAS/ -DMXNET_USE_NCCL=0 -DMXNET_USE_LIBJPEG_TURBO=0" -Dldflags="-pthread -lm -fopenmp -lrt -L/scratch/cahsin/local/lib -lopencv_calib3d -lopencv_contrib -lopencv_core -lopencv_features2d -lopencv_flann -lopencv_highgui -lopencv_imgproc -lopencv_legacy -lopencv_ml -lopencv_nonfree -lopencv_objdetect -lopencv_ocl -lopencv_photo -lopencv_stitching -lopencv_superres -lopencv_video -lopencv_videostab -lrt -lpthread -lm -ldl -lopencv_core -lopencv_imgproc -L/scratch/cahsin/local/lib/ -lopenblas" \
         -Dcurrent_libdir="/scratch/cahsin/repo/mxnet/lib" \
         -Dlddeps="/scratch/cahsin/repo/mxnet/dmlc-core/libdmlc.a /scratch/cahsin/repo/mxnet/nnvm/lib/libnnvm.a /scratch/cahsin/repo/mxnet/lib/libmxnet.a")
   [INFO] Scanning for projects...
   [WARNING] 
   [WARNING] Some problems were encountered while building the effective model for ml.dmlc.mxnet:mxnet-examples_2.11:jar:1.0.0-SNAPSHOT
   [WARNING] 'build.plugins.plugin.version' for net.alchim31.maven:scala-maven-plugin is missing. @ ml.dmlc.mxnet:mxnet-examples_2.11:[unknown-version], /scratch/cahsin/repo/mxnet/scala-package/examples/pom.xml, line 106, column 15
   [WARNING] 
   [WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
   [WARNING] 
   [WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
   [WARNING] 
   [INFO] ------------------------------------------------------------------------
   [INFO] Reactor Build Order:
   ...
   ...
   ...
   ...
   [INFO] --- maven-jar-plugin:3.0.2:jar (default-jar) @ mxnet-full_2.11-linux-x86_64-cpu ---
   [INFO] 
   [INFO] --- maven-source-plugin:2.2.1:jar-no-fork (attach-sources) @ mxnet-full_2.11-linux-x86_64-cpu ---
   [INFO] No sources in project. Archive not created.
   [INFO] 
   [INFO] --- maven-jar-plugin:3.0.2:jar (empty-javadoc-jar) @ mxnet-full_2.11-linux-x86_64-cpu ---
   [WARNING] JAR will be empty - no content was marked for inclusion!
   [INFO] 
   [INFO] --- maven-assembly-plugin:2.5.5:single (default) @ mxnet-full_2.11-linux-x86_64-cpu ---
   [INFO] Reading assembly descriptor: src/main/assembly/assembly.xml
   [WARNING] Artifact: ml.dmlc.mxnet:mxnet-full_2.11-linux-x86_64-cpu:jar:1.0.0-SNAPSHOT references the same file as the assembly destination file. Moving it to a temporary location for inclusion.
   [INFO] Building jar: /scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT.jar
   [WARNING] Configuration options: 'appendAssemblyId' is set to false, and 'classifier' is missing.
   Instead of attaching the assembly file: /scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT.jar, it will become the file for main project artifact.
   NOTE: If multiple descriptors or descriptor-formats are provided for this project, the value of this file will be non-deterministic!
   [WARNING] Replacing pre-existing project main-artifact file: /scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/archive-tmp/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT.jar
   with assembly file: /scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT.jar
   [INFO] 
   [INFO] --- maven-javadoc-plugin:2.9.1:jar (attach-javadocs) @ mxnet-full_2.11-linux-x86_64-cpu ---
   [INFO] ------------------------------------------------------------------------
   [INFO] Reactor Summary:
   [INFO] 
   [INFO] MXNet Scala Package - Parent ....................... SUCCESS [  4.593 s]
   [INFO] MXNet Scala Package - Initializer .................. SUCCESS [  1.896 s]
   [INFO] MXNet Scala Package - Initializer Native Parent .... SUCCESS [  0.107 s]
   [INFO] MXNet Scala Package - Initializer Native Linux-x86_64 SUCCESS [  4.807 s]
   [INFO] MXNet Scala Package - Macros ....................... SUCCESS [  1.144 s]
   [INFO] MXNet Scala Package - Core ......................... SUCCESS [ 20.476 s]
   [INFO] MXNet Scala Package - Native Parent ................ SUCCESS [  0.128 s]
   [INFO] MXNet Scala Package - Native Linux-x86_64 CPU-only . SUCCESS [  3.077 s]
   [INFO] MXNet Scala Package - Examples ..................... SUCCESS [ 27.360 s]
   [INFO] MXNet Scala Package - Spark ML ..................... SUCCESS [ 10.935 s]
   [INFO] MXNet Scala Package - Full Parent .................. SUCCESS [  0.109 s]
   [INFO] MXNet Scala Package - Full Linux-x86_64 CPU-only ... SUCCESS [  9.293 s]
   [INFO] ------------------------------------------------------------------------
   [INFO] BUILD SUCCESS
   [INFO] ------------------------------------------------------------------------
   [INFO] Total time: 01:25 min
   [INFO] Finished at: 2017-12-12T17:23:09-05:00
   [INFO] Final Memory: 154M/1173M
   ```
   3. make scalatest
   ```
   bash-4.1$ make scalatest
   Makefile:224: WARNING: Significant performance increases can be achieved by installing and enabling gperftools or jemalloc development packages
   (cd /scratch/cahsin/repo/mxnet/scala-package; \
       mvn verify -Plinux-x86_64-cpu -Dcxx="g++" \
         -Dcflags="-DMSHADOW_FORCE_STREAM -Wall -Wsign-compare -O3 -DNDEBUG=1 -I/scratch/cahsin/repo/mxnet/mshadow/ -I/scratch/cahsin/repo/mxnet/dmlc-core/include -fPIC -I/scratch/cahsin/repo/mxnet/nnvm/include -I/scratch/cahsin/repo/mxnet/dlpack/include -Iinclude -funroll-loops -Wno-unused-variable -Wno-unused-parameter -Wno-unknown-pragmas -Wno-unused-local-typedefs -msse3 -DMSHADOW_USE_CUDA=0 -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 -I/scratch/cahsin/local/include/opencv -I/scratch/cahsin/local/include   -fopenmp -DMXNET_USE_OPERATOR_TUNING=1 -DMXNET_USE_LAPACK -I/scratch/cahsin/local/include/ -I/scratch/cahsin/repo/OpenBLAS/ -DMXNET_USE_NCCL=0 -DMXNET_USE_LIBJPEG_TURBO=0" -Dldflags="-pthread -lm -fopenmp -lrt -L/scratch/cahsin/local/lib -lopencv_calib3d -lopencv_contrib -lopencv_core -lopencv_features2d -lopencv_flann -lopencv_highgui -lopencv_imgproc -lopencv_legacy -lopencv_ml -lopencv_nonfree -lopencv_objdetect -lopencv_ocl -lopencv_photo -lopencv_stitching -lopencv_superres -lopencv_video -lopencv_videostab -lrt -lpthread -lm -ldl -lopencv_core -lopencv_imgproc -L/scratch/cahsin/local/lib/ -lopenblas" \
         -Dlddeps="/scratch/cahsin/repo/mxnet/dmlc-core/libdmlc.a /scratch/cahsin/repo/mxnet/nnvm/lib/libnnvm.a /scratch/cahsin/repo/mxnet/lib/libmxnet.a" )
   [INFO] Scanning for projects...
   [WARNING] 
   [WARNING] Some problems were encountered while building the effective model for ml.dmlc.mxnet:mxnet-examples_2.11:jar:1.0.0-SNAPSHOT
   [WARNING] 'build.plugins.plugin.version' for net.alchim31.maven:scala-maven-plugin is missing. @ ml.dmlc.mxnet:mxnet-examples_2.11:[unknown-version], /scratch/cahsin/repo/mxnet/scala-package/examples/pom.xml, line 106, column 15
   [WARNING] 
   [WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
   [WARNING] 
   [WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
   [WARNING] 
   [INFO] ------------------------------------------------------------------------
   [INFO] Reactor Build Order:
   ...
   ...
   ...
   ...
   [INFO] 
   [INFO] --- scalastyle-maven-plugin:0.8.0:check (default) @ mxnet-full_2.11-linux-x86_64-cpu ---
   [WARNING] sourceDirectory is not specified or does not exist value=/scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/src/main/scala
   [WARNING] testSourceDirectory is not specified or does not exist value=/scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/src/test/scala
   Saving to outputFile=/scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/scalastyle-output.xml
   Processed 0 file(s)
   Found 0 errors
   Found 0 warnings
   Found 0 infos
   Finished in 2 ms
   [INFO] ------------------------------------------------------------------------
   [INFO] Reactor Summary:
   [INFO] 
   [INFO] MXNet Scala Package - Parent ....................... SUCCESS [  6.316 s]
   [INFO] MXNet Scala Package - Initializer .................. SUCCESS [  3.302 s]
   [INFO] MXNet Scala Package - Initializer Native Parent .... SUCCESS [  1.033 s]
   [INFO] MXNet Scala Package - Initializer Native Linux-x86_64 SUCCESS [  6.798 s]
   [INFO] MXNet Scala Package - Macros ....................... SUCCESS [  2.462 s]
   [INFO] MXNet Scala Package - Core ......................... SUCCESS [01:27 min]
   [INFO] MXNet Scala Package - Native Parent ................ SUCCESS [  1.449 s]
   [INFO] MXNet Scala Package - Native Linux-x86_64 CPU-only . SUCCESS [  4.219 s]
   [INFO] MXNet Scala Package - Examples ..................... SUCCESS [ 36.493 s]
   [INFO] MXNet Scala Package - Spark ML ..................... SUCCESS [ 13.132 s]
   [INFO] MXNet Scala Package - Full Parent .................. SUCCESS [  0.963 s]
   [INFO] MXNet Scala Package - Full Linux-x86_64 CPU-only ... SUCCESS [  9.823 s]
   [INFO] ------------------------------------------------------------------------
   [INFO] BUILD SUCCESS
   [INFO] ------------------------------------------------------------------------
   [INFO] Total time: 02:54 min
   [INFO] Finished at: 2017-12-12T17:44:15-05:00
   [INFO] Final Memory: 156M/1134M
   [INFO] ------------------------------------------------------------------------
   ```
   4. make scalainstall
   ```
   bash-4.1$ make scalainstall
   Makefile:224: WARNING: Significant performance increases can be achieved by installing and enabling gperftools or jemalloc development packages
   (cd /scratch/cahsin/repo/mxnet/scala-package; \
   		mvn install -Plinux-x86_64-cpu -DskipTests -Dcxx="g++" \
   			-Dcflags="-DMSHADOW_FORCE_STREAM -Wall -Wsign-compare -O3 -DNDEBUG=1 -I/scratch/cahsin/repo/mxnet/mshadow/ -I/scratch/cahsin/repo/mxnet/dmlc-core/include -fPIC -I/scratch/cahsin/repo/mxnet/nnvm/include -I/scratch/cahsin/repo/mxnet/dlpack/include -Iinclude -funroll-loops -Wno-unused-variable -Wno-unused-parameter -Wno-unknown-pragmas -Wno-unused-local-typedefs -msse3 -DMSHADOW_USE_CUDA=0 -DMSHADOW_USE_CBLAS=1 -DMSHADOW_USE_MKL=0 -DMSHADOW_RABIT_PS=0 -DMSHADOW_DIST_PS=0 -DMSHADOW_USE_PASCAL=0 -DMXNET_USE_OPENCV=1 -I/scratch/cahsin/local/include/opencv -I/scratch/cahsin/local/include   -fopenmp -DMXNET_USE_OPERATOR_TUNING=1 -DMXNET_USE_LAPACK -I/scratch/cahsin/local/include/ -I/scratch/cahsin/repo/OpenBLAS/ -DMXNET_USE_NCCL=0 -DMXNET_USE_LIBJPEG_TURBO=0" -Dldflags="-pthread -lm -fopenmp -lrt -L/scratch/cahsin/local/lib -lopencv_calib3d -lopencv_contrib -lopencv_core -lopencv_features2d -lopencv_flann -lopencv_highgui -lopencv_imgproc -lopencv_legacy -lopencv_ml -lopencv_nonfree -lopencv_objdetect -lopencv_ocl -lopencv_photo -lopencv_stitching -lopencv_superres -lopencv_video -lopencv_videostab -lrt -lpthread -lm -ldl -lopencv_core -lopencv_imgproc -L/scratch/cahsin/local/lib/ -lopenblas" \
   			-Dlddeps="/scratch/cahsin/repo/mxnet/dmlc-core/libdmlc.a /scratch/cahsin/repo/mxnet/nnvm/lib/libnnvm.a /scratch/cahsin/repo/mxnet/lib/libmxnet.a")
   [INFO] Scanning for projects...
   [WARNING] 
   [WARNING] Some problems were encountered while building the effective model for ml.dmlc.mxnet:mxnet-examples_2.11:jar:1.0.0-SNAPSHOT
   [WARNING] 'build.plugins.plugin.version' for net.alchim31.maven:scala-maven-plugin is missing. @ ml.dmlc.mxnet:mxnet-examples_2.11:[unknown-version], /scratch/cahsin/repo/mxnet/scala-package/examples/pom.xml, line 106, column 15
   [WARNING] 
   [WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
   [WARNING] 
   [WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
   [WARNING] 
   [INFO] ------------------------------------------------------------------------
   [INFO] Reactor Build Order:
   ...
   ...
   ...
   ...
   [INFO] 
   [INFO] --- scalastyle-maven-plugin:0.8.0:check (default) @ mxnet-full_2.11-linux-x86_64-cpu ---
   [WARNING] sourceDirectory is not specified or does not exist value=/scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/src/main/scala
   [WARNING] testSourceDirectory is not specified or does not exist value=/scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/src/test/scala
   Saving to outputFile=/scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/scalastyle-output.xml
   Processed 0 file(s)
   Found 0 errors
   Found 0 warnings
   Found 0 infos
   Finished in 1 ms
   [INFO] 
   [INFO] --- maven-install-plugin:2.5.2:install (default-install) @ mxnet-full_2.11-linux-x86_64-cpu ---
   [INFO] Installing /scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT.jar to /home/cahsin/.m2/repository/ml/dmlc/mxnet/mxnet-full_2.11-linux-x86_64-cpu/1.0.0-SNAPSHOT/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT.jar
   [INFO] Installing /scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/pom.xml to /home/cahsin/.m2/repository/ml/dmlc/mxnet/mxnet-full_2.11-linux-x86_64-cpu/1.0.0-SNAPSHOT/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT.pom
   [INFO] Installing /scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT-javadoc.jar to /home/cahsin/.m2/repository/ml/dmlc/mxnet/mxnet-full_2.11-linux-x86_64-cpu/1.0.0-SNAPSHOT/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT-javadoc.jar
   [INFO] ------------------------------------------------------------------------
   [INFO] Reactor Summary:
   [INFO] 
   [INFO] MXNet Scala Package - Parent ....................... SUCCESS [  5.448 s]
   [INFO] MXNet Scala Package - Initializer .................. SUCCESS [  2.116 s]
   [INFO] MXNet Scala Package - Initializer Native Parent .... SUCCESS [  0.164 s]
   [INFO] MXNet Scala Package - Initializer Native Linux-x86_64 SUCCESS [  6.489 s]
   [INFO] MXNet Scala Package - Macros ....................... SUCCESS [  1.517 s]
   [INFO] MXNet Scala Package - Core ......................... SUCCESS [ 18.221 s]
   [INFO] MXNet Scala Package - Native Parent ................ SUCCESS [  0.182 s]
   [INFO] MXNet Scala Package - Native Linux-x86_64 CPU-only . SUCCESS [  3.736 s]
   [INFO] MXNet Scala Package - Examples ..................... SUCCESS [ 33.491 s]
   [INFO] MXNet Scala Package - Spark ML ..................... SUCCESS [ 11.440 s]
   [INFO] MXNet Scala Package - Full Parent .................. SUCCESS [  0.130 s]
   [INFO] MXNet Scala Package - Full Linux-x86_64 CPU-only ... SUCCESS [  9.548 s]
   [INFO] ------------------------------------------------------------------------
   [INFO] BUILD SUCCESS
   [INFO] ------------------------------------------------------------------------
   [INFO] Total time: 01:33 min
   [INFO] Finished at: 2017-12-12T17:50:14-05:00
   [INFO] Final Memory: 156M/1274M
   [INFO] ------------------------------------------------------------------------
   ```
   5. get the mnist data
   ```
   bash-4.1$ cd scala-package/
   bash-4.1$ core/scripts/get_mnist_data.sh
   ```
   6. update run_gan_mnist.sh to be cpu
   ```
   #!/bin/bash
   
   # Licensed to the Apache Software Foundation (ASF) under one
   # or more contributor license agreements.  See the NOTICE file
   # distributed with this work for additional information
   # regarding copyright ownership.  The ASF licenses this file
   # to you under the Apache License, Version 2.0 (the
   # "License"); you may not use this file except in compliance
   # with the License.  You may obtain a copy of the License at
   #
   #   http://www.apache.org/licenses/LICENSE-2.0
   #
   # Unless required by applicable law or agreed to in writing,
   # software distributed under the License is distributed on an
   # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
   # KIND, either express or implied.  See the License for the
   # specific language governing permissions and limitations
   # under the License.
   
   
   MXNET_ROOT=$(cd "$(dirname $0)/../../.."; pwd)
   CLASS_PATH=$MXNET_ROOT/scala-package/assembly/linux-x86_64-cpu/target/*:$MXNET_ROOT/scala-package/examples/target/*:$MXNET_ROOT/scala-package/examples/target/classes/lib/*
   
   # which gpu card to use, -1 means cpu
   GPU=$1
   
   # the mnist data path
   # you can get the mnist data using the script core/scripts/get_mnist_data.sh
   MNIST_DATA_PATH=$2
   
   # the path to save the generated results
   OUTPUT_PATH=$3
   
   java -Xmx4G -cp $CLASS_PATH \
   	ml.dmlc.mxnetexamples.gan.GanMnist \
   	--mnist-data-path $MNIST_DATA_PATH \
   	--gpu $GPU \
   	--output-path $OUTPUT_PATH
   ```
   7. bash run_gan_mnist.sh -1 ../../data ../../tmp
   ```
   bash-4.1$ bash run_gan_mnist.sh -1 ../../data ../../tmp
   SLF4J: Class path contains multiple SLF4J bindings.
   SLF4J: Found binding in [jar:file:/scratch/cahsin/repo/mxnet/scala-package/assembly/linux-x86_64-cpu/target/mxnet-full_2.11-linux-x86_64-cpu-1.0.0-SNAPSHOT.jar!/org/slf4j/impl/StaticLoggerBinder.class]
   SLF4J: Found binding in [jar:file:/scratch/cahsin/repo/mxnet/scala-package/examples/target/classes/lib/slf4j-log4j12-1.7.7.jar!/org/slf4j/impl/StaticLoggerBinder.class]
   SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
   SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]
   2017-12-12 17:54:07,654 [main] [MXNetJVM] [INFO] - Try loading mxnet-scala from native path.
   2017-12-12 17:54:07,657 [main] [MXNetJVM] [INFO] - Try loading mxnet-scala-linux-x86_64-gpu from native path.
   2017-12-12 17:54:07,658 [main] [MXNetJVM] [INFO] - Try loading mxnet-scala-linux-x86_64-cpu from native path.
   2017-12-12 17:54:07,659 [main] [MXNetJVM] [WARN] - MXNet Scala native library not found in path. Copying native library from the archive. Consider installing the library somewhere in the path (for Windows: PATH, for Linux: LD_LIBRARY_PATH), or specifying by Java cmd option -Djava.library.path=[lib path].
   2017-12-12 17:54:07,697 [main] [ml.dmlc.mxnet.util.NativeLibraryLoader] [INFO] - Loading libmxnet-scala.so from /lib/native/ copying to mxnet-scala
   [17:54:10] src/io/iter_mnist.cc:113: MNISTIter: load 60000 images, shuffle=1, shape=[100,1,28,28]
   java: symbol lookup error: /tmp/mxnet1076674076824248309/mxnet-scala: undefined symbol: cblas_sgemm
   ```
   
   ## What have you tried to solve it?
   
   1. Check the links in libmxnet.so are there:
   ```
   bash-4.1$  ldd lib/libmxnet.so | grep blas
   	libopenblas.so.0 => /scratch/cahsin/local/lib/libopenblas.so.0 (0x00007f86e2406000)
   ```
   2. Check the built openblas from https://github.com/xianyi/OpenBLAS, but that doesn't seem to be the issue since the cblas function is there:
   ```
   bash-4.1$ nm /scratch/cahsin/local/lib/libopenblas.so.0 | grep cblas_sgemm
   0000000000090380 T cblas_sgemm
   ```

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