Skip to main content

pm-remez: Parks-McClellan Remez FIR design algorithm

Crates.io Rust Rust Docs Python Python Docs License License: MIT

pm-remez is a modern Rust implementation of the Parks-McClellan Remez exchange algorithm. It can be used as a Rust library and as a Python package via its Python bindings.

pm-remez supports the design of FIR filters with even symmetry and odd symmetry, and with an even number of taps and an odd number of taps, by reducing all these cases to the even symmetry odd number of taps case. The desired frequency response in each band, as well as the weights, can be defined as arbitrary functions. The library can use double-precision IEEE 754 floating-point numbers for calculations, as well as other higher precision floating-point implementations, such as num-bigfloat. This can be used to solve numerically challenging problems that are difficult to solve using double-precision arithmetic.

The implementation draws ideas from a paper by S.I. Filip to make the algorithm robust against numerical errors. These ideas include the use of Chebyshev proxy root finding to find the extrema of the weighted error function in the Remez exchange step.

Documentation

The documentation for the Rust crate is hosted in docs.rs/pm-remez.

The documentation for the Python package is hosted in pm-remez.readthedocs.io.

The Python package documentation contains a series of examples that show how to use pm-remez to design commonly used types of FIR filters. These illustrate the capabilities of pm-remez and also serve as a filter design guide. The documentation of the Rust crate contains a few examples of the Rust API. The Python examples can also be written in Rust (and in fact this is done as part of integration testing).

Python package

The pm-remez Python package is published in PyPI. There are pre-built binary packages for common architectures and operating systems. For these, the package can be installed by doing

pip install pm-remez

Building

The pm-remez crate uses ndarray-linalg to solve eigenvalue problems. This in turn depends on LAPACK. The pm-remez crate has several feature flags that are used to select the LAPACK backend. Exactly one of these features needs to be enabled to build pm-remez. The feature flags are openblas-static, openblas-system, netlib-static, netlib-system, intel-mkl-static and intel-mkl-system. The -static versions of each flag build the LAPACK backend and link statically against it. The -system versions link against a system-installed library (linking can be dynamic or static depending on which type of library is installed). For example,

cargo build --release --features openblas-system

will build against a system-installed OpenBLAS library.

The Python package is built using maturin. It can be built with

maturin build --release

or

python -mbuild

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Metadata

Release files for pm-remez 0.4.0

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

Source distribution (sdist)

Source distribution for pm-remez 0.4.0
File Size Uploaded Provenance Actions
pm_remez-0.4.0.tar.gz 66.5 kB Without provenance Details for pm_remez-0.4.0.tar.gz

Built distributions (wheels)

Table of built distributions (wheels) for pm-remez 0.4.0
File Actions
pm_remez-0.4.0-cp39-abi3-win_amd64.whl CPython 3.9 abi3 Windows x86-64 Details for pm_remez-0.4.0-cp39-abi3-win_amd64.whl
pm_remez-0.4.0-cp39-abi3-win32.whl CPython 3.9 abi3 Windows x86-32 Details for pm_remez-0.4.0-cp39-abi3-win32.whl
pm_remez-0.4.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl CPython 3.9 abi3 Linux glibc 2.17+ x86-64 Details for pm_remez-0.4.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
pm_remez-0.4.0-cp39-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl CPython 3.9 abi3 Linux glibc 2.17+ IBM System/390x Details for pm_remez-0.4.0-cp39-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl
pm_remez-0.4.0-cp39-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl CPython 3.9 abi3 Linux glibc 2.17+ PowerPC 64-le Details for pm_remez-0.4.0-cp39-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
pm_remez-0.4.0-cp39-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl CPython 3.9 abi3 Linux glibc 2.17+ ARMv7l Details for pm_remez-0.4.0-cp39-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
pm_remez-0.4.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.9 abi3 Linux glibc 2.17+ ARM64 Details for pm_remez-0.4.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
pm_remez-0.4.0-cp39-abi3-macosx_11_0_arm64.whl CPython 3.9 abi3 macOS 11.0+ ARM64 Details for pm_remez-0.4.0-cp39-abi3-macosx_11_0_arm64.whl
pm_remez-0.4.0-cp39-abi3-macosx_10_12_x86_64.whl CPython 3.9 abi3 macOS 10.12+ x86-64 Details for pm_remez-0.4.0-cp39-abi3-macosx_10_12_x86_64.whl

Total release size: 6.3 MB

Release files / pm_remez-0.4.0.tar.gz

Download URL pm_remez-0.4.0.tar.gz
Size 66.5 kB
Tags Source
SHA-256 checksum
How to use checksums
821818f01f39e326a9cf429b96759d48760b0ea0e5fe90e6cc4fc73125db549a
BLAKE2b-256 checksum
How to use checksums
b9d042dcc760ff2ca510c9a00d1f106c763824bd17dcae383d2c84ce467599f4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / pm_remez-0.4.0-cp39-abi3-win_amd64.whl

Download URL pm_remez-0.4.0-cp39-abi3-win_amd64.whl
Size 572.2 kB
Tags CPython 3.9 Windows x86-64 abi3
SHA-256 checksum
How to use checksums
0db357532a0775aafaeac43c289705fbd5907e388ea26140083465b562a00855
BLAKE2b-256 checksum
How to use checksums
20657c450f6dcc36b7d16833c2e77caff15163e504240e87144f723953b56e4a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / pm_remez-0.4.0-cp39-abi3-win32.whl

Download URL pm_remez-0.4.0-cp39-abi3-win32.whl
Size 562.7 kB
Tags CPython 3.9 Windows x86-32 abi3
SHA-256 checksum
How to use checksums
27dd43e908f8eeee36a73cfdb8d7a00cae33b67630884576e57f907096979d87
BLAKE2b-256 checksum
How to use checksums
a84b8f72d37ba03aa8c654f991a15866bae1af17f05de9d6851ff7b5615a62ba
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / pm_remez-0.4.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Download URL pm_remez-0.4.0-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Size 720.5 kB
Tags CPython 3.9 Linux glibc 2.17+ x86-64 abi3
SHA-256 checksum
How to use checksums
80a1b961548d83f686cc89895e520a0469db41cdb200ce7d547b7744f04467e5
BLAKE2b-256 checksum
How to use checksums
04a635770b776b3a3b0f438efd66fefae15a8587a74c2ad99ccfd30be93612d0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / pm_remez-0.4.0-cp39-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl

Download URL pm_remez-0.4.0-cp39-abi3-manylinux_2_17_s390x.manylinux2014_s390x.whl
Size 755.9 kB
Tags CPython 3.9 Linux glibc 2.17+ IBM System/390x abi3
SHA-256 checksum
How to use checksums
71101d49a079efe333f612a5c954e6c1efd51992607576a55f19d86eed667270
BLAKE2b-256 checksum
How to use checksums
098e7457b26b27615e2187870072f80abc23bf94a098fbd9266fbe4d80c5f2b0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / pm_remez-0.4.0-cp39-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl

Download URL pm_remez-0.4.0-cp39-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Size 854.8 kB
Tags CPython 3.9 Linux glibc 2.17+ PowerPC 64-le abi3
SHA-256 checksum
How to use checksums
0bc06888a6ca40dcdfa7009d96a860297bc78caa3bba75575748c9767baf503f
BLAKE2b-256 checksum
How to use checksums
bf75ca2e26b7c0ce821ffc1da27f000517bd30723afb4e9578ebb7fe66df805e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / pm_remez-0.4.0-cp39-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl

Download URL pm_remez-0.4.0-cp39-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Size 715.7 kB
Tags CPython 3.9 Linux glibc 2.17+ ARMv7l abi3
SHA-256 checksum
How to use checksums
12955c8fa4c72c1573e7cb7371f4d83fa5c67a1c94d944d59f1f2216fdffab27
BLAKE2b-256 checksum
How to use checksums
01df41a9b7e75c00b1f7c3624fb2c96de6d2db3f718b3e421c34f6f56a1f3c36
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / pm_remez-0.4.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL pm_remez-0.4.0-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 713.4 kB
Tags CPython 3.9 Linux glibc 2.17+ ARM64 abi3
SHA-256 checksum
How to use checksums
e93648ccb1e208dc052250a431a10ce1ae482cc331ee1effa5cfe5d65afc18ec
BLAKE2b-256 checksum
How to use checksums
e9ebee1a855b43a4a411425ca32d2e2880fd8111dc2c7a441c008e39ae1556fe
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / pm_remez-0.4.0-cp39-abi3-macosx_11_0_arm64.whl

Download URL pm_remez-0.4.0-cp39-abi3-macosx_11_0_arm64.whl
Size 678.0 kB
Tags CPython 3.9 abi3 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
9739018173a525b77ce0f29e6f53d71b15770d3390c3609748793898c11a4cd9
BLAKE2b-256 checksum
How to use checksums
e7950685a4e84d8d91ea6984dcbdce0875717d5fc7c3f69e328460c0fc718cfb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Release files / pm_remez-0.4.0-cp39-abi3-macosx_10_12_x86_64.whl

Download URL pm_remez-0.4.0-cp39-abi3-macosx_10_12_x86_64.whl
Size 682.0 kB
Tags CPython 3.9 abi3 macOS 10.12+ x86-64
SHA-256 checksum
How to use checksums
8a99a8c33f3836de9d0b60d15b4fa539f5a27f54acaab1ff46d78d858899b797
BLAKE2b-256 checksum
How to use checksums
e87a3d00c3816c7d8fcc4fc30ef4a156b57f7f639498a2bddda5bf8355a78949
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via maturin/1.15.0

Security for pm-remez 0.4.0

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.

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