Skip to main content

Installation

Requirements

RequirementMinimum
Python3.8
pip21+
OSWindows, macOS, Linux
Disk space~650 MB (PyTorch + ultralytics)

From PyPI

pip install safelicensing

This installs the package and all runtime dependencies:

DependencyPurpose
streamlitWeb UI
opencv-python-headlessVideo reading and writing
ultralyticsYOLOv8 model runtime
moviepy<2.0.0Audio extraction and muxing
imageio-ffmpegFFmpeg bindings
numpyArray operations
pillowImage I/O
requestsHTTP utilities

Verify the installation

import safelicensing as sl
print(sl.__version__) # 1.0.1

Or from the terminal:

safelicensing --help

From source

git clone https://github.com/FahimFBA/safelicensing-pypi.git
cd safelicensing-pypi
pip install -r requirements.txt
pip install -e .

Development setup

For running tests and contributing:

pip install -r requirements-dev.txt
pip install -e .
pytest
python -m venv .venv

# Linux / macOS
source .venv/bin/activate

# Windows PowerShell
.venv\Scripts\Activate.ps1

pip install safelicensing

Specific version

pip install safelicensing==1.0.1

Troubleshooting

No module named 'cv2' OpenCV was not installed. Run:

pip install opencv-python-headless

No module named 'ultralytics'

pip install ultralytics

safelicensing: command not found Ensure your Python Scripts/ (Windows) or bin/ (Unix) directory is on PATH, or run directly:

python -m safelicensing.cli

Slow first run The bundled best.pt is loaded from the package directory. This takes a few seconds on first call per process; subsequent calls in the same process reuse the cached model.


Next: Quick Start →