DeepStack Documentation!

Official Documentation and Guide for DeepStack AI Server.

DeepStack is an AI server that empowers every developer in the world to easily build state-of-the-art AI systems both on premise and in the cloud. The promises of Artificial Intelligence are huge but becoming a machine learning engineer is hard. DeepStack is device and language agnostic. You can run it on Windows, Mac OS, Linux, Raspberry PI and use it with any programming language.

DeepStack’s source code is available on GitHub via https://github.com/johnolafenwa/DeepStack

DeepStack is developed and maintained by DeepQuest AI .

Top Features

Example Code

_images/road.jpg

Using DeepStack, we can classify the scene of the above image as seen below.

python
import requests

image_data = open("image.jpg","rb").read()

response = requests.post("http://localhost:80/v1/vision/scene",
files={"image":image_data}).json()
print(response)
js
const request = require("request")
const fs = require("fs")

image_stream = fs.createReadStream("image.jpg")

var form = {"image":image_stream}

request.post({url:"http://localhost:80/v1/vision/scene", formData:form},function(err,res,body){

    response = JSON.parse(body)
    console.log(response)
})
c#
using System;
using System.IO;
using System.Net.Http;
using System.Threading.Tasks;


namespace app
{

    class App {

    static HttpClient client = new HttpClient();

    public static async Task makeRequest(){

        var request = new MultipartFormDataContent();
        var image_data = File.OpenRead("image.jpg");
        request.Add(new StreamContent(image_data),"image",Path.GetFileName("image.jpg"));
        var output = await client.PostAsync("http://localhost:80/v1/vision/scene",request);
        var jsonString = await output.Content.ReadAsStringAsync();

        Console.WriteLine(jsonString);

    }

    static void Main(string[] args){

        makeRequest().Wait();

    }

    }

}

Response

json
{ 'success': true, label: 'highway', confidence: 0.63377846 }

Installation

DeepStack is available in three variants, CPU Version, GPU Version, NVIDIA Jetson and Raspberry PI Version (With Support for Intel Neural Compute Stick)

Installation Guide for GPU Version

Installation Guide for NVIDIA Jetson

Installation Guide for Windows ( CPU and GPU )

Installation Guide for Raspberry Pi

Installation Guide for CPU Version

Step 1: Install Docker (If not already installed) Mac OS and Windows Users can install docker from Docker’s Website .

To install on a Linux operating system, run the commands below

bash
sudo apt-get update
sudo apt-get install docker.io

Step 2: Install DeepStack

bash
docker pull deepquestai/deepstack

Run DeepStack with Scene Recognition API enabled

Run the command below as it applies to the version you have installed

bash
docker run -e VISION-SCENE=True -v localstorage:/datastore -p 80:5000 deepquestai/deepstack
bash
sudo docker run --gpus all -e VISION-SCENE=True -v localstorage:/datastore -p 80:5000 deepquestai/deepstack:gpu
bash
deepstack --VISION-SCENE True --PORT 80
bash
sudo docker run --runtime nvidia -e VISION-SCENE=True -p 80:5000 deepquestai/deepstack:jetpack
bash
sudo deepstack start "VISION-SCENE=True"

Basic Parameters

-e VISION-SCENE=True This enables the scene recognition API.

-p 80:5000 This makes DeepStack accessible via port 80 of the machine.

Run the example scene recognition code at the begining of this page to verify your installation is working.

Contents: