-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
32 lines (23 loc) · 814 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
# Import necessary libraries
from system import initialize_models, initialize_system
from UI import AudioClassifierApp
import sys
from PyQt5.QtWidgets import QApplication
import warnings
import importlib
# Initialize the system, and reload the voiceModel module
initialize_system()
module = importlib.import_module("voiceModel")
importlib.reload(module)
from voiceModel import getModelVoice
def main():
# Suppress future warnings to clean up the console output
warnings.filterwarnings("ignore", category=FutureWarning)
# Initialize models
initialize_models()
# Create the PyQt5 application instance and execute the event loop
app = QApplication(sys.argv)
ex = AudioClassifierApp()
sys.exit(app.exec_())
if __name__ == '__main__':
main()