Code Monkey home page Code Monkey logo

ell's Introduction

Embedded Learning Library

The Embedded Learning Library (ELL) allows you to design and deploy intelligent machine-learned models onto resource constrained platforms and small single-board computers, like Raspberry Pi, Arduino, and micro:bit. The deployed models run locally, without requiring a network connection and without relying on servers in the cloud. ELL is an early preview of the embedded AI and machine learning technologies developed at Microsoft Research.

Go to our website for tutorials, instructions, and a gallery of pretrained ELL models for use in your projects.

ELL is a work in progress, and we expect it to change rapidly, including breaking API changes. Despite this code churn, we welcome you to try it and give us feedback.

License

See LICENSE.txt.

Code of conduct

This project has adopted the Microsoft Open Source Code of Conduct. For more information on this code of conduct, see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

Build and Installation Instructions

Build Status

Technical Documentation

ell's People

Contributors

botship avatar cjacobs avatar clovett avatar dashesy avatar dennysun2020 avatar dixiecrockford avatar hiramf avatar joeksam avatar kernhanda avatar lisaong avatar lovettchris avatar masonremy avatar mr-yamraj avatar oferdekel avatar pcdeadeasy avatar rdeline avatar shawncal avatar suiyengar avatar umeshma avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ell's Issues

Docker running in Raspberry PI or PC..

Does any one tried to make it work inside docker on a rasberry pi or PC?

I was able to compile and run all unit tests and to some what darnetDemo.py file .. But not clear on how to use camera connected to PC or Rasberry PI.. and hooking it up with docker linux running ELL..

make failed on Ubuntu 14.04 LTS, error: undefined reference to `cblas_xxx'

After checking the docs several times, I believe I have all the proper version of prerequisites installed on Ubuntu 14.04 LTS, but make still failed finally.
The output messages are:

[ 0%] Built target documentation
[ 10%] Built target utilities
[ 11%] Built target math
[ 14%] Built target data
[ 23%] Built target emitters
[ 24%] Built target evaluators
[ 28%] Built target functions
[ 37%] Built target model
[ 39%] Built target predictors
[ 48%] Built target nodes
[ 52%] Built target trainers
[ 59%] Built target common
[ 60%] Built target testing
[ 61%] Linking CXX executable common_test
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Copy(int, float const*, int, float*, int)': BlasWrapper.cpp:(.text+0x31): undefined reference to cblas_scopy'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Copy(int, double const*, int, double*, int)': BlasWrapper.cpp:(.text+0x69): undefined reference to cblas_dcopy'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Asum(int, float const*, int)': BlasWrapper.cpp:(.text+0x92): undefined reference to cblas_sasum'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Asum(int, double const*, int)': BlasWrapper.cpp:(.text+0xba): undefined reference to cblas_dasum'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Nrm2(int, float const*, int)': BlasWrapper.cpp:(.text+0xf0): undefined reference to cblas_snrm2'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Nrm2(int, double const*, int)': BlasWrapper.cpp:(.text+0x118): undefined reference to cblas_dnrm2'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Scal(int, float, float*, int)': BlasWrapper.cpp:(.text+0x15b): undefined reference to cblas_sscal'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Scal(int, double, double*, int)': BlasWrapper.cpp:(.text+0x193): undefined reference to cblas_dscal'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Axpy(int, float, float const*, int, float*, int)': BlasWrapper.cpp:(.text+0x1d9): undefined reference to cblas_saxpy'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Axpy(int, double, double const*, int, double*, int)': BlasWrapper.cpp:(.text+0x221): undefined reference to cblas_daxpy'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Dot(int, float const*, int, float const*, int)': BlasWrapper.cpp:(.text+0x259): undefined reference to cblas_sdot'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Dot(int, double const*, int, double const*, int)': BlasWrapper.cpp:(.text+0x290): undefined reference to cblas_ddot'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Gemv(CBLAS_ORDER, CBLAS_TRANSPOSE, int, int, float, float const*, int, float const*, int, float, float*, int)': BlasWrapper.cpp:(.text+0x309): undefined reference to cblas_sgemv'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Gemv(CBLAS_ORDER, CBLAS_TRANSPOSE, int, int, double, double const*, int, double const*, int, double, double*, int)': BlasWrapper.cpp:(.text+0x37c): undefined reference to cblas_dgemv'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Gemm(CBLAS_ORDER, CBLAS_TRANSPOSE, CBLAS_TRANSPOSE, int, int, int, float, float const*, int, float const*, int, float, float*, int)': BlasWrapper.cpp:(.text+0x3f5): undefined reference to cblas_sgemm'
../math/libmath.a(BlasWrapper.cpp.o): In function ell::math::Blas::Gemm(CBLAS_ORDER, CBLAS_TRANSPOSE, CBLAS_TRANSPOSE, int, int, int, double, double const*, int, double const*, int, double, double*, int)': BlasWrapper.cpp:(.text+0x471): undefined reference to cblas_dgemm'
collect2: error: ld returned 1 exit status
make[2]: *** [libraries/common/common_test] Error 1
make[1]: *** [libraries/common/CMakeFiles/common_test.dir/all] Error 2
make: *** [all] Error 2

It seems that the "cblas_xxx" errors are related to openblas? But I have installed the libopenblas-dev already.
So, any suggestions? Thanks a lot.

sudo make Does Not Work on Ubuntu Linux 14.04 x86_64

I can build just fine into > ELL/build, but upon running sudo make, I get a huge list of errors -- too long to post here. But it ends with:

make[2]: *** [libraries/utilities/CMakeFiles/utilities.dir/src/Archiver.cpp.o] Error 1
make[1]: *** [libraries/utilities/CMakeFiles/utilities.dir/all] Error 2
make: *** [all] Error 2

** On entry to SGEMM parameter number 8 had an illegal value [Pi Zero]

I am trying to deploy the darknet tutorial on Pi Zero. The model has been successfully compiled on Ubuntu.
On Pi Zero, I recompiled directly on the main environment instead of Miniconda. Because Miniconda3-latest-Linux-armv7l.sh does not support Pi Zero (armv6l). Meanwhile, Miniconda-3.5.5-Linux-armv6l.sh supports Pi Zero but can't install python 3 environment, which is required by the tutorials.

The compiling process does not raise any troubles

-- The C compiler identification is GNU 4.9.2
-- The CXX compiler identification is GNU 4.9.2
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Blas libraries: /usr/lib/libopenblas.so
-- Blas linker flags:
-- Blas include directories:
-- Using BLAS include path: /usr/include
-- Using BLAS library: /usr/lib/libopenblas.so
-- Using BLAS DLLs:
-- Found PythonInterp: /usr/bin/python3.4 (found suitable version "3.4.2", minimum required is "3.4")
-- Found PythonLibs: /usr/lib/arm-linux-gnueabihf/libpython3.4m.so (found suitable version "3.4.2", minimum required is "3.4")
-- Configuring done
-- Generating done
-- Build files have been written to: /home/pi/ELL_demo/build

However, when I run the demo python compiledDarknetDemo.py, there are errors

** On entry to SGEMM  parameter number  8 had an illegal value
 ** On entry to SGEMM  parameter number  8 had an illegal value
 ** On entry to SGEMM  parameter number  8 had an illegal value
 ** On entry to SGEMM  parameter number  8 had an illegal value
 ** On entry to SGEMM  parameter number  8 had an illegal value
 ** On entry to SGEMM  parameter number  8 had an illegal value
 ** On entry to SGEMM  parameter number  8 had an illegal value
 ** On entry to SGEMM  parameter number  8 had an illegal value

(frame:1241): Gtk-WARNING **: cannot open display:

I have checked the system only has libopenblas-dev, no libatlas-dev

Would you help me with this issue?
Thank you

make failed on Raspberry Pi 3B, Arch Linux ARM

Hardware version: Raspberry Pi 3B
OS: Arch Linux ARM

I've installed the dependencies and the make process failed finally, and part of the command line output messages are as following, so does anyone knows how could I solve it? Thanks in advance.

[ 29%] Linking CXX static library libfunctions.a
[ 29%] Built target functions
Scanning dependencies of target model
[ 29%] Building CXX object libraries/model/CMakeFiles/model.dir/src/CompilableNode.cpp.o
In file included from /root/resource/ELL/libraries/model/include/Model.h:13:0,
from /root/resource/ELL/libraries/model/include/IRModelProfiler.h:11,
from /root/resource/ELL/libraries/model/include/CompilableNode.h:11,
from /root/resource/ELL/libraries/model/src/CompilableNode.cpp:9:
/root/resource/ELL/libraries/model/include/PortElements.h: In member function ‘const ell::model::OutputPort* ell::model::PortElements::ReferencedPort() const’:
/root/resource/ELL/libraries/model/include/PortElements.h:448:135: error: ‘ell::model::PortElementBase’ is not a base of ‘const ell::model::PortElements’
ncedPort() const { return static_cast<const OutputPort*>(this->PortElementBase::ReferencedPort()); }
^~~~~~~~~~~~~~
make[2]: *** [libraries/model/CMakeFiles/model.dir/build.make:63: libraries/model/CMakeFiles/model.dir/src/CompilableNode.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:875: libraries/model/CMakeFiles/model.dir/all] Error 2
make: *** [Makefile:95: all] Error 2

darknetDemo errors

(py36) root@8fa27a83d7dd:~/ELL/build/tutorials/vision/gettingStarted# python darknetDemo.py
convolutional: 224 x 224 x 3 -> 224 x 224 x 16 , pad 1
max_pool: 224 x 224 x 16 -> 112 x 112 x 16 , pad 0
convolutional: 112 x 112 x 16 -> 112 x 112 x 32 , pad 1
max_pool: 112 x 112 x 32 -> 56 x 56 x 32 , pad 0
convolutional: 56 x 56 x 32 -> 56 x 56 x 64 , pad 1
max_pool: 56 x 56 x 64 -> 28 x 28 x 64 , pad 0
convolutional: 28 x 28 x 64 -> 28 x 28 x 128 , pad 1
max_pool: 28 x 28 x 128 -> 14 x 14 x 128 , pad 0
convolutional: 14 x 14 x 128 -> 14 x 14 x 256 , pad 1
max_pool: 14 x 14 x 256 -> 7 x 7 x 256 , pad 0
convolutional: 7 x 7 x 256 -> 7 x 7 x 512 , pad 1
max_pool: 7 x 7 x 512 -> 4 x 4 x 512 , pad 1
convolutional: 4 x 4 x 512 -> 4 x 4 x 1024 , pad 1
convolutional: 4 x 4 x 1024 -> 4 x 4 x 1000 , pad 0
avg_pool: 4 x 4 x 1000 -> 1 x 1 x 1000 , pad 0
softmax: 1 x 1 x 1000 -> 1 x 1 x 1000
Traceback (most recent call last):
File "darknetDemo.py", line 70, in
main()
File "darknetDemo.py", line 28, in main
model = get_ell_predictor(helper)
File "darknetDemo.py", line 12, in get_ell_predictor
return darknet_to_ell.predictor_from_darknet_model(helper.model_files[0], helper.model_files[1])
File "./../../../../build/tools/importers/Darknet/darknet_to_ell.py", line 432, in predictor_from_darknet_model
predictor = process_network(network, weightsData, convolutionOrder)
File "./../../../../build/tools/importers/Darknet/darknet_to_ell.py", line 396, in process_network
ellLayers += process_convolutional_layer(layer, weightsData, convolutionOrder)
File "./../../../../build/tools/importers/Darknet/darknet_to_ell.py", line 283, in process_convolutional_layer
weight_vals.append(struct.unpack('f', bin_data.read(4)))
struct.error: unpack requires a bytes object of length 4

(py36) root@8fa27a83d7dd:~/ELL/build/tutorials/vision/gettingStarted# sh compile_darknetReference.sh
Compiling darknetReference from ELL, emitting LLVM IR
Command line parse error:
Cannot read from specified input map file: darknetReference.map
Parsing darknetReference from ELL, generating SWIG interface
Command line parse error:
Cannot read from specified input map file: darknetReference.map
Compiling darknetReference LLVM IR, generating model object file
compile_darknetReference.sh: 9: compile_darknetReference.sh: llc: not found
Running disutils setup to compile and link model + SWIG wrappers into Python module, and install package locally
running build
running build_ext
building '_darknetReference' extension
swigging darknetReference.i to darknetReference_wrap.cpp
swig -python -modern -c++ -py3 -Fmicrosoft -I/root/ELL/interfaces/common -I/root/ELL/interfaces/common/include -I/root/ELL/libraries/emitters/include -o darknetReference_wrap.cpp darknetReference.i
Unable to find file 'darknetReference.i'.
error: command 'swig' failed with exit status 1

Anyone seen these errors?

Low FPS on RPi 3 (1 fps)

Finally got it up and running!

What is everyone getting as their FPS? Right now, I'm barely getting 1.0 fps and extreme lag (4 seconds).

Raspberry Pi 3, PiCam v2

cntkDemo.py 'lastPrediction' referenced before assignment

...Finished constructing ELL layers.
Traceback (most recent call last):
  File "cntkDemo.py", line 67, in <module>
    main()
  File "cntkDemo.py", line 53, in main
    if (text != lastPrediction):
UnboundLocalError: local variable 'lastPrediction' referenced before assignment

Surface Pro 3, i5 8GB, Windows 10
Anaconda3

[Error] Build on Raspberry Pi 3 due to missing darknetReference.map file

I have build ELL on Ubuntu with the compiling instruction of Pi3, following exactly the same with it.

It have succeeded just entering "make" command,
but "make compiled_darknetReference_pi3" got me this message below.

Environment was Ubuntu 16.04.

[ 17%] Built target utilities
[ 19%] Built target math
[ 25%] Built target data
[ 40%] Built target emitters
[ 42%] Built target evaluators
[ 48%] Built target functions
[ 61%] Built target model
[ 65%] Built target predictors
[ 78%] Built target nodes
[ 84%] Built target trainers
[ 96%] Built target common
[ 98%] Built target compile
make[3]: *** No rule to make target 'tutorials/vision/gettingStarted/darknetReference.map', needed by 'tutorials/vision/gettingStarted/compiled_darknetReference_pi3/darknetReference.bc'. Stop.
CMakeFiles/Makefile2:3311: recipe for target 'tutorials/vision/gettingStarted/CMakeFiles/compiled_darknetReference_pi3.dir/all' failed
make[2]: *** [tutorials/vision/gettingStarted/CMakeFiles/compiled_darknetReference_pi3.dir/all] Error 2
CMakeFiles/Makefile2:3318: recipe for target 'tutorials/vision/gettingStarted/CMakeFiles/compiled_darknetReference_pi3.dir/rule' failed
make[1]: *** [tutorials/vision/gettingStarted/CMakeFiles/compiled_darknetReference_pi3.dir/rule] Error 2
Makefile:896: recipe for target 'compiled_darknetReference_pi3' failed
make: *** [compiled_darknetReference_pi3] Error 2

I have no idea how to solve this problem..

how do I get ELL.py?

I was able to compile and run unit tests successfully now ... and follow instructions

https://github.com/Microsoft/ELL/blob/master/tutorials/vision/gettingStarted/README.md

installed
miniconda,
OpenCV,
numpy
and downloaded Microsoft Cognitive Toolkit

But it seems to fail in this step now ..

root@8fa27a83d7dd:~/ELL/build/tutorials/vision/gettingStarted# python cntkDemo.py
Could not find './../../../build/interfaces/python/ELL.py', did you follow the ELL Python Binding build instructions?

Also, can't find compile_vggImageNet.sh ... what is ELL Python Binding build? and how can I get ELL.py file?

Thnaks in advance...

can't build on 64 bit ubuntu 16.04 - Any ideas..

root@ad00bef8edc1:/anil/ELL/build# gcc --version
gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
Copyright (C) 2015 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.

root@ad00bef8edc1:/anil/ELL/build# uname -a
Linux ad00bef8edc1 4.9.31-moby #1 SMP Sat Jun 24 06:29:23 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

root@ad00bef8edc1:/anil/ELL/build# cmake ..
-- The CXX compiler identification is unknown
-- Check for working CXX compiler: /usr/bin/gcc
-- Check for working CXX compiler: /usr/bin/gcc -- broken
CMake Error at /usr/share/cmake-3.5/Modules/CMakeTestCXXCompiler.cmake:54 (message):
The C++ compiler "/usr/bin/gcc" is not able to compile a simple test
program.

It fails with the following output:

Change Dir: /anil/ELL/build/CMakeFiles/CMakeTmp

Run Build Command:"/usr/bin/make" "cmTC_2c297/fast"

/usr/bin/make -f CMakeFiles/cmTC_2c297.dir/build.make
CMakeFiles/cmTC_2c297.dir/build

make[1]: Entering directory '/anil/ELL/build/CMakeFiles/CMakeTmp'

Building CXX object CMakeFiles/cmTC_2c297.dir/testCXXCompiler.cxx.o

/usr/bin/gcc -o CMakeFiles/cmTC_2c297.dir/testCXXCompiler.cxx.o -c
/anil/ELL/build/CMakeFiles/CMakeTmp/testCXXCompiler.cxx

gcc: error trying to exec 'cc1plus': execvp: No such file or directory

CMakeFiles/cmTC_2c297.dir/build.make:65: recipe for target
'CMakeFiles/cmTC_2c297.dir/testCXXCompiler.cxx.o' failed

make[1]: *** [CMakeFiles/cmTC_2c297.dir/testCXXCompiler.cxx.o] Error 1

make[1]: Leaving directory '/anil/ELL/build/CMakeFiles/CMakeTmp'

Makefile:126: recipe for target 'cmTC_2c297/fast' failed

make: *** [cmTC_2c297/fast] Error 2

CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
CMakeLists.txt:7 (project)

-- Configuring incomplete, errors occurred!
See also "/anil/ELL/build/CMakeFiles/CMakeOutput.log".
See also "/anil/ELL/build/CMakeFiles/CMakeError.log".
root@ad00bef8edc1:/anil/ELL/build# gcc --version
gcc (Ubuntu 5.4.0-6ubuntu1~16.04.4) 5.4.0 20160609
Copyright (C) 2015 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.

rebuild.cmd

I like the new rebuild.cmd file but it assumes VS2015 maybe you could add something like this:
`@echo off

if not EXIST build goto :mkbuild

rd /s /q build
if ERRORLEVEL 1 goto :nodelete

:mkbuild
mkdir build
if ERRORLEVEL 1 goto :nodelete

cd build

set /p vs="Enter your Visual Studio version (2015/2017): "
if %vs% == 2017 goto :2017

cmake -G "Visual Studio 14 2015 Win64" -DPROCESSOR_HINT=haswell ..
if ERRORLEVEL 1 goto :nocmake
goto :build

:2017
cmake -G "Visual Studio 15 2017 Win64" -DPROCESSOR_HINT=haswell ..

:build
cmake --build . --config RelWithDebInfo
if ERRORLEVEL 1 goto :builderror

cmake --build . --target _ELL_python --config RelWithDebInfo

goto :eof

:nodelete
echo Error deleting 'build' folder, is it locked?
goto :eof

:nocmake
echo cmake step failed
goto :eof

:builderror`

Error at cntkDemo.py test

I've worked through several issues with my build (this is my first foray into python and pi). I'm down to this error and then I think I can compile and put this baby on pi.

I get through the pooling, and then there's a whole set of "converting layer" lines that run, i noticed the word tensor on each line (this was not listed as something that happens when running the demo so it's a little confusing):

Constructing equivalent ELL layers from CNTK...
Converting layer conv1_1: Convolution(data: Tensor[3,224,224]) -> Tensor[64,224,224]
Converting layer relu1_1: ReLU(conv1_1: Tensor[64,224,224]) -> Tensor[64,224,224]
..(several more lines of this)

Then I get this output:

...Finished constructing ELL layers.
Traceback (most recent call last):
File "cntkDemo.py", line 68, in
main()
File "cntkDemo.py", line 43, in main
data = helper.prepare_image_for_predictor(frame)
File "C:\AIPi\ELL\build\tutorials\vision\gettingStarted\modelHelper.py", line 70, in prepare_image_for_predictor
resized = self.resize_image(image, self.inputHeightAndWidth)
File "C:\AIPi\ELL\build\tutorials\vision\gettingStarted\modelHelper.py", line 53, in resize_image
if (image.shape[0] > image.shape[1]):
AttributeError: 'NoneType' object has no attribute 'shape'

Any help would be greatly appreciated!

python version problem

Python has been updated to 3.60, however, when do cmake, the error still occures....
Anybody can tell how to solve?

`pi@raspberrypi:~/Desktop/ELL/build $ cmake ..
-- The C compiler identification is GNU 4.9.2
-- The CXX compiler identification is GNU 4.9.2
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Blas libraries: /usr/lib/libopenblas.so
-- Blas linker flags:
-- Blas include directories:
-- Using BLAS include path: /usr/include
-- Using BLAS library: /usr/lib/libopenblas.so
-- Using BLAS DLLs:
-- Found PythonInterp: /usr/bin/python (found version "2.7.9")
-- Found PythonLibs: /usr/lib/arm-linux-gnueabihf/libpython2.7.so (found version "2.7.9")
-- Found SWIG: /usr/local/bin/swig (found suitable version "3.0.12", minimum required is "3.0.12")
CMake Warning at interfaces/python/CMakeLists.txt:9 (message):
Couldn't find Python libraries 3.5 or later, _ELL_python target will not be
build properly. This is not a required component, so it can be skipped.

-- Creating wrappers for python
-- Creating wrappers for javascript
-- Creating wrappers for xml
-- Using python found at: /usr/bin/python
-- Using python libraries found at: /usr/lib/arm-linux-gnueabihf/libpython2.7.so
-- Creating wrappers for python
-- Configuring done
-- Generating done
-- Build files have been written to: /home/pi/Desktop/ELL/build
pi@raspberrypi:~/Desktop/ELL/build $ python3
Python 3.6.0 (default, Jul 7 2017, 19:20:32)
[GCC 4.9.2] on linux
`

cmake fails on Ubuntu 17.04

After tracking down SWIG and the ./configure --without-pcre , I'm still unable to successfully complete cmake.

cmake ..
-- The C compiler identification is GNU 6.3.0
-- The CXX compiler identification is GNU 6.3.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Blas libraries: /usr/lib/libopenblas.so
-- Blas linker flags:
-- Blas include directories:
-- Using BLAS include path: /usr/include
-- Using BLAS library: /usr/lib/libopenblas.so
-- Using BLAS DLLs:
CMake Error at CMake/LLVMSetup.cmake:41 (string):
string sub-command REPLACE requires at least four arguments.
Call Stack (most recent call first):
CMake/LLVMSetup.cmake:51 (get_llvm_config_list)
CMakeLists.txt:63 (include)

[ERROR] python darknetDemo.py

==================================================================== ELL module is not loading It is possible that you need to add LibOpenBLAS to your system path (See Install-*.md) from root of this repo Traceback (most recent call last): File "./../../../../build/interfaces/python/ELL.py", line 14, in swig_import_helper return importlib.import_module(mname) File "/home/zxd/miniconda3/envs/py36/lib/python3.6/importlib/__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "<frozen importlib._bootstrap>", line 978, in _gcd_import File "<frozen importlib._bootstrap>", line 961, in _find_and_load File "<frozen importlib._bootstrap>", line 950, in _find_and_load_unlocked File "<frozen importlib._bootstrap>", line 648, in _load_unlocked File "<frozen importlib._bootstrap>", line 560, in module_from_spec File "<frozen importlib._bootstrap_external>", line 922, in create_module File "<frozen importlib._bootstrap>", line 205, in _call_with_frames_removed ImportError: /home/zxd/miniconda3/envs/py36/lib/python3.6/site-packages/../../libstdc++.so.6: version CXXABI_1.3.9' not found (required by ./../../../../build/interfaces/python/_ELL.so)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "darknetDemo.py", line 7, in
import darknet_to_ell
File "./../../../../build/tools/importers/darknet/darknet_to_ell.py", line 17, in
import ELL
File "./../../../../build/interfaces/python/ELL.py", line 17, in
_ELL = swig_import_helper()
File "./../../../../build/interfaces/python/ELL.py", line 16, in swig_import_helper
return importlib.import_module('_ELL')
File "/home/zxd/miniconda3/envs/py36/lib/python3.6/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: /home/zxd/miniconda3/envs/py36/lib/python3.6/site-packages/../../libstdc++.so.6: version CXXABI_1.3.9' not found (required by ./../../../../build/interfaces/python/_ELL.so)

make failed on Ubuntu 17.04

After updating to CMake 3.9.0.rc5, cmake was able to run successfully. New error when trying make.

make
Scanning dependencies of target documentation
[ 0%] Built target documentation
Scanning dependencies of target utilities
[ 1%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/Archiver.cpp.o
[ 1%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/CommandLineParser.cpp.o
[ 2%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/CompressedIntegerList.cpp.o
[ 2%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/ConformingVector.cpp.o
[ 3%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/CStringParser.cpp.o
[ 3%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/Files.cpp.o
[ 4%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/Format.cpp.o
[ 4%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/IArchivable.cpp.o
[ 5%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/IndentedTextWriter.cpp.o
[ 5%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/IntegerList.cpp.o
[ 6%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/IntegerStack.cpp.o
[ 6%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/JsonArchiver.cpp.o
[ 7%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/ObjectArchive.cpp.o
[ 7%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/ObjectArchiver.cpp.o
[ 8%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/OutputStreamImpostor.cpp.o
[ 8%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/PPMImageParser.cpp.o
[ 9%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/RandomEngines.cpp.o
[ 9%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/Tokenizer.cpp.o
[ 10%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/TypeName.cpp.o
[ 10%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/UniqueId.cpp.o
[ 11%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/Variant.cpp.o
[ 11%] Building CXX object libraries/utilities/CMakeFiles/utilities.dir/src/XmlArchiver.cpp.o
[ 13%] Linking CXX static library libutilities.a
[ 13%] Built target utilities
Scanning dependencies of target math
[ 13%] Building CXX object libraries/math/CMakeFiles/math.dir/src/BlasWrapper.cpp.o
[ 14%] Linking CXX static library libmath.a
[ 14%] Built target math
Scanning dependencies of target data
[ 15%] Building CXX object libraries/data/CMakeFiles/data.dir/src/Dataset.cpp.o
[ 15%] Building CXX object libraries/data/CMakeFiles/data.dir/src/DataVector.cpp.o
[ 16%] Building CXX object libraries/data/CMakeFiles/data.dir/src/DataVectorOperations.cpp.o
[ 16%] Building CXX object libraries/data/CMakeFiles/data.dir/src/GeneralizedSparseParsingIterator.cpp.o
[ 17%] Building CXX object libraries/data/CMakeFiles/data.dir/src/SequentialLineIterator.cpp.o
[ 17%] Building CXX object libraries/data/CMakeFiles/data.dir/src/TextLine.cpp.o
[ 18%] Building CXX object libraries/data/CMakeFiles/data.dir/src/WeightLabel.cpp.o
[ 18%] Linking CXX static library libdata.a
[ 18%] Built target data
Scanning dependencies of target evaluators
[ 18%] Building CXX object libraries/evaluators/CMakeFiles/evaluators.dir/src/AUCAggregator.cpp.o
[ 19%] Building CXX object libraries/evaluators/CMakeFiles/evaluators.dir/src/BinaryErrorAggregator.cpp.o
[ 19%] Linking CXX static library libevaluators.a
[ 19%] Built target evaluators
Scanning dependencies of target functions
[ 19%] Building CXX object libraries/functions/CMakeFiles/functions.dir/src/ElasticNetRegularizer.cpp.o
[ 20%] Building CXX object libraries/functions/CMakeFiles/functions.dir/src/HingeLoss.cpp.o
[ 20%] Building CXX object libraries/functions/CMakeFiles/functions.dir/src/L2Regularizer.cpp.o
[ 21%] Building CXX object libraries/functions/CMakeFiles/functions.dir/src/LogLoss.cpp.o
[ 21%] Building CXX object libraries/functions/CMakeFiles/functions.dir/src/SmoothHingeLoss.cpp.o
[ 22%] Building CXX object libraries/functions/CMakeFiles/functions.dir/src/SquaredLoss.cpp.o
[ 22%] Linking CXX static library libfunctions.a
[ 22%] Built target functions
Scanning dependencies of target model
[ 22%] Building CXX object libraries/model/CMakeFiles/model.dir/src/CompilableNode.cpp.o
In file included from /home/malynda/Development/ELL/libraries/model/include/CompilableNode.h:11:0,
from /home/malynda/Development/ELL/libraries/model/src/CompilableNode.cpp:9:
/home/malynda/Development/ELL/libraries/model/include/IRModelProfiler.h:15:26: fatal error: EmitterTypes.h: No such file or directory
#include "EmitterTypes.h"
^
compilation terminated.
libraries/model/CMakeFiles/model.dir/build.make:62: recipe for target 'libraries/model/CMakeFiles/model.dir/src/CompilableNode.cpp.o' failed
make[2]: *** [libraries/model/CMakeFiles/model.dir/src/CompilableNode.cpp.o] Error 1
CMakeFiles/Makefile2:739: recipe for target 'libraries/model/CMakeFiles/model.dir/all' failed
make[1]: *** [libraries/model/CMakeFiles/model.dir/all] Error 2
Makefile:94: recipe for target 'all' failed
make: *** [all] Error 2

implement slowly and some cfg&weights files are not work-test on laptop

ubuntu16.04 LTS 64
Device:Alienware 17 R4
I7/8GB/6G(GPU)

1\shall I must copy darknet_to_ell.py to the path of darknetDemo.py?

2\if '#" in cfg file,darknetDemo.py will crash.

3\darknetDemo.py with darknet.cfg& darknet.weights run slowly
I add a timer at function main() in while loop

/××××××××××××××××××××××/
timer = Timer()
timer.tic()
# Get the model to classify the image, by returning a list of probabilities for the classes it can detect
predictions = model.Predict(data)
timer.toc()
print (('Detection took {:.3f}s').format(timer.total_time))

and display show as follow:
Detection took 1.981s
Detection took 1.993s
Detection took 1.996s
Detection took 2.021s
Detection took 1.998s
Detection took 1.990s
Detection took 1.990s

it is so slowly.where did I make a mistake? or which configuration is not correct?
(SWIG and Python version follows readme.md instructions)how can I solve this slowly problem ?if it run slowly on my alienware laptop ,how can I try it on PI?

4\if cfg file is tiny-yolo.cfg & tiny-yolo.weights, then darknetDemo.py crashed at modelhelpler.py's function 'get_top_n' in first cycle:

if (not os.path.exists('data/tinyyolo.cfg')):
print("Please download the 'darknet.cfg' file, see README.md")
sys.exit(1)
if (not os.path.exists('data/tinyyolo.weights')):
print("Please download the 'darknet.weights' file, see README.md")
sys.exit(1)
helper = mh.ModelHelper("darknetReference", ["data/tinyyolo.cfg", "data/tinyyolo.weights"], "data/coco.txt",(416,416))

error is:
**Detection took 6.795s
Traceback (most recent call last):
File "darknetDemo.py", line 77, in
main()
File "darknetDemo.py", line 60, in main
top5 = helper.get_top_n(predictions, 5)
File "/home/huimin/projects/Microsoft/ELL/build/tutorials/vision/gettingStarted/modelHelper.py", line 43, in get_top_n
result.append((self.labels[int(element[1])], round(element[0],2)))
IndexError: list index out of range
**

could anyone can tell me what the problems are?

many thanks.

make failed on Raspberry Pi 3B, Raspbian ARMv7

Hi, I'm trying to build an ELL binary on Raspbian ARMv7.
But I got few errors like below.

[ 44%] Building CXX object libraries/nodes/CMakeFiles/nodes.dir/src/BinaryConvolutionalLayerNode.cpp.o
In file included from /root/ELL/libraries/utilities/include/Archiver.h:430:0,
from /root/ELL/libraries/utilities/include/IArchivable.h:11,
from /root/ELL/libraries/utilities/include/UniqueId.h:11,
from /root/ELL/libraries/model/include/Node.h:11,
from /root/ELL/libraries/model/include/Model.h:11,
from /root/ELL/libraries/model/include/IRModelProfiler.h:11,
from /root/ELL/libraries/model/include/CompilableNode.h:11,
from /root/ELL/libraries/nodes/include/NeuralNetworkLayerNode.h:12,
from /root/ELL/libraries/nodes/include/BinaryConvolutionalLayerNode.h:11,
from /root/ELL/libraries/nodes/src/BinaryConvolutionalLayerNode.cpp:9:
/root/ELL/libraries/utilities/include/../tcc/Archiver.tcc: In instantiation of ‘void ell::utilities::Archiver::ArchiveItem(const char*, const std::vector&) [with ValueType = long long unsigned int; typename std::enable_if<std::is_fundamental<typename std::decay<_Tp>::type>::value, int>::type concept = 0]’:
/root/ELL/libraries/utilities/include/../tcc/Archiver.tcc:42:9: required from ‘void ell::utilities::Archiver::Archive(const char*, ValueType&&) [with ValueType = std::vector<long long unsigned int, std::allocator >&]’
/root/ELL/libraries/utilities/include/../tcc/Archiver.tcc:20:9: required from ‘void ell::utilities::Archiver::PropertyArchiver::operator<<(ValueType&&) [with ValueType = std::vector<long long unsigned int, std::allocator >&]’
/root/ELL/libraries/predictors/neural/include/../tcc/BinaryConvolutionalLayer.tcc:294:45: required from ‘void ell::predictors::neural::BinaryConvolutionalLayer::WriteToArchive(ell::utilities::Archiver&) const [with ElementType = double]’
/root/ELL/libraries/nodes/src/BinaryConvolutionalLayerNode.cpp:549:1: required from here
/root/ELL/libraries/utilities/include/../tcc/Archiver.tcc:67:9: error: no matching function for call to ‘ell::utilities::Archiver::ArchiveArray(const char*&, const std::vector<long long unsigned int, std::allocator >&)’
ArchiveArray(name, array);
^~~~~~~~~~~~
In file included from /root/ELL/libraries/utilities/include/IArchivable.h:11:0,
from /root/ELL/libraries/utilities/include/UniqueId.h:11,
from /root/ELL/libraries/model/include/Node.h:11,
from /root/ELL/libraries/model/include/Model.h:11,
from /root/ELL/libraries/model/include/IRModelProfiler.h:11,
from /root/ELL/libraries/model/include/CompilableNode.h:11,
from /root/ELL/libraries/nodes/include/NeuralNetworkLayerNode.h:12,
from /root/ELL/libraries/nodes/include/BinaryConvolutionalLayerNode.h:11,
from /root/ELL/libraries/nodes/src/BinaryConvolutionalLayerNode.cpp:9:
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const std::vector&, ell::utilities::IsFundamental)
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:200:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(bool);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: no known conversion for argument 2 from ‘const std::vector<long long unsigned int, std::allocator >’ to ‘const std::vector&’
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:200:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(bool);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const std::vector&, ell::utilities::IsFundamental)
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:201:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(char);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: no known conversion for argument 2 from ‘const std::vector<long long unsigned int, std::allocator >’ to ‘const std::vector&’
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:201:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(char);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const std::vector&, ell::utilities::IsFundamental)
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:202:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(short);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: no known conversion for argument 2 from ‘const std::vector<long long unsigned int, std::allocator >’ to ‘const std::vector&’
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:202:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(short);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const std::vector&, ell::utilities::IsFundamental)
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:203:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(int);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: no known conversion for argument 2 from ‘const std::vector<long long unsigned int, std::allocator >’ to ‘const std::vector&’
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:203:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(int);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const std::vector&, ell::utilities::IsFundamental)
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:204:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(size_t);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: no known conversion for argument 2 from ‘const std::vector<long long unsigned int, std::allocator >’ to ‘const std::vector&’
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:204:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(size_t);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const std::vector&, ell::utilities::IsFundamental)
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:205:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(int64_t);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: no known conversion for argument 2 from ‘const std::vector<long long unsigned int, std::allocator >’ to ‘const std::vector’
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:205:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(int64_t);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const std::vector&, ell::utilities::IsFundamental)
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:209:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(float);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: no known conversion for argument 2 from ‘const std::vector<long long unsigned int, std::allocator >’ to ‘const std::vector&’
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:209:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(float);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const std::vector&, ell::utilities::IsFundamental)
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:210:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(double);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:69:55: note: no known conversion for argument 2 from ‘const std::vector<long long unsigned int, std::allocator >’ to ‘const std::vector&’
#define DECLARE_ARCHIVE_ARRAY_BASE(type) virtual void ArchiveArray(const char* name, const std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:210:9: note: in expansion of macro ‘DECLARE_ARCHIVE_ARRAY_BASE’
DECLARE_ARCHIVE_ARRAY_BASE(double);
^~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:211:22: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const std::vector<std::__cxx11::basic_string >&)
virtual void ArchiveArray(const char* name, const std::vectorstd::string& array) = 0;
^~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:211:22: note: no known conversion for argument 2 from ‘const std::vector<long long unsigned int, std::allocator >’ to ‘const std::vector<std::__cxx11::basic_string >&’
/root/ELL/libraries/utilities/include/Archiver.h:212:22: note: candidate: virtual void ell::utilities::Archiver::ArchiveArray(const char*, const string&, const std::vector<const ell::utilities::IArchivable*>&)
virtual void ArchiveArray(const char* name, const std::string& baseTypeName, const std::vector<const IArchivable*>& array) = 0;
^~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:212:22: note: candidate expects 3 arguments, 2 provided
In file included from /root/ELL/libraries/utilities/include/Archiver.h:430:0,
from /root/ELL/libraries/utilities/include/IArchivable.h:11,
from /root/ELL/libraries/utilities/include/UniqueId.h:11,
from /root/ELL/libraries/model/include/Node.h:11,
from /root/ELL/libraries/model/include/Model.h:11,
from /root/ELL/libraries/model/include/IRModelProfiler.h:11,
from /root/ELL/libraries/model/include/CompilableNode.h:11,
from /root/ELL/libraries/nodes/include/NeuralNetworkLayerNode.h:12,
from /root/ELL/libraries/nodes/include/BinaryConvolutionalLayerNode.h:11,
from /root/ELL/libraries/nodes/src/BinaryConvolutionalLayerNode.cpp:9:
/root/ELL/libraries/utilities/include/../tcc/Archiver.tcc: In instantiation of ‘void ell::utilities::Unarchiver::UnarchiveItem(const char*, std::vector&) [with ValueType = long long unsigned int; typename std::enable_if<std::is_fundamental<typename std::decay<_Tp>::type>::value, int>::type concept = 0]’:
/root/ELL/libraries/utilities/include/../tcc/Archiver.tcc:129:9: required from ‘void ell::utilities::Unarchiver::Unarchive(const char*, ValueType&&) [with ValueType = std::vector<long long unsigned int, std::allocator >&]’
/root/ELL/libraries/utilities/include/../tcc/Archiver.tcc:108:9: required from ‘void ell::utilities::Unarchiver::PropertyUnarchiver::operator>>(ValueType&&) [with ValueType = std::vector<long long unsigned int, std::allocator >&]’
/root/ELL/libraries/predictors/neural/include/../tcc/BinaryConvolutionalLayer.tcc:322:45: required from ‘void ell::predictors::neural::BinaryConvolutionalLayer::ReadFromArchive(ell::utilities::Unarchiver&) [with ElementType = double]’
/root/ELL/libraries/nodes/src/BinaryConvolutionalLayerNode.cpp:549:1: required from here
/root/ELL/libraries/utilities/include/../tcc/Archiver.tcc:184:9: error: no matching function for call to ‘ell::utilities::Unarchiver::UnarchiveArray(const char*&, std::vector<long long unsigned int, std::allocator >&)’
UnarchiveArray(name, arr);
^~~~~~~~~~~~~~
In file included from /root/ELL/libraries/utilities/include/IArchivable.h:11:0,
from /root/ELL/libraries/utilities/include/UniqueId.h:11,
from /root/ELL/libraries/model/include/Node.h:11,
from /root/ELL/libraries/model/include/Model.h:11,
from /root/ELL/libraries/model/include/IRModelProfiler.h:11,
from /root/ELL/libraries/model/include/CompilableNode.h:11,
from /root/ELL/libraries/nodes/include/NeuralNetworkLayerNode.h:12,
from /root/ELL/libraries/nodes/include/BinaryConvolutionalLayerNode.h:11,
from /root/ELL/libraries/nodes/src/BinaryConvolutionalLayerNode.cpp:9:
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: candidate: virtual void ell::utilities::Unarchiver::UnarchiveArray(const char*, std::vector&, ell::utilities::IsFundamental)
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:327:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(bool);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: no known conversion for argument 2 from ‘std::vector<long long unsigned int, std::allocator >’ to ‘std::vector&’
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:327:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(bool);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: candidate: virtual void ell::utilities::Unarchiver::UnarchiveArray(const char*, std::vector&, ell::utilities::IsFundamental)
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:328:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(char);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: no known conversion for argument 2 from ‘std::vector<long long unsigned int, std::allocator >’ to ‘std::vector&’
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:328:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(char);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: candidate: virtual void ell::utilities::Unarchiver::UnarchiveArray(const char*, std::vector&, ell::utilities::IsFundamental)
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:329:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(short);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: no known conversion for argument 2 from ‘std::vector<long long unsigned int, std::allocator >’ to ‘std::vector&’
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:329:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(short);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: candidate: virtual void ell::utilities::Unarchiver::UnarchiveArray(const char*, std::vector&, ell::utilities::IsFundamental)
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:330:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(int);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: no known conversion for argument 2 from ‘std::vector<long long unsigned int, std::allocator >’ to ‘std::vector&’
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:330:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(int);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: candidate: virtual void ell::utilities::Unarchiver::UnarchiveArray(const char*, std::vector&, ell::utilities::IsFundamental)
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:331:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(size_t);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: no known conversion for argument 2 from ‘std::vector<long long unsigned int, std::allocator >’ to ‘std::vector&’
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:331:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(size_t);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: candidate: virtual void ell::utilities::Unarchiver::UnarchiveArray(const char*, std::vector&, ell::utilities::IsFundamental)
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:332:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(int64_t);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: no known conversion for argument 2 from ‘std::vector<long long unsigned int, std::allocator >’ to ‘std::vector&’
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:332:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(int64_t);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: candidate: virtual void ell::utilities::Unarchiver::UnarchiveArray(const char*, std::vector&, ell::utilities::IsFundamental)
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:336:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(float);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: no known conversion for argument 2 from ‘std::vector<long long unsigned int, std::allocator >’ to ‘std::vector&’
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:336:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(float);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: candidate: virtual void ell::utilities::Unarchiver::UnarchiveArray(const char*, std::vector&, ell::utilities::IsFundamental)
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:337:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(double);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:241:57: note: no known conversion for argument 2 from ‘std::vector<long long unsigned int, std::allocator >’ to ‘std::vector&’
#define DECLARE_UNARCHIVE_ARRAY_BASE(type) virtual void UnarchiveArray(const char* name, std::vector& value, IsFundamental dummy = 0) = 0;
^
/root/ELL/libraries/utilities/include/Archiver.h:337:9: note: in expansion of macro ‘DECLARE_UNARCHIVE_ARRAY_BASE’
DECLARE_UNARCHIVE_ARRAY_BASE(double);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:338:22: note: candidate: virtual void ell::utilities::Unarchiver::UnarchiveArray(const char*, std::vector<std::__cxx11::basic_string >&)
virtual void UnarchiveArray(const char* name, std::vectorstd::string& array) = 0;
^~~~~~~~~~~~~~
/root/ELL/libraries/utilities/include/Archiver.h:338:22: note: no known conversion for argument 2 from ‘std::vector<long long unsigned int, std::allocator >’ to ‘std::vector<std::__cxx11::basic_string >&’
libraries/nodes/CMakeFiles/nodes.dir/build.make:134: recipe for target 'libraries/nodes/CMakeFiles/nodes.dir/src/BinaryConvolutionalLayerNode.cpp.o' failed
make[2]: *** [libraries/nodes/CMakeFiles/nodes.dir/src/BinaryConvolutionalLayerNode.cpp.o] Error 1
CMakeFiles/Makefile2:1032: recipe for target 'libraries/nodes/CMakeFiles/nodes.dir/all' failed
make[1]: *** [libraries/nodes/CMakeFiles/nodes.dir/all] Error 2
Makefile:94: recipe for target 'all' failed
make: *** [all] Error 2

ELL.py file not found

When I run this command:
python cntkDemo.py

I get this error message:
Could not find './../../../build/interfaces/python/ELL.py', did you follow the ELL Python Binding build instructions?

However when I ran this earlier:
ctest --build-config Debug

100% of the tests passed. Can you let me know how I can obtain this ELL.py file?

On Win10, Visual Studio 2017 community edition.

compile error

platform: Ubuntu 16.04 LTS

compile result:

/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp: In function ‘void ell::nodes::{anonymous}::EmitMatrixMatrixMultiplyBlas(ell::emitters::IRFunctionEmitter&, bool, bool, int, int, int, llvm::Value*, int, llvm::Value*, int, llvm::Value*, int)’:
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp:30:34: error: ‘CBLAS_ORDER’ has not been declared
                 function.Literal(CBLAS_ORDER::CblasRowMajor), // order
                                  ^
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp:31:47: error: ‘CBLAS_TRANSPOSE’ has not been declared
                 function.Literal(transposeA ? CBLAS_TRANSPOSE::CblasTrans : CBLAS_TRANSPOSE::CblasNoTrans), // transposeA
                                               ^
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp:31:77: error: ‘CBLAS_TRANSPOSE’ has not been declared
                 function.Literal(transposeA ? CBLAS_TRANSPOSE::CblasTrans : CBLAS_TRANSPOSE::CblasNoTrans), // transposeA
                                                                             ^
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp:32:47: error: ‘CBLAS_TRANSPOSE’ has not been declared
                 function.Literal(transposeB ? CBLAS_TRANSPOSE::CblasTrans : CBLAS_TRANSPOSE::CblasNoTrans), // transposeB
                                               ^
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp:32:77: error: ‘CBLAS_TRANSPOSE’ has not been declared
                 function.Literal(transposeB ? CBLAS_TRANSPOSE::CblasTrans : CBLAS_TRANSPOSE::CblasNoTrans), // transposeB
                                                                             ^
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp: In instantiation of ‘void ell::nodes::{anonymous}::EmitMatrixMatrixMultiplyBlas(ell::emitters::IRFunctionEmitter&, bool, bool, int, int, int, llvm::Value*, int, llvm::Value*, int, llvm::Value*, int) [with ValueType = double]’:
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp:98:56:   required from ‘void ell::nodes::{anonymous}::EmitMatrixMatrixMultiply(ell::emitters::IRFunctionEmitter&, bool, bool, bool, int, int, int, llvm::Value*, int, llvm::Value*, int, llvm::Value*, int) [with ValueType = double]’
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp:444:52:   required from ‘void ell::nodes::DiagonalConvolutionNode<ValueType>::Compile(ell::model::IRMapCompiler&, ell::emitters::IRFunctionEmitter&) [with ValueType = double]’
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp:500:1:   required from here
/home/liudf/ELL/libraries/nodes/src/ConvolutionalLayerNode.cpp:44:13: error: no matching function for call to ‘std::vector<llvm::Value*, std::allocator<llvm::Value*> >::vector(<brace-enclosed initializer list>)’
             }; // ldc
             ^

Python: No module named 'ELL'

I compiled ELL exactly according to the instructions here without any errors, but when I try to import ELL (or let test.py import ELL) the module cannot be found. Any idea what the problem could be? This is the output from cmake:

-- The C compiler identification is GNU 5.4.0
-- The CXX compiler identification is GNU 5.4.0
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Blas libraries: /usr/lib/libblas.so
-- Blas linker flags:
-- Blas include directories:
-- Using BLAS include path: /usr/include
-- Using BLAS library: /usr/lib/libblas.so
-- Using BLAS DLLs:
-- Found PythonInterp: /home/frederik/anaconda3/envs/ell/bin/python (found version "3.6.1")
-- Found PythonLibs: /home/frederik/anaconda3/envs/ell/lib/libpython3.6m.so (found version "3.6.1")
-- Found SWIG: /usr/local/bin/swig (found suitable version "3.0.12", minimum required is "3.0.12")
-- Creating wrappers for python
-- Creating wrappers for javascript
-- Creating wrappers for xml
-- Using python found at: /home/frederik/anaconda3/envs/ell/bin/python
-- Using python libraries found at: /home/frederik/anaconda3/envs/ell/lib/libpython3.6m.so
-- Creating wrappers for python
-- Configuring done
-- Generating done
-- Build files have been written to: /home/frederik/Documents/dev/experimental/ELL/build

and this is the output from make _ELL_python is also normal; the last lines are:

[ 96%] Linking CXX static library libcommon.a
[ 96%] Built target common
Scanning dependencies of target ELL_common
[ 96%] Built target ELL_common
[ 98%] Swig source
Scanning dependencies of target _ELL_python
[ 98%] Building CXX object interfaces/python/CMakeFiles/_ELL_python.dir/ELLPYTHON_wrap.cxx.o
[100%] Building CXX object interfaces/python/CMakeFiles/_ELL_python.dir/__/common/src/ModelInterface.cpp.o
[100%] Linking CXX shared module _ELL.so
[100%] Built target _ELL_python

But nothing is added to my conda environment in the way of libraries, nor to any other place on disk as far as I can see.

_darknetReference.so generated on RPi, but failed to run compiledDarknetDemo.py

I was able to finish all the steps in tutorial and finally build a _darknetReference.so Python module on RPi 3, but when I run compiledDarknetDemo.py under the conda env, it gives following error messages:

(py34)[root@alarmpi compiled_darknetReference_pi3]# python compiledDarknetDemo.py ~/cat.jpg
Traceback (most recent call last):
File "/root/raspberry-pi/ai/ell-related/compiled_darknetReference_pi3/darknetReference.py", line 14, in swig_import_helper
return importlib.import_module(mname)
File "/root/.miniconda3/envs/py34/lib/python3.4/importlib/init.py", line 109, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 2254, in _gcd_import
File "", line 2237, in _find_and_load
File "", line 2226, in _find_and_load_unlocked
File "", line 1191, in _load_unlocked
File "", line 1161, in _load_backward_compatible
File "", line 539, in _check_name_wrapper
File "", line 1715, in load_module
File "", line 321, in _call_with_frames_removed
ImportError: build/_darknetReference.so: undefined symbol: cblas_sgemm

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "compiledDarknetDemo.py", line 11, in
import darknetReference as model
File "/root/raspberry-pi/ai/ell-related/compiled_darknetReference_pi3/darknetReference.py", line 17, in
_darknetReference = swig_import_helper()
File "/root/raspberry-pi/ai/ell-related/compiled_darknetReference_pi3/darknetReference.py", line 16, in swig_import_helper
return importlib.import_module('_darknetReference')
File "/root/.miniconda3/envs/py34/lib/python3.4/importlib/init.py", line 109, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: build/_darknetReference.so: undefined symbol: cblas_sgemm

And below are the output messages of "cmake .." command on RPi 3 to generate the _darknetReference.so Python module:

(py34)[root@alarmpi build]# cmake ..
-- The C compiler identification is GNU 7.1.1
-- The CXX compiler identification is GNU 7.1.1
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Blas libraries: /usr/lib/libblas.so
-- Blas linker flags:
-- Blas include directories:
-- Using BLAS include path: /usr/include
-- Using BLAS library: /usr/lib/libblas.so
-- Using BLAS DLLs:
-- Found PythonInterp: /root/.miniconda3/envs/py34/bin/python3.4 (found suitable version "3.4.3", minimum required is "3.4")
-- Found PythonLibs: /root/.miniconda3/envs/py34/lib/libpython3.4m.so (found suitable version "3.4.3", minimum required is "3.4")
-- Configuring done
-- Generating done
-- Build files have been written to: /root/raspberry-pi/ai/ell-related/compiled_darknetReference_pi3/build

Could anyone tell me what am I missing?
Thanks a lot.

Instructions to build

I have a clarification to make:
Looking at the instructions here:
https://github.com/Microsoft/ELL/blob/master/INSTALL-Windows.md

After this line NuGet will download the prerequisites into the ELL/external directory.
I have to run:
cmake -G "Visual Studio 15 2017 Win64" -DPROCESSOR_HINT=haswell ..

Do I need to change my directory to external because if I stay in ELL, and run the above command then the file CMakeLists.txt file will not be found.

Also when building the ELL in the build folder:
cmake -G "Visual Studio 14 2015 Win64" -DPROCESSOR_HINT=haswell ..

However since I have Visual Studio 2017 installed, can we also use this instead:
cmake -G "Visual Studio 15 2017 Win64" -DPROCESSOR_HINT=haswell ..

Solve errors like "BlasWrapper.cpp:(.text+0x31): undefined reference to `cblas_scopy'"

Following the install instruction on https://github.com/Microsoft/ELL/blob/master/INSTALL-Ubuntu.md, when cmake .. in ${ELL_HOME}/build folder output errors like the following:

 "libmath.a(BlasWrapper.cpp.o): In function `ell::math::Blas::Copy(int, float const*, int, float*, int)':
BlasWrapper.cpp:(.text+0x31): undefined reference to `cblas_scopy'

Several similar issues has been proposed too. For reference, here is a way worked.

1. Env

1.1. OS: Linux Mint 18.1 Cinnamon 64-bit: Linux kernel 4.4 and Ubuntu 16.04
1.2. ELL git version:

$ git rev-parse HEAD
244273ee64ec9432243a8d0e354d3769b642e502

2. A simple solution

Inspired by https://github.com/Microsoft/ELL/tree/master/interfaces , here is the full commands:

cd ~/Downloads/
wget https://ncu.dl.sourceforge.net/project/swig/swig/swig-3.0.12/swig-3.0.12.tar.gz
cd  /usr/local/share
sudo tar xvf ~/Downloads/swig-3.0.12.tar.gz
cd swig-3.0.12
./configure --without-pcre && make && sudo make install
sudo mv /usr/bin/swig3.0 /usr/bin/swig3.0.bak
sudo ln -s /usr/local/share/swig-3.0.12 /usr/bin/swig3.0

Definitely, this is not a elegant sol to the issues.
All comments/advice are welcomed, pls.

Error while compiling

I'm getting the following error while executing make _ELL_python as per the instructions available at https://github.com/Microsoft/ELL/blob/master/interfaces/README.md

[ 20%] Built target utilities
[ 22%] Built target math
[ 29%] Built target data
[ 31%] Built target evaluators
[ 37%] Built target functions
[ 39%] Building CXX object libraries/model/CMakeFiles/model.dir/src/CompilableNode.cpp.o
In file included from /home/sria91/Development/ELL/libraries/model/include/CompilableNode.h:11:0,
                 from /home/sria91/Development/ELL/libraries/model/src/CompilableNode.cpp:9:
/home/sria91/Development/ELL/libraries/model/include/IRModelProfiler.h:15:26: fatal error: EmitterTypes.h: No such file or directory
compilation terminated.
libraries/model/CMakeFiles/model.dir/build.make:62: recipe for target 'libraries/model/CMakeFiles/model.dir/src/CompilableNode.cpp.o' failed
make[3]: *** [libraries/model/CMakeFiles/model.dir/src/CompilableNode.cpp.o] Error 1
CMakeFiles/Makefile2:707: recipe for target 'libraries/model/CMakeFiles/model.dir/all' failed
make[2]: *** [libraries/model/CMakeFiles/model.dir/all] Error 2
CMakeFiles/Makefile2:2203: recipe for target 'interfaces/python/CMakeFiles/_ELL_python.dir/rule' failed
make[1]: *** [interfaces/python/CMakeFiles/_ELL_python.dir/rule] Error 2
Makefile:584: recipe for target '_ELL_python' failed
make: *** [_ELL_python] Error 2

Kindly help.

How can I use ELL with C++ or C?

Dear ELL developers,
I'm looking for a machine learning library for my embedded system(1.5M RAM) running Nuttx.
I read ELL tutorial and built compiled_darknetReference_aarch64. But it is wrapped with python which will not work on the very primitive environment of Nuttx.
Can you give me some ideas to use it with C or C++?
Thank you.

Fail to run sh compile_darknetReference.sh on Mac OSX Sierra

  • python darknetDemo.py works well.
  • sh compile_darknetReference.sh fails to run on the last step, namely:
    /Users/xxx/anaconda/bin/python darknetReference_setup.py build install running build
  • Here is the error details:
/Users/XXX/ELL/interfaces/common/CallbackInterface.h:28:35: warning: defaulted function
      definitions are a C++11 extension [-Wc++11-extensions]
        virtual ~CallbackBase() = default;
                                  ^
/Users/XXX/ELL/interfaces/common/CallbackInterface.h:55:40: warning: defaulted function
      definitions are a C++11 extension [-Wc++11-extensions]
        virtual ~CallbackForwarder() = default;
                                       ^
In file included from darknetReference_wrap.cpp:6144:
./darknetReference_wrap.h:22:13: error: exception specification of overriding function is more lax than base version
    virtual ~SwigDirector_DoubleCallbackBase();
            ^
/Users/XXX/ELL/interfaces/common/CallbackInterface.h:28:17: note: overridden virtual function is
      here
        virtual ~CallbackBase() = default;
                ^
In file included from darknetReference_wrap.cpp:6144:
./darknetReference_wrap.h:64:13: error: exception specification of overriding function is more lax than base version
    virtual ~SwigDirector_FloatCallbackBase();
            ^
/Users/XXX/ELL/interfaces/common/CallbackInterface.h:28:17: note: overridden virtual function is
      here
        virtual ~CallbackBase() = default;
                ^

Compiling models for other targets

Hi everybody!

I was able to go through all examples without problems. But when I tried the examples from ELL/examples/compiled_code, I neither had a Release directory nor a compile command. Do I have to install any further dependencies to make it work or do I oversee something?
Thanks for your help! Great work you guys are doing here!

error on ubuntu 16.04 x64

hi,i build ell on ubuntu x64 , i fllow the install tutorial,i can start build ,but one error arise when it compile 64%:
[ 63%] Building CXX object libraries/common/CMakeFiles/common_test.dir/test/src/LoadDataset_test.cpp.o
[ 63%] Building CXX object libraries/common/CMakeFiles/common_test.dir/test/src/LoadMap_test.cpp.o
[ 64%] Building CXX object libraries/common/CMakeFiles/common_test.dir/test/src/LoadModel_test.cpp.o
[ 64%] Linking CXX executable common_test
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Copy(int, float const*, int, float*, int)’中:
BlasWrapper.cpp:(.text+0x31):对‘cblas_scopy’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Copy(int, double const*, int, double*, int)’中:
BlasWrapper.cpp:(.text+0x69):对‘cblas_dcopy’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Asum(int, float const*, int)’中:
BlasWrapper.cpp:(.text+0x92):对‘cblas_sasum’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Asum(int, double const*, int)’中:
BlasWrapper.cpp:(.text+0xba):对‘cblas_dasum’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Nrm2(int, float const*, int)’中:
BlasWrapper.cpp:(.text+0xf0):对‘cblas_snrm2’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Nrm2(int, double const*, int)’中:
BlasWrapper.cpp:(.text+0x118):对‘cblas_dnrm2’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Scal(int, float, float*, int)’中:
BlasWrapper.cpp:(.text+0x15b):对‘cblas_sscal’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Scal(int, double, double*, int)’中:
BlasWrapper.cpp:(.text+0x193):对‘cblas_dscal’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Axpy(int, float, float const*, int, float*, int)’中:
BlasWrapper.cpp:(.text+0x1d9):对‘cblas_saxpy’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Axpy(int, double, double const*, int, double*, int)’中:
BlasWrapper.cpp:(.text+0x221):对‘cblas_daxpy’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Dot(int, float const*, int, float const*, int)’中:
BlasWrapper.cpp:(.text+0x259):对‘cblas_sdot’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Dot(int, double const*, int, double const*, int)’中:
BlasWrapper.cpp:(.text+0x290):对‘cblas_ddot’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Gemv(CBLAS_LAYOUT, CBLAS_TRANSPOSE, int, int, float, float const*, int, float const*, int, float, float*, int)’中:
BlasWrapper.cpp:(.text+0x309):对‘cblas_sgemv’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Gemv(CBLAS_LAYOUT, CBLAS_TRANSPOSE, int, int, double, double const*, int, double const*, int, double, double*, int)’中:
BlasWrapper.cpp:(.text+0x37c):对‘cblas_dgemv’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Gemm(CBLAS_LAYOUT, CBLAS_TRANSPOSE, CBLAS_TRANSPOSE, int, int, int, float, float const*, int, float const*, int, float, float*, int)’中:
BlasWrapper.cpp:(.text+0x3f5):对‘cblas_sgemm’未定义的引用
../math/libmath.a(BlasWrapper.cpp.o):在函数‘ell::math::Blas::Gemm(CBLAS_LAYOUT, CBLAS_TRANSPOSE, CBLAS_TRANSPOSE, int, int, int, double, double const*, int, double const*, int, double, double*, int)’中:
BlasWrapper.cpp:(.text+0x471):对‘cblas_dgemm’未定义的引用
collect2: error: ld returned 1 exit status
libraries/common/CMakeFiles/common_test.dir/build.make:190: recipe for target 'libraries/common/common_test' failed
make[2]: *** [libraries/common/common_test] Error 1
CMakeFiles/Makefile2:264: recipe for target 'libraries/common/CMakeFiles/common_test.dir/all' failed
make[1]: *** [libraries/common/CMakeFiles/common_test.dir/all] Error 2
Makefile:94: recipe for target 'all' failed
make: *** [all] Error 2

I have already installed openblas。

python cntkDemo.py error on Ubuntu 14.04

When running command python cntkDemo.py on Ubuntu 14.04, I got following errors:

OpenBLAS : Your OS does not support AVX instructions. OpenBLAS is using Nehalem kernels as a fallback, which may give poorer performance.
Traceback (most recent call last):
File "/home/codelast/.miniconda3/envs/py36/lib/python3.6/site-packages/cntk/cntk_py.py", line 18, in swig_import_helper
return importlib.import_module(mname)
File "/home/codelast/.miniconda3/envs/py36/lib/python3.6/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 978, in _gcd_import
File "", line 961, in _find_and_load
File "", line 948, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'cntk._cntk_py'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "cntkDemo.py", line 7, in
import cntk_to_ell
File "./../../../../build/tools/importers/CNTK/cntk_to_ell.py", line 17, in
from cntk.layers import Convolution, MaxPooling, AveragePooling, Dropout, BatchNormalization, Dense
File "/home/codelast/.miniconda3/envs/py36/lib/python3.6/site-packages/cntk/init.py", line 10, in
from . import cntk_py
File "/home/codelast/.miniconda3/envs/py36/lib/python3.6/site-packages/cntk/cntk_py.py", line 21, in
_cntk_py = swig_import_helper()
File "/home/codelast/.miniconda3/envs/py36/lib/python3.6/site-packages/cntk/cntk_py.py", line 20, in swig_import_helper
return importlib.import_module('_cntk_py')
File "/home/codelast/.miniconda3/envs/py36/lib/python3.6/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
ImportError: libmpi_cxx.so.1: cannot open shared object file: No such file or directory

And before that, I've successfully executed the following steps as the doc asked:

(1) make ELL
(2) generate Python bindings & run the test, below are my output:

OpenBLAS : Your OS does not support AVX instructions. OpenBLAS is using Nehalem kernels as a fallback, which may give poorer performance.
Testing HingeLoss.Evaluate(2, 1) ... Passed
Testing HingeLoss.Evaluate(-2, -1) ... Passed
Testing HingeLoss.Evaluate(2, -1) ... Passed
Testing HingeLoss.Evaluate(-2, 1) ... Passed
Testing HingeLoss.Evaluate(0, 1) ... Passed
Testing HingeLoss.Evaluate(0, -1) ... Passed
Testing HingeLoss.GetDerivative(2, 1) ... Passed
Testing HingeLoss.GetDerivative(-2, -1) ... Passed
Testing HingeLoss.GetDerivative(2, -1) ... Passed
Testing HingeLoss.GetDerivative(-2, 1) ... Passed
Testing HingeLoss.GetDerivative(0, 1) ... Passed
Testing HingeLoss.GetDerivative(0, -1) ... Passed
Testing LogLoss.Evaluate(2, 1) ... Passed
Testing LogLoss.Evaluate(-2, -1) ... Passed
Testing LogLoss.Evaluate(2, -1) ... Passed
Testing LogLoss.Evaluate(-2, 1) ... Passed
Testing LogLoss.Evaluate(0, 1) ... Passed
Testing LogLoss.Evaluate(0, -1) ... Passed
Testing LogLoss.GetDerivative(2, 1) ... Passed
Testing LogLoss.GetDerivative(-2, -1) ... Passed
Testing LogLoss.GetDerivative(2, -1) ... Passed
Testing LogLoss.GetDerivative(-2, 1) ... Passed
Testing LogLoss.GetDerivative(0, 1) ... Passed
Testing LogLoss.GetDerivative(0, -1) ... Passed
Testing SquaredLoss.Evaluate(4, 4) ... Passed
Testing SquaredLoss.Evaluate(4, 2) ... Passed
Testing SquaredLoss.Evaluate(2, 4) ... Passed
Testing SquaredLoss.GetDerivative(4, 4) ... Passed
Testing SquaredLoss.GetDerivative(4, 2) ... Passed
Testing SquaredLoss.GetDerivative(2, 4) ... Passed
functions_test passed
[1] One subgraph
Subgraph Vertices Edges Cycles
0 6 8 3
[2] One subgraph
Subgraph Vertices Edges Cycles
0 6 6 1
[3] One subgraph
Subgraph Vertices Edges Cycles
0 8 11 4
[tree_0] One subgraph
Subgraph Vertices Edges Cycles
0 17 18 2
[tree_1] One subgraph
Subgraph Vertices Edges Cycles
0 45 54 10
[tree_2] One subgraph
Subgraph Vertices Edges Cycles
0 73 90 18
[tree_3] One subgraph
Subgraph Vertices Edges Cycles
0 101 126 26
model_test passed
Model 1 size: 6
Model 2 size: 6
Model 3 size: 8
Tree 0 size: 17
Tree 1 size: 45
Tree 2 size: 73
Tree 3 size: 101
Loading file ../../../examples/data/model_1.model
Loading file ../../../examples/data/model_2.model
common_test passed
trainers_test.test -- TBD
trainers_test passed
predictors_test.test -- TBD
predictors_test passed
nodes_test.test -- TBD
nodes_test passed
linear_test.test -- TBD
linear_test passed
evaluators_test.test -- TBD
evaluators_test passed
Testing ModelBuilder ... Passed
modelbuilder_test passed

(3) install CNTK python packages:

(py36) [codelast@ gettingStarted]$ pip install https://cntk.ai/PythonWheel/CPU-Only/cntk-2.0-cp36-cp36m-linux_x86_64.whl
Requirement already satisfied: cntk==2.0 from https://cntk.ai/PythonWheel/CPU-Only/cntk-2.0-cp36-cp36m-linux_x86_64.whl in /home/codelast/.miniconda3/envs/py36/lib/python3.6/site-packages
Requirement already satisfied: numpy>=1.11 in /home/codelast/.miniconda3/envs/py36/lib/python3.6/site-packages (from cntk==2.0)
Requirement already satisfied: scipy>=0.17 in /home/codelast/.miniconda3/envs/py36/lib/python3.6/site-packages (from cntk==2.0)

(4) download the CNTK ImageNet reference model

curl -O https://www.cntk.ai/Models/Caffe_Converted/VGG16_ImageNet_Caffe.model

So, could anyone give me a hint on how to solve the problem? Thanks a lot.

Doesn't build on a OSX Sierra Imac.

I already have llvm installed. and get the following.

c-2%
Peters-iMac-2%
Peters-iMac-2% make
[ 0%] Built target documentation
[ 11%] Built target utilities
[ 12%] Built target math
[ 15%] Built target data
[ 15%] Building CXX object libraries/emitters/CMakeFiles/emitters.dir/src/IRAssemblyWriter.cpp.o
In file included from /Users/peter/Projects/ELL/libraries/emitters/src/IRAssemblyWriter.cpp:17:
In file included from /Users/peter/Projects/ELL/libraries/emitters/include/IRModuleEmitter.h:15:
In file included from /Users/peter/Projects/ELL/libraries/emitters/include/IRFunctionEmitter.h:15:
/Users/peter/Projects/ELL/libraries/emitters/include/LLVMInclude.h:12:10: fatal error: 'llvm/Bitcode/ReaderWriter.h'
file not found
#include "llvm/Bitcode/ReaderWriter.h"
^
1 error generated.
make[2]: *** [libraries/emitters/CMakeFiles/emitters.dir/src/IRAssemblyWriter.cpp.o] Error 1
make[1]: *** [libraries/emitters/CMakeFiles/emitters.dir/all] Error 2
make: *** [all] Error 2
Peters-iMac-2%

python cntkDemo.py error: OpenCV Error: Unspecified error in cvShowImage

I was able to successfully finish all the steps before running python cntkDemo.py on my Ubuntu 14.04, and failed after a long time running python cntkDemo.py:

OpenBLAS : Your OS does not support AVX instructions. OpenBLAS is using Nehalem kernels as a fallback, which may give poorer performance.
Loading...
Selected CPU as the process wide default device.

Finished loading.
Pre-processing...

Will not process Dropout - skipping this layer as irrelevant.
Will not process Dropout - skipping this layer as irrelevant.
Will not process Combine - skipping this layer as irrelevant.
Convolution : 226x226x3 -> 224x224x64 | padding 1
ReLU : 224x224x64 -> 226x226x64 | padding 0
......
Softmax : 1x1x1000 -> 1x1x1000 | padding 0

Finished pre-processing.

Constructing equivalent ELL layers from CNTK...
Converting layer conv1_1: Convolution(data: Tensor[3,224,224]) -> Tensor[64,224,224]
......
Converting layer prob: Softmax(fc8: Tensor[1000]) -> Tensor[1000]

...Finished constructing ELL layers.
OpenCV Error: Unspecified error (The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script) in cvShowImage, file /feedstock_root/build_artefacts/opencv_1490907195496/work/opencv-3.2.0/modules/highgui/src/window.cpp, line 583
Traceback (most recent call last):
File "cntkDemo.py", line 68, in
main()
File "cntkDemo.py", line 61, in main
cv2.imshow('frame', frameToShow)
cv2.error: /feedstock_root/build_artefacts/opencv_1490907195496/work/opencv-3.2.0/modules/highgui/src/window.cpp:583: error: (-2) The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function cvShowImage

It seems that the error occurred when the program tried to pop up a window on Ubuntu.
I followed the instruction in the error message(install libgtk2.0-dev and pkg-config, and re-cmake, re-make ELL), but the problem still exists.

Hope I can get some help from anyone, thanks a lot.

common_test failed

While running test.py (in build/interfaces/python/test), all tests appear to pass but common_test. Built on Ubuntu 16.04.

ELL/build/interfaces/python/test$ python test.py
Testing HingeLoss.Evaluate(2, 1) ... Passed
Testing HingeLoss.Evaluate(-2, -1) ... Passed
Testing HingeLoss.Evaluate(2, -1) ... Passed
Testing HingeLoss.Evaluate(-2, 1) ... Passed
Testing HingeLoss.Evaluate(0, 1) ... Passed
Testing HingeLoss.Evaluate(0, -1) ... Passed
Testing HingeLoss.GetDerivative(2, 1) ... Passed
Testing HingeLoss.GetDerivative(-2, -1) ... Passed
Testing HingeLoss.GetDerivative(2, -1) ... Passed
Testing HingeLoss.GetDerivative(-2, 1) ... Passed
Testing HingeLoss.GetDerivative(0, 1) ... Passed
Testing HingeLoss.GetDerivative(0, -1) ... Passed
Testing LogLoss.Evaluate(2, 1) ... Passed
Testing LogLoss.Evaluate(-2, -1) ... Passed
Testing LogLoss.Evaluate(2, -1) ... Passed
Testing LogLoss.Evaluate(-2, 1) ... Passed
Testing LogLoss.Evaluate(0, 1) ... Passed
Testing LogLoss.Evaluate(0, -1) ... Passed
Testing LogLoss.GetDerivative(2, 1) ... Passed
Testing LogLoss.GetDerivative(-2, -1) ... Passed
Testing LogLoss.GetDerivative(2, -1) ... Passed
Testing LogLoss.GetDerivative(-2, 1) ... Passed
Testing LogLoss.GetDerivative(0, 1) ... Passed
Testing LogLoss.GetDerivative(0, -1) ... Passed
Testing SquaredLoss.Evaluate(4, 4) ... Passed
Testing SquaredLoss.Evaluate(4, 2) ... Passed
Testing SquaredLoss.Evaluate(2, 4) ... Passed
Testing SquaredLoss.GetDerivative(4, 4) ... Passed
Testing SquaredLoss.GetDerivative(4, 2) ... Passed
Testing SquaredLoss.GetDerivative(2, 4) ... Passed
functions_test passed
[1] One subgraph
Subgraph Vertices Edges Cycles
0 6 8 3
[2] One subgraph
Subgraph Vertices Edges Cycles
0 6 6 1
[3] One subgraph
Subgraph Vertices Edges Cycles
0 8 11 4
[tree_0] One subgraph
Subgraph Vertices Edges Cycles
0 17 18 2
[tree_1] One subgraph
Subgraph Vertices Edges Cycles
0 45 54 10
[tree_2] One subgraph
Subgraph Vertices Edges Cycles
0 73 90 18
[tree_3] One subgraph
Subgraph Vertices Edges Cycles
0 101 126 26
model_test passed
Model 1 size: 6
Model 2 size: 6
Model 3 size: 8
Tree 0 size: 17
Tree 1 size: 45
Tree 2 size: 73
Tree 3 size: 101
Loading file ../../../examples/data/model_1.model
common_test failed
trainers_test.test -- TBD
trainers_test passed
predictors_test.test -- TBD
predictors_test passed
nodes_test.test -- TBD
nodes_test passed
linear_test.test -- TBD
linear_test passed
evaluators_test.test -- TBD
evaluators_test passed
Testing ModelBuilder ... Passed
modelbuilder_test passed

Can't compile in Ubuntu 16.04

I get the following error:-
sXXX@sXXX:~/Downloads/ELL/build$ make
[ 0%] Built target documentation
[ 10%] Built target utilities
[ 11%] Built target math
[ 15%] Built target data
[ 24%] Built target emitters
[ 26%] Built target evaluators
[ 29%] Built target functions
[ 39%] Built target model
[ 41%] Built target predictors
[ 51%] Built target nodes
[ 55%] Built target trainers
[ 62%] Built target common
[ 63%] Built target testing
[ 63%] Linking CXX executable common_test
libcommon.a(LoadModel.cpp.o): In function ell::model::SteppableMap<std::chrono::_V2::system_clock>::WriteToArchive(ell::utilities::Archiver&) const': LoadModel.cpp:(.text._ZNK3ell5model12SteppableMapINSt6chrono3_V212system_clockEE14WriteToArchiveERNS_9utilities8ArchiverE[_ZNK3ell5model12SteppableMapINSt6chrono3_V212system_clockEE14WriteToArchiveERNS_9utilities8ArchiverE]+0x7e): undefined reference to ell::utilities::Archiver::operator[](std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&)'
LoadModel.cpp:(.text._ZNK3ell5model12SteppableMapINSt6chrono3_V212system_clockEE14WriteToArchiveERNS_9utilities8ArchiverE[_ZNK3ell5model12SteppableMapINSt6chrono3_V212system_clockEE14WriteToArchiveERNS_9utilities8ArchiverE]+0x112): undefined reference to ell::utilities::Archiver::operator[](std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)' libcommon.a(LoadModel.cpp.o): In function ell::model::SteppableMapstd::chrono::_V2::system_clock::ReadFromArchive(ell::utilities::Unarchiver&)':
...

I think I have installed all pre-requisites. The output of cmake is:-

-- Blas libraries: /usr/lib/libblas.so
-- Blas linker flags:
-- Blas include directories: /usr/include
-- Using BLAS include path: /usr/include
-- Using BLAS library: /usr/lib/libblas.so
-- Using BLAS DLLs:
-- Creating wrappers for python
-- Creating wrappers for javascript
-- Creating wrappers for xml
-- Using python found at: /home/sXXX/anaconda3/bin/python
-- Using python libraries found at: /home/sXXX/anaconda3/lib/libpython3.5m.so
-- Creating wrappers for python
-- Configuring done
-- Generating done
-- Build files have been written to: /home/sXXX/Downloads/ELL/build

Thanks!

compile_darknetReference.cmd fails with cl.exe

I'm trying to complete the tutorial to run off my Raspberry Pi and compile_darknetReference.cmd is failing on swigging darknetReference.i to darknetReference_wrap.cpp, if I don't specify anything it comes back with a file not found error; if I set a path folder containing cl.exe it comes up with
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\bin\\x86_amd64\\cl.exe' failed with exit status -1073741515
I tried with different options for example x64_x86 and I still get the same result, any pointers or guidance?

Thanks
--Rp

Not Found Image Errors Traceback When Trying To Execute `python darknetDemo.py`

(py36) ➜  gettingStarted git:(master) python darknetDemo.py
Traceback (most recent call last):
  File "darknetDemo.py", line 4, in <module>
    import cv2
ImportError: dlopen(/Users/yoge/miniconda2/envs/py36/lib/python3.6/site-packages/cv2.cpython-36m-darwin.so, 2): Library not loaded: @rpath/libopenblasp-r0.2.19.dylib
  Referenced from: /Users/yoge/miniconda2/envs/py36/lib/libopencv_hdf.3.2.0.dylib
  Reason: image not found

keras model importer?

In the tools/importer, there is CNTK and Darknet only. Keras is one of most popular toolkit, any plans or suggestions on how to import models trained using Keras?

Can't install Miniconda

Following these steps:

wget http://repo.continuum.io/miniconda/Miniconda3-latest-Linux-armv7l.sh
chmod +x Miniconda3-latest-Linux-armv7l.sh
./Miniconda3-latest-Linux-armv7l.sh

I get to License Agreement and after I enter 'yes', I just get a series of 'y' repeating to infinity. Help?

y
y
y
y
y
y
y

Error importing ELL (.\interfaces\python\test\test.py)

Hello,

I am able to build both ELL and interfaces on Windows, however, when I try to run tests on python it comes back with an error, is not able to load ELL
Traceback (most recent call last): File "test.py", line 9, in <module> import ELL File "./..\ELL.py", line 17, in <module> _ELL = swig_import_helper() File "./..\ELL.py", line 16, in swig_import_helper return importlib.import_module('_ELL') File "C:\Users\ROBEP\AppData\Local\Continuum\Miniconda3\lib\importlib\__init__.py", line 126, in import_module return _bootstrap._gcd_import(name[level:], package, level) ImportError: DLL load failed: The specified module could not be found.

The only reference I couldn't add is glibcc which is not available on the win-64 channel, any ideas on how to solve this?

Thanks!
--Rp

What is SWIG and do I need it.

CMake Warning at CMakeLists.txt:83 (message):
SWIG not found, interfaces and projects that depend on them will not build
properly. They are not part of the default make targets, so can be
skipped. If you want to build interfaces (such as the Python bindings),
follow the instructions in INSTALL-XXXXX.md file to install SWIG. Then
delete the CMakeCache.txt file from your build directory run the cmake
command again.

-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
CMake Warning at interfaces/python/CMakeLists.txt:9 (message):
Couldn't find Python libraries 3.5 or later, _ELL_python target will not be
build properly. This is not a required component, so it can be skipped.

-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
-- Creating wrappers for python
-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
-- Creating wrappers for javascript
-- Found npm at /usr/local/bin/npm
-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
-- Creating wrappers for xml
-- Configuring done
-- Generating done
-- Build files have been written to: /Users/peter/Projects/ELL/build
[ 0%] Built target documentation
[ 11%] Built target utilities
[ 12%] Built target math
[ 15%] Built

failed to build the compiled CNTK model on Raspberry Pi 3 (make process takes a long time)

When builing the compiled CNTK model on Rasberry Pi 3 by this tutorial, I failed to finish the make process.

Here are my steps:
(1) scp the compiled CNTK model to Raspberry Pi 3, unpack it on Pi
(2) cmake under the miniconda environment, output messages are:

-- (py34)[root@alarmpi build]# cmake ..
-- The C compiler identification is GNU 7.1.1
-- The CXX compiler identification is GNU 7.1.1
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Blas libraries: /usr/lib/libblas.so
-- Blas linker flags:
-- Blas include directories:
-- Using BLAS include path: /usr/include
-- Using BLAS library: /usr/lib/libblas.so
-- Using BLAS DLLs:
-- Found PythonInterp: /root/.miniconda3/envs/py34/bin/python3.4 (found suitable version "3.4.3", minimum required is "3.4")
-- Found PythonLibs: /root/.miniconda3/envs/py34/lib/libpython3.4m.so (found suitable version "3.4.3", minimum required is "3.4")
-- Configuring done
-- Generating done
-- Build files have been written to: /root/raspberry-pi/ai/ell-related/compiled_vgg16ImageNet_pi3/build

(3) make and then failed, part of the output messages are:

Scanning dependencies of target _vgg16ImageNet
[ 50%] Building CXX object CMakeFiles/_vgg16ImageNet.dir/vgg16ImageNetPYTHON_wrap.cxx.o
......(TOO MANY MESSAGES, OMIT)
/usr/include/c++/7.1.1/bits/stl_iterator_base_funcs.h: In function ‘typename std::iterator_traits<_Iterator>::difference_type std::__distance(_RandomAccessIterator, _RandomAccessIterator, std::random_access_iterator_tag) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<double*, std::vector<double, std::allocator > >]’:
/usr/include/c++/7.1.1/bits/stl_iterator_base_funcs.h:98:5: note: parameter passing for argument of type ‘__gnu_cxx::__normal_iterator<double*, std::vector<double, std::allocator > >’ changed in GCC 7.1
__distance(_RandomAccessIterator __first, _RandomAccessIterator __last,
^~~~~~~~~~
/usr/include/c++/7.1.1/bits/stl_iterator_base_funcs.h:98:5: note: parameter passing for argument of type ‘__gnu_cxx::__normal_iterator<double*, std::vector<double, std::allocator > >’ changed in GCC 7.1
/usr/include/c++/7.1.1/bits/stl_iterator_base_funcs.h: In function ‘typename std::iterator_traits<_Iterator>::difference_type std::__distance(_RandomAccessIterator, _RandomAccessIterator, std::random_access_iterator_tag) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<double*, std::vector<double, std::allocator > >]’:
/usr/include/c++/7.1.1/bits/stl_iterator_base_funcs.h:98:5: note: parameter passing for argument of type ‘__gnu_cxx::__normal_iterator<double*, std::vector<double, std::allocator > >’ changed in GCC 7.1
__distance(_RandomAccessIterator __first, _RandomAccessIterator __last,
^~~~~~~~~~
/usr/include/c++/7.1.1/bits/stl_iterator_base_funcs.h:98:5: note: parameter passing for argument of type ‘__gnu_cxx::__normal_iterator<double*, std::vector<double, std::allocator > >’ changed in GCC 7.1/usr/include/c++/7.1.1/bits/stl_iterator_base_funcs.h: In function ‘typename std::iterator_traits<_Iterator>::difference_type std::__distance(_RandomAccessIterator, _RandomAccessIterator, std::random_access_iterator_tag) [with _RandomAccessIterator = __gnu_cxx::__normal_iterator<double*, std::vector<double, std::allocator > >]’:
/usr/include/c++/7.1.1/bits/stl_iterator_base_funcs.h:98:5: note: parameter passing for argument of type ‘__gnu_cxx::__normal_iterator<double*, std::vector<double, std::allocator > >’ changed in GCC 7.1
__distance(_RandomAccessIterator __first, _RandomAccessIterator __last,
^~~~~~~~~~
/usr/include/c++/7.1.1/bits/stl_iterator_base_funcs.h:98:5: note: parameter passing for argument of type ‘__gnu_cxx::__normal_iterator<double*, std::vector<double, std::allocator > >’ changed in GCC 7.1
[100%] Linking CXX shared library _vgg16ImageNet.so
../vgg16ImageNet.o: file not recognized: File truncated
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/_vgg16ImageNet.dir/build.make:99: _vgg16ImageNet.so] Error 1
make[1]: *** [CMakeFiles/Makefile2:68: CMakeFiles/_vgg16ImageNet.dir/all] Error 2
make: *** [Makefile:84: all] Error 2

BTW, the OS of my Raspberry Pi 3 is:
Arch Linux ARM
(Linux version 4.9.36-1-ARCH (builduser@leming) (gcc version 7.1.1 20170516 (GCC) ) # 1 SMP Fri Jul 7 02:16:47 UTC 2017)

Does anyone know how to solve this problem? Thanks a lot.

No module named 'darknet_to_ell'

I just built everything on my Ubuntu 16.04 box and was going to test the darknet tutorial, but alas! errors.

/build/tutorials/vision/gettingStarted$ python darknetDemo.py
Traceback (most recent call last):
File "darknetDemo.py", line 7, in
import darknet_to_ell
ModuleNotFoundError: No module named 'darknet_to_ell'

My guess is it doesn't know that darknet_to_ell is in /build/tools/importers/darknet
Not sure if this was supposed to be copied in the python build or if it needs to be directed to the correct folder.

SWIG missing...

-- Using BLAS include path: /usr/include
-- Using BLAS library: /usr/lib/libblas.so
-- Using BLAS DLLs:
-- Found PythonInterp: /root/miniconda3/bin/python (found version "3.6.1")
-- Found PythonLibs: /root/miniconda3/lib/libpython3.6m.so (found version "3.6.1")
-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
CMake Warning at CMakeLists.txt:85 (message):
SWIG not found, interfaces and projects that depend on them will not build
properly. They are not part of the default make targets, so can be
skipped. If you want to build interfaces (such as the Python bindings),
follow the instructions in INSTALL-XXXXX.md file to install SWIG. Then
delete the CMakeCache.txt file from your build directory run the cmake
command again.

-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
-- Creating wrappers for python
-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
-- Creating wrappers for javascript
-- Could NOT find SWIG (missing: SWIG_EXECUTABLE SWIG_DIR) (Required is at least version "3.0.12")
-- Creating wrappers for xml
-- Configuring done
-- Generating done
-- Build files have been written to: /root/ELL/build

question:can't make in Ubuntu 14.04

IRExecutionEngine.cpp:(.text+0x532): undefined reference to llvm::EngineBuilder::selectTarget(llvm::Triple const&, llvm::StringRef, llvm::StringRef, llvm::SmallVectorImpl<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > const&)' libemitters.a(IRAssemblyWriter.cpp.o): In function ell::emitters::GenerateMachineCode(llvm::raw_ostream&, ell::emitters::IRModuleEmitter&, llvm::TargetMachine::CodeGenFileType, ell::emitters::MachineCodeOutputOptions const&)':
IRAssemblyWriter.cpp:(.text+0x4d7): undefined reference to llvm::sys::getDefaultTargetTriple[abi:cxx11]()' IRAssemblyWriter.cpp:(.text+0x542): undefined reference to llvm::Triple::normalizeabi:cxx11'
IRAssemblyWriter.cpp:(.text+0x607): undefined reference to `llvm::TargetRegistry::lookupTarget(std::__cxx11::basic_string<char, std::char_traits, std::allocator > const&, llvm::Triple&, std::__cxx11::basic_string<char, std::char_traits, std::allocator >&)'
collect2: error: ld returned 1 exit status
make[2]: *** [libraries/emitters/emitters_test] Error 1
make[1]: *** [libraries/emitters/CMakeFiles/emitters_test.dir/all] Error 2
[ 75%] Linking CXX static library libcommon.a
[ 75%] Built target common
make: *** [all] Error 2
Is there something wrong with LLVM?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.