473,836 Members | 1,455 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

video analysis with python

Hi,

I need to write a video analysis tool which extracts statistics from
microsocope video. Essentially what I need is to translate the video data
into numerical matrices. I have been using Python for the past 1.5 years
anytime I could for absolutely everything, because it has every library
imaginable... Alas, I can not find a library for decoding video/using
codecs. The only solution I have been able to come up with is to create
an image sequence and load those in with PIL, however this is not really
feasible as the images are too large (nor is it proffessional).

Is there a library or project that I have missed, or is there a way to
incorporate something like vfw.lib directly? If there isn't I think this
would be a pretty large whole in Python's arsenal. Thanks in advance for
any help.

--
Ashot Petrosian
University of Texas at Austin, Computer Sciences
Jul 18 '05 #1
5 4108
Hello Ashot,
I need to write a video analysis tool which extracts statistics from
microsocope video. Essentially what I need is to translate the video data
into numerical matrices. I have been using Python for the past 1.5 years
anytime I could for absolutely everything, because it has every library
imaginable... Alas, I can not find a library for decoding video/using
codecs. The only solution I have been able to come up with is to create
an image sequence and load those in with PIL, however this is not really
feasible as the images are too large (nor is it proffessional).

Is there a library or project that I have missed, or is there a way
to incorporate something like vfw.lib directly? If there isn't I think
this would be a pretty large whole in Python's arsenal. Thanks in advance
for any help.


1. There is PyMedia (http://pymedia.org/)
2. Maybe you can use the code from VLC (http://www.videolan.org/vlc/)
(using SWIG/PyBoost/Pyrex ...)

HTH.
--
------------------------------------------------------------------------
Miki Tebeka <mi*********@zo ran.com>
http://tebeka.bizhat.com
The only difference between children and adults is the price of the toys
Jul 18 '05 #2
This helps alot! pyMedia looks perfect. I can't believe I couldn't find
it after a full day of searching.. losing my touch

On Sun, 16 Jan 2005 13:44:27 +0200, Miki Tebeka <mi*********@zo ran.com>
wrote:
Hello Ashot,
I need to write a video analysis tool which extracts statistics from
microsocope video. Essentially what I need is to translate the video
data
into numerical matrices. I have been using Python for the past 1.5 years
anytime I could for absolutely everything, because it has every library
imaginable... Alas, I can not find a library for decoding video/using
codecs. The only solution I have been able to come up with is to create
an image sequence and load those in with PIL, however this is not really
feasible as the images are too large (nor is it proffessional).

Is there a library or project that I have missed, or is there a way
to incorporate something like vfw.lib directly? If there isn't I
think
this would be a pretty large whole in Python's arsenal. Thanks in
advance
for any help.


1. There is PyMedia (http://pymedia.org/)
2. Maybe you can use the code from VLC (http://www.videolan.org/vlc/)
(using SWIG/PyBoost/Pyrex ...)

HTH.
--
------------------------------------------------------------------------
Miki Tebeka <mi*********@zo ran.com>
http://tebeka.bizhat.com
The only difference between children and adults is the price of the toys


--
--
Ashot Petrosian
University of Texas at Austin, Computer Sciences
Jul 18 '05 #3
Hi

Am 16.01.2005 12:44:27 schrieb Miki Tebeka:
1. There is PyMedia (http://pymedia.org/)


Is this library able to extract single images from a video? AFAICS it
can only convert videos from one format to another. But I didn't try it,
I've looked only in the docu.

Maybe pyVideo (http://www.geocities.com/rtrocca/python/) would be a
solution. But for me the AVIFile-Module doesn't work stable, it
regularly crashes the python-interpreter.

And there is a library for accessing DirectShow called PyDShowCam.

cu boesi
--
|¯|/¯/¯¯¯\|¯| |¯|¯| |¯|/¯/¯¯¯\|¯¯¯¯\|¯¯¯¯ | #1671 : icq-intern
http://| / / /¯\ | | | | | | / / /¯\ | (¯) | |¯¯#73628288 : icq-extern
smb://| \ \ \_/ | `¯´ | |__| \ \ \_/ | ¯ /| ¯| boesi111 : aim
ftp://|_|\_\___/|_|¯|_|____|_|\ _\___/|_|¯¯ |_|¯ i171 : reallife
Jul 18 '05 #4
On Mon, 17 Jan 2005 08:08:46 +0100, Alexander 'boesi' Bösecke
<bo********@gmx .net> wrote:
Hi

Am 16.01.2005 12:44:27 schrieb Miki Tebeka:
1. There is PyMedia (http://pymedia.org/)


Is this library able to extract single images from a video? AFAICS it
can only convert videos from one format to another. But I didn't try it,
I've looked only in the docu.

Maybe pyVideo (http://www.geocities.com/rtrocca/python/) would be a
solution. But for me the AVIFile-Module doesn't work stable, it
regularly crashes the python-interpreter.

And there is a library for accessing DirectShow called PyDShowCam.

cu boesi


I haven't tried it yet, but yes its pretty full featured library, there is
a tutorial here on extracting images:
http://java.sun.com/products/java-me...ameAccess.html

--
Ashot Petrosian
University of Texas at Austin, Computer Sciences
Jul 18 '05 #5
On Mon, 17 Jan 2005 08:08:46 +0100, "Alexander 'boesi' Bösecke"
<bo********@gmx .net> wrote:
1. There is PyMedia (http://pymedia.org/)


Is this library able to extract single images from a video? AFAICS it
can only convert videos from one format to another. But I didn't try it,
I've looked only in the docu.


Yes, you can extract single images from a video. The package uses the
avformat and avcodec libraries from ffmpeg and it provides rather low
level access to video/audio files. You can access the individual
streams in a file, obtain the stream data and decode the data therein.
What you do with the data is up to your application. Converting the
file into another format is just one such application.

- Matthias -

Jul 18 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1221
by: Chris Esther | last post by:
I discovered what appears to be a copy of Python 2.1 included/embedded? with the video editing system Avid Adrenalin Media Composer (Win XP). In the program directory there is python21.dll and a directory containing the standard library. As I'm in the middle of an exercise to see if I can automate some non-creative tasks in the creation of short video clips (e.g. creating 'slate's) this piqued my interest somewhat. I have googled...
2
4771
by: Olivia Robinson | last post by:
Hi, I am an artist who creates interactive video installations that are controlled using a set of sensors, a microcontroller, computer and video projector. Currently I am using MAX/MSP and Jitter to program how information collected from the sensors then is used to manipulate pre-recorded video footage. I have been investigating Python as an alternative to using MAX/MSP/Jitter to program the collection of information from the sensors...
2
2921
by: googlemike | last post by:
Is there a video module so that I can write a Linux Python script to record video coming over USB video cams? What about these side-thoughts: * What about recording multiple streams over multiple USB ports? (Think in the context of a security system.) * What about lossy compression?
0
1394
by: Simon Brunning | last post by:
QOTW: "The security 'droids have decided that since the MS Office Suite is a 'standard' application then software written in MS Office VBA must be 'safe.' Any other development environments (such as Java, Perl, Cygwin) are 'unsafe' and can't be installed." - Peter Olsen "There's nothing wrong with open source projects catering to a market, and there's nothing wrong with running open source software on a proprietary operating system." -...
53
3571
by: john67 | last post by:
The company I work for is about to embark on developing a commercial application that will cost us tens-of-millions to develop. When all is said and done it will have thousands of business objects/classes, some of which will have hundreds-of-thousands of instances stored in a DB. Our clients will probably have somewhere between 50-200 users working on the app during the day, possibly in mutiple offices, and then a large number of batch...
0
2147
by: Stefan Tietke | last post by:
Hi all, for a realtime simulation of a video installation we want to use Quicktime to read video data from a file or stream and process the data in a realtime Gameblender model. We are trying to simulate a large-scale, low resolution media facade using individuell video pixels to control lamps mounted into the facade.
1
2090
by: Petr Prikryl | last post by:
Do you think that the following could became PEP (pre PEP). Please, read it, comment it, reformulate it,... Abstract Introduction of the mechanism for language extensions via modules written using other languages. Extensions of Python could be done via special interpreter extensions. From Python sources, the special modules would look like other modules, with the Python API (the key feature from
1
1821
by: showcaran | last post by:
For a project I need to analysis of web content. So I should get a web page as a input and then decompose information and other objects. Every object may have special processing after decomposition. I have doubt which language is more suitable for this situation. Do you think python is a good option or recommend Perl or other languages? I have to mention that I have C++ programming experience and a little JavaScript.
40
2875
by: walterbyrd | last post by:
I mean other than sysadmins, programmers, and web-site developers? I have heard of some DBAs who use a lot of python. I suppose some scientists. I think python is used in bioinformatics. I think some math and physics people use python. I suppose some people use python to learn "programming" in general. Python would do well as a teaching language.
0
9671
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10558
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
10257
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9387
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7794
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6981
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5651
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5829
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
4022
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.