[API] Random Polyhedral Scenes: An Image Generator for Active Vision System Experiments

Markus D. Solbach, Stephen Voland, Jeff Edmonds and John K. Tsotsos

We present a Polyhedral Scene Generator system which creates a random scene based on a few user parameters, renders the scene from random view points and creates a dataset containing the renderings and corresponding annotation files. We think that this generator will help to understand how a program could parse a scene if it had multiple angle to compare. For ambiguous scenes, typically people move their head or change their position to see the scene from different angle as well as seeing how it changes while they move; a research field called active perception. The random scene generator presented is designed to support research in this field by generating images of scenes with known complexity characteristics and with verfieable properties with respect to the distribution of features across a population. Thus, it is well-suited for research in active perception without the requirement of a live 3D environment and mobile sensing agent as well as for comparative performance evaluations. :rocket:

System: :point_right: HERE

Paper: HERE :point_left:

Example Scenes Six different scenes (left to right) rendered from three different views (top to bottom). See the paper for more information:heavy_exclamation_mark:

What is this GitHub page about?

This is the home of the application program interface (API) for the Random Polyhedral Scenes: An Image Generator for Active Vision System Experiments system. The API is realized using WebSockets. Basically any programming language that supports WebSockets can be used :tada: (Java, C/C++, Python, MatLab, …). We provide examples in

The example provided below is a minimal version of the Python :snake: example written in Python 3 :snake::snake::snake:.

Minimal Example (Python)

# Author: Markus Solbach (polyhedral@eecs.yorku.ca)
from websocket import create_connection
import io, sys, json, base64
from json import dumps

# Create Connection
ws = create_connection("wss://polyhedral.eecs.yorku.ca/api/")
parameter = {
    'ID':'YOUR ID HERE',
    'random_cam': 'true',
json_params = dumps(parameter, indent=2)

while True:
    result = json.loads(ws.recv())
    print("Job Status: {0}".format(result['status']))
    if result['status'] == "SUCCESS":
    elif "FAILURE" in result['status'] or "INVALID" in result['status']:

image_base64 = result['image']
image_decoded = base64.b64decode(image_base64)

# Close Connection

Requirements for example script

Optional for example script