Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to run RTSP Video Stream using OpenCV in Python applications #7

Open
kishore-xinthe opened this issue Jan 2, 2025 · 1 comment
Assignees
Labels
question Further information is requested

Comments

@kishore-xinthe
Copy link
Contributor

When try running python applications with RTSP, application unable to read RTSP feed.

Device:
Volterra Windows Dev Kit-2023

Operating System:
Windows ARM64

Python Version:
Python 3.11 ARM64

OpenCV Version:
4.10.0.84

@kishore-xinthe kishore-xinthe added the question Further information is requested label Jan 2, 2025
@rayyan-xinthe
Copy link
Collaborator

The issue of RTSP feed with arm64-based OpenCV-Python is not working is solved.

The application, written in Python, can leverage the NPU only from an arm64-based Python environment.
However, the RTSP feed with amd64-based OpenCV-Python is working even on the Volterra Dev Kit 2023.

To make it work, a virtual environment containing Python 3.11.9 amd64 was created. From that virtual environment, the RTSP feed was fetched. Each frame from the feed was then sent to the application running on Python arm64 using a Network Socket.

The client, which fetches the RTSP feed, is located at client.py. The Python application performing inference receives the packets from the client RTSP and processes them.


Process to Create the Virtual Environment

  1. Install Python 3.11.9 amd64 at the preferred location.

  2. Create a virtual environment using the Python installed in Step 1.

  3. Activate the virtual environment.

  4. Run the following commands:
    python -m pip install --upgrade pip
    pip install numpy==1.25.2
    pip install opencv-python==4.10.0.84

  5. In the client.py script, change the RTSP path accordingly.

  6. In the Python application scripts, for example, image_classification_inference.py change the Python interpreter path to the path according to the virtual environment path created in Step 2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants