Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9146357
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T10:43:53+00:00 2026-06-17T10:43:53+00:00

Using python I would like to monitor a .avi raw RGB video file that

  • 0

Using python I would like to monitor a .avi raw RGB video file that is being written to the hard disk by another process at the time of recording. So what I need is something that repeatedly gives me the currently last frame (or n-th last frame) of the video file on the disk.

I tried using OpenCV for that already, this however gives me only the currently last frame once, any further calls of QueryFrame after reaching the last frame for the first time do not return further images.

So essentially I am looking for something like this, but for .avi video files. Additionally for me it is not a problem if frames are skipped, it would be enough to get a couple of new frames a second.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T10:43:54+00:00Added an answer on June 17, 2026 at 10:43 am

    You must close the .avi-file at the end of each loop-iteration and then reopen it.

    EDIT: art requested a code sample. Here it is.

    while True:
        with open("test.avi") as fh:
            get_last_frame()
        wait_or_do_whatever_you_want()
    

    I have no idea how OP uses the AVI format, but that wasn’t part of the question.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to get the temperature of a hard disk using Python (under
I would like to add to the end of an XML file using python.
I would like to play 2 videos together using python. Apart from that, I
I am quite often using Python instead of pseudocode. For that, I would like
I'm using python-mock to mock out a file open call. I would like to
Using Python's Imaging Library I want to create a PNG file. I would like
Using python on Mac OS, I would like to open a file for writing
Using Python I would like to find the date object for last Wednesday. I
I would like to parse free-text time intervals like the following, using Python: 1
I have a working application using python and zeromq and I would like to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.