Skip to content

Commit 9f43308

Browse files
refactor: Migrate entire codebase from PyQt6 to PySide6 for Nuitka macOS threading support
1 parent 0010fe1 commit 9f43308

25 files changed

Lines changed: 94 additions & 94 deletions

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ jobs:
5151
nuitka-version: main
5252
script-name: run_gui.py
5353
mode: onefile
54-
enable-plugins: pyqt6
54+
enable-plugins: pyside6
5555
output-file: RadarSim
5656

5757
- name: Package Windows

capture_screenshots.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@
1616
sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
1717

1818
import numpy as np
19-
from PyQt6.QtCore import QTimer
20-
from PyQt6.QtGui import QScreen
21-
from PyQt6.QtWidgets import QApplication
19+
from PySide6.QtCore import QTimer
20+
from PySide6.QtGui import QScreen
21+
from PySide6.QtWidgets import QApplication
2222

2323

2424
def capture_screenshots():

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ matplotlib>=3.4.0
77
numba>=0.56.0
88

99
# GUI Framework (Required)
10-
PyQt6>=6.0.0
10+
PySide6>=6.0.0
1111
pyqtgraph>=0.13.0
1212

1313
# Data Storage & Config

run_gui.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"""
33
RadarSim - Professional Radar Operator Console
44
5-
Launch the modern PyQt6-based radar simulation GUI.
5+
Launch the modern PySide6-based radar simulation GUI.
66
77
Usage:
88
python run_gui.py
@@ -47,11 +47,11 @@ def main():
4747

4848
# Check dependencies
4949
try:
50-
from PyQt6.QtWidgets import QApplication
50+
from PySide6.QtWidgets import QApplication
5151

52-
print("✓ PyQt6 OK")
52+
print("✓ PySide6 OK")
5353
except ImportError:
54-
print("✗ PyQt6 not installed. Run: pip install PyQt6")
54+
print("✗ PySide6 not installed. Run: pip install PySide6")
5555
return 1
5656

5757
try:
@@ -96,7 +96,7 @@ def main():
9696
app.setStyle("Fusion")
9797

9898
# Apply dark theme palette
99-
from PyQt6.QtGui import QColor, QPalette
99+
from PySide6.QtGui import QColor, QPalette
100100

101101
palette = QPalette()
102102
palette.setColor(QPalette.ColorRole.Window, QColor(10, 25, 15))

src/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
- 3D radar physics (ITU-R P.676, Swerling RCS)
66
- Target tracking and simulation
77
- ECM/ECCM simulation
8-
- Modern PyQt6 visualization
8+
- Modern PySide6 visualization
99
"""
1010

1111
# Re-export from modern subpackages

src/ui/a_scope.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@
1818

1919
import numpy as np
2020
import pyqtgraph as pg
21-
from PyQt6.QtCore import Qt, pyqtSlot
22-
from PyQt6.QtGui import QColor
23-
from PyQt6.QtWidgets import QHBoxLayout, QLabel, QVBoxLayout, QWidget
21+
from PySide6.QtCore import Qt, Slot
22+
from PySide6.QtGui import QColor
23+
from PySide6.QtWidgets import QHBoxLayout, QLabel, QVBoxLayout, QWidget
2424

2525

2626
class AScope(QWidget):
@@ -279,7 +279,7 @@ def _hide_cfar_cells(self):
279279
self.ref_region_right.setVisible(False)
280280
self.cfar_label.setText("Hover over plot to see CFAR cells")
281281

282-
@pyqtSlot(dict)
282+
@Slot(dict)
283283
def update_display(self, state: Dict[str, Any]):
284284
"""
285285
Update display with new simulation state.

src/ui/analysis/ambiguity_plot.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@
1414
"""
1515

1616
import numpy as np
17-
from PyQt6.QtCore import Qt
18-
from PyQt6.QtGui import QColor, QFont
19-
from PyQt6.QtWidgets import (
17+
from PySide6.QtCore import Qt
18+
from PySide6.QtGui import QColor, QFont
19+
from PySide6.QtWidgets import (
2020
QFrame,
2121
QGridLayout,
2222
QGroupBox,
@@ -363,7 +363,7 @@ def _draw_curves(self):
363363
if __name__ == "__main__":
364364
import sys
365365

366-
from PyQt6.QtWidgets import QApplication
366+
from PySide6.QtWidgets import QApplication
367367

368368
app = QApplication(sys.argv)
369369
widget = AmbiguityPlot()

src/ui/analysis/roc_curve.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
Reference: Skolnik, "Radar Handbook", Chapter 2
88
"""
99

10-
from PyQt6.QtCore import Qt
11-
from PyQt6.QtGui import QFont
12-
from PyQt6.QtWidgets import (
10+
from PySide6.QtCore import Qt
11+
from PySide6.QtGui import QFont
12+
from PySide6.QtWidgets import (
1313
QComboBox,
1414
QGridLayout,
1515
QGroupBox,
@@ -328,7 +328,7 @@ def _update_operating_point(self):
328328
if __name__ == "__main__":
329329
import sys
330330

331-
from PyQt6.QtWidgets import QApplication
331+
from PySide6.QtWidgets import QApplication
332332

333333
app = QApplication(sys.argv)
334334
widget = ROCCurveWidget()

src/ui/analysis/snr_histogram.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313
from collections import deque
1414

1515
import numpy as np
16-
from PyQt6.QtCore import Qt
17-
from PyQt6.QtGui import QFont
18-
from PyQt6.QtWidgets import (
16+
from PySide6.QtCore import Qt
17+
from PySide6.QtGui import QFont
18+
from PySide6.QtWidgets import (
1919
QGridLayout,
2020
QGroupBox,
2121
QHBoxLayout,
@@ -338,7 +338,7 @@ def _clear_history(self):
338338
if __name__ == "__main__":
339339
import sys
340340

341-
from PyQt6.QtWidgets import QApplication
341+
from PySide6.QtWidgets import QApplication
342342

343343
app = QApplication(sys.argv)
344344
widget = SNRHistogramWidget()

src/ui/analysis_panel.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
from typing import Optional
1313

1414
import numpy as np
15-
from PyQt6.QtCore import Qt
16-
from PyQt6.QtWidgets import QComboBox, QFrame, QHBoxLayout, QLabel, QVBoxLayout, QWidget
15+
from PySide6.QtCore import Qt
16+
from PySide6.QtWidgets import QComboBox, QFrame, QHBoxLayout, QLabel, QVBoxLayout, QWidget
1717

1818
try:
1919
import pyqtgraph as pg

0 commit comments

Comments
 (0)