Micah P. Dombrowski / Jan 28 2019

MXNet Clojure Environment


Clojure deps.edn file, which will be mounted into the filesystem when the runtime boots—this installs MXNet and the Clojure frontend. Note that the current version of Clojure/MXNet is compiled against CUDA 9.0, so we must set NEXTJOURNAL_MOUNT_CUDA appropriately in the runtime config.

{ :deps {
  org.apache.mxnet.contrib.clojure/clojure-mxnet-linux-gpu {
    :mvn/version "1.3.1" },
  nu.pattern/opencv {:mvn/version "2.4.9-7"},
  net.mikera/imagez {:mvn/version "0.12.0"},
  thinktopic/think.image {:mvn/version "0.4.16"}}}
Extensible Data Notation

Install various dependencies, including Scala and OpenCV.

apt-get -qq update
apt-get install --no-install-recommends software-properties-common \
  runit apt-transport-https build-essential devscripts \
  libopenblas-base libatlas3-base \
  libcurl3 scala libssl1.0.0 \
  libgdal20 libilmbase12 libopenexr22 libtbb2 libwebp6
add-apt-repository -y ppa:timsc/opencv-3.4
apt-get -qq update
apt-get install libopencv-imgcodecs3.4
apt-get clean