Parametric radio frequency modeling, optimization and sampling
Project description
ParamRF, or pmrf, is an open-source radio frequency (RF) modeling framework. It provides a declarative, functional syntax for creating RF circuit and surrogate models using JAX.
The library also provides tools for model optimization, fitting, statistical analysis and Bayesian inference.
- Version:
- Author:
Gary Allen
- Homepage:
- Docs:
- Paper:
Features
Declarative syntax: Allows for the definition of models using either a self-documenting, declarative syntax, or via compositional techniques such as cascading or nodal circuit building. Also, since models can contain other models, this provides a natural means of building deeply nested, hierarchical models.
Differentiable: Since the framework is built on top of jax (as opposed to numpy), all models can be differentiated with respect to both frequency and parameters using auto-differentiation. This allows for both more efficient and flexible optimization, as well as unique design and analysis opportunities.
High performance and hardware flexible: Since models are compiled using jax with Just-In-Time (JIT) compilation, model performance is improved, and models can also be computed on high-performance hardware (CPU, GPU, TPU).
Built-in optimization and inference wrappers: Provides built-in wrappers for frequentist optimization and Bayesian inference in pmrf.optimize and pmrf.infer, as well as high-level wrappers for fitting models to data in pmrf.fitting.
Extensibility: Designed to be extendable, such that additional models, fitting algorithms, cost functions, sampling routines etc. can easily be implemented.
Installation
ParamRF can be installed directly using pip (requires Python 3.11+):
$ pip install paramrf
Example
The example below shows how to define and optimize a simple RLC model to satisfy a given goal function. See the documentation for more complex examples, or have a look at the tutorials folder on GitHub.
import pmrf as prf
from pmrf.parameters import Scaled
from pmrf.models import Resistor, Inductor, Capacitor
freq = prf.Frequency(1, 10, 101, 'GHz')
rlc_model = Resistor(50) ** Inductor(Scaled(1.0, 1e-9)) ** Capacitor(Scaled(1.0, 1e-12))
opt_freq = prf.Frequency(4, 6, 101, 'GHz')
goal = prf.evaluators.Goal('s11_db', '<', -20)
result = prf.optimize.minimize(goal, rlc_model, opt_freq, solver=prf.optimize.ScipyMinimize())
result.model.plot_s_db(freq, m=0, n=0)
Optional dependencies
Several additional dependencies are required/recommended for more advanced use-cases.
For Bayesian inference, you may need this fork of distreqx:
$ pip install git+https://github.com/gvcallen/distreqx
For BlackJAX’s Bayesian solvers:
$ pip install git+https://github.com/handley-lab/blackjax.git@v0.1.0-beta
For the PolyChord solver:
$ pip install git+https://github.com/PolyChord/PolyChordLite.git anesthetic mpi4py
Citation
If you have used ParamRF for academic work, please cite the original paper (https://doi.org/10.48550/arXiv.2510.15881): as:
G.V.C. Allen, D.I.L. de Villiers, (2025). ParamRF: A JAX-native Framework for Declarative Circuit Modelling. arXiv, https://doi.org/10.48550/arXiv.2510.15881.
or using the BibTeX:
@article{paramrf,
doi = {10.48550/arXiv.2510.15881},
url = {https://doi.org/10.48550/arXiv.2510.15881},
year = {2025},
month = {Oct},
title = {ParamRF: A JAX-native Framework for Declarative Circuit Modelling},
author = {Gary V. C. Allen and Dirk I. L. de Villiers},
eprint = {2510.15881},
archivePrefix = {arXiv},
primaryClass = {cs.OH},
}
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 Distribution
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 paramrf-0.18.1.tar.gz.
File metadata
- Download URL: paramrf-0.18.1.tar.gz
- Upload date:
- Size: 4.8 MB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5627aadbe3fda354654a8c091d6a801f9fce442e5fd8ded4fc1cd8e26b55548a
|
|
| MD5 |
1d5adc9c981efc2a5f79d439a592d9e9
|
|
| BLAKE2b-256 |
3d7895b008142fd21f257d620cd8d5d6f3c7c6527a78c00c2a473b470aa38bb5
|
Provenance
The following attestation bundles were made for paramrf-0.18.1.tar.gz:
Publisher:
publish.yml on gvcallen/paramrf
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
paramrf-0.18.1.tar.gz -
Subject digest:
5627aadbe3fda354654a8c091d6a801f9fce442e5fd8ded4fc1cd8e26b55548a - Sigstore transparency entry: 1525333323
- Sigstore integration time:
-
Permalink:
gvcallen/paramrf@777b75cc6575a8a95da0cfd076d3f2109b2157a5 -
Branch / Tag:
refs/tags/v0.18.1 - Owner: https://github.com/gvcallen
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@777b75cc6575a8a95da0cfd076d3f2109b2157a5 -
Trigger Event:
push
-
Statement type:
File details
Details for the file paramrf-0.18.1-py3-none-any.whl.
File metadata
- Download URL: paramrf-0.18.1-py3-none-any.whl
- Upload date:
- Size: 139.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
06ec75f3faff846f56d203826dd0ec87eb3326f392a3c90f42a188aa793846f4
|
|
| MD5 |
91765f38938bbda714f0a89506397e03
|
|
| BLAKE2b-256 |
38327967ad4ca8afca4271d38406ca936719bf35e28ef34ec8e625deface9c41
|
Provenance
The following attestation bundles were made for paramrf-0.18.1-py3-none-any.whl:
Publisher:
publish.yml on gvcallen/paramrf
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
paramrf-0.18.1-py3-none-any.whl -
Subject digest:
06ec75f3faff846f56d203826dd0ec87eb3326f392a3c90f42a188aa793846f4 - Sigstore transparency entry: 1525333351
- Sigstore integration time:
-
Permalink:
gvcallen/paramrf@777b75cc6575a8a95da0cfd076d3f2109b2157a5 -
Branch / Tag:
refs/tags/v0.18.1 - Owner: https://github.com/gvcallen
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@777b75cc6575a8a95da0cfd076d3f2109b2157a5 -
Trigger Event:
push
-
Statement type: