-
Notifications
You must be signed in to change notification settings - Fork 0
/
page5.py
166 lines (158 loc) · 8.23 KB
/
page5.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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'page5.ui'
#
# Created by: PyQt5 UI code generator 5.14.1
#
# WARNING! All changes made in this file will be lost!
from PyQt5 import QtCore, QtGui, QtWidgets
class Ui_Form(object):
def setupUi(self, Form):
Form.setObjectName("Form")
Form.resize(666, 744)
self.horizontalSlider_train = QtWidgets.QSlider(Form)
self.horizontalSlider_train.setGeometry(QtCore.QRect(130, 100, 471, 16))
self.horizontalSlider_train.setMaximum(100)
self.horizontalSlider_train.setOrientation(QtCore.Qt.Horizontal)
self.horizontalSlider_train.setObjectName("horizontalSlider_train")
self.horizontalSlider_validation = QtWidgets.QSlider(Form)
self.horizontalSlider_validation.setGeometry(QtCore.QRect(130, 150, 471, 16))
self.horizontalSlider_validation.setMaximum(100)
self.horizontalSlider_validation.setOrientation(QtCore.Qt.Horizontal)
self.horizontalSlider_validation.setObjectName("horizontalSlider_validation")
self.horizontalSlider_test = QtWidgets.QSlider(Form)
self.horizontalSlider_test.setGeometry(QtCore.QRect(130, 200, 471, 16))
self.horizontalSlider_test.setMaximum(100)
self.horizontalSlider_test.setOrientation(QtCore.Qt.Horizontal)
self.horizontalSlider_test.setObjectName("horizontalSlider_test")
self.label = QtWidgets.QLabel(Form)
self.label.setGeometry(QtCore.QRect(30, 100, 67, 17))
self.label.setObjectName("label")
self.label_2 = QtWidgets.QLabel(Form)
self.label_2.setGeometry(QtCore.QRect(30, 150, 71, 17))
self.label_2.setObjectName("label_2")
self.label_3 = QtWidgets.QLabel(Form)
self.label_3.setGeometry(QtCore.QRect(30, 200, 41, 17))
self.label_3.setObjectName("label_3")
self.label_train = QtWidgets.QLabel(Form)
self.label_train.setGeometry(QtCore.QRect(620, 90, 41, 31))
font = QtGui.QFont()
font.setPointSize(13)
self.label_train.setFont(font)
self.label_train.setText("")
self.label_train.setObjectName("label_train")
self.label_validation = QtWidgets.QLabel(Form)
self.label_validation.setGeometry(QtCore.QRect(620, 140, 41, 31))
font = QtGui.QFont()
font.setPointSize(13)
self.label_validation.setFont(font)
self.label_validation.setText("")
self.label_validation.setObjectName("label_validation")
self.label_test = QtWidgets.QLabel(Form)
self.label_test.setGeometry(QtCore.QRect(620, 190, 41, 31))
font = QtGui.QFont()
font.setPointSize(13)
self.label_test.setFont(font)
self.label_test.setText("")
self.label_test.setObjectName("label_test")
self.pushButton_prepare = QtWidgets.QPushButton(Form)
self.pushButton_prepare.setGeometry(QtCore.QRect(200, 630, 291, 61))
font = QtGui.QFont()
font.setPointSize(14)
self.pushButton_prepare.setFont(font)
self.pushButton_prepare.setStyleSheet("")
self.pushButton_prepare.setObjectName("pushButton_prepare")
self.label_7 = QtWidgets.QLabel(Form)
self.label_7.setGeometry(QtCore.QRect(170, 30, 361, 41))
font = QtGui.QFont()
font.setPointSize(15)
self.label_7.setFont(font)
self.label_7.setStyleSheet("color: rgb(245, 121, 0);")
self.label_7.setObjectName("label_7")
self.label_8 = QtWidgets.QLabel(Form)
self.label_8.setGeometry(QtCore.QRect(60, 320, 551, 41))
font = QtGui.QFont()
font.setPointSize(15)
self.label_8.setFont(font)
self.label_8.setStyleSheet("color: rgb(245, 121, 0);")
self.label_8.setObjectName("label_8")
self.line = QtWidgets.QFrame(Form)
self.line.setGeometry(QtCore.QRect(-60, 270, 741, 20))
self.line.setFrameShape(QtWidgets.QFrame.HLine)
self.line.setFrameShadow(QtWidgets.QFrame.Sunken)
self.line.setObjectName("line")
self.horizontalSlider_size = QtWidgets.QSlider(Form)
self.horizontalSlider_size.setGeometry(QtCore.QRect(100, 410, 471, 20))
self.horizontalSlider_size.setMinimum(2)
self.horizontalSlider_size.setMaximum(50)
self.horizontalSlider_size.setOrientation(QtCore.Qt.Horizontal)
self.horizontalSlider_size.setObjectName("horizontalSlider_size")
self.label_increase = QtWidgets.QLabel(Form)
self.label_increase.setGeometry(QtCore.QRect(60, 410, 31, 17))
font = QtGui.QFont()
font.setPointSize(14)
self.label_increase.setFont(font)
self.label_increase.setObjectName("label_increase")
self.label_10 = QtWidgets.QLabel(Form)
self.label_10.setGeometry(QtCore.QRect(60, 490, 161, 17))
self.label_10.setObjectName("label_10")
self.label_total_number = QtWidgets.QLabel(Form)
self.label_total_number.setGeometry(QtCore.QRect(240, 490, 67, 17))
self.label_total_number.setStyleSheet("color: rgb(245, 121, 0);")
self.label_total_number.setText("")
self.label_total_number.setObjectName("label_total_number")
self.label_4 = QtWidgets.QLabel(Form)
self.label_4.setGeometry(QtCore.QRect(150, 240, 381, 17))
self.label_4.setStyleSheet("color: rgb(52, 101, 164);")
self.label_4.setObjectName("label_4")
self.pushButton_output_path = QtWidgets.QPushButton(Form)
self.pushButton_output_path.setGeometry(QtCore.QRect(180, 570, 331, 41))
font = QtGui.QFont()
font.setPointSize(12)
self.pushButton_output_path.setFont(font)
self.pushButton_output_path.setStyleSheet("")
self.pushButton_output_path.setObjectName("pushButton_output_path")
self.line_2 = QtWidgets.QFrame(Form)
self.line_2.setGeometry(QtCore.QRect(-70, 530, 741, 20))
self.line_2.setFrameShape(QtWidgets.QFrame.HLine)
self.line_2.setFrameShadow(QtWidgets.QFrame.Sunken)
self.line_2.setObjectName("line_2")
self.label_output_path = QtWidgets.QLabel(Form)
self.label_output_path.setGeometry(QtCore.QRect(50, 710, 571, 20))
self.label_output_path.setStyleSheet("color: rgb(52, 101, 164);")
self.label_output_path.setText("")
self.label_output_path.setAlignment(QtCore.Qt.AlignCenter)
self.label_output_path.setObjectName("label_output_path")
self.label_null = QtWidgets.QLabel(Form)
self.label_null.setGeometry(QtCore.QRect(40, 388, 31, 61))
font = QtGui.QFont()
font.setPointSize(18)
self.label_null.setFont(font)
self.label_null.setObjectName("label_null")
self.retranslateUi(Form)
self.horizontalSlider_train.valueChanged['int'].connect(self.label_train.setNum)
self.horizontalSlider_validation.valueChanged['int'].connect(self.label_validation.setNum)
self.horizontalSlider_test.valueChanged['int'].connect(self.label_test.setNum)
self.horizontalSlider_size.valueChanged['int'].connect(self.label_increase.setNum)
QtCore.QMetaObject.connectSlotsByName(Form)
def retranslateUi(self, Form):
_translate = QtCore.QCoreApplication.translate
Form.setWindowTitle(_translate("Form", "Form"))
self.label.setText(_translate("Form", "Train"))
self.label_2.setText(_translate("Form", "Validation"))
self.label_3.setText(_translate("Form", "Test"))
self.pushButton_prepare.setText(_translate("Form", "Prepare Augmented Dataset"))
self.label_7.setText(_translate("Form", "How do you want to split the dataset?"))
self.label_8.setText(_translate("Form", "By what amount would you like to increase the dataset size?"))
self.label_increase.setText(_translate("Form", "2"))
self.label_10.setText(_translate("Form", "Total number of image:"))
self.label_4.setText(_translate("Form", "(Follow this order for arranging: Test - Validation - Train)"))
self.pushButton_output_path.setText(_translate("Form", "Choose a Path to Create Output Folder "))
self.label_null.setText(_translate("Form", "X"))
if __name__ == "__main__":
import sys
app = QtWidgets.QApplication(sys.argv)
Form = QtWidgets.QWidget()
ui = Ui_Form()
ui.setupUi(Form)
Form.show()
sys.exit(app.exec_())