개정판 b76683b4
issue #1366: change offset
Change-Id: I563eb49a963e965c2b0f7a70564e3eec34b65ea1
DTI_PID/DTI_PID/RecognitionDialog.py | ||
---|---|---|
2691 | 2691 |
|
2692 | 2692 |
# get Rotated Original Point |
2693 | 2693 |
sow, soh = symGray.shape[::-1] |
2694 |
offset_x, offset_y = round(rect[3] * 0.4), round(rect[4] * 0.4)#int(max(sow, soh) / 2)
|
|
2694 |
offset_x, offset_y = round(rect[3] * 0.5), round(rect[4] * 0.5)#int(max(sow, soh) / 2)
|
|
2695 | 2695 |
|
2696 | 2696 |
roiItem = Worker.remove_small_objects(area.img, 0, sow * soh * 0.5) if hasInstrumentLabel else area.img.copy() |
2697 | 2697 |
x_start = round(rect[1]) - round(offset_x) if round(rect[1]) - round(offset_x) > 0 else 0 |
... | ... | |
2913 | 2913 |
symGray = Worker.cvtGrayImage(sym) |
2914 | 2914 |
|
2915 | 2915 |
for symbol in symbols: |
2916 |
#if symbol[0] == symbolName: |
|
2917 |
if symbol[0] == 'check': |
|
2916 |
if symbol[0] == symbolName: |
|
2918 | 2917 |
searchedItemSp, symbolRotatedAngle, flipped, originalPoint, connectionPoint, sw, sh, score = \ |
2919 | 2918 |
Worker.calculate_exact_position(area, symGray, targetSymbol, symbol, worker) |
2920 | 2919 |
if not searchedItemSp: |
내보내기 Unified diff