• Stars
    star
    151
  • Rank 245,308 (Top 5 %)
  • Language
    Python
  • License
    Apache License 2.0
  • Created over 7 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

bring keras-models to production with tensorflow-serving and nodejs + docker πŸ•

keras-serving

keras->tensorflow+grpc+docker=>nodejs 🐳πŸ”₯

  • example of bringing a keras model to production using tensorflow serving
  • using custom XOR model with tensor.proto dimensions example
  • building & training of the model works with python2.7 on the workstation
  • exported model is served via grpc in a C++ server using a Docker-Container
  • a nodejs server wraps the grpc api for a simple http POST endpoint
  • also ships an advanced multi-model face (emotion, gender) detection example /face-recog
  • and and advanced google bigquery (as dataaset) example /bigquery

Overview

Workflow (Unix - testen on Ubuntu 16.04 64bit)

You will need

python
pip
docker (docker-compose)

1. Install Requirements

./prepare.sh
# installs python dependencies via pip
# builds the docker image for tensorflow_serving (takes a while ~ 30 minutes)
# image size ~ 3.5 GB

checkout build troubleshoot if you are having trouble

2. Build, Train and Serialise Keras Model

python train.py
# results will be in (/result)

3. Load and export Model as Tensorflow Graph

python export.py
# results will be in (/export)

4. Build & Run Containers via docker-compose

./start-servers.sh
# ./stop-servers.sh

5. Test API via curl

curl -X POST \
  http://localhost:8080/predict-xor \
  -H 'cache-control: no-cache' \
  -H 'content-type: application/json' \
  -d '{"inputs": [0,1]}'

More Repositories

1

coinpusher

πŸ“ˆ real-time cryptocurrency chart prediction based on neuronal-networks :bowtie:
JavaScript
165
star
2

node-bitstamp

bitstamp REST and WS API Node.js client πŸ’΅
JavaScript
60
star
3

elixir-ms

an elixir microservice base/skeleton πŸ’€
Elixir
42
star
4

blockchain

πŸ’ͺπŸ”— PoW Blockchain implementation in Typescript πŸ’±
TypeScript
33
star
5

rust-ms

🎣 Secure High Performance Microservice Skeleton
Rust
14
star
6

cloudrun-test

Rust πŸ¦€ Google Cloud Run Demo
Rust
8
star
7

mac-scanner

Monitor private network MAC address appearance, leaves and IP changes
JavaScript
7
star
8

udpws

nodejs udp server/client ws (websocket) style
JavaScript
6
star
9

sandshark

expressjs like http server with almost raw http module performance
JavaScript
2
star
10

learning-nodejs-the-hard-way

Learning Node.js the hard way
JavaScript
2
star
11

tf-model-workflow

Python
2
star
12

balrok

πŸ‘Ή mongoose helper for heavy lifting of un-indexed collections
TypeScript
2
star
13

ceka

Ceka - Data Mining Library in C Sharp
C#
2
star
14

eisenhertz

🍻 module-as-a-process cluster management 🍺
JavaScript
1
star
15

pt-model-workflow

Python
1
star
16

elixir-microservice

base for an elixir microsservice
Elixir
1
star
17

json-to-form-data

JSON to FormData
JavaScript
1
star
18

node-n-api-base

skeleton project for async Node.js N-API C++ native modules
C++
1
star
19

grpc-hybrid-container

gRpc < node.js + C++ > Container = <3
C++
1
star
20

nodejs-string-vs-buffer

V8 Strings vs Binary Buffers
JavaScript
1
star
21

ceka-cli

CekaCli - Command Line Interface Application for Ceka Data Mining Library in C Sharp
C#
1
star