Q: Not able to install DTW algorithm in DSX's R notebook - data-science-experience

I am trying to install DTW package of R in DSX's R notebook.
when running install command:
install.packages("dtw")
gives following error:
"installation of package ‘dtw’ had non-zero exit status” warning.

Additional output from the installation attempt can be found in the log file for your R kernel. In the R notebook, execute
Sys.getenv("LOG_FILE")
to get the name of the log file. Then open a Python notebook and execute
!cat <name-of-the-log-file>
to see the contents of the log file.
After trying to install dtw, my log file showed:
gcc -std=gnu99 -shared -L/usr/local/lib64 -o dtw.so computeCM.o Launching java with spark-submit command /usr/local/src/spark20master/spark/bin/spark-submit sparkr-shell /gpfs/fs01/user/s10d-7f8820dde34dec-4cf890276e2b/notebook/tmp/RtmpofrZnw/backend_portd1c4793df5e
which looks like garbled log output from two processes writing to the same log file. But a bit further down, I find:
gcc: error: Launching: No such file or directory
gcc: error: java: No such file or directory
gcc: error: with: No such file or directory
gcc: error: spark-submit: No such file or directory
gcc: error: command: No such file or directory
gcc: error: sparkr-shell: No such file or directory
gcc: error: /gpfs/fs01/user/s10d-7f8820dde34dec-4cf890276e2b/notebook/tmp/Rtmpkh93V2/backend_porte8853270b27: No such file or directory
make: *** [dtw.so] Error 1
ERROR: compilation failed for package ‘dtw’
So the garbled line was actually executed. I'd say that the installation logic for the dtw package makes some assumptions about the environment which are not satisfied in DSX.
To dig further into the problem, you'll have to debug the dtw installer, or find somebody who can do that for you.

Related

Bazel Build Permission denied

Recently, I'm trying to learn the NVidia Isaac which is built by Bazel.
While I was following the document here:
https://docs.nvidia.com/isaac/isaac/doc/getting_started.html#running-an-application
I encountered an error kept saying the cpp files Bazel need to build is "Permission denied".
The error message looks like below:
Use --sandbox_debug to see verbose messages from the sandbox
gcc: error: engine/alice/components/Subprocess.cpp: Permission denied
gcc: fatal error: no input files
compilation terminated.
ERROR: /home/acas/HDD/CatDog/Isaak/engine/alice/BUILD:23:1: Couldn't build file engine/alice/_objs/impl/ReplayBridge.o: C++ compilation of rule '//engine/alice:impl' faed (Exit 1) crosstool_wrapper_driver_is_not_gcc_host.py failed: error executing command external/toolchain/crosstool/scripts/crosstool_wrapper_driver_is_not_gcc_host.pyD_DEFAULT_SOURCE -U_FORTIFY_SOURCE -fstack-protector -Wall -Werror -B/usr/bin -Wunused-but-set-parameter ... (remaining 183 argument(s) skipped)
Use --sandbox_debug to see verbose messages from the sandbox
gcc: error: engine/alice/components/ReplayBridge.cpp: Permission denied
gcc: fatal error: no input files
compilation terminated.
ERROR: /home/acas/HDD/CatDog/Isaak/engine/gems/image/BUILD:42:1: Couldn't build file engine/gems/image/_objs/cuda_conversions/yuv2rgb.cu.o: error while parsing .d file:root/.cache/bazel/_bazel_root/6ab44b9a455585caa8f9f5f55ddd002b/execroot/com_nvidia_isaac/bazel-out/k8-opt/bin/engine/gems/image/_objs/cuda_conversions/yuv2rgb.cu.d (No ch file or directory)
gcc: error: engine/gems/image/cuda/yuv2rgb.cu.cpp: Permission denied
gcc: warning: '-x c++' after last input file has no effect
gcc: fatal error: no input files
compilation terminated.
Target //apps/samples/stereo_dummy:stereo_dummy failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 6.627s, Critical Path: 0.62s, Remote (0.00% of the time): [queue: 0.00%, setup: 0.00%, process: 0.00%]
INFO: 0 processes.
FAILED: Build did NOT complete successfully
And so much the same "Permission denied" error.
I've tried root, sudo, but none of that works.
Is anyone has the same Bazel problem (I think this problem is not about NVidia Isaac but Bazel)?

fatal error: openssl/ssl.h: No such file or directory

I'm coming from Python and new to C++ and am trying to test a program which retrieves data via websockets.
I copied this github repository with
git clone https://github.com/tensaix2j/binacpp
I'm trying to run the example so I filled in the api key and secret in:
/binacpp/example/example.cpp
Now from /binacpp/example folder I'm trying
make example
and I'm getting this error:
Making example
g++ -I../lib/libcurl-7.56.0/include -I../lib/jsoncpp-1.8.3/include -I../lib/libwebsockets-2.4.0/include -I../lib/libbinacpp/include \
example.cpp \
-L../lib/libcurl-7.56.0/lib \
-L../lib/libwebsockets-2.4.0/lib \
-L../lib/libbinacpp/lib \
-lcurl -ljsoncpp -lcrypto -lwebsockets -lbinacpp -o example
In file included from ../lib/libbinacpp/include/binacpp_websocket.h:16:0,
from example.cpp:8:
../lib/libwebsockets-2.4.0/include/libwebsockets.h:214:10: fatal error: openssl/ssl.h: No such file or directory
#include <openssl/ssl.h>
^~~~~~~~~~~~~~~
compilation terminated.
Makefile:25: recipe for target 'example' failed
make: *** [example] Error 1
user#ip:/opt/binacpp/example$ ^C
user#ip:/opt/binacpp/example$ ./example.run.sh
./example: error while loading shared libraries: librtmp.so.0: cannot open shared object file: No such file or directory
I'm trying to figure out why I'm getting this error and what to do with it?
1) It says on the readme that the dependencies are
jsoncpp-1.8.3
libcurl-7.56.0
libwebsockets-2.4.0
However these are included in the repository
2) if maybe it is assumed that openssl normally is already installed, how do I know which version to install? And how do I install this, because with Python you can just use pip and everything will be placed in the correct directories for including it in your program.
It looks like that the development package for openssl is not installed:
https://stackoverflow.com/a/3016986/5147260

installing gdal on mac os sierra

I have a Django project that I want to install and it uses GDAL. The documentation refers me to this page in the Django documentation. I have been able to install GEOS and PROJ.4. I wanted to use the latest GDAL which is 2.2.1 and ./configure command failed so I followed this instructions and it compiled. However, make command now fails with the following error
In file included from cpl_odbc.cpp:30:
/Users/DNG/gdal-2.2.1/port/cpl_odbc.h:39:10: fatal error: 'sql.h' file not found
#include <sql.h>
^
1 error generated.
make[1]: *** [cpl_odbc.o] Error 1
make: *** [port-target] Error 2
sudo find / -name sql.h outputs:
find: /dev/fd/DNG: No such file or directory
find: /dev/fd/DNG: No such file or directory
/usr/local/Cellar/unixodbc/2.3.4/include/sql.h
/usr/local/include/sql.h
/usr/local/php5-7.0.18-20170506-095200/include/sql.h

How to compile and run a vmmlib test program?

I have successfully installed vmmlib 1.7 using the following steps:
Downloaded the files from https://github.com/VMML/vmmlib/tree/1.7
and followed the steps below:
mkdir vmmlib/build
cd vmmlib/build
cmake ..
make
Now, I'm trying to run a program in the test folder "t3_hosvd_test.cpp" , but I'm not able to run it.
I tried to run the Makefile but got the following error:
svd_test.cpp:13:0:
../include/vmmlib/vmmlib.hpp:33:30: fatal error: vmmlib/version.hpp: No such file or directory
compilation terminated.
: recipe for target 'svd_test.o' failed
make: *** [svd_test.o] Error 1
I also tried to run by giving the following command in the terminal:
g++ t3_hosvd_test.cpp -lapack -lvmmlib
but got an error:
t3_hosvd_test.cpp:2:31: fatal error: vmmlib/t3_hosvd.hpp: No such file or directory
compilation terminated.
Can someone help me compile and run this program on Ubuntu 16.04?
When compiling directly, you need to provide the include path via the -I option.
g++ t3_hosvd_test.cpp -I/usr/local/vmmlib17/include -lapack -lvmmlib
Also ensure that your include path is set to vmmlib/include and not vmmlib/include/vmmlib

Error building llvm 3.0

I was trying to get llvm 3.0 on my machine, but I get the following errors when I give make -k.
chethan#ubuntu:~/llvm-3.0$ make
make[1]: Entering directory `/home/chethan/llvm-3.0/lib/Support'
llvm[1]: Compiling APFloat.cpp for Release build
In file included from APFloat.cpp:15:
In file included from /home/chethan/llvm-3.0/include/llvm/ADT/APFloat.h:104:
In file included from /home/chethan/llvm-3.0/include/llvm/ADT/APInt.h:18:
In file included from /home/chethan/llvm-3.0/include/llvm/ADT/ArrayRef.h:13:
In file included from /home/chethan/llvm-3.0/include/llvm/ADT/SmallVector.h:17:
/home/chethan/llvm-3.0/include/llvm/Support/type_traits.h:20:10: fatal error: 'utility' file not found
#include <utility>
^
1 error generated.
make[1]: *** [/home/chethan/llvm-3.0/lib/Support/Release/APFloat.o] Error 1
make[1]: Leaving directory `/home/chethan/llvm-3.0/lib/Support'
make: *** [all] Error 1
I follow these steps to build llvm on my machine.
Get the llvm source zip file from llvm download page and unzipped to folder llvm-3.0
cd /home/chethan/llvm-3.0
./configure
make -k
Although in this case, I just gave 'make' so that it stops on first error. I have llvm-gcc 4.2 installed on my machine.
I followed the same steps today morning in my home machine, and llvm-3.0 built successfully! Any idea what might be missing here?
configure with CC=gcc CXX=g++. It looks like the configure script is finding a version of clang that isn't actually set up correctly to compile C++ code.