Coder Social home page Coder Social logo

videointerpreterai's Introduction

Video Understanding App

This Streamlit-based application integrates computer vision and AI to analyze and understand video content. It uses OpenAI's powerful GPT-4 API to generate descriptive text for video sequences, offering a glimpse into the content and context of the videos.

Features

  • Video Upload: Users can upload videos in MP4, AVI, or MOV formats.
  • Frame Display: The application displays the first frame of the uploaded video.
  • Automated Description: Leverages OpenAI's GPT-4 to generate descriptions for the video content.

How to Use

  1. Upload a video file using the Streamlit file uploader.
  2. Wait as the app processes the video and displays the first frame.
  3. Read the generated description of the video content.

Technical Details

  • The app saves the video to a temporary file for processing.
  • Frames are extracted and converted to base64 for analysis.
  • Descriptions are generated by sending frames to the OpenAI API.
  • The first frame of the video and its description are displayed on the UI.

Getting Started

To run this application locally, follow these steps:

  1. Ensure you have Python installed on your system.

  2. Clone this repository to your local machine.

  3. Install the required dependencies

  4. Create a .env file in the root directory of the project and add your OpenAI API key:

    OPENAI_API_KEY='your_api_key_here'
    
  5. Start the Streamlit app:

    streamlit run your_script_name.py

Replace your_script_name.py with the name of your Python script.

Installation

Make sure you have the following Python packages installed:

  • streamlit
  • opencv-python-headless
  • base64
  • tempfile
  • openai
  • dotenv
  • requests

You can install these packages using pip

videointerpreterai's People

Contributors

alanh90 avatar

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.