Skip to content

An unofficial Python module for connecting Basler AG cameras and capturing images.

License

Notifications You must be signed in to change notification settings

rwalle/pybasler

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PyBasler

A Python module for connecting Basler cameras and capturing images. This is a wrapper based on the official pypylon package.

It contains the following classes:

  • BaslerCamera: a base class for Basler cameras
  • BaslerCameraArray: a base class for Basler camera arrays
  • BaslerCameraManager: a manager class, currently can be used to return a list of available cameras

Example

>>> from basler.basler_camera import BaslerCamera
>>> from basler.helper import BaslerCameraManager
>>> import matplotlib.pyplot as plt
>>> BaslerCameraManager.get_camera_list_names()
['Basler piA1600-35gm (20717903)', 'Basler piA1600-35gm (21939024)']
>>> SERIAL_NUMBER = '21939024'
>>> cam = BaslerCamera(serial_number=SERIAL_NUMBER)
>>> cam.connect()
>>> frame = cam.grab_one()
>>> plt.imshow(frame, cmap='gray')
>>> plt.show()
>>> cam.disconnect()

Prerequisites

Documentation

Full Documentation is available at https://lizhe.me/pybasler-docs/.

About

An unofficial Python module for connecting Basler AG cameras and capturing images.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages