Skip to main content

A Python library for downloading videos from UW Panopto

Project description

UW Panopto Downloader

A Python tool for downloading videos from UW Panopto and optionally converting them to audio format.

Features

  • Interactive browser-based login to access your Panopto content
  • Extract video links from Panopto course pages
  • Concurrent downloading of multiple videos
  • Video to audio conversion (MP4 to MP3)
  • User-friendly command line interface with rich formatting
  • Configurable settings saved between sessions

Installation

# From PyPI
pip install uw-panopto-downloader

# From source
git clone https://github.com/elimelt/uw-panopto-downloader.git
cd uw-panopto-downloader
pip install -e .

Requirements

  • Python 3.11 or higher
  • FFmpeg (for video downloads and conversion)
  • Chrome or Chromium browser (for Selenium)

Usage

Command Line Interface

The package provides a command-line tool uw-panopto-dl with several subcommands:

# Show help
uw-panopto-dl --help

# Download videos
uw-panopto-dl download [OPTIONS]

# Convert videos to audio
uw-panopto-dl convert [INPUT] [OPTIONS]

# View or update configuration
uw-panopto-dl config [OPTIONS]

# Show version
uw-panopto-dl version

Download Command

# Start an interactive download session
uw-panopto-dl download

# Specify a starting URL
uw-panopto-dl download --url "https://panopto.uw.edu/your-course-page"

# Set output directory
uw-panopto-dl download --output "path/to/downloads"

# Set number of concurrent downloads
uw-panopto-dl download --workers 5

# Run in headless mode (no browser window)
uw-panopto-dl download --headless

Convert Command

# Convert a single video
uw-panopto-dl convert video.mp4

# Convert with output path
uw-panopto-dl convert video.mp4 --output audio.mp3

# Convert a directory of videos
uw-panopto-dl convert videos_dir/ --output audio_dir/

# Set audio bitrate
uw-panopto-dl convert video.mp4 --bitrate 320k

# Set number of FFmpeg threads
uw-panopto-dl convert video.mp4 --threads 4

Config Command

# Show current configuration
uw-panopto-dl config --show

# Update configuration
uw-panopto-dl config --download-dir "path/to/downloads" --max-workers 4

Python API

You can also use the package programmatically:

from uw_panopto_downloader.core import BrowserSession, PanoptoDownloader, VideoConverter

# Initialize a browser session
browser = BrowserSession(headless=False)
browser.manual_login("https://panopto.uw.edu/your-course-page")

# Download videos
downloader = PanoptoDownloader(browser, max_workers=3)
video_links = browser.extract_links()
downloader.download_videos(video_links, "downloads")

# Convert videos to audio
converter = VideoConverter(bitrate="192k")
converter.convert_directory("downloads", "audio")

Configuration

The configuration is stored in ~/.uw-panopto-downloader/config.json and includes:

  • download_dir: Default download directory
  • max_workers: Maximum number of concurrent downloads
  • headless: Whether to run the browser in headless mode
  • audio_bitrate: Default audio bitrate for conversion
  • ffmpeg_threads: Default number of FFmpeg threads

License

This project is licensed under the MIT License - see the LICENSE file for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

uw_panopto_downloader-1.0.2.tar.gz (18.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

uw_panopto_downloader-1.0.2-py3-none-any.whl (24.4 kB view details)

Uploaded Python 3

File details

Details for the file uw_panopto_downloader-1.0.2.tar.gz.

File metadata

  • Download URL: uw_panopto_downloader-1.0.2.tar.gz
  • Upload date:
  • Size: 18.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.10

File hashes

Hashes for uw_panopto_downloader-1.0.2.tar.gz
Algorithm Hash digest
SHA256 0200ed34ea42b864356cf318237c63dac84b9d3130893c87c445108360b4ed37
MD5 61fce87df7511cec4b4e5ad15008de1f
BLAKE2b-256 54f0e32570dfd21024f7c1f5d718fc956a50015c471979a6a2cb7ac3431ea50c

See more details on using hashes here.

File details

Details for the file uw_panopto_downloader-1.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for uw_panopto_downloader-1.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 4c38b22c299de41c3127e1560e6dd6ca1998e1cf8ca200a065030ca5b1cbecec
MD5 bce24f05ef73aa99f0341e73861958b3
BLAKE2b-256 199d295065e1250007d4e16f524612bb7e34279a0a14f2eff4c1c202b4f4f2b3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page