# -*- coding: utf-8 -*-

# Form implementation generated from reading ui file 'test_mod.ui'
#
# Created by: PyQt5 UI code generator 5.15.2
#
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
# run again.  Do not edit this file unless you know what you are doing.


from PyQt5 import QtCore, QtGui, QtWidgets
from PyQt5.QtWidgets import QMessageBox
import numpy as np
import cv2
from scipy.spatial import distance as dist
import argparse
import imutils
import os

class Ui_VehicleCollisionAlertSystem(object):

    def __init__(self):
        self.inp_fileName = None
        self.out_fileName = "traffic_collisionAlert.mp4"
        self.outSlow_fileName = "output_correct.avi"


    def setupUi(self, VehicleCollisionAlertSystem):
        VehicleCollisionAlertSystem.setObjectName("VehicleCollisionAlertSystem")
        VehicleCollisionAlertSystem.resize(800, 600)
        VehicleCollisionAlertSystem.setStyleSheet("background-color: rgb(170, 170, 255);")
        self.centralwidget = QtWidgets.QWidget(VehicleCollisionAlertSystem)
        self.centralwidget.setObjectName("centralwidget")
        self.widget = QtWidgets.QWidget(self.centralwidget)
        self.widget.setGeometry(QtCore.QRect(100, 50, 585, 481))
        self.widget.setObjectName("widget")
        self.verticalLayout = QtWidgets.QVBoxLayout(self.widget)
        self.verticalLayout.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout.setObjectName("verticalLayout")
        self.pushButton = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.pushButton.setFont(font)
        self.pushButton.setObjectName("pushButton")
        self.verticalLayout.addWidget(self.pushButton)
        self.button1 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.button1.setFont(font)
        self.button1.setObjectName("button1")
        self.verticalLayout.addWidget(self.button1)
        self.button2 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.button2.setFont(font)
        self.button2.setObjectName("button2")
        self.verticalLayout.addWidget(self.button2)
        self.button3 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(28)
        font.setBold(True)
        font.setWeight(75)
        self.button3.setFont(font)
        self.button3.setObjectName("button3")
        self.verticalLayout.addWidget(self.button3)
        VehicleCollisionAlertSystem.setCentralWidget(self.centralwidget)
        self.menubar = QtWidgets.QMenuBar(VehicleCollisionAlertSystem)
        self.menubar.setGeometry(QtCore.QRect(0, 0, 800, 21))
        self.menubar.setObjectName("menubar")
        VehicleCollisionAlertSystem.setMenuBar(self.menubar)
        self.statusbar = QtWidgets.QStatusBar(VehicleCollisionAlertSystem)
        self.statusbar.setObjectName("statusbar")
        VehicleCollisionAlertSystem.setStatusBar(self.statusbar)

        self.retranslateUi(VehicleCollisionAlertSystem)
        QtCore.QMetaObject.connectSlotsByName(VehicleCollisionAlertSystem)

        self.pushButton.clicked.connect(self.getfiles)
        self.button1.clicked.connect(self.play_inp_video)
        self.button2.clicked.connect(self.detect_vehicles)
        self.button3.clicked.connect(self.play_out_video)

    def retranslateUi(self, VehicleCollisionAlertSystem):
        _translate = QtCore.QCoreApplication.translate
        VehicleCollisionAlertSystem.setWindowTitle(_translate("VehicleCollisionAlertSystem", "MainWindow"))
        self.pushButton.setText(_translate("VehicleCollisionAlertSystem", "Select Input video"))
        self.button1.setText(_translate("VehicleCollisionAlertSystem", "View Input video"))
        self.button2.setText(_translate("VehicleCollisionAlertSystem", "Perform Vehicle collision alert !!!"))
        self.button3.setText(_translate("VehicleCollisionAlertSystem", "View Output video"))

    def getfiles(self):
        self.inp_fileName, _ = QtWidgets.QFileDialog.getOpenFileName(None, 'Single File', '', '*.mp4')
    
    def play_inp_video(self):
        vs = cv2.VideoCapture(self.inp_fileName)

        while(True):
            ret, frame = vs.read()
            if ret == False:
                break

            cv2.imshow('original',frame)
            while(cv2.waitKey(1) & 0xFF == ord('q')):
                break

        vs.release()
        cv2.destroyAllWindows()
    
    def play_out_video(self):
        vs = cv2.VideoCapture(self.out_fileName)

        while(True):
            ret, frame = vs.read()
            if ret == False:
                break

            cv2.imshow('original',frame)
            while(cv2.waitKey(1) & 0xFF == ord('q')):
                break

        vs.release()
        cv2.destroyAllWindows()
    
    def detect_vehicles(self):
        os.system('python detect_vehicles.py --input {} --output {}'.format(self.inp_fileName, self.outSlow_fileName))
        self.show_popup()

    def show_popup(self):
        msg = QMessageBox()
        msg.setWindowTitle("Alert")
        msg.setText("Detection done, click output button to view results")

        x = msg.exec_()




if __name__ == "__main__":
    import sys
    app = QtWidgets.QApplication(sys.argv)
    VehicleCollisionAlertSystem = QtWidgets.QMainWindow()
    ui = Ui_VehicleCollisionAlertSystem()
    ui.setupUi(VehicleCollisionAlertSystem)
    VehicleCollisionAlertSystem.show()
    sys.exit(app.exec_())

de760a561594b348e719c05337a4840525646530
<mask token>


class Ui_VehicleCollisionAlertSystem(object):

    def __init__(self):
        self.inp_fileName = None
        self.out_fileName = 'traffic_collisionAlert.mp4'
        self.outSlow_fileName = 'output_correct.avi'
    <mask token>

    def retranslateUi(self, VehicleCollisionAlertSystem):
        _translate = QtCore.QCoreApplication.translate
        VehicleCollisionAlertSystem.setWindowTitle(_translate(
            'VehicleCollisionAlertSystem', 'MainWindow'))
        self.pushButton.setText(_translate('VehicleCollisionAlertSystem',
            'Select Input video'))
        self.button1.setText(_translate('VehicleCollisionAlertSystem',
            'View Input video'))
        self.button2.setText(_translate('VehicleCollisionAlertSystem',
            'Perform Vehicle collision alert !!!'))
        self.button3.setText(_translate('VehicleCollisionAlertSystem',
            'View Output video'))
    <mask token>

    def play_inp_video(self):
        vs = cv2.VideoCapture(self.inp_fileName)
        while True:
            ret, frame = vs.read()
            if ret == False:
                break
            cv2.imshow('original', frame)
            while cv2.waitKey(1) & 255 == ord('q'):
                break
        vs.release()
        cv2.destroyAllWindows()
    <mask token>

    def detect_vehicles(self):
        os.system('python detect_vehicles.py --input {} --output {}'.format
            (self.inp_fileName, self.outSlow_fileName))
        self.show_popup()
    <mask token>


<mask token>

<mask token>


class Ui_VehicleCollisionAlertSystem(object):

    def __init__(self):
        self.inp_fileName = None
        self.out_fileName = 'traffic_collisionAlert.mp4'
        self.outSlow_fileName = 'output_correct.avi'
    <mask token>

    def retranslateUi(self, VehicleCollisionAlertSystem):
        _translate = QtCore.QCoreApplication.translate
        VehicleCollisionAlertSystem.setWindowTitle(_translate(
            'VehicleCollisionAlertSystem', 'MainWindow'))
        self.pushButton.setText(_translate('VehicleCollisionAlertSystem',
            'Select Input video'))
        self.button1.setText(_translate('VehicleCollisionAlertSystem',
            'View Input video'))
        self.button2.setText(_translate('VehicleCollisionAlertSystem',
            'Perform Vehicle collision alert !!!'))
        self.button3.setText(_translate('VehicleCollisionAlertSystem',
            'View Output video'))
    <mask token>

    def play_inp_video(self):
        vs = cv2.VideoCapture(self.inp_fileName)
        while True:
            ret, frame = vs.read()
            if ret == False:
                break
            cv2.imshow('original', frame)
            while cv2.waitKey(1) & 255 == ord('q'):
                break
        vs.release()
        cv2.destroyAllWindows()

    def play_out_video(self):
        vs = cv2.VideoCapture(self.out_fileName)
        while True:
            ret, frame = vs.read()
            if ret == False:
                break
            cv2.imshow('original', frame)
            while cv2.waitKey(1) & 255 == ord('q'):
                break
        vs.release()
        cv2.destroyAllWindows()

    def detect_vehicles(self):
        os.system('python detect_vehicles.py --input {} --output {}'.format
            (self.inp_fileName, self.outSlow_fileName))
        self.show_popup()
    <mask token>


<mask token>

<mask token>


class Ui_VehicleCollisionAlertSystem(object):

    def __init__(self):
        self.inp_fileName = None
        self.out_fileName = 'traffic_collisionAlert.mp4'
        self.outSlow_fileName = 'output_correct.avi'

    def setupUi(self, VehicleCollisionAlertSystem):
        VehicleCollisionAlertSystem.setObjectName('VehicleCollisionAlertSystem'
            )
        VehicleCollisionAlertSystem.resize(800, 600)
        VehicleCollisionAlertSystem.setStyleSheet(
            'background-color: rgb(170, 170, 255);')
        self.centralwidget = QtWidgets.QWidget(VehicleCollisionAlertSystem)
        self.centralwidget.setObjectName('centralwidget')
        self.widget = QtWidgets.QWidget(self.centralwidget)
        self.widget.setGeometry(QtCore.QRect(100, 50, 585, 481))
        self.widget.setObjectName('widget')
        self.verticalLayout = QtWidgets.QVBoxLayout(self.widget)
        self.verticalLayout.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout.setObjectName('verticalLayout')
        self.pushButton = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.pushButton.setFont(font)
        self.pushButton.setObjectName('pushButton')
        self.verticalLayout.addWidget(self.pushButton)
        self.button1 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.button1.setFont(font)
        self.button1.setObjectName('button1')
        self.verticalLayout.addWidget(self.button1)
        self.button2 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.button2.setFont(font)
        self.button2.setObjectName('button2')
        self.verticalLayout.addWidget(self.button2)
        self.button3 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(28)
        font.setBold(True)
        font.setWeight(75)
        self.button3.setFont(font)
        self.button3.setObjectName('button3')
        self.verticalLayout.addWidget(self.button3)
        VehicleCollisionAlertSystem.setCentralWidget(self.centralwidget)
        self.menubar = QtWidgets.QMenuBar(VehicleCollisionAlertSystem)
        self.menubar.setGeometry(QtCore.QRect(0, 0, 800, 21))
        self.menubar.setObjectName('menubar')
        VehicleCollisionAlertSystem.setMenuBar(self.menubar)
        self.statusbar = QtWidgets.QStatusBar(VehicleCollisionAlertSystem)
        self.statusbar.setObjectName('statusbar')
        VehicleCollisionAlertSystem.setStatusBar(self.statusbar)
        self.retranslateUi(VehicleCollisionAlertSystem)
        QtCore.QMetaObject.connectSlotsByName(VehicleCollisionAlertSystem)
        self.pushButton.clicked.connect(self.getfiles)
        self.button1.clicked.connect(self.play_inp_video)
        self.button2.clicked.connect(self.detect_vehicles)
        self.button3.clicked.connect(self.play_out_video)

    def retranslateUi(self, VehicleCollisionAlertSystem):
        _translate = QtCore.QCoreApplication.translate
        VehicleCollisionAlertSystem.setWindowTitle(_translate(
            'VehicleCollisionAlertSystem', 'MainWindow'))
        self.pushButton.setText(_translate('VehicleCollisionAlertSystem',
            'Select Input video'))
        self.button1.setText(_translate('VehicleCollisionAlertSystem',
            'View Input video'))
        self.button2.setText(_translate('VehicleCollisionAlertSystem',
            'Perform Vehicle collision alert !!!'))
        self.button3.setText(_translate('VehicleCollisionAlertSystem',
            'View Output video'))
    <mask token>

    def play_inp_video(self):
        vs = cv2.VideoCapture(self.inp_fileName)
        while True:
            ret, frame = vs.read()
            if ret == False:
                break
            cv2.imshow('original', frame)
            while cv2.waitKey(1) & 255 == ord('q'):
                break
        vs.release()
        cv2.destroyAllWindows()

    def play_out_video(self):
        vs = cv2.VideoCapture(self.out_fileName)
        while True:
            ret, frame = vs.read()
            if ret == False:
                break
            cv2.imshow('original', frame)
            while cv2.waitKey(1) & 255 == ord('q'):
                break
        vs.release()
        cv2.destroyAllWindows()

    def detect_vehicles(self):
        os.system('python detect_vehicles.py --input {} --output {}'.format
            (self.inp_fileName, self.outSlow_fileName))
        self.show_popup()
    <mask token>


<mask token>

from PyQt5 import QtCore, QtGui, QtWidgets
from PyQt5.QtWidgets import QMessageBox
import numpy as np
import cv2
from scipy.spatial import distance as dist
import argparse
import imutils
import os


class Ui_VehicleCollisionAlertSystem(object):

    def __init__(self):
        self.inp_fileName = None
        self.out_fileName = 'traffic_collisionAlert.mp4'
        self.outSlow_fileName = 'output_correct.avi'

    def setupUi(self, VehicleCollisionAlertSystem):
        VehicleCollisionAlertSystem.setObjectName('VehicleCollisionAlertSystem'
            )
        VehicleCollisionAlertSystem.resize(800, 600)
        VehicleCollisionAlertSystem.setStyleSheet(
            'background-color: rgb(170, 170, 255);')
        self.centralwidget = QtWidgets.QWidget(VehicleCollisionAlertSystem)
        self.centralwidget.setObjectName('centralwidget')
        self.widget = QtWidgets.QWidget(self.centralwidget)
        self.widget.setGeometry(QtCore.QRect(100, 50, 585, 481))
        self.widget.setObjectName('widget')
        self.verticalLayout = QtWidgets.QVBoxLayout(self.widget)
        self.verticalLayout.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout.setObjectName('verticalLayout')
        self.pushButton = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.pushButton.setFont(font)
        self.pushButton.setObjectName('pushButton')
        self.verticalLayout.addWidget(self.pushButton)
        self.button1 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.button1.setFont(font)
        self.button1.setObjectName('button1')
        self.verticalLayout.addWidget(self.button1)
        self.button2 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.button2.setFont(font)
        self.button2.setObjectName('button2')
        self.verticalLayout.addWidget(self.button2)
        self.button3 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(28)
        font.setBold(True)
        font.setWeight(75)
        self.button3.setFont(font)
        self.button3.setObjectName('button3')
        self.verticalLayout.addWidget(self.button3)
        VehicleCollisionAlertSystem.setCentralWidget(self.centralwidget)
        self.menubar = QtWidgets.QMenuBar(VehicleCollisionAlertSystem)
        self.menubar.setGeometry(QtCore.QRect(0, 0, 800, 21))
        self.menubar.setObjectName('menubar')
        VehicleCollisionAlertSystem.setMenuBar(self.menubar)
        self.statusbar = QtWidgets.QStatusBar(VehicleCollisionAlertSystem)
        self.statusbar.setObjectName('statusbar')
        VehicleCollisionAlertSystem.setStatusBar(self.statusbar)
        self.retranslateUi(VehicleCollisionAlertSystem)
        QtCore.QMetaObject.connectSlotsByName(VehicleCollisionAlertSystem)
        self.pushButton.clicked.connect(self.getfiles)
        self.button1.clicked.connect(self.play_inp_video)
        self.button2.clicked.connect(self.detect_vehicles)
        self.button3.clicked.connect(self.play_out_video)

    def retranslateUi(self, VehicleCollisionAlertSystem):
        _translate = QtCore.QCoreApplication.translate
        VehicleCollisionAlertSystem.setWindowTitle(_translate(
            'VehicleCollisionAlertSystem', 'MainWindow'))
        self.pushButton.setText(_translate('VehicleCollisionAlertSystem',
            'Select Input video'))
        self.button1.setText(_translate('VehicleCollisionAlertSystem',
            'View Input video'))
        self.button2.setText(_translate('VehicleCollisionAlertSystem',
            'Perform Vehicle collision alert !!!'))
        self.button3.setText(_translate('VehicleCollisionAlertSystem',
            'View Output video'))

    def getfiles(self):
        self.inp_fileName, _ = QtWidgets.QFileDialog.getOpenFileName(None,
            'Single File', '', '*.mp4')

    def play_inp_video(self):
        vs = cv2.VideoCapture(self.inp_fileName)
        while True:
            ret, frame = vs.read()
            if ret == False:
                break
            cv2.imshow('original', frame)
            while cv2.waitKey(1) & 255 == ord('q'):
                break
        vs.release()
        cv2.destroyAllWindows()

    def play_out_video(self):
        vs = cv2.VideoCapture(self.out_fileName)
        while True:
            ret, frame = vs.read()
            if ret == False:
                break
            cv2.imshow('original', frame)
            while cv2.waitKey(1) & 255 == ord('q'):
                break
        vs.release()
        cv2.destroyAllWindows()

    def detect_vehicles(self):
        os.system('python detect_vehicles.py --input {} --output {}'.format
            (self.inp_fileName, self.outSlow_fileName))
        self.show_popup()

    def show_popup(self):
        msg = QMessageBox()
        msg.setWindowTitle('Alert')
        msg.setText('Detection done, click output button to view results')
        x = msg.exec_()


if __name__ == '__main__':
    import sys
    app = QtWidgets.QApplication(sys.argv)
    VehicleCollisionAlertSystem = QtWidgets.QMainWindow()
    ui = Ui_VehicleCollisionAlertSystem()
    ui.setupUi(VehicleCollisionAlertSystem)
    VehicleCollisionAlertSystem.show()
    sys.exit(app.exec_())

# -*- coding: utf-8 -*-

# Form implementation generated from reading ui file 'test_mod.ui'
#
# Created by: PyQt5 UI code generator 5.15.2
#
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
# run again.  Do not edit this file unless you know what you are doing.


from PyQt5 import QtCore, QtGui, QtWidgets
from PyQt5.QtWidgets import QMessageBox
import numpy as np
import cv2
from scipy.spatial import distance as dist
import argparse
import imutils
import os

class Ui_VehicleCollisionAlertSystem(object):

    def __init__(self):
        self.inp_fileName = None
        self.out_fileName = "traffic_collisionAlert.mp4"
        self.outSlow_fileName = "output_correct.avi"


    def setupUi(self, VehicleCollisionAlertSystem):
        VehicleCollisionAlertSystem.setObjectName("VehicleCollisionAlertSystem")
        VehicleCollisionAlertSystem.resize(800, 600)
        VehicleCollisionAlertSystem.setStyleSheet("background-color: rgb(170, 170, 255);")
        self.centralwidget = QtWidgets.QWidget(VehicleCollisionAlertSystem)
        self.centralwidget.setObjectName("centralwidget")
        self.widget = QtWidgets.QWidget(self.centralwidget)
        self.widget.setGeometry(QtCore.QRect(100, 50, 585, 481))
        self.widget.setObjectName("widget")
        self.verticalLayout = QtWidgets.QVBoxLayout(self.widget)
        self.verticalLayout.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout.setObjectName("verticalLayout")
        self.pushButton = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.pushButton.setFont(font)
        self.pushButton.setObjectName("pushButton")
        self.verticalLayout.addWidget(self.pushButton)
        self.button1 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.button1.setFont(font)
        self.button1.setObjectName("button1")
        self.verticalLayout.addWidget(self.button1)
        self.button2 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(26)
        font.setBold(True)
        font.setWeight(75)
        self.button2.setFont(font)
        self.button2.setObjectName("button2")
        self.verticalLayout.addWidget(self.button2)
        self.button3 = QtWidgets.QPushButton(self.widget)
        font = QtGui.QFont()
        font.setPointSize(28)
        font.setBold(True)
        font.setWeight(75)
        self.button3.setFont(font)
        self.button3.setObjectName("button3")
        self.verticalLayout.addWidget(self.button3)
        VehicleCollisionAlertSystem.setCentralWidget(self.centralwidget)
        self.menubar = QtWidgets.QMenuBar(VehicleCollisionAlertSystem)
        self.menubar.setGeometry(QtCore.QRect(0, 0, 800, 21))
        self.menubar.setObjectName("menubar")
        VehicleCollisionAlertSystem.setMenuBar(self.menubar)
        self.statusbar = QtWidgets.QStatusBar(VehicleCollisionAlertSystem)
        self.statusbar.setObjectName("statusbar")
        VehicleCollisionAlertSystem.setStatusBar(self.statusbar)

        self.retranslateUi(VehicleCollisionAlertSystem)
        QtCore.QMetaObject.connectSlotsByName(VehicleCollisionAlertSystem)

        self.pushButton.clicked.connect(self.getfiles)
        self.button1.clicked.connect(self.play_inp_video)
        self.button2.clicked.connect(self.detect_vehicles)
        self.button3.clicked.connect(self.play_out_video)

    def retranslateUi(self, VehicleCollisionAlertSystem):
        _translate = QtCore.QCoreApplication.translate
        VehicleCollisionAlertSystem.setWindowTitle(_translate("VehicleCollisionAlertSystem", "MainWindow"))
        self.pushButton.setText(_translate("VehicleCollisionAlertSystem", "Select Input video"))
        self.button1.setText(_translate("VehicleCollisionAlertSystem", "View Input video"))
        self.button2.setText(_translate("VehicleCollisionAlertSystem", "Perform Vehicle collision alert !!!"))
        self.button3.setText(_translate("VehicleCollisionAlertSystem", "View Output video"))

    def getfiles(self):
        self.inp_fileName, _ = QtWidgets.QFileDialog.getOpenFileName(None, 'Single File', '', '*.mp4')
    
    def play_inp_video(self):
        vs = cv2.VideoCapture(self.inp_fileName)

        while(True):
            ret, frame = vs.read()
            if ret == False:
                break

            cv2.imshow('original',frame)
            while(cv2.waitKey(1) & 0xFF == ord('q')):
                break

        vs.release()
        cv2.destroyAllWindows()
    
    def play_out_video(self):
        vs = cv2.VideoCapture(self.out_fileName)

        while(True):
            ret, frame = vs.read()
            if ret == False:
                break

            cv2.imshow('original',frame)
            while(cv2.waitKey(1) & 0xFF == ord('q')):
                break

        vs.release()
        cv2.destroyAllWindows()
    
    def detect_vehicles(self):
        os.system('python detect_vehicles.py --input {} --output {}'.format(self.inp_fileName, self.outSlow_fileName))
        self.show_popup()

    def show_popup(self):
        msg = QMessageBox()
        msg.setWindowTitle("Alert")
        msg.setText("Detection done, click output button to view results")

        x = msg.exec_()




if __name__ == "__main__":
    import sys
    app = QtWidgets.QApplication(sys.argv)
    VehicleCollisionAlertSystem = QtWidgets.QMainWindow()
    ui = Ui_VehicleCollisionAlertSystem()
    ui.setupUi(VehicleCollisionAlertSystem)
    VehicleCollisionAlertSystem.show()
    sys.exit(app.exec_())
