A fast goertzel calculator Rust
Project description
ultrafastgoertzel Python Bindings
Ultra-fast Goertzel algorithm implementation with SIMD optimization for Python.
Usage
import ultrafastgoertzel as ufg
import math
# Generate a test signal (sine wave at frequency 0.1)
signal = [math.sin(2 * math.pi * 0.1 * i) for i in range(1000)]
# Analyze a single frequency
magnitude = ufg.goertzel(signal, 0.1)
print(f"Magnitude at 0.1: {magnitude:.4f}")
# Analyze multiple frequencies efficiently (recommended)
frequencies = [0.1, 0.2, 0.3]
magnitudes = ufg.goertzel_batch(signal, frequencies)
for freq, mag in zip(frequencies, magnitudes):
print(f"Frequency {freq}: {mag:.4f}")
Frequency Normalization
Frequencies are normalized, where:
- 0.0 = DC (0 Hz)
- 0.5 = Nyquist frequency (half the sampling rate)
For example, if your sampling rate is 1000 Hz:
- 0.1 represents 100 Hz
- 0.25 represents 250 Hz
- 0.5 represents 500 Hz (Nyquist)
Performance
This implementation uses SIMD instructions for optimal performance. The goertzel_batch function is particularly efficient when analyzing multiple frequencies on the same signal, as it can process multiple frequencies in parallel.
License
WTFPL License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ultrafastgoertzel-0.1.0.tar.gz.
File metadata
- Download URL: ultrafastgoertzel-0.1.0.tar.gz
- Upload date:
- Size: 16.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f65061775d329adf04435ec3dc47299034b93d82e7bceead73b7bf7a407e0c14
|
|
| MD5 |
424fbfd4b84412c4db5363d338dd6dd3
|
|
| BLAKE2b-256 |
fa4dedb1c62aeebe7e5f08ca2eb7f8728ad565ab456bafb69c078f8b4233bbe3
|
File details
Details for the file ultrafastgoertzel-0.1.0-cp39-abi3-win_amd64.whl.
File metadata
- Download URL: ultrafastgoertzel-0.1.0-cp39-abi3-win_amd64.whl
- Upload date:
- Size: 138.2 kB
- Tags: CPython 3.9+, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
bb426bd242d05281afdc1a23e787f0a9522dc69146701e57bc7bad299776ea59
|
|
| MD5 |
fa785dfff6b4c561ca4ce799bca615df
|
|
| BLAKE2b-256 |
f23408a38218c3b8af1b72ec72fa5768ef3cbfcd75a8519820d28da20ddbbd33
|
File details
Details for the file ultrafastgoertzel-0.1.0-cp39-abi3-musllinux_1_2_x86_64.whl.
File metadata
- Download URL: ultrafastgoertzel-0.1.0-cp39-abi3-musllinux_1_2_x86_64.whl
- Upload date:
- Size: 435.4 kB
- Tags: CPython 3.9+, musllinux: musl 1.2+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
97790be33e7c7255bfce788066e1ca1a17b2720d143f992a2e74e0696f17c772
|
|
| MD5 |
2c3550fa83f49f054adf9fe1afb0f0a5
|
|
| BLAKE2b-256 |
8ee96d5d778cbe7c3ba0203d7c5746bf7bb1224b6af0dc1127011fd339a60ae0
|
File details
Details for the file ultrafastgoertzel-0.1.0-cp39-abi3-musllinux_1_2_aarch64.whl.
File metadata
- Download URL: ultrafastgoertzel-0.1.0-cp39-abi3-musllinux_1_2_aarch64.whl
- Upload date:
- Size: 428.2 kB
- Tags: CPython 3.9+, musllinux: musl 1.2+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
621cac3d35e1515d459cdba6edf14f666da78dd240cd4f51de0bca31ea5fd187
|
|
| MD5 |
5bba69170e6008e050a940697645683e
|
|
| BLAKE2b-256 |
116da394619bea21efdf8f4b3077dbfa36060fb7ef01ada68caa0a11529bf0f7
|
File details
Details for the file ultrafastgoertzel-0.1.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.
File metadata
- Download URL: ultrafastgoertzel-0.1.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
- Upload date:
- Size: 261.3 kB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0aa729c1fef3b6cc5d2fbecd83f58e6795d36bcff1e219b3e82ea13a5140394c
|
|
| MD5 |
0db07b01ecf73ecd235130bc6a688aef
|
|
| BLAKE2b-256 |
9f4d24f06b429d468db994b7921f8fcbe635d902245f5f09c5652f986a393b76
|
File details
Details for the file ultrafastgoertzel-0.1.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.
File metadata
- Download URL: ultrafastgoertzel-0.1.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
- Upload date:
- Size: 246.3 kB
- Tags: CPython 3.9+, manylinux: glibc 2.17+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0f2daf97c93fccec174665435a32bedc4280700f353fda2c18521f1f7eb7789f
|
|
| MD5 |
6d1862392c397ff2b35ac80fa0e37a07
|
|
| BLAKE2b-256 |
5a644d58d98b5079db8600b7e6b8796eef63e9a39f7c276bef8a6c522757168b
|
File details
Details for the file ultrafastgoertzel-0.1.0-cp39-abi3-macosx_11_0_arm64.whl.
File metadata
- Download URL: ultrafastgoertzel-0.1.0-cp39-abi3-macosx_11_0_arm64.whl
- Upload date:
- Size: 222.2 kB
- Tags: CPython 3.9+, macOS 11.0+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
60ef6c93c7a2b649b665b4a224a68c1a89e95df466b56299a25628d589ca5d91
|
|
| MD5 |
ad8097eed8534b2fba7820afe894f04b
|
|
| BLAKE2b-256 |
ea67a765747baeb5b60044658cc9a23c9937deefaec00f21015c956d2f640d24
|
File details
Details for the file ultrafastgoertzel-0.1.0-cp39-abi3-macosx_10_12_x86_64.whl.
File metadata
- Download URL: ultrafastgoertzel-0.1.0-cp39-abi3-macosx_10_12_x86_64.whl
- Upload date:
- Size: 243.5 kB
- Tags: CPython 3.9+, macOS 10.12+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via: maturin/1.9.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
83a0b11f8b66ed1bfa5c45853c512f935b4fe7546eff3a3fe9a1491cc7eab7fd
|
|
| MD5 |
065b6a00f3bba7039542c101737b79c8
|
|
| BLAKE2b-256 |
11ef824efe3a207ae47ce80cd7108b1fc6b859c38eb8b37c0baac0e38fd6d64d
|