Coder Social home page Coder Social logo

pypyueye's Introduction

Pypyueye

Convenience wrapper around pyueye API for IDS cameras.

Pypyueye allows to easily display live videos, save images or record videos usin IDS cameras.

Relative to the original pypyueye, this fork replaces opencv with imageio, for fewer incompatibilities with embedded systems.

Installation

python setup.py install

The dependencies (pyueye and opencv) should be installed automatically.

You still have to install the IDS driver for the camera you intend to use.

Usage

Note that all data formats are 8-bit except for .tiff and .bip which are 16-bit

The following script allows to display the live video:

from pypyueye import Camera, FrameThread, PyuEyeQtApp, PyuEyeQtView
from pyueye import ueye

with Camera(device_id=0, buffer_count=10) as cam:
    #======================================================================
    # Camera settings
    #======================================================================
    cam.set_colormode(ueye.IS_CM_BGR8_PACKED)
    cam.set_aoi(0, 0, 800, 400)
    cam.set_fps(4)

    #======================================================================
    # Get Live video
    #======================================================================
    # Set up the view
    app = PyuEyeQtApp()
    view = PyuEyeQtView()
    view.show()
    # Set up the thread gathering images
    thread = FrameThread(cam, view)
    thread.start()
    # Stop the thread on view closing
    app.exit_connect(thread.stop)
    app.exec_()

See example.py for more examples.

Documentation

The script simple_capture runs the camera without any metaparameters, while capture typically requires command added inline. The different options can be seen by running "python3 capture.py".

Note that all the file formats except envi use imageio for saving, but envi uses spectral python. Thus, to save as envi requires specifying the absolute file path, whereas the other file types can be stored with relative file paths.

Pypyueye is documented inline. The documentation of the Camera class is a good start.

pypyueye's People

Contributors

galaunay avatar jlgarrett avatar krisklau avatar netzo92 avatar

Stargazers

 avatar

Watchers

 avatar

Forkers

krisklau dthirst

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.