generate_fft_report
Generate an FFT spectrum report from vibration signal data to detect machinery faults. Produces an HTML file with peak detection and harmonic labeling.
Instructions
Generate professional FFT spectrum report as HTML file.
**NEW PREFERRED METHOD**: Generates a professional HTML report file
instead of inline content. Saves to reports/ directory.
Args:
signal_file: Signal filename in data/signals/
sampling_rate: Sampling rate in Hz (auto-detect if None)
max_freq: Maximum frequency to display (Hz). Default 5000 Hz
num_peaks: Number of peaks to detect and label. Default 15
rotation_freq: Optional shaft rotation frequency for harmonic labels
ctx: MCP context
Returns:
Dictionary with file path, metadata, and summary (NO HTML content)
Example:
>>> result = generate_fft_report("real_train/baseline_1.csv")
>>> # User can open: result['file_path']
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| signal_file | Yes | ||
| sampling_rate | No | ||
| max_freq | No | ||
| num_peaks | No | ||
| rotation_freq | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||