Skip to main content

Benchmark Numba, Taichi, Warp, CuPy Kernel, Triton using Mandelbrot set

Project description

mandelbrot-benchmark

CI Status Documentation Status Test coverage percentage

uv Ruff pre-commit

PyPI Version Supported Python versions License


Documentation: https://mandelbrot-benchmark.readthedocs.io

Source Code: https://github.com/34j/mandelbrot-benchmark


Benchmark Numba, Taichi, Warp, CuPy Kernel, Triton using Mandelbrot set

Results

  • 200 iterations max
  • $c \in [-2, 1] \times [-1.5, 1.5]$
  • JAX version is quite hacky ("vectorized")
  • JAX version is omitted because it makes the benchmark unstable (see previous release for the comparison)
  • AMD Ryzen 9 3950X + NVIDIA GeForce RTX 4070 SUPER

Results

  • The results are almost identical when device = cuda
  • The computation time for Numba is quite unstable

Mandelbrot Set

Some notes

  • In Numba, the type of variables needs to be explicitly specified to use float32 instead of float64 (default), while is not the case for Taichi, Warp.

Installation

Install this via pip (or your favourite package manager):

pipx install mandelbrot-benchmark

Usage

Run the benchmark and plot the results:

mandelbrot-benchmark benchmark
mandelbrot-benchmark plot

Alternatives

Contributors ✨

Thanks goes to these wonderful people (emoji key):

This project follows the all-contributors specification. Contributions of any kind welcome!

Credits

Copier

This package was created with Copier and the browniebroke/pypackage-template project template.

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

mandelbrot_benchmark-1.1.4.tar.gz (12.1 kB view details)

Uploaded Source

Built Distribution

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

mandelbrot_benchmark-1.1.4-py3-none-any.whl (10.5 kB view details)

Uploaded Python 3

File details

Details for the file mandelbrot_benchmark-1.1.4.tar.gz.

File metadata

  • Download URL: mandelbrot_benchmark-1.1.4.tar.gz
  • Upload date:
  • Size: 12.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for mandelbrot_benchmark-1.1.4.tar.gz
Algorithm Hash digest
SHA256 5af6ec269d60447dae9b6362eeb06929dc95d9d1ecf448594ff9b90d7378e30d
MD5 1c4eba18849c3c85c09f31bd992ce039
BLAKE2b-256 915ff2c29e6c951275ec6067ce9eb59d6b4aca16f09721a8b7d9e0cba97ff985

See more details on using hashes here.

Provenance

The following attestation bundles were made for mandelbrot_benchmark-1.1.4.tar.gz:

Publisher: ci.yml on 34j/mandelbrot-benchmark

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file mandelbrot_benchmark-1.1.4-py3-none-any.whl.

File metadata

File hashes

Hashes for mandelbrot_benchmark-1.1.4-py3-none-any.whl
Algorithm Hash digest
SHA256 f4343180ff353ae75b09acd9876eb3376214904010980226eed0dbd510c8b348
MD5 c0c9e4ac9fc86e4a8ac09bbbde2a4487
BLAKE2b-256 40bfe7ff9d50ac24996b19350b04b7325ed65c01a1fc4588fa054f33f87e4e68

See more details on using hashes here.

Provenance

The following attestation bundles were made for mandelbrot_benchmark-1.1.4-py3-none-any.whl:

Publisher: ci.yml on 34j/mandelbrot-benchmark

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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