Zulko/gizeh is an open-source project on GitHub with 725 stars, written primarily in Python. Simple Vector Graphics for Python
Snapshot summary built from the project's own GitHub metadata — there's no written TopGit review yet. The page will update automatically when a full review is published.
WHY NO REVIEW YET
TopGit writes full reviews for the most-starred, most-requested repositories. This page is a snapshot until then — see the READ ME tab for the original README in full.
Gizeh is a Python library for vector graphics, built on top of cairocffi (Cairo bindings for Python). Cairo is powerful but low-level; Gizeh adds a small set of intuitive primitives to make drawing easier.
# Let's draw a red circle!
import gizeh
surface = gizeh.Surface(width=320, height=260) # pixels
circle = gizeh.circle(r=30, xy=[40, 40], fill=(1, 0, 0))
circle.draw(surface) # draw the circle on the surface
surface.write_to_png("circle.png") # export as PNG
See Gizeh in action (combined with MoviePy for animations) in
this blog post.
Gizeh supports Python 3.7+.
Installation
Gizeh requires the Cairo graphics library to be installed on your system.
macOS (Homebrew):
brew install cairo pkg-config
Debian/Ubuntu:
sudo apt-get install -y libcairo2-dev pkg-config
Then install the Python package:
pip install gizeh
Alternatively, from source (editable/development install):
pip install -e .
User Guide
This guide, along with the examples in gizeh/examples, should give you everything you need to get started. Check docstrings for details.
Surfaces
A Surface is a rectangle of fixed dimensions (in pixels) on which you draw elements, and which you can save/export as an image:
import gizeh
# initialize surface
surface = gizeh.Surface(width=320, height=260) # in pixels
# make a shape and draw it on the surface
circle = gizeh.circle(r=30, xy=[40, 40], fill=(1, 1, 1))
circle.draw(surface)
# export the surface
surface.get_npimage() # returns a (width x height x 3) numpy array
surface.write_to_png("circle.png")
Elements
Basic elements are circles, rectangles, lines, text, etc., that you draw on a surface using my_element.draw(surface). Common parameters:
xy: center coordinates of the object. At render time (surface.write_to_png) you can set y_origin to "top" (default) or "bottom". With "top", (0, 0) is the upper-left of the final image; the bottom-right is (width, height). With "bottom", (0, 0) is the bottom-left (like plots), and (width, height) is the top-right.
angle: rotation (radians) around xy.
fill: interior fill (default: none). Can be a color (R, G, B), gradient, image pattern, etc.
stroke: contour fill; same rules as fill.
stroke_width: contour width (pixels). Default is 0 (no stroke).
The most recent commit recorded on Zulko/gizeh was 1.0 years ago, based on the GitHub push timestamp. The repository has 68 forks — one of the better signals of community interest.
How many stars does Zulko/gizeh have?
Zulko/gizeh has 725 GitHub stars — refresh the page for the live number, or check github.com/Zulko/gizeh. TopGit mirrors GitHub's count but does not claim minute-by-minute accuracy.
Is Zulko/gizeh open source?
TopGit's metadata for Zulko/gizeh does not record a license. Most public repositories on GitHub ARE open source, but the exact terms vary — verify by opening the LICENSE file directly.
What is Zulko/gizeh?
Zulko/gizeh (Zulko/gizeh) is a Python project on GitHub. From the project's own README: Simple Vector Graphics for Python
What language is Zulko/gizeh written in?
Zulko/gizeh is written primarily in Python. GitHub's language field is based on the largest share of bytes in the default branch.
Where do I read more about Zulko/gizeh?
This TopGit page is a snapshot — the READ ME tab shows the project's own README content (links stripped, images preserved). The GitHub repository at github.com/Zulko/gizeh is the definitive source.
Read full README in the tab above.
Want a second opinion on gizeh?
Ask an AI that can read this page — one click and you get its take on gizeh.