34 lines
805 B
Python
34 lines
805 B
Python
#!/usr/bin/env python3
|
|
# -*- coding: utf-8 -*-
|
|
"""
|
|
车牌检测系统主程序
|
|
基于YOLO11s模型的实时车牌检测应用
|
|
"""
|
|
|
|
import sys
|
|
import os
|
|
from PyQt5.QtWidgets import QApplication
|
|
from PyQt5.QtCore import Qt
|
|
from ui.main_window import MainWindow
|
|
|
|
def main():
|
|
"""主函数"""
|
|
# 创建QApplication实例
|
|
app = QApplication(sys.argv)
|
|
app.setAttribute(Qt.AA_EnableHighDpiScaling, True)
|
|
app.setAttribute(Qt.AA_UseHighDpiPixmaps, True)
|
|
|
|
# 设置应用信息
|
|
app.setApplicationName("车牌检测系统")
|
|
app.setApplicationVersion("1.0.0")
|
|
app.setOrganizationName("License Plate Detection")
|
|
|
|
# 创建主窗口
|
|
main_window = MainWindow()
|
|
main_window.show()
|
|
|
|
# 运行应用
|
|
sys.exit(app.exec_())
|
|
|
|
if __name__ == "__main__":
|
|
main() |