Straw Andrew D, Dickinson Michael H
Bioengineering, California Institute of Technology, Mailcode 138-78, Pasadena, CA 91125, USA.
Source Code Biol Med. 2009 Jul 22;4:5. doi: 10.1186/1751-0473-4-5.
Video cameras sense passively from a distance, offer a rich information stream, and provide intuitively meaningful raw data. Camera-based imaging has thus proven critical for many advances in neuroscience and biology, with applications ranging from cellular imaging of fluorescent dyes to tracking of whole-animal behavior at ecologically relevant spatial scales.
Here we present 'Motmot': an open-source software suite for acquiring, displaying, saving, and analyzing digital video in real-time. At the highest level, Motmot is written in the Python computer language. The large amounts of data produced by digital cameras are handled by low-level, optimized functions, usually written in C. This high-level/low-level partitioning and use of select external libraries allow Motmot, with only modest complexity, to perform well as a core technology for many high-performance imaging tasks. In its current form, Motmot allows for: (1) image acquisition from a variety of camera interfaces (package motmot.cam_iface), (2) the display of these images with minimal latency and computer resources using wxPython and OpenGL (package motmot.wxglvideo), (3) saving images with no compression in a single-pass, low-CPU-use format (package motmot.FlyMovieFormat), (4) a pluggable framework for custom analysis of images in realtime and (5) firmware for an inexpensive USB device to synchronize image acquisition across multiple cameras, with analog input, or with other hardware devices (package motmot.fview_ext_trig). These capabilities are brought together in a graphical user interface, called 'FView', allowing an end user to easily view and save digital video without writing any code. One plugin for FView, 'FlyTrax', which tracks the movement of fruit flies in real-time, is included with Motmot, and is described to illustrate the capabilities of FView.
Motmot enables realtime image processing and display using the Python computer language. In addition to the provided complete applications, the architecture allows the user to write relatively simple plugins, which can accomplish a variety of computer vision tasks and be integrated within larger software systems. The software is available at http://code.astraw.com/projects/motmot.
摄像机从远处进行被动感知,可提供丰富的信息流,并提供直观且有意义的原始数据。因此,基于摄像机的成像已被证明对神经科学和生物学的许多进展至关重要,其应用范围从荧光染料的细胞成像到在生态相关空间尺度上对全动物行为的追踪。
在此,我们展示“Motmot”:一个用于实时采集、显示、保存和分析数字视频的开源软件套件。在最高层面,Motmot是用Python计算机语言编写的。数码相机产生的大量数据由通常用C编写的底层优化函数处理。这种高层/底层划分以及对选定外部库的使用,使得Motmot只需适度的复杂度,就能作为许多高性能成像任务的核心技术良好运行。在其当前形式下,Motmot允许:(1)从各种相机接口采集图像(包motmot.cam_iface),(2)使用wxPython和OpenGL以最小延迟和计算机资源显示这些图像(包motmot.wxglvideo),(3)以单次通过、低CPU使用率的格式无压缩地保存图像(包motmot.FlyMovieFormat),(4)用于实时自定义图像分析的可插拔框架,以及(5)用于廉价USB设备的固件,以跨多个相机、模拟输入或与其他硬件设备同步图像采集(包motmot.fview_ext_trig)。这些功能集成在一个名为“FView”的图形用户界面中,使终端用户无需编写任何代码就能轻松查看和保存数字视频。Motmot包含一个用于FView的插件“FlyTrax”,它可实时追踪果蝇的运动,并用于说明FView的功能。
Motmot使用Python计算机语言实现实时图像处理和显示。除了提供完整的应用程序外,该架构还允许用户编写相对简单的插件,这些插件可以完成各种计算机视觉任务并集成到更大的软件系统中。该软件可在http://code.astraw.com/projects/motmot获取。