SkillAgentSearch skills...

PyPainterly

Python implementation of Aaron Hertzmann's Painterly algorithm for stroke based rendering of an image.

Install / Use

/learn @pschaldenbrand/PyPainterly
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

Painterly

Aaron Hertzmann's algorithm for stroke-based rendering in Python. The algorithm paints a given image using curved brush strokes of given widths. Its only dependencies are OpenCV and NumPy as seen in requirements.txt. Original photo of tomatoes Painting of the tomato photo

Usage

See example.ipynb for an example usage from the command-line or by importing.

From the command-line:

python painterly.py IMAGE_FILE [--r RADII][--output OUTPUT_FILENAME][--T APPROX_THRESH][--straight][--f_g GRID_FACTOR]

example:

python3 painterly.py images/tomato.jpg --r 8 4 2 --output images/tomato_rendered.jpg

where you want to use radii 8, 4, and 2 pixels in that order.

Aaron Hertzmann. 1998. Painterly rendering with curved brush strokes of multiple sizes. In Proceedings of the 25th annual conference on Computer graphics and interactive techniques (SIGGRAPH '98). Association for Computing Machinery, New York, NY, USA, 453–460. https://www.mrl.nyu.edu/publications/painterly98/hertzmann-siggraph98.pdf

Related Skills

View on GitHub
GitHub Stars36
CategoryDevelopment
Updated12d ago
Forks4

Languages

Jupyter Notebook

Security Score

95/100

Audited on Mar 15, 2026

No findings