A Radar Simulator for Python
RadarSimPy is a powerful and versatile Python-based Radar Simulator that models radar transceivers and simulates baseband data from point targets and 3D models. Its signal processing tools offer range/Doppler processing, direction of arrival estimation, and beamforming using various cutting-edge techniques, and you can even characterize radar detection using Swerling’s models. Whether you’re a beginner or an advanced user, RadarSimPy is the perfect tool for anyone looking to develop new radar technologies or expand their knowledge of radar systems.
-
- Radar transceiver modeling
- Arbitrary waveform
- Phase noise
- Phase/amplitude modulation
- Fast-time/slow-time modulation
-
- Simulation of radar baseband data from point targets
- Simulation of interference
- Simulation of radar baseband data from 3D modeled objects/environment (
#raytracing
) - Simulation of target's RCS (
#raytracing
) - Simulation of LiDAR point cloud from 3D modeled objects/environment (
#raytracing
)
-
- Range/Doppler processing
- Direction of arrival (DoA) estimation
- MUltiple SIgnal Classification (MUSIC) DoA estimations for a uniform linear array (ULA)
- Root-MUSIC DoA estimation for a ULA
- Estimation of Signal Parameters via Rational Invariance Techniques (ESPRIT) DoA estimation for a ULA
- Beamformer
- Capon beamformer
- Bartlett beamformer
- Constant false alarm rate (CFAR)
- 1D/2D cell-averaging CFAR (CA-CFAR)
- 1D/2D ordered-statistic CFAR (OS-CFAR)
-
- Radar detection characteristics based on Swerling's models
- numpy
- scipy
- pymeshlab (preferred) or meshio
- Visual C++ Runtime (
Windows
)
To use the module, please put the radarsimpy folder within your project folder as shown below.
-
- your_project.py
- your_project.ipynb
- radarsimpy
- __init__.py
- radarsimcpp.dll
- scene.xxx.pyd
- ...
-
- your_project.py
- your_project.ipynb
- radarsimpy
- __init__.py
- libradarsimcpp.so
- scene.xxx.so
- ...
This module supports CPU/GPU parallelization. CPU parallelization is implemented through OpenMP. GPU parallelization (CUDA) has been added since v6.0.0.
CPU | GPU (CUDA) | |
---|---|---|
Windows | ✅ | ✅ |
Linux | ✅ | ✅ |
macOS | ❌ | ❌ |
-
- axis (m):
[x, y, z]
- phi (deg): angle on the x-y plane. 0 deg is the positive x-axis, 90 deg is the positive y-axis
- theta (deg): angle on the z-x plane. 0 deg is the positive z-axis, 90 deg is the x-y plane
- azimuth (deg): azimuth -90 ~ 90 deg equal to phi -90 ~ 90 deg
- elevation (deg): elevation -90 ~ 90 deg equal to theta 180 ~ 0 deg
- axis (m):
-
- axis (m):
[x, y, z]
- yaw (deg): rotation along the z-axis. Positive yaw rotates the object from the positive x-axis to the positive y-axis
- pitch (deg): rotation along the y-axis. Positive pitch rotates the object from the positive x-axis to the positive z-axis
- roll (deg): rotation along the x-axis. Positive roll rotates the object from the positive z-axis to the negative y-axis
- origin (m):
[x, y, z]
- rotation (deg):
[yaw, pitch, roll]
- rotation (deg/s): rate
[yaw rate, pitch rate, roll rate]
- axis (m):
The source files of these Jupyter notebooks are available here.
Building radarsimpy
requires to access the source code of radarsimcpp
. If you don't have access to radarsimcpp
, please use the pre-built module instead
- Windows CPU
build_win.bat
- Windows CUDA
build_win_cuda.bat
- Linux CPU
./build_linux.sh
- Linux CUDA
./build_linux_cuda.sh
-
Radar Model: Classes to define a radar system
radarsimpy.Transmitter
: Radar transmitterradarsimpy.Receiver
: Radar receiverradarsimpy.Radar
: Radar system
-
Simulator: Radar baseband signal simulator
radarsimpy.simulator.simc
: Simulates and generates raw time domain baseband data (C++/CUDA engine)
-
Raytracing: Raytracing module for radar scene simulation
radarsimpy.rt.lidar_scene
: Simulates LiDAR's point cloud based on a 3D environment model with ray tracingradarsimpy.rt.rcs_sbr
: Simulates target's radar cross section (RCS) based on the 3D model with ray tracingradarsimpy.rt.scene
: Simulates radar's response signal in a 3D environment model with ray tracing
-
Processing: Basic radar signal processing module
radarsimpy.processing.range_fft
: Calculate range profile matrixradarsimpy.processing.doppler_fft
: Calculate range-Doppler matrixradarsimpy.processing.range_doppler_fft
: Range-Doppler processingradarsimpy.processing.cfar_ca_1d
: 1D Cell Averaging CFAR (CA-CFAR)radarsimpy.processing.cfar_ca_2d
: 2D Cell Averaging CFAR (CA-CFAR)radarsimpy.processing.cfar_os_1d
: 1D Ordered Statistic CFAR (OS-CFAR)radarsimpy.processing.cfar_os_2d
: 2D Ordered Statistic CFAR (OS-CFAR)radarsimpy.processing.doa_music
: Estimate DoA using MUSIC for a ULAradarsimpy.processing.doa_root_music
: Estimate DoA using Root-MUSIC for a ULAradarsimpy.processing.doa_esprit
: Estimate DoA using ESPRIT for a ULAradarsimpy.processing.doa_capon
: Capon (MVDR) beamforming for a ULAradarsimpy.processing.doa_bartlett
: Bartlett beamforming for a ULA
-
Tools: Receiver operating characteristic analysis
radarsimpy.tools.roc_pd
: Calculate probability of detection (Pd) in receiver operating characteristic (ROC)radarsimpy.tools.roc_snr
: Calculate the minimal SNR for a certain probability of detection (Pd) and probability of false alarm (Pfa) in receiver operating characteristic (ROC)