Skip to main content

Efficient Sparse q-ary Fourier Transforms

This repository contains code for the paper:

"Efficiently Computing Sparse Fourier Transforms of $q$-ary Functions" Yigit Erginbas*, Justin Kang*, Amirali Aghazadeh, Kannan Ramchandran

*Equal contribution: These authors contributed equally.

This package may be useful to you if you deal with complicated functions of $q$-ary sequences, for example, functions of protiens, DNA or RNA.

Table of Contents

Abstract

Fourier transformations of pseudo-Boolean functions are popular tools for analyzing functions of binary sequences. Real-world functions often have structures that manifest in a sparse Fourier transform, and previous works have shown that under the assumption of sparsity the transform can be computed efficiently. But what if we want to compute the Fourier transform of functions defined over a $q$-ary alphabet? These types of functions arise naturally in many areas including biology. A typical workaround is to encode the $q$-ary sequence in binary however, this approach is computationally inefficient and fundamentally incompatible with the existing sparse Fourier transform techniques. Herein, we develop a sparse Fourier transform algorithm specifically for $q$-ary functions of length $n$ sequences, dubbed $q$-SFT, which provably computes an $S$-sparse transform with vanishing error as $q^n$ goes to $\infty$ in $O(Sn)$ function evaluations and $O(S n^2 \log q)$ computations, where $S = q^{n\delta}$ for some $\delta < 1$. Under certain assumptions, we show that for fixed $q$, a robust version of $q$-SFT has a sample complexity of $O(Sn^2)$ and a computational complexity of $O(Sn^3)$ with the same asymptotic guarantees. We present numerical simulations on synthetic and real-world RNA data, demonstrating the scalability of $q$-SFT to massively high dimensional $q$-ary functions.

Metadata

Release files for qsft 0.0.2

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

Source distribution (sdist)

Source distribution for qsft 0.0.2
File Size Uploaded Provenance
qsft-0.0.2.tar.gz 44.9 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for qsft 0.0.2
File Interpreter ABI Platform
qsft-0.0.2-py3-none-any.whl Python 3 none any Details

Total release size: 71.4 kB

Release files / qsft-0.0.2.tar.gz

Download URL qsft-0.0.2.tar.gz
Size 44.9 kB
Tags Source
SHA-256 checksum
How to use checksums
3f93f41fd93b5481b4378226ad2bacabef3346c62aaf6d3e537d11dfc87f3239
BLAKE2b-256 checksum
How to use checksums
a3c7bef4297615b0c69c27643b6496a702cacc8943017841ffc2c38e53c71331
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.10.8

Release files / qsft-0.0.2-py3-none-any.whl

Download URL qsft-0.0.2-py3-none-any.whl
Size 26.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d85e72ae0a207bd06be76ff04e446aee62c78316754eccf2ffb51ef676a98433
BLAKE2b-256 checksum
How to use checksums
03bee9fb1eb0774aabdf0e50d6b1feea2fe13e14b78f206624162aa2c0baa60d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.10.8

Security for qsft 0.0.2

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

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.

Release history Release notifications | RSS feed

This release

0.0.2 This release

2 release files No provenance

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