Skip to content

BioroboticsLab/bee_view

Repository files navigation

Bee Vision Simulator

Bee_view is a rendering engine based on raycasting that simulates insect vision. Features:

  • The renderer can load arbitrary scenes from .obj files.
  • The core renderer is written in C++ and uses Intel’s high performance raytracing kernel library Embree.
  • A Python package with bindings to the C++ functions is available.
  • It is not limited to simulating bee vision, but can also render normal images from a pinhole or a panoramic camera.
  • It can also be used with different interommatidial and acceptance angles for simulating the vision of other insects.

The bee's eye model implemented is a model of the spatial resolution and field of view. It does not include the spectral sensitivity and light intensity.

The Model is based on the paper:

W. Stürzl, N. Boeddeker, L. Dittmar, and M. Egelhaaf, ‘Mimicking honeybee eyes with a 280 degrees field of view catadioptric imaging system’, Bioinspir. Biomim., vol. 5, no. 3, p. 036002, Sep. 2010.

The R script for calculating the interommatidial angles can be found here. The renderer was built as part of a bachelor's thesis. Implementation details and other information can be found in the thesis.

An example rendering

An example video that was rendered with the engine can be found here.

Python package

Installation

Dependencies:

  • CPython >3.5 64 bit
  • numpy
  • Cython (only needed if building from source)

Windows

A precompiled .pyd file for Windows 10 64 bit is available here. Add the .pyd file together with the .dlls from the lib folder to your PATH variable. Then you can use import beeview to load the package.

Linux

There is no build available for Linux at this moment.

Building from source

For building and installing the python package with Cython from source run:

python setup.py install

in the api folder of bee_view. This will generate the python shared library.

Getting started

Example Python scripts and Notebooks can be found here.

3-D World

A low-res 3-D world of a 2 km^2 area in Hesse, Germany can be downloaded here. The location of the model on Google maps: link

C++ Library

Installation

Windows

Building with Visual Studio on Windows:

  • clone the repository
  • add the "external" folder to Project Settings -> VC++ Directories -> Include Directories
  • add the "lib" folder to Project Settings -> VC++ Directories -> Library Directories
  • add "embree.lib" to Project Settings -> Linker -> Input -> Additional Dependencies
  • add embree.dll, tbb.dll and tbbmalloc.dll (they can be found in the "lib" folder) to your PATH variable, or put them in the same folder as your application.

Then build for x64.

To include bee_view with your project, you can build it as shared library and include the beeview_api.h file.

Credits

The renderer uses the following libraries:

The bee eye model is based on:

The 3D model was recorded from the FU Biorotobotics lab.

About

Bee Eye Camera for Virtual Environments

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published