help@rskworld.in +91 93305 39277
RSK World
  • Home
  • Development
    • Web Development
    • Mobile Apps
    • Software
    • Games
    • Project
  • Technologies
    • Data Science
    • AI Development
    • Cloud Development
    • Blockchain
    • Cyber Security
    • Dev Tools
    • Testing Tools
  • Blog
  • About
  • Contact

Theme Settings

Color Scheme
Display Options
Font Size
100%
Back to Project
RSK World
surveillance-video
RSK World
surveillance-video
Surveillance Video Dataset - Security Camera + Person Detection + Anomaly Detection + OpenCV + YOLO
surveillance-video
  • __pycache__
  • annotations
  • config
  • frames
  • models
  • output
  • videos
  • .gitignore713 B
  • GITHUB_DEPLOYMENT.md3.5 KB
  • LICENSE1.3 KB
  • README.md13 KB
  • RELEASE_NOTES.md5.6 KB
  • alert_system.py12 KB
  • analytics.js9.2 KB
  • analytics_dashboard.html9.3 KB
  • api_server.py10.7 KB
  • batch_processor.py8.3 KB
  • config.py1.2 KB
  • create_sample_video.py7.4 KB
  • create_zip.py2.6 KB
  • detect_anomalies.py7.2 KB
  • detect_persons.py6.3 KB
  • download_sample_videos.py2.5 KB
  • extract_frames.py4.5 KB
  • index.html62.2 KB
  • multi_camera_system.py12.5 KB
  • package.json1.2 KB
  • process_video.py4.4 KB
  • project_data.json1.3 KB
  • project_data.php1.6 KB
  • project_data.py1.7 KB
  • requirements.txt372 B
  • script.js6.6 KB
  • setup.py2 KB
  • styles.css13.4 KB
  • surveillance-video.zip1.2 MB
  • train_ml_model.py9 KB
  • verify_project.py5 KB
  • video_quality_analyzer.py9.5 KB
  • video_search.py10.7 KB
download_sample_videos.py
download_sample_videos.py
Raw Download
Find: Go to:
# Project: Surveillance Video Dataset
# Author: Molla Samser
# Website: https://rskworld.in/
# Contact: help@rskworld.in
# Phone: +91 93305 39277
# Address: Nutanhat, Mongolkote, Purba Burdwan, West Bengal, India, 713147

"""
Script to download sample surveillance videos from public sources.
This provides an alternative to creating synthetic videos.
"""

import os
import urllib.request
from pathlib import Path


def download_sample_video(url, output_path):
    """
    Download a video from URL.
    
    Args:
        url: URL of the video to download
        output_path: Path to save the video
    """
    try:
        os.makedirs(os.path.dirname(output_path) if os.path.dirname(output_path) else '.', exist_ok=True)
        
        print(f"Downloading video from: {url}")
        print(f"Saving to: {output_path}")
        
        urllib.request.urlretrieve(url, output_path)
        
        file_size = os.path.getsize(output_path) / (1024 * 1024)
        print(f"Download complete! File size: {file_size:.2f} MB")
        return True
    except Exception as e:
        print(f"Error downloading video: {e}")
        return False


def get_sample_video_sources():
    """
    Returns list of sample video sources (public domain or free to use).
    Note: Replace these with actual URLs to sample surveillance videos.
    """
    return [
        {
            "name": "sample.mp4",
            "url": "https://sample-videos.com/video123/mp4/720/big_buck_bunny_720p_1mb.mp4",
            "description": "Sample video 1 (replace with actual surveillance video URL)"
        },
        {
            "name": "sample2.mp4",
            "url": "https://sample-videos.com/video123/mp4/720/big_buck_bunny_720p_2mb.mp4",
            "description": "Sample video 2 (replace with actual surveillance video URL)"
        }
    ]


if __name__ == "__main__":
    print("=" * 60)
    print("Sample Video Downloader")
    print("=" * 60)
    print("\nNote: This script requires actual video URLs.")
    print("Replace the URLs in get_sample_video_sources() with real surveillance video links.")
    print("\nAlternatively, use create_sample_video.py to generate synthetic videos.")
    print("=" * 60)
    
    # Uncomment to download (after adding real URLs):
    # sources = get_sample_video_sources()
    # for source in sources:
    #     output_path = f"videos/{source['name']}"
    #     download_sample_video(source['url'], output_path)

76 lines•2.5 KB
python

About RSK World

Founded by Molla Samser, with Designer & Tester Rima Khatun, RSK World is your one-stop destination for free programming resources, source code, and development tools.

Founder: Molla Samser
Designer & Tester: Rima Khatun

Development

  • Game Development
  • Web Development
  • Mobile Development
  • AI Development
  • Development Tools

Legal

  • Terms & Conditions
  • Privacy Policy
  • Disclaimer

Contact Info

Nutanhat, Mongolkote
Purba Burdwan, West Bengal
India, 713147

+91 93305 39277

hello@rskworld.in
support@rskworld.in

© 2026 RSK World. All rights reserved.

Content used for educational purposes only. View Disclaimer