개정판 d1994d14
issue #000: add opc option ocr option
Change-Id: Ica80f0e932588d917794ae79f9bfcde0262eb61b
DTI_PID/DTI_PID/ConfigurationDialog.py | ||
---|---|---|
220 | 220 |
self.ui.lineEditBlind.setText(configs[0].value) if 1 == len(configs) else \ |
221 | 221 |
self.ui.lineEditBlind.setText('blind flange') |
222 | 222 |
|
223 |
configs = docData.getConfigs('Symbol', 'OPC') |
|
224 |
if configs: |
|
225 |
size = int(configs[0].value) |
|
226 |
self.ui.radioButtonOPCModeYes.setChecked(True if size == 1 else False) |
|
227 |
self.ui.radioButtonOPCModeNo.setChecked(True if size == -1 else False) |
|
228 |
else: |
|
229 |
self.ui.radioButtonOPCModeYes.setChecked(True) |
|
230 |
self.ui.radioButtonOPCModeNo.setChecked(False) |
|
231 |
|
|
223 | 232 |
properties = docData.getLineProperties() |
224 | 233 |
if properties: |
225 | 234 |
for prop in properties: |
... | ... | |
228 | 237 |
self.tempLineColorUID.append(prop.Attribute) |
229 | 238 |
self.ui.comboBoxColorOption.addItem(prop.DisplayAttribute) |
230 | 239 |
|
231 |
configs = docData.getConfigs('Default', 'Flange') |
|
232 |
self.ui.lineEditFlange.setText(configs[0].value) if 1 == len(configs) else \ |
|
233 |
self.ui.lineEditFlange.setText('flange') |
|
234 |
|
|
235 | 240 |
properties = docData.getLineProperties() |
236 | 241 |
if properties: |
237 | 242 |
for prop in properties: |
... | ... | |
1092 | 1097 |
configs.append(Config('Line', 'Gap', '1' if self.ui.radioButtonGapYes.isChecked() else '-1')) |
1093 | 1098 |
configs.append(Config('Text', 'Background', '1' if self.ui.radioButtonBackTextYes.isChecked() else '-1')) |
1094 | 1099 |
configs.append(Config('Symbol', 'Detect Inside Package', '1' if self.ui.radioButtonDetectPackageYes.isChecked() else '-1')) |
1100 |
configs.append(Config('Symbol', 'OPC', '1' if self.ui.radioButtonOPCModeYes.isChecked() else '-1')) |
|
1095 | 1101 |
configs.append(Config('Note No Tag Rule', 'Note No Expression', self.ui.lineEditNoteNoExpression.text())) |
1096 | 1102 |
configs.append(Config('Note No Tag Rule', 'Note No Symbol Name', self.ui.lineEditNoteNoSymbolName.text())) |
1097 | 1103 |
configs.append(Config('OPC Tag Rule', 'From Prefix', self.ui.lineEditOPCFromPrefix.text())) |
DTI_PID/DTI_PID/Configuration_UI.py | ||
---|---|---|
113 | 113 |
self.gridLayout_14.setObjectName("gridLayout_14") |
114 | 114 |
self.gridLayout_25 = QtWidgets.QGridLayout() |
115 | 115 |
self.gridLayout_25.setObjectName("gridLayout_25") |
116 |
self.label_44 = QtWidgets.QLabel(self.groupBoxText) |
|
117 |
self.label_44.setObjectName("label_44") |
|
118 |
self.gridLayout_25.addWidget(self.label_44, 9, 0, 1, 1) |
|
119 |
self.spinBoxTextAreaOffset = QtWidgets.QSpinBox(self.groupBoxText) |
|
120 |
self.spinBoxTextAreaOffset.setObjectName("spinBoxTextAreaOffset") |
|
121 |
self.gridLayout_25.addWidget(self.spinBoxTextAreaOffset, 9, 1, 1, 1) |
|
122 | 116 |
self.comboBoxOCRData = QtWidgets.QComboBox(self.groupBoxText) |
123 | 117 |
self.comboBoxOCRData.setMinimumSize(QtCore.QSize(200, 0)) |
124 | 118 |
self.comboBoxOCRData.setMaximumSize(QtCore.QSize(200, 16777215)) |
125 | 119 |
self.comboBoxOCRData.setObjectName("comboBoxOCRData") |
126 | 120 |
self.gridLayout_25.addWidget(self.comboBoxOCRData, 0, 1, 1, 1) |
121 |
self.label_44 = QtWidgets.QLabel(self.groupBoxText) |
|
122 |
self.label_44.setObjectName("label_44") |
|
123 |
self.gridLayout_25.addWidget(self.label_44, 9, 0, 1, 1) |
|
124 |
self.spinBoxExpandSize = QtWidgets.QSpinBox(self.groupBoxText) |
|
125 |
self.spinBoxExpandSize.setMinimumSize(QtCore.QSize(100, 0)) |
|
126 |
self.spinBoxExpandSize.setObjectName("spinBoxExpandSize") |
|
127 |
self.gridLayout_25.addWidget(self.spinBoxExpandSize, 6, 1, 1, 1) |
|
128 |
self.label_22 = QtWidgets.QLabel(self.groupBoxText) |
|
129 |
self.label_22.setObjectName("label_22") |
|
130 |
self.gridLayout_25.addWidget(self.label_22, 8, 0, 1, 1) |
|
131 |
self.label_19 = QtWidgets.QLabel(self.groupBoxText) |
|
132 |
self.label_19.setObjectName("label_19") |
|
133 |
self.gridLayout_25.addWidget(self.label_19, 0, 0, 1, 1) |
|
134 |
self.spinBoxMergeSize = QtWidgets.QSpinBox(self.groupBoxText) |
|
135 |
self.spinBoxMergeSize.setMinimumSize(QtCore.QSize(100, 0)) |
|
136 |
self.spinBoxMergeSize.setObjectName("spinBoxMergeSize") |
|
137 |
self.gridLayout_25.addWidget(self.spinBoxMergeSize, 8, 1, 1, 1) |
|
127 | 138 |
self.maxTextSizeSpinBox = QtWidgets.QSpinBox(self.groupBoxText) |
128 | 139 |
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) |
129 | 140 |
sizePolicy.setHorizontalStretch(0) |
... | ... | |
134 | 145 |
self.maxTextSizeSpinBox.setProperty("value", 60) |
135 | 146 |
self.maxTextSizeSpinBox.setObjectName("maxTextSizeSpinBox") |
136 | 147 |
self.gridLayout_25.addWidget(self.maxTextSizeSpinBox, 7, 3, 1, 1) |
137 |
self.spinBoxMergeSize = QtWidgets.QSpinBox(self.groupBoxText) |
|
138 |
self.spinBoxMergeSize.setMinimumSize(QtCore.QSize(100, 0)) |
|
139 |
self.spinBoxMergeSize.setObjectName("spinBoxMergeSize") |
|
140 |
self.gridLayout_25.addWidget(self.spinBoxMergeSize, 8, 1, 1, 1) |
|
141 | 148 |
self.label_21 = QtWidgets.QLabel(self.groupBoxText) |
142 | 149 |
self.label_21.setObjectName("label_21") |
143 | 150 |
self.gridLayout_25.addWidget(self.label_21, 6, 2, 1, 1) |
151 |
self.spinBoxTextAreaOffset = QtWidgets.QSpinBox(self.groupBoxText) |
|
152 |
self.spinBoxTextAreaOffset.setObjectName("spinBoxTextAreaOffset") |
|
153 |
self.gridLayout_25.addWidget(self.spinBoxTextAreaOffset, 9, 1, 1, 1) |
|
144 | 154 |
self.spinBoxShrinkSize = QtWidgets.QSpinBox(self.groupBoxText) |
145 | 155 |
self.spinBoxShrinkSize.setMinimumSize(QtCore.QSize(100, 0)) |
146 | 156 |
self.spinBoxShrinkSize.setObjectName("spinBoxShrinkSize") |
... | ... | |
149 | 159 |
self.labelTesseractVersion.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter) |
150 | 160 |
self.labelTesseractVersion.setObjectName("labelTesseractVersion") |
151 | 161 |
self.gridLayout_25.addWidget(self.labelTesseractVersion, 0, 2, 1, 2) |
152 |
self.label_22 = QtWidgets.QLabel(self.groupBoxText) |
|
153 |
self.label_22.setObjectName("label_22") |
|
154 |
self.gridLayout_25.addWidget(self.label_22, 8, 0, 1, 1) |
|
155 |
self.spinBoxExpandSize = QtWidgets.QSpinBox(self.groupBoxText) |
|
156 |
self.spinBoxExpandSize.setMinimumSize(QtCore.QSize(100, 0)) |
|
157 |
self.spinBoxExpandSize.setObjectName("spinBoxExpandSize") |
|
158 |
self.gridLayout_25.addWidget(self.spinBoxExpandSize, 6, 1, 1, 1) |
|
159 |
self.label_19 = QtWidgets.QLabel(self.groupBoxText) |
|
160 |
self.label_19.setObjectName("label_19") |
|
161 |
self.gridLayout_25.addWidget(self.label_19, 0, 0, 1, 1) |
|
162 |
self.label_37 = QtWidgets.QLabel(self.groupBoxText) |
|
163 |
self.label_37.setObjectName("label_37") |
|
164 |
self.gridLayout_25.addWidget(self.label_37, 4, 0, 1, 1) |
|
165 |
self.label_50 = QtWidgets.QLabel(self.groupBoxText) |
|
166 |
self.label_50.setObjectName("label_50") |
|
167 |
self.gridLayout_25.addWidget(self.label_50, 5, 0, 1, 1) |
|
168 |
self.lineEditSingleText = QtWidgets.QLineEdit(self.groupBoxText) |
|
169 |
font = QtGui.QFont() |
|
170 |
font.setFamily("Consolas") |
|
171 |
self.lineEditSingleText.setFont(font) |
|
172 |
self.lineEditSingleText.setObjectName("lineEditSingleText") |
|
173 |
self.gridLayout_25.addWidget(self.lineEditSingleText, 4, 1, 1, 3) |
|
174 |
self.label_18 = QtWidgets.QLabel(self.groupBoxText) |
|
175 |
self.label_18.setObjectName("label_18") |
|
176 |
self.gridLayout_25.addWidget(self.label_18, 7, 2, 1, 1) |
|
162 | 177 |
self.minTextSizeSpinBox = QtWidgets.QSpinBox(self.groupBoxText) |
163 | 178 |
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) |
164 | 179 |
sizePolicy.setHorizontalStretch(0) |
... | ... | |
169 | 184 |
self.minTextSizeSpinBox.setProperty("value", 30) |
170 | 185 |
self.minTextSizeSpinBox.setObjectName("minTextSizeSpinBox") |
171 | 186 |
self.gridLayout_25.addWidget(self.minTextSizeSpinBox, 7, 1, 1, 1) |
172 |
self.lineEditWhiteCharList = QtWidgets.QLineEdit(self.groupBoxText) |
|
173 |
font = QtGui.QFont() |
|
174 |
font.setFamily("Consolas") |
|
175 |
self.lineEditWhiteCharList.setFont(font) |
|
176 |
self.lineEditWhiteCharList.setObjectName("lineEditWhiteCharList") |
|
177 |
self.gridLayout_25.addWidget(self.lineEditWhiteCharList, 1, 1, 1, 3) |
|
178 |
self.comboBoxOCREngineMode = QtWidgets.QComboBox(self.groupBoxText) |
|
179 |
self.comboBoxOCREngineMode.setObjectName("comboBoxOCREngineMode") |
|
180 |
self.gridLayout_25.addWidget(self.comboBoxOCREngineMode, 3, 1, 1, 3) |
|
181 |
self.label_39 = QtWidgets.QLabel(self.groupBoxText) |
|
182 |
self.label_39.setObjectName("label_39") |
|
183 |
self.gridLayout_25.addWidget(self.label_39, 2, 0, 1, 1) |
|
184 | 187 |
self.label_20 = QtWidgets.QLabel(self.groupBoxText) |
185 | 188 |
self.label_20.setObjectName("label_20") |
186 | 189 |
self.gridLayout_25.addWidget(self.label_20, 6, 0, 1, 1) |
187 | 190 |
self.comboBoxPageSegmentationModes = QtWidgets.QComboBox(self.groupBoxText) |
188 | 191 |
self.comboBoxPageSegmentationModes.setObjectName("comboBoxPageSegmentationModes") |
189 | 192 |
self.gridLayout_25.addWidget(self.comboBoxPageSegmentationModes, 2, 1, 1, 3) |
190 |
self.label_18 = QtWidgets.QLabel(self.groupBoxText) |
|
191 |
self.label_18.setObjectName("label_18") |
|
192 |
self.gridLayout_25.addWidget(self.label_18, 7, 2, 1, 1) |
|
193 | 193 |
self.label_7 = QtWidgets.QLabel(self.groupBoxText) |
194 | 194 |
self.label_7.setObjectName("label_7") |
195 | 195 |
self.gridLayout_25.addWidget(self.label_7, 1, 0, 1, 1) |
196 |
self.label_43 = QtWidgets.QLabel(self.groupBoxText) |
|
197 |
self.label_43.setObjectName("label_43") |
|
198 |
self.gridLayout_25.addWidget(self.label_43, 3, 0, 1, 1) |
|
199 |
self.label_37 = QtWidgets.QLabel(self.groupBoxText) |
|
200 |
self.label_37.setObjectName("label_37") |
|
201 |
self.gridLayout_25.addWidget(self.label_37, 4, 0, 1, 1) |
|
202 |
self.label_17 = QtWidgets.QLabel(self.groupBoxText) |
|
203 |
self.label_17.setObjectName("label_17") |
|
204 |
self.gridLayout_25.addWidget(self.label_17, 7, 0, 1, 1) |
|
205 |
self.label_50 = QtWidgets.QLabel(self.groupBoxText) |
|
206 |
self.label_50.setObjectName("label_50") |
|
207 |
self.gridLayout_25.addWidget(self.label_50, 5, 0, 1, 1) |
|
208 |
self.lineEditSingleText = QtWidgets.QLineEdit(self.groupBoxText) |
|
209 |
font = QtGui.QFont() |
|
210 |
font.setFamily("Consolas") |
|
211 |
self.lineEditSingleText.setFont(font) |
|
212 |
self.lineEditSingleText.setObjectName("lineEditSingleText") |
|
213 |
self.gridLayout_25.addWidget(self.lineEditSingleText, 4, 1, 1, 3) |
|
214 | 196 |
self.lineEditAllowablePair = QtWidgets.QLineEdit(self.groupBoxText) |
215 | 197 |
font = QtGui.QFont() |
216 | 198 |
font.setFamily("Consolas") |
217 | 199 |
self.lineEditAllowablePair.setFont(font) |
218 | 200 |
self.lineEditAllowablePair.setObjectName("lineEditAllowablePair") |
219 | 201 |
self.gridLayout_25.addWidget(self.lineEditAllowablePair, 5, 1, 1, 3) |
202 |
self.label_43 = QtWidgets.QLabel(self.groupBoxText) |
|
203 |
self.label_43.setObjectName("label_43") |
|
204 |
self.gridLayout_25.addWidget(self.label_43, 3, 0, 1, 1) |
|
205 |
self.lineEditWhiteCharList = QtWidgets.QLineEdit(self.groupBoxText) |
|
206 |
font = QtGui.QFont() |
|
207 |
font.setFamily("Consolas") |
|
208 |
self.lineEditWhiteCharList.setFont(font) |
|
209 |
self.lineEditWhiteCharList.setObjectName("lineEditWhiteCharList") |
|
210 |
self.gridLayout_25.addWidget(self.lineEditWhiteCharList, 1, 1, 1, 3) |
|
211 |
self.label_39 = QtWidgets.QLabel(self.groupBoxText) |
|
212 |
self.label_39.setObjectName("label_39") |
|
213 |
self.gridLayout_25.addWidget(self.label_39, 2, 0, 1, 1) |
|
214 |
self.comboBoxOCREngineMode = QtWidgets.QComboBox(self.groupBoxText) |
|
215 |
self.comboBoxOCREngineMode.setObjectName("comboBoxOCREngineMode") |
|
216 |
self.gridLayout_25.addWidget(self.comboBoxOCREngineMode, 3, 1, 1, 3) |
|
217 |
self.label_17 = QtWidgets.QLabel(self.groupBoxText) |
|
218 |
self.label_17.setObjectName("label_17") |
|
219 |
self.gridLayout_25.addWidget(self.label_17, 7, 0, 1, 1) |
|
220 | 220 |
self.gridLayout_14.addLayout(self.gridLayout_25, 0, 0, 1, 1) |
221 | 221 |
self.gridLayout_2.addWidget(self.groupBoxText, 0, 1, 1, 1) |
222 | 222 |
self.groupBoxAttribute = QtWidgets.QGroupBox(self.Recognition) |
... | ... | |
428 | 428 |
self.gridLayout_40.setObjectName("gridLayout_40") |
429 | 429 |
self.gridLayout_39 = QtWidgets.QGridLayout() |
430 | 430 |
self.gridLayout_39.setObjectName("gridLayout_39") |
431 |
spacerItem3 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) |
|
432 |
self.gridLayout_39.addItem(spacerItem3, 2, 2, 1, 1) |
|
431 |
self.lineEditFlange = QtWidgets.QLineEdit(self.groupBoxSymbol) |
|
432 |
self.lineEditFlange.setObjectName("lineEditFlange") |
|
433 |
self.gridLayout_39.addWidget(self.lineEditFlange, 2, 1, 1, 1) |
|
433 | 434 |
self.label_52 = QtWidgets.QLabel(self.groupBoxSymbol) |
434 | 435 |
self.label_52.setObjectName("label_52") |
435 | 436 |
self.gridLayout_39.addWidget(self.label_52, 2, 0, 1, 1) |
437 |
self.lineEditBlind = QtWidgets.QLineEdit(self.groupBoxSymbol) |
|
438 |
self.lineEditBlind.setObjectName("lineEditBlind") |
|
439 |
self.gridLayout_39.addWidget(self.lineEditBlind, 3, 1, 1, 1) |
|
440 |
spacerItem3 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) |
|
441 |
self.gridLayout_39.addItem(spacerItem3, 2, 2, 1, 1) |
|
436 | 442 |
self.horizontalLayout_10 = QtWidgets.QHBoxLayout() |
437 | 443 |
self.horizontalLayout_10.setObjectName("horizontalLayout_10") |
438 | 444 |
self.radioButtonDetectPackageYes = QtWidgets.QRadioButton(self.groupBoxSymbol) |
... | ... | |
446 | 452 |
self.buttonGroup_8.addButton(self.radioButtonDetectPackageNo) |
447 | 453 |
self.horizontalLayout_10.addWidget(self.radioButtonDetectPackageNo) |
448 | 454 |
self.gridLayout_39.addLayout(self.horizontalLayout_10, 1, 1, 1, 1) |
449 |
self.lineEditFlange = QtWidgets.QLineEdit(self.groupBoxSymbol) |
|
450 |
self.lineEditFlange.setObjectName("lineEditFlange") |
|
451 |
self.gridLayout_39.addWidget(self.lineEditFlange, 2, 1, 1, 1) |
|
452 |
self.label_53 = QtWidgets.QLabel(self.groupBoxSymbol) |
|
453 |
self.label_53.setObjectName("label_53") |
|
454 |
self.gridLayout_39.addWidget(self.label_53, 1, 0, 1, 1) |
|
455 | 455 |
self.label_56 = QtWidgets.QLabel(self.groupBoxSymbol) |
456 | 456 |
self.label_56.setObjectName("label_56") |
457 | 457 |
self.gridLayout_39.addWidget(self.label_56, 3, 0, 1, 1) |
458 |
self.lineEditBlind = QtWidgets.QLineEdit(self.groupBoxSymbol) |
|
459 |
self.lineEditBlind.setObjectName("lineEditBlind") |
|
460 |
self.gridLayout_39.addWidget(self.lineEditBlind, 3, 1, 1, 1) |
|
458 |
self.label_53 = QtWidgets.QLabel(self.groupBoxSymbol) |
|
459 |
self.label_53.setObjectName("label_53") |
|
460 |
self.gridLayout_39.addWidget(self.label_53, 1, 0, 1, 1) |
|
461 |
self.label_59 = QtWidgets.QLabel(self.groupBoxSymbol) |
|
462 |
self.label_59.setObjectName("label_59") |
|
463 |
self.gridLayout_39.addWidget(self.label_59, 4, 0, 1, 1) |
|
464 |
self.horizontalLayout_15 = QtWidgets.QHBoxLayout() |
|
465 |
self.horizontalLayout_15.setObjectName("horizontalLayout_15") |
|
466 |
self.radioButtonOPCModeYes = QtWidgets.QRadioButton(self.groupBoxSymbol) |
|
467 |
self.radioButtonOPCModeYes.setObjectName("radioButtonOPCModeYes") |
|
468 |
self.buttonGroup_12 = QtWidgets.QButtonGroup(ConfigurationDialog) |
|
469 |
self.buttonGroup_12.setObjectName("buttonGroup_12") |
|
470 |
self.buttonGroup_12.addButton(self.radioButtonOPCModeYes) |
|
471 |
self.horizontalLayout_15.addWidget(self.radioButtonOPCModeYes) |
|
472 |
self.radioButtonOPCModeNo = QtWidgets.QRadioButton(self.groupBoxSymbol) |
|
473 |
self.radioButtonOPCModeNo.setObjectName("radioButtonOPCModeNo") |
|
474 |
self.buttonGroup_12.addButton(self.radioButtonOPCModeNo) |
|
475 |
self.horizontalLayout_15.addWidget(self.radioButtonOPCModeNo) |
|
476 |
self.gridLayout_39.addLayout(self.horizontalLayout_15, 4, 1, 1, 1) |
|
461 | 477 |
self.gridLayout_40.addLayout(self.gridLayout_39, 0, 0, 1, 1) |
462 | 478 |
self.gridLayout_21.addWidget(self.groupBoxSymbol, 1, 1, 1, 1) |
463 | 479 |
self.tabWidget.addTab(self.Recognition2, "") |
... | ... | |
998 | 1014 |
self.checkBoxApplyGaussianBlur.setText(_translate("ConfigurationDialog", "Apply")) |
999 | 1015 |
self.groupBoxText.setTitle(_translate("ConfigurationDialog", "Text Detection")) |
1000 | 1016 |
self.label_44.setText(_translate("ConfigurationDialog", "Text Area Offset : ")) |
1001 |
self.label_21.setText(_translate("ConfigurationDialog", "Erosion Size : ")) |
|
1002 |
self.labelTesseractVersion.setText(_translate("ConfigurationDialog", "TesseractVersion")) |
|
1003 | 1017 |
self.label_22.setText(_translate("ConfigurationDialog", "Merge Size : ")) |
1004 | 1018 |
self.label_19.setText(_translate("ConfigurationDialog", "OCR Source : ")) |
1005 |
self.label_39.setText(_translate("ConfigurationDialog", "Page segmentations modes")) |
|
1006 |
self.label_20.setText(_translate("ConfigurationDialog", "Expansion Size : ")) |
|
1019 |
self.label_21.setText(_translate("ConfigurationDialog", "Erosion Size : ")) |
|
1020 |
self.labelTesseractVersion.setText(_translate("ConfigurationDialog", "TesseractVersion")) |
|
1021 |
self.label_37.setText(_translate("ConfigurationDialog", "Allowed Single Text : ")) |
|
1022 |
self.label_50.setText(_translate("ConfigurationDialog", "Allowable Pair : ")) |
|
1007 | 1023 |
self.label_18.setText(_translate("ConfigurationDialog", "Maximum Text Size : ")) |
1024 |
self.label_20.setText(_translate("ConfigurationDialog", "Expansion Size : ")) |
|
1008 | 1025 |
self.label_7.setText(_translate("ConfigurationDialog", "Detected string : ")) |
1009 | 1026 |
self.label_43.setText(_translate("ConfigurationDialog", "OCR Engine Mode")) |
1010 |
self.label_37.setText(_translate("ConfigurationDialog", "Allowed Single Text : "))
|
|
1027 |
self.label_39.setText(_translate("ConfigurationDialog", "Page segmentations modes"))
|
|
1011 | 1028 |
self.label_17.setText(_translate("ConfigurationDialog", "Minimum Text Size : ")) |
1012 |
self.label_50.setText(_translate("ConfigurationDialog", "Allowable Pair : ")) |
|
1013 | 1029 |
self.groupBoxAttribute.setTitle(_translate("ConfigurationDialog", "Attribute")) |
1014 | 1030 |
self.label_6.setText(_translate("ConfigurationDialog", "Size Delimiter : ")) |
1015 | 1031 |
self.label_15.setText(_translate("ConfigurationDialog", "Attribute Detection Range(Ratio) : ")) |
... | ... | |
1040 | 1056 |
self.label_52.setText(_translate("ConfigurationDialog", "Default Flange : ")) |
1041 | 1057 |
self.radioButtonDetectPackageYes.setText(_translate("ConfigurationDialog", "Yes")) |
1042 | 1058 |
self.radioButtonDetectPackageNo.setText(_translate("ConfigurationDialog", "No")) |
1043 |
self.label_53.setText(_translate("ConfigurationDialog", "Detect Inside Equipment Package : ")) |
|
1044 | 1059 |
self.label_56.setText(_translate("ConfigurationDialog", "Default Blind Flange : ")) |
1060 |
self.label_53.setText(_translate("ConfigurationDialog", "Detect Inside Equipment Package : ")) |
|
1061 |
self.label_59.setText(_translate("ConfigurationDialog", "OPC Detection Mode : ")) |
|
1062 |
self.radioButtonOPCModeYes.setText(_translate("ConfigurationDialog", "Yes")) |
|
1063 |
self.radioButtonOPCModeNo.setText(_translate("ConfigurationDialog", "No")) |
|
1045 | 1064 |
self.tabWidget.setTabText(self.tabWidget.indexOf(self.Recognition2), _translate("ConfigurationDialog", "Recognition")) |
1046 | 1065 |
self.groupBox_4.setTitle(_translate("ConfigurationDialog", "Note No Tag Rule")) |
1047 | 1066 |
self.checkBoxNoteNoSymbolName.setText(_translate("ConfigurationDialog", "Note No Symbol Name : ")) |
DTI_PID/DTI_PID/MainWindow.py | ||
---|---|---|
1540 | 1540 |
item.update() |
1541 | 1541 |
DisplayColors.instance().save_data() |
1542 | 1542 |
|
1543 |
def open_image_drawing(self, drawing, force=False): |
|
1543 |
def open_image_drawing(self, drawing, force=False, ocrUnknown=False):
|
|
1544 | 1544 |
"""open and display image drawing file""" |
1545 | 1545 |
from Drawing import Drawing |
1546 | 1546 |
from App import App |
... | ... | |
1692 | 1692 |
self.setWindowTitle(self.title) |
1693 | 1693 |
self.fitWindow(drawing.view_rect) |
1694 | 1694 |
|
1695 |
if force:
|
|
1695 |
if ocrUnknown:
|
|
1696 | 1696 |
self.on_ocr_unknown_items() |
1697 | 1697 |
|
1698 | 1698 |
# save alarm |
... | ... | |
2490 | 2490 |
dlg.exec_() |
2491 | 2491 |
|
2492 | 2492 |
if current_drawing and current_drawing in checked_drawings.keys() and dlg.isTreated: |
2493 |
self.open_image_drawing(current_drawing, force=True) |
|
2493 |
self.open_image_drawing(current_drawing, force=True, ocrUnknown=dlg.ui.checkBoxOCRUnknown.isChecked())
|
|
2494 | 2494 |
|
2495 | 2495 |
# save working date-time |
2496 | 2496 |
_now = datetime.now().strftime('%Y-%m-%d %H:%M:%S') |
DTI_PID/DTI_PID/RecognitionDialog.py | ||
---|---|---|
2221 | 2221 |
|
2222 | 2222 |
# For OPC |
2223 | 2223 |
drawing_area = app_doc_data.getArea('Drawing') |
2224 |
# disable opc detection
|
|
2225 |
if drawing_area is not None and (symbolType == "Piping OPC\'s" or symbolType == "Instrument OPC\'s"): |
|
2224 |
configs = app_doc_data.getConfigs('Symbol', 'OPC')
|
|
2225 |
if drawing_area is not None and (symbolType == "Piping OPC\'s" or symbolType == "Instrument OPC\'s") and configs and int(configs[0].value) == 1:
|
|
2226 | 2226 |
customMatch = worker.detectOPCOnPid(drawing_area, symGray) |
2227 | 2227 |
customMatch = [match for match in customMatch if match[0] > symbolThreshold] |
2228 | 2228 |
if customMatch and len(customMatch) > 0: |
... | ... | |
3834 | 3834 |
else: |
3835 | 3835 |
self.ui.checkBoxTraining.setVisible(False) |
3836 | 3836 |
|
3837 |
if False:#len(self.drawings) == 1 and appDocData.activeDrawing and appDocData.activeDrawing == self.drawings[0]:
|
|
3837 |
if False: |
|
3838 | 3838 |
self.ui.checkBoxSymbol.setCheckState(Qt.Checked) |
3839 | 3839 |
self.ui.lineCheckBox.setCheckState(Qt.Unchecked) |
3840 | 3840 |
self.ui.checkBoxText.setCheckState(Qt.Unchecked) |
... | ... | |
3842 | 3842 |
self.ui.checkBoxSymbol.setCheckState(Qt.Checked) |
3843 | 3843 |
self.ui.lineCheckBox.setCheckState(Qt.Checked) |
3844 | 3844 |
self.ui.checkBoxText.setCheckState(Qt.Checked) |
3845 |
#self.ui.checkBoxSymbol.setEnabled(False) |
|
3846 |
#self.ui.lineCheckBox.setEnabled(False)
|
|
3847 |
#self.ui.checkBoxText.setEnabled(False)
|
|
3845 |
|
|
3846 |
if len(self.drawings) != 1:
|
|
3847 |
self.ui.checkBoxOCRUnknown.hide()
|
|
3848 | 3848 |
|
3849 | 3849 |
self.ui.progressBarBatch.setFormat('{}/{}'.format('0', str(len(self.drawings)))) |
3850 | 3850 |
|
... | ... | |
3880 | 3880 |
elif self.ui.checkBoxText.isChecked() and not self.ui.checkBoxSymbol.isChecked(): |
3881 | 3881 |
self.ui.checkBoxText.setCheckState(Qt.Unchecked) |
3882 | 3882 |
|
3883 |
if self.ui.checkBoxSymbol.isChecked() and self.ui.checkBoxText.isChecked() and self.ui.lineCheckBox.isChecked() and len(self.drawings) == 1: |
|
3884 |
self.ui.checkBoxOCRUnknown.setHidden(False) |
|
3885 |
else: |
|
3886 |
self.ui.checkBoxOCRUnknown.setHidden(True) |
|
3887 |
self.ui.checkBoxOCRUnknown.setCheckState(Qt.Unchecked) |
|
3888 |
|
|
3883 | 3889 |
''' |
3884 | 3890 |
@brief QListWidget Row Inserted Listener |
3885 | 3891 |
Whenever row inserted, scroll to bottom |
DTI_PID/DTI_PID/Recognition_UI.py | ||
---|---|---|
25 | 25 |
self.checkBoxSymbol.setChecked(True) |
26 | 26 |
self.checkBoxSymbol.setObjectName("checkBoxSymbol") |
27 | 27 |
self.gridLayout_2.addWidget(self.checkBoxSymbol, 0, 0, 1, 1) |
28 |
self.listWidget = QtWidgets.QListWidget(Recognition) |
|
29 |
self.listWidget.setObjectName("listWidget") |
|
30 |
self.gridLayout_2.addWidget(self.listWidget, 1, 0, 1, 7) |
|
31 |
self.progressBar = QtWidgets.QProgressBar(Recognition) |
|
32 |
self.progressBar.setProperty("value", 0) |
|
33 |
self.progressBar.setObjectName("progressBar") |
|
34 |
self.gridLayout_2.addWidget(self.progressBar, 2, 0, 1, 7) |
|
28 |
self.checkBoxTraining = QtWidgets.QCheckBox(Recognition) |
|
29 |
self.checkBoxTraining.setObjectName("checkBoxTraining") |
|
30 |
self.gridLayout_2.addWidget(self.checkBoxTraining, 0, 6, 1, 1) |
|
35 | 31 |
self.labelImage = QtWidgets.QLabel(Recognition) |
36 | 32 |
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Ignored, QtWidgets.QSizePolicy.Ignored) |
37 | 33 |
sizePolicy.setHorizontalStretch(0) |
... | ... | |
45 | 41 |
self.labelImage.setScaledContents(True) |
46 | 42 |
self.labelImage.setAlignment(QtCore.Qt.AlignCenter) |
47 | 43 |
self.labelImage.setObjectName("labelImage") |
48 |
self.gridLayout_2.addWidget(self.labelImage, 1, 7, 1, 1) |
|
44 |
self.gridLayout_2.addWidget(self.labelImage, 1, 8, 1, 1) |
|
45 |
self.recognizeButton = QtWidgets.QPushButton(Recognition) |
|
46 |
self.recognizeButton.setMinimumSize(QtCore.QSize(150, 0)) |
|
47 |
self.recognizeButton.setMaximumSize(QtCore.QSize(150, 16777215)) |
|
48 |
self.recognizeButton.setObjectName("recognizeButton") |
|
49 |
self.gridLayout_2.addWidget(self.recognizeButton, 0, 8, 1, 1, QtCore.Qt.AlignRight) |
|
50 |
self.progressBarBatch = QtWidgets.QProgressBar(Recognition) |
|
51 |
self.progressBarBatch.setProperty("value", 0) |
|
52 |
self.progressBarBatch.setObjectName("progressBarBatch") |
|
53 |
self.gridLayout_2.addWidget(self.progressBarBatch, 3, 0, 1, 8) |
|
49 | 54 |
self.lineCheckBox = QtWidgets.QCheckBox(Recognition) |
50 | 55 |
self.lineCheckBox.setMaximumSize(QtCore.QSize(47, 16777215)) |
51 | 56 |
self.lineCheckBox.setChecked(False) |
52 | 57 |
self.lineCheckBox.setObjectName("lineCheckBox") |
53 | 58 |
self.gridLayout_2.addWidget(self.lineCheckBox, 0, 2, 1, 1) |
54 |
self.checkBoxText = QtWidgets.QCheckBox(Recognition) |
|
55 |
self.checkBoxText.setMaximumSize(QtCore.QSize(103, 16777215)) |
|
56 |
self.checkBoxText.setChecked(True) |
|
57 |
self.checkBoxText.setObjectName("checkBoxText") |
|
58 |
self.gridLayout_2.addWidget(self.checkBoxText, 0, 1, 1, 1) |
|
59 | 59 |
self.labelTitle = QtWidgets.QLabel(Recognition) |
60 | 60 |
palette = QtGui.QPalette() |
61 | 61 |
brush = QtGui.QBrush(QtGui.QColor(0, 0, 255)) |
... | ... | |
75 | 75 |
self.labelTitle.setText("") |
76 | 76 |
self.labelTitle.setAlignment(QtCore.Qt.AlignCenter) |
77 | 77 |
self.labelTitle.setObjectName("labelTitle") |
78 |
self.gridLayout_2.addWidget(self.labelTitle, 0, 6, 1, 1) |
|
79 |
self.progressBarBatch = QtWidgets.QProgressBar(Recognition) |
|
80 |
self.progressBarBatch.setProperty("value", 0) |
|
81 |
self.progressBarBatch.setObjectName("progressBarBatch") |
|
82 |
self.gridLayout_2.addWidget(self.progressBarBatch, 3, 0, 1, 7) |
|
83 |
self.recognizeButton = QtWidgets.QPushButton(Recognition) |
|
84 |
self.recognizeButton.setMinimumSize(QtCore.QSize(150, 0)) |
|
85 |
self.recognizeButton.setMaximumSize(QtCore.QSize(150, 16777215)) |
|
86 |
self.recognizeButton.setObjectName("recognizeButton") |
|
87 |
self.gridLayout_2.addWidget(self.recognizeButton, 0, 7, 1, 1, QtCore.Qt.AlignRight) |
|
78 |
self.gridLayout_2.addWidget(self.labelTitle, 0, 7, 1, 1) |
|
79 |
self.listWidget = QtWidgets.QListWidget(Recognition) |
|
80 |
self.listWidget.setObjectName("listWidget") |
|
81 |
self.gridLayout_2.addWidget(self.listWidget, 1, 0, 1, 8) |
|
82 |
self.progressBar = QtWidgets.QProgressBar(Recognition) |
|
83 |
self.progressBar.setProperty("value", 0) |
|
84 |
self.progressBar.setObjectName("progressBar") |
|
85 |
self.gridLayout_2.addWidget(self.progressBar, 2, 0, 1, 8) |
|
86 |
self.checkBoxText = QtWidgets.QCheckBox(Recognition) |
|
87 |
self.checkBoxText.setMaximumSize(QtCore.QSize(103, 16777215)) |
|
88 |
self.checkBoxText.setChecked(True) |
|
89 |
self.checkBoxText.setObjectName("checkBoxText") |
|
90 |
self.gridLayout_2.addWidget(self.checkBoxText, 0, 1, 1, 1) |
|
88 | 91 |
self.buttonBox = QtWidgets.QDialogButtonBox(Recognition) |
89 | 92 |
self.buttonBox.setEnabled(False) |
90 | 93 |
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) |
... | ... | |
97 | 100 |
self.buttonBox.setOrientation(QtCore.Qt.Horizontal) |
98 | 101 |
self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.Close) |
99 | 102 |
self.buttonBox.setObjectName("buttonBox") |
100 |
self.gridLayout_2.addWidget(self.buttonBox, 3, 7, 1, 1)
|
|
103 |
self.gridLayout_2.addWidget(self.buttonBox, 3, 8, 1, 1)
|
|
101 | 104 |
spacerItem = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) |
102 |
self.gridLayout_2.addItem(spacerItem, 0, 3, 1, 1)
|
|
103 |
self.checkBoxTraining = QtWidgets.QCheckBox(Recognition)
|
|
104 |
self.checkBoxTraining.setObjectName("checkBoxTraining")
|
|
105 |
self.gridLayout_2.addWidget(self.checkBoxTraining, 0, 5, 1, 1)
|
|
105 |
self.gridLayout_2.addItem(spacerItem, 0, 4, 1, 1)
|
|
106 |
self.checkBoxOCRUnknown = QtWidgets.QCheckBox(Recognition)
|
|
107 |
self.checkBoxOCRUnknown.setObjectName("checkBoxOCRUnknown")
|
|
108 |
self.gridLayout_2.addWidget(self.checkBoxOCRUnknown, 0, 3, 1, 1)
|
|
106 | 109 |
self.gridLayout.addLayout(self.gridLayout_2, 0, 1, 1, 1) |
107 | 110 |
|
108 | 111 |
self.retranslateUi(Recognition) |
... | ... | |
113 | 116 |
_translate = QtCore.QCoreApplication.translate |
114 | 117 |
Recognition.setWindowTitle(_translate("Recognition", "Recognize Engineering Info.")) |
115 | 118 |
self.checkBoxSymbol.setText(_translate("Recognition", "Symbol")) |
119 |
self.checkBoxTraining.setText(_translate("Recognition", "Make Data for Training")) |
|
120 |
self.recognizeButton.setText(_translate("Recognition", "Recognize")) |
|
116 | 121 |
self.lineCheckBox.setText(_translate("Recognition", "Line")) |
117 | 122 |
self.checkBoxText.setText(_translate("Recognition", "Text")) |
118 |
self.recognizeButton.setText(_translate("Recognition", "Recognize")) |
|
119 |
self.checkBoxTraining.setText(_translate("Recognition", "Make Data for Training")) |
|
123 |
self.checkBoxOCRUnknown.setText(_translate("Recognition", "OCR to Unknown Items")) |
|
120 | 124 |
|
121 | 125 |
|
122 | 126 |
if __name__ == "__main__": |
DTI_PID/DTI_PID/UI/Configuration.ui | ||
---|---|---|
223 | 223 |
<layout class="QGridLayout" name="gridLayout_14"> |
224 | 224 |
<item row="0" column="0"> |
225 | 225 |
<layout class="QGridLayout" name="gridLayout_25"> |
226 |
<item row="0" column="1"> |
|
227 |
<widget class="QComboBox" name="comboBoxOCRData"> |
|
228 |
<property name="minimumSize"> |
|
229 |
<size> |
|
230 |
<width>200</width> |
|
231 |
<height>0</height> |
|
232 |
</size> |
|
233 |
</property> |
|
234 |
<property name="maximumSize"> |
|
235 |
<size> |
|
236 |
<width>200</width> |
|
237 |
<height>16777215</height> |
|
238 |
</size> |
|
239 |
</property> |
|
240 |
</widget> |
|
241 |
</item> |
|
226 | 242 |
<item row="9" column="0"> |
227 | 243 |
<widget class="QLabel" name="label_44"> |
228 | 244 |
<property name="text"> |
... | ... | |
230 | 246 |
</property> |
231 | 247 |
</widget> |
232 | 248 |
</item> |
233 |
<item row="9" column="1"> |
|
234 |
<widget class="QSpinBox" name="spinBoxTextAreaOffset"/> |
|
235 |
</item> |
|
236 |
<item row="0" column="1"> |
|
237 |
<widget class="QComboBox" name="comboBoxOCRData"> |
|
249 |
<item row="6" column="1"> |
|
250 |
<widget class="QSpinBox" name="spinBoxExpandSize"> |
|
238 | 251 |
<property name="minimumSize"> |
239 | 252 |
<size> |
240 |
<width>200</width>
|
|
253 |
<width>100</width>
|
|
241 | 254 |
<height>0</height> |
242 | 255 |
</size> |
243 | 256 |
</property> |
244 |
<property name="maximumSize"> |
|
257 |
</widget> |
|
258 |
</item> |
|
259 |
<item row="8" column="0"> |
|
260 |
<widget class="QLabel" name="label_22"> |
|
261 |
<property name="text"> |
|
262 |
<string>Merge Size : </string> |
|
263 |
</property> |
|
264 |
</widget> |
|
265 |
</item> |
|
266 |
<item row="0" column="0"> |
|
267 |
<widget class="QLabel" name="label_19"> |
|
268 |
<property name="text"> |
|
269 |
<string>OCR Source : </string> |
|
270 |
</property> |
|
271 |
</widget> |
|
272 |
</item> |
|
273 |
<item row="8" column="1"> |
|
274 |
<widget class="QSpinBox" name="spinBoxMergeSize"> |
|
275 |
<property name="minimumSize"> |
|
245 | 276 |
<size> |
246 |
<width>200</width>
|
|
247 |
<height>16777215</height>
|
|
277 |
<width>100</width>
|
|
278 |
<height>0</height>
|
|
248 | 279 |
</size> |
249 | 280 |
</property> |
250 | 281 |
</widget> |
... | ... | |
265 | 296 |
</property> |
266 | 297 |
</widget> |
267 | 298 |
</item> |
268 |
<item row="8" column="1"> |
|
269 |
<widget class="QSpinBox" name="spinBoxMergeSize"> |
|
270 |
<property name="minimumSize"> |
|
271 |
<size> |
|
272 |
<width>100</width> |
|
273 |
<height>0</height> |
|
274 |
</size> |
|
275 |
</property> |
|
276 |
</widget> |
|
277 |
</item> |
|
278 | 299 |
<item row="6" column="2"> |
279 | 300 |
<widget class="QLabel" name="label_21"> |
280 | 301 |
<property name="text"> |
... | ... | |
282 | 303 |
</property> |
283 | 304 |
</widget> |
284 | 305 |
</item> |
306 |
<item row="9" column="1"> |
|
307 |
<widget class="QSpinBox" name="spinBoxTextAreaOffset"/> |
|
308 |
</item> |
|
285 | 309 |
<item row="6" column="3"> |
286 | 310 |
<widget class="QSpinBox" name="spinBoxShrinkSize"> |
287 | 311 |
<property name="minimumSize"> |
... | ... | |
302 | 326 |
</property> |
303 | 327 |
</widget> |
304 | 328 |
</item> |
305 |
<item row="8" column="0">
|
|
306 |
<widget class="QLabel" name="label_22">
|
|
329 |
<item row="4" column="0">
|
|
330 |
<widget class="QLabel" name="label_37">
|
|
307 | 331 |
<property name="text"> |
308 |
<string>Merge Size : </string>
|
|
332 |
<string>Allowed Single Text : </string>
|
|
309 | 333 |
</property> |
310 | 334 |
</widget> |
311 | 335 |
</item> |
312 |
<item row="6" column="1"> |
|
313 |
<widget class="QSpinBox" name="spinBoxExpandSize"> |
|
314 |
<property name="minimumSize"> |
|
315 |
<size> |
|
316 |
<width>100</width> |
|
317 |
<height>0</height> |
|
318 |
</size> |
|
336 |
<item row="5" column="0"> |
|
337 |
<widget class="QLabel" name="label_50"> |
|
338 |
<property name="text"> |
|
339 |
<string>Allowable Pair : </string> |
|
319 | 340 |
</property> |
320 | 341 |
</widget> |
321 | 342 |
</item> |
322 |
<item row="0" column="0"> |
|
323 |
<widget class="QLabel" name="label_19"> |
|
343 |
<item row="4" column="1" colspan="3"> |
|
344 |
<widget class="QLineEdit" name="lineEditSingleText"> |
|
345 |
<property name="font"> |
|
346 |
<font> |
|
347 |
<family>Consolas</family> |
|
348 |
</font> |
|
349 |
</property> |
|
350 |
</widget> |
|
351 |
</item> |
|
352 |
<item row="7" column="2"> |
|
353 |
<widget class="QLabel" name="label_18"> |
|
324 | 354 |
<property name="text"> |
325 |
<string>OCR Source : </string>
|
|
355 |
<string>Maximum Text Size : </string>
|
|
326 | 356 |
</property> |
327 | 357 |
</widget> |
328 | 358 |
</item> |
... | ... | |
345 | 375 |
</property> |
346 | 376 |
</widget> |
347 | 377 |
</item> |
348 |
<item row="1" column="1" colspan="3"> |
|
349 |
<widget class="QLineEdit" name="lineEditWhiteCharList"> |
|
350 |
<property name="font"> |
|
351 |
<font> |
|
352 |
<family>Consolas</family> |
|
353 |
</font> |
|
354 |
</property> |
|
355 |
</widget> |
|
356 |
</item> |
|
357 |
<item row="3" column="1" colspan="3"> |
|
358 |
<widget class="QComboBox" name="comboBoxOCREngineMode"/> |
|
359 |
</item> |
|
360 |
<item row="2" column="0"> |
|
361 |
<widget class="QLabel" name="label_39"> |
|
362 |
<property name="text"> |
|
363 |
<string>Page segmentations modes</string> |
|
364 |
</property> |
|
365 |
</widget> |
|
366 |
</item> |
|
367 | 378 |
<item row="6" column="0"> |
368 | 379 |
<widget class="QLabel" name="label_20"> |
369 | 380 |
<property name="text"> |
... | ... | |
374 | 385 |
<item row="2" column="1" colspan="3"> |
375 | 386 |
<widget class="QComboBox" name="comboBoxPageSegmentationModes"/> |
376 | 387 |
</item> |
377 |
<item row="7" column="2"> |
|
378 |
<widget class="QLabel" name="label_18"> |
|
379 |
<property name="text"> |
|
380 |
<string>Maximum Text Size : </string> |
|
381 |
</property> |
|
382 |
</widget> |
|
383 |
</item> |
|
384 | 388 |
<item row="1" column="0"> |
385 | 389 |
<widget class="QLabel" name="label_7"> |
386 | 390 |
<property name="text"> |
... | ... | |
388 | 392 |
</property> |
389 | 393 |
</widget> |
390 | 394 |
</item> |
391 |
<item row="3" column="0"> |
|
392 |
<widget class="QLabel" name="label_43"> |
|
393 |
<property name="text"> |
|
394 |
<string>OCR Engine Mode</string> |
|
395 |
<item row="5" column="1" colspan="3"> |
|
396 |
<widget class="QLineEdit" name="lineEditAllowablePair"> |
|
397 |
<property name="font"> |
|
398 |
<font> |
|
399 |
<family>Consolas</family> |
|
400 |
</font> |
|
395 | 401 |
</property> |
396 | 402 |
</widget> |
397 | 403 |
</item> |
398 |
<item row="4" column="0">
|
|
399 |
<widget class="QLabel" name="label_37">
|
|
404 |
<item row="3" column="0">
|
|
405 |
<widget class="QLabel" name="label_43">
|
|
400 | 406 |
<property name="text"> |
401 |
<string>Allowed Single Text : </string>
|
|
407 |
<string>OCR Engine Mode</string>
|
|
402 | 408 |
</property> |
403 | 409 |
</widget> |
404 | 410 |
</item> |
405 |
<item row="7" column="0"> |
|
406 |
<widget class="QLabel" name="label_17"> |
|
407 |
<property name="text"> |
|
408 |
<string>Minimum Text Size : </string> |
|
411 |
<item row="1" column="1" colspan="3"> |
|
412 |
<widget class="QLineEdit" name="lineEditWhiteCharList"> |
|
413 |
<property name="font"> |
|
414 |
<font> |
|
415 |
<family>Consolas</family> |
|
416 |
</font> |
|
409 | 417 |
</property> |
410 | 418 |
</widget> |
411 | 419 |
</item> |
412 |
<item row="5" column="0">
|
|
413 |
<widget class="QLabel" name="label_50">
|
|
420 |
<item row="2" column="0">
|
|
421 |
<widget class="QLabel" name="label_39">
|
|
414 | 422 |
<property name="text"> |
415 |
<string>Allowable Pair : </string>
|
|
423 |
<string>Page segmentations modes</string>
|
|
416 | 424 |
</property> |
417 | 425 |
</widget> |
418 | 426 |
</item> |
419 |
<item row="4" column="1" colspan="3"> |
|
420 |
<widget class="QLineEdit" name="lineEditSingleText"> |
|
421 |
<property name="font"> |
|
422 |
<font> |
|
423 |
<family>Consolas</family> |
|
424 |
</font> |
|
425 |
</property> |
|
426 |
</widget> |
|
427 |
<item row="3" column="1" colspan="3"> |
|
428 |
<widget class="QComboBox" name="comboBoxOCREngineMode"/> |
|
427 | 429 |
</item> |
428 |
<item row="5" column="1" colspan="3"> |
|
429 |
<widget class="QLineEdit" name="lineEditAllowablePair"> |
|
430 |
<property name="font"> |
|
431 |
<font> |
|
432 |
<family>Consolas</family> |
|
433 |
</font> |
|
430 |
<item row="7" column="0"> |
|
431 |
<widget class="QLabel" name="label_17"> |
|
432 |
<property name="text"> |
|
433 |
<string>Minimum Text Size : </string> |
|
434 | 434 |
</property> |
435 | 435 |
</widget> |
436 | 436 |
</item> |
... | ... | |
896 | 896 |
<layout class="QGridLayout" name="gridLayout_40"> |
897 | 897 |
<item row="0" column="0"> |
898 | 898 |
<layout class="QGridLayout" name="gridLayout_39"> |
899 |
<item row="2" column="1"> |
|
900 |
<widget class="QLineEdit" name="lineEditFlange"/> |
|
901 |
</item> |
|
902 |
<item row="2" column="0"> |
|
903 |
<widget class="QLabel" name="label_52"> |
|
904 |
<property name="text"> |
|
905 |
<string>Default Flange : </string> |
|
906 |
</property> |
|
907 |
</widget> |
|
908 |
</item> |
|
909 |
<item row="3" column="1"> |
|
910 |
<widget class="QLineEdit" name="lineEditBlind"/> |
|
911 |
</item> |
|
899 | 912 |
<item row="2" column="2"> |
900 | 913 |
<spacer name="horizontalSpacer_7"> |
901 | 914 |
<property name="orientation"> |
... | ... | |
909 | 922 |
</property> |
910 | 923 |
</spacer> |
911 | 924 |
</item> |
912 |
<item row="2" column="0"> |
|
913 |
<widget class="QLabel" name="label_52"> |
|
914 |
<property name="text"> |
|
915 |
<string>Default Flange : </string> |
|
916 |
</property> |
|
917 |
</widget> |
|
918 |
</item> |
|
919 | 925 |
<item row="1" column="1"> |
920 | 926 |
<layout class="QHBoxLayout" name="horizontalLayout_10"> |
921 | 927 |
<item> |
... | ... | |
940 | 946 |
</item> |
941 | 947 |
</layout> |
942 | 948 |
</item> |
943 |
<item row="2" column="1"> |
|
944 |
<widget class="QLineEdit" name="lineEditFlange"/> |
|
949 |
<item row="3" column="0"> |
|
950 |
<widget class="QLabel" name="label_56"> |
|
951 |
<property name="text"> |
|
952 |
<string>Default Blind Flange : </string> |
|
953 |
</property> |
|
954 |
</widget> |
|
945 | 955 |
</item> |
946 | 956 |
<item row="1" column="0"> |
947 | 957 |
<widget class="QLabel" name="label_53"> |
... | ... | |
950 | 960 |
</property> |
951 | 961 |
</widget> |
952 | 962 |
</item> |
953 |
<item row="3" column="0">
|
|
954 |
<widget class="QLabel" name="label_56">
|
|
963 |
<item row="4" column="0">
|
|
964 |
<widget class="QLabel" name="label_59">
|
|
955 | 965 |
<property name="text"> |
956 |
<string>Default Blind Flange : </string>
|
|
966 |
<string>OPC Detection Mode : </string>
|
|
957 | 967 |
</property> |
958 | 968 |
</widget> |
959 | 969 |
</item> |
960 |
<item row="3" column="1"> |
|
961 |
<widget class="QLineEdit" name="lineEditBlind"/> |
|
970 |
<item row="4" column="1"> |
|
971 |
<layout class="QHBoxLayout" name="horizontalLayout_15"> |
|
972 |
<item> |
|
973 |
<widget class="QRadioButton" name="radioButtonOPCModeYes"> |
|
974 |
<property name="text"> |
|
975 |
<string>Yes</string> |
|
976 |
</property> |
|
977 |
<attribute name="buttonGroup"> |
|
978 |
<string notr="true">buttonGroup_12</string> |
|
979 |
</attribute> |
|
980 |
</widget> |
|
981 |
</item> |
|
982 |
<item> |
|
983 |
<widget class="QRadioButton" name="radioButtonOPCModeNo"> |
|
984 |
<property name="text"> |
|
985 |
<string>No</string> |
|
986 |
</property> |
|
987 |
<attribute name="buttonGroup"> |
|
988 |
<string notr="true">buttonGroup_12</string> |
|
989 |
</attribute> |
|
990 |
</widget> |
|
991 |
</item> |
|
992 |
</layout> |
|
962 | 993 |
</item> |
963 | 994 |
</layout> |
964 | 995 |
</item> |
... | ... | |
2012 | 2043 |
</connection> |
2013 | 2044 |
</connections> |
2014 | 2045 |
<buttongroups> |
2015 |
<buttongroup name="buttonGroup_4"/> |
|
2016 |
<buttongroup name="buttonGroup_6"/> |
|
2017 |
<buttongroup name="buttonGroup"/> |
|
2018 |
<buttongroup name="buttonGroup_2"/> |
|
2019 | 2046 |
<buttongroup name="buttonGroup_7"/> |
2047 |
<buttongroup name="buttonGroup_11"/> |
|
2020 | 2048 |
<buttongroup name="buttonGroup_10"/> |
2049 |
<buttongroup name="buttonGroup_3"/> |
|
2050 |
<buttongroup name="buttonGroup"/> |
|
2051 |
<buttongroup name="buttonGroup_2"/> |
|
2052 |
<buttongroup name="buttonGroup_6"/> |
|
2021 | 2053 |
<buttongroup name="buttonGroup_5"/> |
2022 | 2054 |
<buttongroup name="buttonGroup_8"/> |
2055 |
<buttongroup name="buttonGroup_4"/> |
|
2023 | 2056 |
<buttongroup name="buttonGroup_9"/> |
2024 |
<buttongroup name="buttonGroup_3"/> |
|
2025 |
<buttongroup name="buttonGroup_11"/> |
|
2057 |
<buttongroup name="buttonGroup_12"/> |
|
2026 | 2058 |
</buttongroups> |
2027 | 2059 |
</ui> |
DTI_PID/DTI_PID/UI/Recognition.ui | ||
---|---|---|
40 | 40 |
</property> |
41 | 41 |
</widget> |
42 | 42 |
</item> |
43 |
<item row="1" column="0" colspan="7"> |
|
44 |
<widget class="QListWidget" name="listWidget"/> |
|
45 |
</item> |
|
46 |
<item row="2" column="0" colspan="7"> |
|
47 |
<widget class="QProgressBar" name="progressBar"> |
|
48 |
<property name="value"> |
|
49 |
<number>0</number> |
|
43 |
<item row="0" column="6"> |
|
44 |
<widget class="QCheckBox" name="checkBoxTraining"> |
|
45 |
<property name="text"> |
|
46 |
<string>Make Data for Training</string> |
|
50 | 47 |
</property> |
51 | 48 |
</widget> |
52 | 49 |
</item> |
53 |
<item row="1" column="7">
|
|
50 |
<item row="1" column="8">
|
|
54 | 51 |
<widget class="QLabel" name="labelImage"> |
55 | 52 |
<property name="sizePolicy"> |
56 | 53 |
<sizepolicy hsizetype="Ignored" vsizetype="Ignored"> |
... | ... | |
84 | 81 |
</property> |
85 | 82 |
</widget> |
86 | 83 |
</item> |
87 |
<item row="0" column="2"> |
|
88 |
<widget class="QCheckBox" name="lineCheckBox"> |
|
84 |
<item row="0" column="8" alignment="Qt::AlignRight"> |
|
85 |
<widget class="QPushButton" name="recognizeButton"> |
|
86 |
<property name="minimumSize"> |
|
87 |
<size> |
|
88 |
<width>150</width> |
|
89 |
<height>0</height> |
|
90 |
</size> |
|
91 |
</property> |
|
89 | 92 |
<property name="maximumSize"> |
90 | 93 |
<size> |
91 |
<width>47</width>
|
|
94 |
<width>150</width>
|
|
92 | 95 |
<height>16777215</height> |
93 | 96 |
</size> |
94 | 97 |
</property> |
95 | 98 |
<property name="text"> |
96 |
<string>Line</string>
|
|
99 |
<string>Recognize</string>
|
|
97 | 100 |
</property> |
98 |
<property name="checked"> |
|
99 |
<bool>false</bool> |
|
101 |
</widget> |
|
102 |
</item> |
|
103 |
<item row="3" column="0" colspan="8"> |
|
104 |
<widget class="QProgressBar" name="progressBarBatch"> |
|
105 |
<property name="value"> |
|
106 |
<number>0</number> |
|
100 | 107 |
</property> |
101 | 108 |
</widget> |
102 | 109 |
</item> |
103 |
<item row="0" column="1">
|
|
104 |
<widget class="QCheckBox" name="checkBoxText">
|
|
110 |
<item row="0" column="2">
|
|
111 |
<widget class="QCheckBox" name="lineCheckBox">
|
|
105 | 112 |
<property name="maximumSize"> |
106 | 113 |
<size> |
107 |
<width>103</width>
|
|
114 |
<width>47</width>
|
|
108 | 115 |
<height>16777215</height> |
109 | 116 |
</size> |
110 | 117 |
</property> |
111 | 118 |
<property name="text"> |
112 |
<string>Text</string>
|
|
119 |
<string>Line</string>
|
|
113 | 120 |
</property> |
114 | 121 |
<property name="checked"> |
115 |
<bool>true</bool>
|
|
122 |
<bool>false</bool>
|
|
116 | 123 |
</property> |
117 | 124 |
</widget> |
118 | 125 |
</item> |
119 |
<item row="0" column="6">
|
|
126 |
<item row="0" column="7">
|
|
120 | 127 |
<widget class="QLabel" name="labelTitle"> |
121 | 128 |
<property name="palette"> |
122 | 129 |
<palette> |
... | ... | |
169 | 176 |
</property> |
170 | 177 |
</widget> |
171 | 178 |
</item> |
172 |
<item row="3" column="0" colspan="7"> |
|
173 |
<widget class="QProgressBar" name="progressBarBatch"> |
|
179 |
<item row="1" column="0" colspan="8"> |
|
180 |
<widget class="QListWidget" name="listWidget"/> |
|
181 |
</item> |
|
182 |
<item row="2" column="0" colspan="8"> |
|
183 |
<widget class="QProgressBar" name="progressBar"> |
|
174 | 184 |
<property name="value"> |
175 | 185 |
<number>0</number> |
176 | 186 |
</property> |
177 | 187 |
</widget> |
178 | 188 |
</item> |
179 |
<item row="0" column="7" alignment="Qt::AlignRight"> |
|
180 |
<widget class="QPushButton" name="recognizeButton"> |
|
181 |
<property name="minimumSize"> |
|
182 |
<size> |
|
183 |
<width>150</width> |
|
184 |
<height>0</height> |
|
185 |
</size> |
|
186 |
</property> |
|
189 |
<item row="0" column="1"> |
|
190 |
<widget class="QCheckBox" name="checkBoxText"> |
|
187 | 191 |
<property name="maximumSize"> |
188 | 192 |
<size> |
189 |
<width>150</width>
|
|
193 |
<width>103</width>
|
|
190 | 194 |
<height>16777215</height> |
191 | 195 |
</size> |
192 | 196 |
</property> |
193 | 197 |
<property name="text"> |
194 |
<string>Recognize</string> |
|
198 |
<string>Text</string> |
|
199 |
</property> |
|
200 |
<property name="checked"> |
|
201 |
<bool>true</bool> |
|
195 | 202 |
</property> |
196 | 203 |
</widget> |
197 | 204 |
</item> |
198 |
<item row="3" column="7">
|
|
205 |
<item row="3" column="8">
|
|
199 | 206 |
<widget class="QDialogButtonBox" name="buttonBox"> |
200 | 207 |
<property name="enabled"> |
201 | 208 |
<bool>false</bool> |
... | ... | |
226 | 233 |
</property> |
227 | 234 |
</widget> |
228 | 235 |
</item> |
229 |
<item row="0" column="3">
|
|
236 |
<item row="0" column="4">
|
|
230 | 237 |
<spacer name="horizontalSpacer"> |
231 | 238 |
<property name="orientation"> |
232 | 239 |
<enum>Qt::Horizontal</enum> |
... | ... | |
239 | 246 |
</property> |
240 | 247 |
</spacer> |
241 | 248 |
</item> |
242 |
<item row="0" column="5">
|
|
243 |
<widget class="QCheckBox" name="checkBoxTraining">
|
|
249 |
<item row="0" column="3">
|
|
250 |
<widget class="QCheckBox" name="checkBoxOCRUnknown">
|
|
244 | 251 |
<property name="text"> |
245 |
<string>Make Data for Training</string>
|
|
252 |
<string>OCR to Unknown Items</string>
|
|
246 | 253 |
</property> |
247 | 254 |
</widget> |
248 | 255 |
</item> |
내보내기 Unified diff