Skip to main content

biglogo

Python Tests Python Version Support Version PyPI version Documentation Status GitHub repository github: stars github: forks License: MIT zenodo: DOI

SHIFT : Scalable High-level Interface for Fourier Transforms

Introduction

SHIFT is a lightweight Python library designed to simplify Fourier transforms and spectral calculations on regular grids. Built around SciPy's FFT routines, SHIFT provides a convenient interface for computing Fourier, discrete cosine (DCT), and discrete sine (DST) transforms in one, two, and three dimensions, alongside utilities for constructing grids and their corresponding Fourier-space modes.

A central motivation behind SHIFT is to make parallel Fourier transforms easier to install, use, and integrate into scientific applications. Unlike implementations requiring FFTW and additional compiled extensions, SHIFT uses SciPy's FFT backend and supports distributed transforms through mpi4py, employing an MPI slab decomposition. This avoids the need for a separate FFTW installation while retaining compatibility with standard scientific Python environments.

In addition to spectral transforms, SHIFT provides utilities for MPI communication and distributed array operations, making it suitable for integration into larger scientific computing workflows.

NOTE: SHIFT was originally conceived as a framework for Fourier transforms in Cartesian, polar, and spherical coordinate systems. Current development focuses on Cartesian spectral transforms and MPI-based scientific computing. Experimental polar and spherical transform implementations are available in the sphere branch, but are not part of the supported release and should be used with caution. Further development of these capabilities is planned.

Dependencies

  • numba
  • numpy
  • scipy
  • mpi4py [Optional: enables MPI distributed processes]

Installation

SHIFT can be installed via pip:

pip install shift-fft

Or by cloning the github repository:

git clone https://github.com/knaidoo29/SHIFT.git
cd SHIFT
pip install .

The latter of which can be used to install specific branches.

Once this is done you should be able to call SHIFT from python:

import shift

To use the MPI functionality please take a look at the documentation which instructs users how to use the SHIFT MPI object and how to run these distributed jobs successfully without errors or MPI related hanging.

Documentation

In depth documentation and tutorials are provided here.

License

SHIFT is released under the MIT License. See LICENSE for details.

Citation

If you use SHIFT in your work, please cite:

DOI

  @software{naidoo_shift_2025,
    author       = {Naidoo, Krishna},
    title        = {SHIFT: a scalable MPI library for computing fast Fourier transforms in python},
    year         = 2025,
    publisher    = {Zenodo},
    doi          = {10.5281/zenodo.17093446},
    url          = {https://doi.org/10.5281/zenodo.17093446}}

Support

If you have any issues with the code or want to suggest ways to improve it please open a new issue (here) or (if you don't have a github account) email krishna.naidoo.11@ucl.ac.uk.

Metadata

Release files for shift-fft 1.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for shift-fft 1.2.1
File Size Uploaded Provenance Actions
shift_fft-1.2.1.tar.gz 47.6 kB With provenance Details for shift_fft-1.2.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for shift-fft 1.2.1
File Interpreter ABI Platform Actions
shift_fft-1.2.1-py3-none-any.whl Python 3 none any Details for shift_fft-1.2.1-py3-none-any.whl

Total release size: 103.9 kB

Release files / shift_fft-1.2.1.tar.gz

Download URL shift_fft-1.2.1.tar.gz
Size 47.6 kB
Tags Source
SHA-256 checksum
How to use checksums
112e12d6cdec961ba71af9f1fc9d05c94a45baa516431b97f0e7c1b9be13f831
BLAKE2b-256 checksum
How to use checksums
7a4d7223d19fd1bb3a8314de0d09df45effd8dbb629c1b32119e4b26e955538a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 6, 2026.

Transparency log

Release files / shift_fft-1.2.1-py3-none-any.whl

Download URL shift_fft-1.2.1-py3-none-any.whl
Size 56.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5a85a8d56287d1f85ac674dae0c3d02812745663dd88a0c860632ff682b0dc23
BLAKE2b-256 checksum
How to use checksums
4529f326e6547c5ac5859732125d273dae40bff02ba2cb42810e2a8d640c54b5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 6, 2026.

Transparency log

Security for shift-fft 1.2.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for shift_fft-1.2.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 6, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page