Installation
Basic install
Section titled “Basic install”pip install rfx-fdtdrfx requires Python 3.10+ and installs JAX, NumPy, SciPy, matplotlib, and
h5py.
The package name on PyPI is rfx-fdtd, while the Python import remains:
import rfxFor the packaged local Studio, background experiment CLI, and Model Context Protocol (MCP) server, install the Studio extra:
pip install "rfx-fdtd[studio]"rfx studio --workspace .rfx-studioSee Studio, CLI, and MCP Experiments for the current UI scope, shared-workspace rules, replay, approvals, and remote deployment requirements.
Verify your install
Section titled “Verify your install”After installing, confirm the environment can actually run a simulation.
First run the bundled diagnostics command:
rfx-diagnoseIt prints a PASS / WARN / FAIL report (Python and rfx versions, the JAX
backend and devices, core dependencies, optional extras) and finishes with a
tiny end-to-end FDTD run. It exits 0 only when every critical check
passes; WARN lines (CPU-only backend, x64 disabled) are informational.
The diagnostic’s final short run is the installed-package execution check.
Examples under examples/ are available only from a source checkout; they are
not installed as wheel data.
GPU support
Section titled “GPU support”pip install --upgrade "jax[cuda12]"python -c "import jax; print(jax.devices())"See the official JAX installation guide for CUDA/cuDNN details.
Development install
Section titled “Development install”git clone https://github.com/bk-squared/rfx.gitcd rfxpip install -e ".[dev]"python examples/quickstart/hello_world.pyThe hello-world script builds a tiny box, injects one pulse, records one field probe, and prints a short finite-data summary.
The dev extra includes:
pytestpytest-xdistruff
System requirements
Section titled “System requirements”- Python: 3.10 / 3.11 / 3.12
- CPU: modern x86_64
- GPU: NVIDIA + CUDA 12+ for acceleration
- RAM: 4 GB minimum, 16 GB+ recommended for larger 3D runs
Next steps
Section titled “Next steps”From a source checkout with the development install above, run
examples/quickstart/hello_world.py, then follow the ordered tutorials in
examples/tutorials/; examples/README.md lists the sequence. For a wheel-only
install, use rfx-diagnose as the execution check because the wheel does not
include examples/.