Skip to main content

A code generator for array-based code on CPUs and GPUs

Project description

Gitlab Build Status Github Build Status Python Package Index Release Page Zenodo DOI for latest release

Loopy lets you easily generate the tedious, complicated code that is necessary to get good performance out of GPUs and multi-core CPUs. Loopy’s core idea is that a computation should be described simply and then transformed into a version that gets high performance. This transformation takes place under user control, from within Python.

It can capture the following types of optimizations:

  • Vector and multi-core parallelism in the OpenCL/CUDA model

  • Data layout transformations (structure of arrays to array of structures)

  • Loop unrolling

  • Loop tiling with efficient handling of boundary cases

  • Prefetching/copy optimizations

  • Instruction level parallelism

  • and many more!

Loopy targets array-type computations, such as the following:

  • dense linear algebra,

  • convolutions,

  • n-body interactions,

  • PDE solvers, such as finite element, finite difference, and Fast-Multipole-type computations.

It is not (and does not want to be) a general-purpose programming language.

Loopy is licensed under the liberal MIT license and free for commercial, academic, and private use. All of Loopy’s dependencies can be automatically installed from the package index after using:

pip install loopy

In addition, Loopy is compatible with and enhances pyopencl.

Places on the web related to Loopy:

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

loopy-2025.1.tar.gz (608.7 kB view details)

Uploaded Source

Built Distribution

loopy-2025.1-py3-none-any.whl (530.4 kB view details)

Uploaded Python 3

File details

Details for the file loopy-2025.1.tar.gz.

File metadata

  • Download URL: loopy-2025.1.tar.gz
  • Upload date:
  • Size: 608.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.13.2

File hashes

Hashes for loopy-2025.1.tar.gz
Algorithm Hash digest
SHA256 2de13505e2b3faa14917708e5eae1420e5eee19ba81bc46157c397292e9721e3
MD5 862b338503152e66fcae8d1786b1fb29
BLAKE2b-256 f5da47eea8be9a958f3f47dfc83573708240a7c2e88d4191044c5857cb2a33a1

See more details on using hashes here.

File details

Details for the file loopy-2025.1-py3-none-any.whl.

File metadata

  • Download URL: loopy-2025.1-py3-none-any.whl
  • Upload date:
  • Size: 530.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.13.2

File hashes

Hashes for loopy-2025.1-py3-none-any.whl
Algorithm Hash digest
SHA256 103123f163f9aeae739cbf6ec87b63bfadf94b4ee31650469e7864049e18f1d2
MD5 b5450c03e5010980ceabf4287f48767f
BLAKE2b-256 535fe9c4953605ddd8caa834b378a71105ca94c9988912d0b5f0ba7ace9cc327

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page