#rune #tensorflow #coral

hotg-runecoral

Bindings to the librunecoral library for doing hardware-accelerated inference

4 releases (2 breaking)

0.3.1 Sep 19, 2021
0.3.0 Sep 16, 2021
0.2.0 Sep 10, 2021
0.1.1 Aug 9, 2021

#24 in Machine learning

Download history 103/week @ 2021-08-08 113/week @ 2021-08-15 231/week @ 2021-08-22 76/week @ 2021-08-29 109/week @ 2021-09-05 159/week @ 2021-09-12 169/week @ 2021-09-19

268 downloads per month
Used in hotg-rune-cli

MIT/Apache

3MB
15K SLoC

C++ 14K SLoC // 0.2% comments Rust 548 SLoC // 0.1% comments Shell 246 SLoC // 0.2% comments FlatBuffers Schema 198 SLoC // 0.6% comments Batch 127 SLoC // 0.2% comments Python 40 SLoC // 0.5% comments

librunecoral

A thinly veiled wrapper around tflite and libedgetpu from Google

Building

Prerequisites

Linux/Android:

Windows 10:

  • Visual Studio Build tools 2019
  • Msys2
  • choco install python llvm bazel
  • pip install numpy
  • rust

OS X:

  • git
  • bazel
  • XCode
  • pip install numpy
  • rust

Getting the sources

$ git clone https://github.com/hotg-ai/librunecoral
$ cd librunecoral
$ git submodule update --init --recursive

Build the docker container

$ make docker-image-linux
$ docker image ls
REPOSITORY                      TAG     IMAGE ID       CREATED         SIZE
docker.pkg.github.com/hotg-ai/librunecoral/runecoral-cross-linux     latest  b431b6fa5895   7 hours ago     2.94GB

Build the package for Linux

$ make librunecoral-linux-aarch64
$ ls dist/include
runecoral.h
$ ls dist/lib/linux/aarch64
librunecoral.so

# To build for all supported CPU architectures under linux
$ make librunecoral-linux
$ ls dist/lib/linux
arm  arm64  x86_64

Build the package for / on Windows

$ bazel build --config windows //runecoral:runecoral
$ ls bazel-bin/runecoral/
_objs  runecoral.lib  runecoral.params

Thanks to:

  • Webcoral
  • libedgetpu
  • mediapipe

Dependencies