Skip to content

pmatrix

An alternative to the famous cmatrix C++ program written in Python

Repository Information

Language Python
Stars 6
Forks 0
Last Updated 5/31/2026
View on GitHub

PMatrix

A Matrix digital rain effect terminal application, written in Python.

Overview

This program creates a digital rain effect, similar to the iconic Matrix movie visuals, with falling characters in the terminal. Written in modern Python with improved features including variable drop speeds, intensity-based coloring, and optimized rendering.

Features

  • Dynamic drop speeds: Each drop falls at a random speed for more variety
  • Intensity-based coloring: Leading characters are brighter green
  • Smooth animations: Optimized rendering at ~30 FPS
  • Terminal resize support: Automatically adjusts to window size changes
  • Graceful shutdown: Handles Ctrl+C cleanly
  • No external dependencies: Uses Python standard library only

Running

Execute without installing using nix run or uvx:

1nix run github:4ster-light/pmatrix
1uvx git+https://github.com/4ster-light/pmatrix

Installation

Install directly from GitHub:

1nix profile add github:4ster-light/pmatrix

Or add the flake to your system config if you use NixOS.

Using UV

Install directly from GitHub:

1uv tool install git+https://github.com/4ster-light/pmatrix

Using pip

Install directly from GitHub:

1pip install git+https://github.com/4ster-light/pmatrix

Requirements

  • Python 3.10 or later
  • A terminal that supports ANSI escape codes (most modern terminals)
  • Linux, macOS, or compatible terminal

License

MIT

Want to see more? Visit my GitHub page for all my repositories and contributions.

View All Repositories on GitHub →