Coder Social home page Coder Social logo

maxenceplebrun / webcam-acquisition Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 2.0 236.04 MB

A program designed to acquire webcam images synchronised with a widefield imaging system.

Home Page: https://maxenceplebrun.github.io/Webcam-Acquisition/

Python 95.61% C++ 4.39%
widefield synchronization webcam python

webcam-acquisition's Introduction


Logo

Webcam Acquisition

A Python GUI designed to acquire webcam images synchronised with a widefield imaging system.

Explore the Documentation
Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. Roadmap
  5. License
  6. Contact

About The Project

For many scientific applications, it is useful to have a camera feed synchronised with another acquisition system. If both systems have the same acquisition rate, a common trigger can be used: if their sampling rate is different, a different approach must be used.

This programs solves this problem by monitoring the trigger signal of the acquisition system with an Arduino Board. For each Falling Edge in the incoming signal, the Arduino increases its Frames Acquired index by one, thus tracking the number of frames acquired by the imaging system.

This variable is then read by the Webcam software, which is running a indenpendent image acquisition using a USB webcam. For each webcam frame acquired, the program will save the Frames Acquired index in a separate NPY array. For each webcam image, it is therefore possible to know the corresponding Imaging System image.

You can download the program by following the instructions below. Some indications are also given on how to adapt the program to your current setup.

(back to top)

Built With

Getting Started

Prerequisites

  • Python 3.9 must be installed

Installation

  1. Download the latest release in the Releases section of the repository.
  2. Unzip the downloaded file and move to desired location.
  3. Install the required modules using one of the following methods:

Using Pip

  1. Open a terminal window
  2. Go to the directory where the program is saved using the cd command.
  3. Run the following command: pip install -r requirements.txt

Using Anaconda

  1. Open a terminal window
  2. Run the following two commands:
conda create -n py3.9 python=3.9.12
conda activate py3.9
  1. In a terminal window, go to the directory where the program is saved using the cd command.
  2. Run the following command: pip install -r requirements.txt

(back to top)

Usage

Running the program

  1. Launch the webcam.pyw module found in the gui subfolder.

Modifying the Arduino COM port

  1. Open the config.json file using any text editor.
  2. Replace the string at te arduino_port key with the desired port.

Modifying the Arduino input PIN

  1. Open the arduino.ino file using any text editor.
  2. On the first line, replace the inPin variable with the desired PIN port number.
  3. Transfer the arduino.ino file to the board using the Arduino Software.

(back to top)

Roadmap

See the open issues for a full list of proposed features (and known issues).

(back to top)

License

Distributed under the MIT License. See LICENSE.txt for more information.

(back to top)

Contact

Created by Maxence Pelletier-Lebrun - [email protected]

For a research internship at Michèle Desjardins' Laboratory

Research Page: https://www.crchudequebec.ulaval.ca/recherche/chercheurs/michele-desjardins/

(back to top)

webcam-acquisition's People

Contributors

maxenceplebrun avatar jeguilbert1 avatar

Stargazers

 avatar

Watchers

 avatar

webcam-acquisition's Issues

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.