Skip to content
Spatiotemporal query language
Branch: master
Clone or download
Type Name Latest commit message Commit time
Failed to load latest commit information.
rekalljs Bump to 0.2.10 Jul 3, 2019
rekallpy Bump to 0.2.10 Jul 3, 2019
tutorials Update tutorial README May 14, 2019
.gitignore Ignore files from building javascript May 27, 2019
.readthedocs.yml update docs requirements.txt Apr 9, 2019
.travis.yml Fix npm key Apr 26, 2019 Update README to reflect Python3 everywhere Jul 9, 2019
rekall_preview.png Update README image May 13, 2019

rekall: spatiotemporal query language

Build Status Documentation Status

Rekall is a spatiotemporal query language. It operates over sets of intervals and allows for combining and filtering on temporal and spatial predicates. In combination with the VGrid visualization widget, Rekall can be used to filter and visualize spatiotemporal data:


Rekall has a main Python API for all the core interval processing operations. Rekall also has a Javascript API which we use for the vgrid video metadata visualization widget.

Getting Started

Sample Usage

Rekall provides utilities for processing spatiotemporal intervals (like bounding boxes in a video). This code sample shows how bounding boxes for a few videos can be loaded into Rekall:

from rekall import Interval, IntervalSet, IntervalSetMapping, Bounds3D
import urllib3, requests, os

# Load bounding box info from JSON files on server
metadata_files = [ 'driving1.json', 'driving2.json', 'driving3.json', 'driving4.json' ]
driving_metadata = [ requests.get(os.path.join(VIDEO_COLLECTION_BASEURL, metadata_file),
                    for metadata_file in metadata_files ]

# Load bounding box data into Rekall
bbox_ism = IntervalSetMapping({
    video_file: IntervalSet([
        Interval(Bounds3D(t1=f['frame'], t2=(f['frame'] + 1),
                          x1=bbox['x1'], x2=bbox['x2'],
                          y1=bbox['y1'], y2=bbox['y2']),
                 payload = { 'class': bbox['class'], 'score': bbox['score'] })
        for f in metadata
        for bbox in f['bboxes']
    for video_file, metadata in zip([ 'driving1.mp4', 'driving2.mp4', 'driving3.mp4', 'driving4.mp4' ],

Check out the tutorials for more on how Rekall can be used to operate on this spatiotemporal data.


Python API

Rekall requires Python 3.5 or greater.

pip3 install rekallpy

JavaScript API

The Rekall JavaScript API must be installed in the context of a JavaScript application using the npm package structure. You must have npm installed.

npm install --save @wcrichto/rekall

Now that you've installed Rekall, check out the tutorials!

Developer Guidelines

If you are interested in contributing to Rekall (and we welcome contribution via pull requests!), you should install Rekall from source:

[1] Clone the rekall repo

git clone

[2] Install Python API from source

cd rekall/rekallpy
pip3 install -e .

And run tests:

python3 -m unittest discover test

[3] Install JavaScript API from source

cd rekall/rekalljs
npm install
npm run prepublishOnly
npm link
You can’t perform that action at this time.