pypylon interface for Python development – now approved as Open Source Project!

pypylon is the new Python wrapper interface for the Basler pylon Camera Software Suite and is now available as an open source project. Learn more about pypylon and how to get started in this article.

In the past the Imaginghub already referred to a number of projects (e.g. the Raspberry Pi Face Detection), which made use of a Python wrapper around the pylon camera SDK called pypylon. This wrapper however was a kind of alpha version and closed source. Now, pypylon has been approved by Basler and was published as an Open Source project on GitHub - a number of programming samples included. 

The advantages of a python wrapper around the camera SDK are obvious: it lets new and experienced Python programmers quickly and conveniently develop prototype applications and test Basler cameras without needing to set up a complex development environment. This not only speeds up the camera evaluation process significantly, but also increases the productivity and lowers the total project costs. In addition, it can be used with interactive rapid prototyping tools like Jupyter Notebook etc.

Python is a dynamic, object-oriented and multipurpose programming language designed to be quick to understand, learn and use. The syntax in Python helps programmers do coding in fewer steps, as compared to Java, VB, C, C++ or C#. Python's extensive library of open-source image processing libraries (e.g. Open CV), data analysis tools, web frameworks, and testing instruments makes its ecosystem one of the largest of any programming community.


How to get started?

Getting started with pypylon is very easy. Of course, Python needs to be installed. It is recommend to always use Python 3 in its newest version. In addition, you simply need to download the pylon Camera Software Suite, which suits your operating system from the Basler website. After this you need to install pypylon with

$ pip install pypylon

for python 2.x or


$ pip3 install pypylon

for python 3.x


This will automatically download the pypylon binary (wheel) which fits to your OS, Python, and your pylon version from pypi. You may alternatively also download pypylon wheels from GitHub and install the downloaded wheel with pip or pip3 respectively:

$ pip3 install<pypylon_wheel_file_name>


In this case, you must make sure by yourself that you download a wheel, which suits your OS, pylon and Python version.

Right after performing these actions, you can immediately write and run Python applications making use of Basler cameras:

from pypylon import pylon
from pypylon import genicam

# Create an instant camera object with the camera device found first.
camera = pylon.InstantCamera(pylon.TlFactory.GetInstance().CreateFirstDevice())
# etc…



System Requirements

If you want to use pypylon the following system requirements must be fulfilled:



pypylon is "community-supported"

pypylon is available as an open source project and hosted on This is also the place, where you find a nice collection of sample Python programs, which demonstrate all common camera use cases.

Offering pypylon in source code, results in a high degree of flexibility, since you can modify and build pypylon exactly to your needs. With this project everyone is encouraged to integrate own ideas and actively participate in the further development of pypylon.


You are welcome to post any questions or issues in the comment box below. Just log in or register and leave a comment here.


javier-zamarreno report abuse
Hello, I'm trying to install pypylon and I couldn't. I downloaded the latest version of pylon from basler official page. After that, I introduced this command (pip install pypylon) in the terminal, because I have python 2.7, to downloaded the corresponding wheel but I get the following message: ~$ pip install pypylon Collecting pypylon Could not find a version that satisfies the requirement pypylon (from versions: ) No matching distribution found for pypylon You are using pip version 18.1, however version 19.0 is available. You should consider upgrading via the 'pip install --upgrade pip' command. Please help me!! Thank you

Join the community!

Imaginghub: your community ... Show more