Multi-Sensor Fusion for Defense Applications
结合天基持续红外(OPIR)热探测与射频(RF)地理定位的先进多情报融合系统,实现实时威胁探测与跟踪
## 项目概述
SENTINEL-XF 是一款面向国防应用的生产级机器学习平台,展示了传感器融合、地理定位算法和多传感器跟踪方面的专业能力。该系统将热事件探测与射频信号处理相结合,提供全面的态势感知。
**核心能力:**
- 实时 OPIR 热事件探测与分类
- 使用 TDOA/FDOA 算法进行射频辐射源地理定位
- 基于卡尔曼滤波的多传感器数据融合
- 航迹质量评估与不确定性量化
- 支持多种传感器模态的可扩展架构
## 为什么传感器融合至关重要:乘法效应
考虑这样一个场景:OPIR 卫星探测到与导弹发射一致的热异常。置信度:70%。同时,射频地理定位系统以 50 米不确定性识别出一个辐射源。置信度:80%。
**朴素方法**:分别独立报告两者。
**融合方法**:使用协方差加权结合测量值。
数学原理简单但强大。使用协方差交集,融合后的位置不确定性变为:
其中 `P` 表示位置协方差矩阵。融合后的不确定性**始终低于**任何单一测量值。这不仅仅是数据组合;而是从任何单一传感器都无法单独提供的信息中提取信息。
## 系统架构
### 信号生成与数据管道
- **OPIR 信号生成器**:基于物理的热特征建模
- 5 种事件类型:导弹发射、爆炸、森林火灾、飞机、背景
- 逼真的时间动态和噪声特性
- **RF 信号生成器**:通信和雷达信号模拟
- **训练数据集**:10,000+ 个标记样本,为 PyTorch 训练组织
### 探测、分类与跟踪
- **探测算法**:4 种互补方法
- 时间差分探测
- 异常探测(MAD 和 Z-Score)
- 上升时间分析
- 多方法集成
- **CNN 分类器**:一维卷积神经网络
- 5 类事件分类
- 256 样本输入,带批归一化
- Dropout 正则化以提高泛化能力
- **卡尔曼滤波跟踪**:带 coasting 和 pruning 的多目标跟踪
### RF 地理定位与传感器融合
- **TDOA 地理定位**:到达时间差定位
- 最小二乘优化
- GDOP 计算以评估质量
- **FDOA 地理定位**:用于移动辐射源的到达频率差
- 基于多普勒的速度估计
- 传感器运动补偿
- **混合 TDOA/FDOA**:结合时间和频率测量
- 通过互补数据提高精度
- **传感器融合引擎**:多传感器航迹管理
- 基于马氏距离门控的数据关联
- 协方差加权测量融合
- 航迹质量评分和置信度估计
- 不确定性量化(CEP、位置/速度协方差)
## 项目结构
```
sentinel-multi-intel-platform/
│
├── src/
│ ├── models/
│ │ ├── signal_generator.py # OPIR thermal signature generation
│ │ ├── rf_generator.py # RF signal generation
│ │ └── cnn_classifier.py # Event classification CNN
│ │
│ ├── detection/
│ │ └── opir_detectors.py # 4 detection algorithms
│ │
│ ├── tracking/
│ │ └── kalman_tracker.py # Multi-target Kalman tracking
│ │
│ ├── geolocation/
│ │ ├── tdoa_fdoa.py # TDOA/FDOA geolocation
│ │ └── multilateration.py # Spherical/hyperbolic positioning
│ │
│ ├── fusion/
│ │ └── sensor_fusion.py # Multi-sensor fusion engine
│ │
│ ├── training/
│ │ └── train_classifier.py # CNN training pipeline
│ │
│ └── pipeline/
│ ├── phase2_pipeline.py # OPIR detection pipeline
│ └── phase3_pipeline.py # Full multi-sensor pipeline
│
├── scripts/
│ └── generate_opir_dataset.py # Training data generation
│
├── tests/
│ ├── test_0_generator.py # Signal generator tests
│ ├── test_1_detection.py # Detection algorithm tests
│ ├── test_2_cnn.py # CNN architecture tests
│ ├── test_3_classifier.py # Classifier wrapper tests
│ ├── test_4_kalman.py # Kalman filter tests
│ ├── test_5_tracker.py # Multi-target tracking tests
│ ├── test_6_tdoa_fdoa.py # TDOA/FDOA geolocation tests
│ ├── test_7_multilateration.py # Multilateration tests
│ ├── test_8_sensor_fusion.py # Sensor fusion tests
│ └── test_9_full_system.py # Complete system integration test
│
├── data/
│ ├── raw/
│ ├── processed/
│ └── synthetic/
│ └── opir/
│ ├── train/ # Training data (5 classes)
│ ├── validation/ # Validation data
│ └── test/ # Test data
│
└── outputs/
└── models/ # Trained model checkpoints
```
## 安装
### 设置
```
# 克隆仓库
git clone https://github.com/michael-gurule/sentinel-multi-intel-platform.git
cd sentinel-multi-intel-platform
# 创建虚拟环境
# 安装依赖项
pip install torch torchvision
pip install numpy scipy pandas matplotlib
# 验证安装
python -c "import torch; print(f'PyTorch {torch.__version__} installed')"
```
## 使用方法
### 快速开始:完整系统演示
```
from src.pipeline.phase3_pipeline import demo_phase3_system
# 运行完整的多传感器演示
demo_phase3_system()
```
### OPIR 探测与分类
```
from src.models.signal_generator import OPIRSignalGenerator
from src.detection.opir_detectors import MultiMethodDetector
from src.models.cnn_classifier import OPIRClassifier
# 生成信号
generator = OPIRSignalGenerator()
signal = generator.generate_launch_signature(start_time=2.0)
# 检测事件
detector = MultiMethodDetector()
detection = detector.detect(signal, generator.sampling_rate)
# 分类事件
classifier = OPIRClassifier(device='cpu')
classification = classifier.classify(signal)
print(f"Detected: {detection.detected}")
print(f"Event type: {classification.class_name}")
print(f"Confidence: {classification.confidence:.3f}")
```
### RF 地理定位
```
from src.geolocation.tdoa_fdoa import (
HybridTDOAFDOA,
SensorPosition,
simulate_tdoa_measurements
)
import numpy as np
# 定义传感器网络(混合高度部署)
sensors = [
SensorPosition(id=0, position=np.array([0.0, 0.0, 500.0])),
SensorPosition(id=1, position=np.array([10000.0, 0.0, 1500.0])),
SensorPosition(id=2, position=np.array([10000.0, 10000.0, 1000.0])),
SensorPosition(id=3, position=np.array([0.0, 10000.0, 2000.0]))
]
# 模拟测量
emitter_pos = np.array([5000.0, 5000.0, 500.0])
measurements = simulate_tdoa_measurements(emitter_pos, sensors)
# 定位发射器
solver = HybridTDOAFDOA(carrier_freq=1e9)
result = solver.estimate(sensors, measurements)
print(f"Estimated position: {result.position}")
print(f"Position error: {np.linalg.norm(result.position - emitter_pos):.1f} m")
print(f"GDOP: {result.gdop:.3f}")
```
### 多传感器融合
```
from src.pipeline.phase3_pipeline import SENTINELPhase3Pipeline
from src.models.signal_generator import OPIRSignalGenerator
from src.geolocation.tdoa_fdoa import simulate_tdoa_measurements
import numpy as np
# 初始化系统
pipeline = SENTINELPhase3Pipeline()
# 生成多传感器帧
generator = OPIRSignalGenerator()
opir_signals = [generator.generate_launch_signature(start_time=2.0)]
emitter_pos = np.array([5000.0, 5000.0, 500.0])
rf_measurements = [simulate_tdoa_measurements(emitter_pos, pipeline.sensors)]
# 处理帧
result = pipeline.process_multi_sensor_frame(
opir_signals=opir_signals,
rf_measurements=rf_measurements,
sampling_rate=generator.sampling_rate,
timestamp=0.0
)
print(f"OPIR detections: {result['opir_detections']}")
print(f"RF geolocations: {result['rf_geolocations']}")
print(f"Fused tracks: {result['fused_tracks']}")
# 获取态势感知
sa = pipeline.get_situation_awareness()
print(f"Track quality: {sa['average_track_quality']:.3f}")
```
### 训练 CNN 分类器
```
from src.training.train_classifier import train_model_from_folders
# 在生成的数据集上训练模型
history = train_model_from_folders(
train_dir='data/synthetic/opir/train',
val_dir='data/synthetic/opir/validation',
output_dir='outputs/models',
num_epochs=50,
batch_size=32,
device='cpu' # or 'cuda' for GPU
)
print(f"Best validation accuracy: {max(history['val_acc']):.2f}%")
```
## 测试
### 运行单个组件测试
```
# 测试信号生成
python tests/test_0_generator.py
# 测试检测算法
python tests/test_1_detection.py
# 测试CNN架构
python tests/test_2_cnn.py
# 测试TDOA/FDOA定位
python tests/test_6_tdoa_fdoa.py
# 测试多点定位
python tests/test_7_multilateration.py
# 测试传感器融合
python tests/test_8_sensor_fusion.py
# 测试完整系统
python tests/test_9_full_system.py
```
### 预期测试结果
- 探测算法:75-100% 探测率
- CNN 前向传播:成功处理 4-5 类
- 卡尔曼跟踪:10 步平均误差 <5m
- TDOA 地理定位:位置误差 <50m(4 个传感器,低噪声)
- FDOA 速度估计:速度误差 <20 m/s
- 传感器融合:高置信度航迹的航迹质量 >0.7
- 完整系统:成功创建和维护融合航迹
## 性能指标
### 地理定位精度
- **位置误差**:10-50m(取决于传感器几何和噪声)
- **GDOP**:2-5(混合高度传感器几何良好)
- **收敛率**:4 个以上传感器 >95%
### 探测性能
- **时间差分**:80-90% 探测率
- **异常探测**:75-85% 探测率
- **多方法集成**:90-95% 探测率
### 分类精度(未训练模型)
- 随机基线:~20%(5 类)
- 训练后:预期 85-95% 验证精度
### 传感器融合质量
- **航迹质量**:多传感器航迹 0.7-0.9
- **位置不确定性**:20-100m CEP(50% 置信度)
- **速度不确定性**:5-20 m/s 标准差
## 技术亮点
### 算法实现
**探测算法:**
- 自适应阈值时间差分
- 基于 MAD 的异常探测用于离群值识别
- 上升时间分析用于特征表征
- 集成投票用于稳健探测
**地理定位方法:**
- 使用 Levenberg-Marquardt 优化的最小二乘 TDOA 定位
- 多普勒频移 FDOA 用于速度估计
- Chan's 算法用于闭式双曲线定位
- 带协方差估计的加权最小二乘
**传感器融合:**
- 马氏距离门控用于数据关联
- 协方差交集用于多传感器融合
- 扩展卡尔曼滤波用于航迹传播
- 基于置信度、不确定性和传感器多样性的航迹质量评分
## 参考资料
**地理定位算法:**
- Y. T. Chan 和 K. C. Ho,"一种简单有效的双曲线定位估计器"
- K. C. Ho 和 W. Xu,"运动源定位的精确代数解"
**传感器融合:**
- S. Blackman 和 R. Popoli,"现代跟踪系统的设计与分析"
- Y. Bar-Shalom 等,"估计理论及其在跟踪和导航中的应用"
**信号处理:**
- S. Kay,"统计信号处理基础:检测理论"