| | |
| | | { |
| | | } |
| | | |
| | | // [2017:5:12]-[WEZASW] : DFS Result File Format 변경 |
| | | // [2017:5:12]-[WEZASW] : DFS Result File Format ���� |
| | | void CParsingGlassResult_CPJT::ParsingFileToGlassResult(CGlassResult* pGlassResult, CResultFileManager* pResultFileMgr)//Cmark |
| | | { |
| | | if(pGlassResult==NULL || pResultFileMgr==NULL) |
| | |
| | | |
| | | |
| | | //========================= |
| | | #pragma region 옛날 코드 |
| | | #pragma region ���� �ڵ� |
| | | //cellResult.strCellID = pResultFileMgr->GetRawData(eCSOTRaw_PanelInfoData, nCellIdx, eCSOTRaw_Panel_CellNum); // No.1 Cell Number |
| | | // No.1 Cell Number |
| | | //cellResult.nDefectCount = atoi(pResultFileMgr->GetRawData(eCSOTRaw_PanelInfoData, nCellIdx, eCSOTRaw_Panel_RearCPDefectNum)); // No.2 Defect Count |
| | |
| | | //========================= |
| | | |
| | | |
| | | pGlassResult->AddCellResult(cellResult); // 추가 |
| | | pGlassResult->AddCellResult(cellResult); // �߰� |
| | | |
| | | // 예외처리 : PNL Total 수량과 실제 불량 개수 확인 |
| | | // ����ó�� : PNL Total ������ ���� �ҷ� ���� Ȯ�� |
| | | if (nTotalDefectIdx+cellResult.nDefectCount > nDefectRawDataCount) { continue; } |
| | | |
| | | |
| | |
| | | // pDefectResult->nDefectidx1 = atoi( pResultFileMgr->GetDefectData(nDefIdx,1)); |
| | | // pDefectResult->nDefectidx2 = atoi(pResultFileMgr->GetDefectData(nDefIdx,2)); |
| | | |
| | | //pDefectResult->strDefectCode = pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_Code); // No.1 결함코드1 |
| | | //pDefectResult->strDefectCode = pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_Code); // No.1 �����ڵ�1 |
| | | pDefectResult->strDefectCode.TrimRight(); |
| | | pDefectResult->nDefectCode = GetDefectCodeType( pGlassResult->m_strRecipeID, pDefectResult->strDefectCode ); |
| | | |
| | |
| | | |
| | | |
| | | |
| | | //pDefectResult->strDefectType = pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_AOI_DEFECT_TYPE); // No.7 결함 Type // A - N: Normal, C: Common, M: Mask |
| | | //pDefectResult->strDefectType = pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_AOI_DEFECT_TYPE); // No.7 ���� Type // A - N: Normal, C: Common, M: Mask |
| | | pDefectResult->nDefectType = GetCSOTDefectType(pDefectResult->strDefectType); |
| | | |
| | | pDefectResult->nAOIArea = atof(pResultFileMgr->GetDefectData(nTotalDefectIdx, 20)); // No.5 Defect Size |
| | |
| | | pDefectResult->nSizeType = GetSizeType(pDefectResult->strSizeType); |
| | | |
| | | |
| | | pDefectResult->nAOISizeW = atof(pResultFileMgr->GetDefectData(nTotalDefectIdx, eCPJTRaw_Defect_AOI_DEFECT_WID))*1000; // No.10 Defect’s X axis size (um) |
| | | pDefectResult->nAOISizeH = atof(pResultFileMgr->GetDefectData(nTotalDefectIdx, eCPJTRaw_Defect_AOI_DEFECT_HGT))*1000; // No.11 Defect’s Y axis size (um) |
| | | pDefectResult->nAOISizeW = atof(pResultFileMgr->GetDefectData(nTotalDefectIdx, eCPJTRaw_Defect_AOI_DEFECT_WID))*1000; // No.10 Defect��s X axis size (um) |
| | | pDefectResult->nAOISizeH = atof(pResultFileMgr->GetDefectData(nTotalDefectIdx, eCPJTRaw_Defect_AOI_DEFECT_HGT))*1000; // No.11 Defect��s Y axis size (um) |
| | | pDefectResult->nAOISize = atof(pResultFileMgr->GetDefectData(nTotalDefectIdx, 26)); |
| | | |
| | | //pDefectResult->nAOISizeLength = pDefectResult->nAOISizeW; |
| | |
| | | |
| | | |
| | | //======================= |
| | | #pragma region 옛날 코드 |
| | | #pragma region ���� �ڵ� |
| | | /* |
| | | //atoi(pResultFileMgr->GetCellData(idx,nCellIdx)); |
| | | ////pDefectResult->strCellID |
| | | // |
| | | |
| | | pDefectResult->strDefectCode = pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_Code); // No.1 결함코드1 |
| | | pDefectResult->strDefectCode = pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_Code); // No.1 �����ڵ�1 |
| | | pDefectResult->strDefectCode.TrimRight(); |
| | | pDefectResult->nDefectCode = GetDefectCodeType( pGlassResult->m_strRecipeID, pDefectResult->strDefectCode ); |
| | | |
| | | pDefectResult->nUMCenterOriginX = atof(pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_CenterOriX)); // No.3 Glass Center 기준 좌표 X(mm) |
| | | pDefectResult->nUMCenterOriginY = atof(pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_CenterOriY)); // No.4 Glass Center 기준 좌표 Y(mm) |
| | | pDefectResult->nUMCenterOriginX = atof(pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_CenterOriX)); // No.3 Glass Center ���� ��ǥ X(mm) |
| | | pDefectResult->nUMCenterOriginY = atof(pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_CenterOriY)); // No.4 Glass Center ���� ��ǥ Y(mm) |
| | | pDefectResult->nUMOriginX = (pGlassResult->GetGlassSizeX()/2) + pDefectResult->nUMCenterOriginX*1000; |
| | | pDefectResult->nUMOriginY = (pGlassResult->GetGlassSizeY()/2) + pDefectResult->nUMCenterOriginY*1000; |
| | | //pDefectResult->nUMOriginX = pDefectResult->nUMCenterOriginX*1000; |
| | |
| | | pDefectResult->strSizeType = pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_DefectSizeType); // No.6 Defect SizeType // S/M/L/O |
| | | pDefectResult->nSizeType = GetSizeType(pDefectResult->strSizeType); |
| | | |
| | | pDefectResult->strDefectType = pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_DefectType); // No.7 결함 Type // A - N: Normal, C: Common, M: Mask |
| | | pDefectResult->strDefectType = pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_DefectType); // No.7 ���� Type // A - N: Normal, C: Common, M: Mask |
| | | pDefectResult->nDefectType = GetCSOTDefectType(pDefectResult->strDefectType); |
| | | |
| | | pDefectResult->nAOISizeW = atof(pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_SizeDX))*1000; // No.10 Defect’s X axis size (um) |
| | | pDefectResult->nAOISizeH = atof(pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_SizeDY))*1000; // No.11 Defect’s Y axis size (um) |
| | | pDefectResult->nAOISizeW = atof(pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_SizeDX))*1000; // No.10 Defect��s X axis size (um) |
| | | pDefectResult->nAOISizeH = atof(pResultFileMgr->GetRawData(eCSOTRaw_DefectInfoData, nTotalDefectIdx, eCSOTRaw_Defect_SizeDY))*1000; // No.11 Defect��s Y axis size (um) |
| | | pDefectResult->nAOISize = int(pDefectResult->nAOISizeW*pDefectResult->nAOISizeH); |
| | | pDefectResult->nAOISizeLength = pDefectResult->nAOISizeW; |
| | | |
| | |
| | | } |
| | | } |
| | | |
| | | // [2017:5:12]-[WEZASW] : DFS Result File Format 변경 cmark |
| | | // [2017:5:12]-[WEZASW] : DFS Result File Format ���� cmark |
| | | int CParsingGlassResult_CPJT::ParsingReviewResultDataToFile(CGlassResult* pGlassResult, CResultFileManager* pResultFileMgr) |
| | | { |
| | | if (pResultFileMgr==NULL || pGlassResult==NULL) |
| | |
| | | #endif |
| | | if (pResult->nDefectIdx != -1) |
| | | { |
| | | // 고정리뷰일때만 |
| | | // ���������϶��� |
| | | / * |
| | | if( pGlassResult->GetUserResultCount() > 0 ) |
| | | { |
| | |
| | | return nWriteCount; |
| | | } |
| | | |
| | | // [2017:1:3]-[WEZASW] : WSI 측정 결과 쓰기 (사양 미정으로 기본 설정) (ING) |
| | | // [2017:1:3]-[WEZASW] : WSI ���� ��� ���� (��� �������� �⺻ ����) (ING) |
| | | int CParsingGlassResult_CPJT::ParsingWsiResultDataToFile(CGlassResult* pGlassResult, CResultFileManager* pResultFileMgr) |
| | | { |
| | | |
| | |
| | | |
| | | if (pResultFileMgr && pResult->nDefectIdx != -1) |
| | | { |
| | | // [2017:5:13]-[WEZASW] : 7개 추가 항목이었으나 고객사 제출시(최종) 삭제(미스)되어 제공되어 고객사 회신으로 추가 항목(13, 25, 26)만 적용 하기로 기술팀(김D) 협의됨. |
| | | // [2017:5:24]-[WEZASW] : AOI DFS(DFT) 항목 추가(Index 변경) |
| | | // [2017:5:13]-[WEZASW] : 7�� �߰� ���̾����� ����� �����(����) ����(�̽�)�Ǿ� �����Ǿ� ����� ȸ������ �߰� ��(13, 25, 26)�� ���� �ϱ�� �����(��D) ���ǵ�. |
| | | // [2017:5:24]-[WEZASW] : AOI DFS(DFT) �� �߰�(Index ����) |
| | | ///pResultFileMgr->SetRawData(eB7Raw_DefectInfoData, pResult->nTotalDefectCount, 15, int(pResult->pWsi_ResultData[Wsi_X_Height]*1000)); // No.13 Defect Height (um) |
| | | ///pResultFileMgr->SetRawData(eB7Raw_DefectInfoData, pResult->nTotalDefectCount, 27, pResult->nWsi_ResultCode); // No.25 Measurement Code (Success:1 / fail:0) |
| | | ///pResultFileMgr->SetRawData(eB7Raw_DefectInfoData, pResult->nTotalDefectCount, 28, int(pResult->pWsi_ResultData[Wsi_X_A_Ratio]*1000)); // No.26 Defect X axis Ration (um) |
| | |
| | | // review image file name |
| | | strImageFileName = pResult->strUploadImgFileName; |
| | | |
| | | // [2018/02/13 22:22:06 by jylee] related RTMS 매칭, 복사 처리 |
| | | // [2018/02/13 22:22:06 by jylee] related RTMS ��Ī, ���� ó�� |
| | | if (pResult->nDefectIdx != -1) |
| | | { |
| | | CheckResultFileAndCopy( pGlassResult, pResultFileMgr, pResult, strImageFileName ); |
| | |
| | | int CParsingGlassResult_CPJT::GetCSOTDefectCode(CString strDfectType){ |
| | | |
| | | //COST_CRACK=0,CSOT_PARTICLE,CSOT_MURA,CSOT_PROTRUDE,CSOT_DENT,CSOT_TFE_ABNORMAL,CSOT_BUBBLE,CSOT_SCRATCH |
| | | //Compare 대상이면 0 대상보다크면 1 작으면 -1 |
| | | //Compare ����̸� 0 ���ũ�� 1 ������ -1 |
| | | |
| | | if(strDfectType.Compare(_T("CRACK"))==0) |
| | | { |
| | |
| | | break; |
| | | case Judge_Rework: sStr.Format("RW"); |
| | | break; |
| | | case Judge_Unknown: sStr.Format("OK");//sStr.Format("Unknown"); //Unknown도 일단 OK |
| | | case Judge_Unknown: sStr.Format("OK");//sStr.Format("Unknown"); //Unknown�� �ϴ� OK |
| | | break; |
| | | default: sStr.Format("OK");//sStr.Format("Ets"); |
| | | break; |
| | |
| | | { |
| | | return DOWS; |
| | | } |
| | | else |
| | | { |
| | | return CODE_DEFAULT; |
| | | } |
| | | return 0; |
| | | |
| | | } |
| | | |
| | | |
| | | // [2018/03/14 09:47:51 by jylee] related Deep Learning |
| | | int CParsingGlassResult_CPJT::GetDefectCodeType( const CString& strRecipeID, const CString& strValue ) |
| | |
| | | void CParsingGlassResult_CPJT::MemoryParsingFileToGlassResult( CGlassResult* pGlassResult, CDitGlassRawClient* pDitRawClient ) |
| | | { |
| | | |
| | | //찐코드// |
| | | //���ڵ�// |
| | | if(pGlassResult==NULL || pDitRawClient==NULL) return; |
| | | |
| | | CString strItem = _T(""); |
| | |
| | | cellResult.nDefectCount = pDitRawClient->GetCellData(nCellIdx)->getTotalDefectNum(); |
| | | cellResult.strCellJudge.Format(_T("%d"),pDitRawClient->GetCellData(nCellIdx)->m_nJudgement); |
| | | |
| | | //20201126 CELL 좌표계를 센터좌표로 바꿈으로 내부 좌표계에서 + 글라스 사이즈/2 해야됨 |
| | | //20201126 CELL ��ǥ�踦 ������ǥ�� �ٲ����� ���� ��ǥ�迡�� + �۶� ������/2 �ؾߵ� |
| | | cellResult.nUMOriginX = pDitRawClient->GetCellData(nCellIdx)->m_rectCellLeft + pDitRawClient->GetGlassData()->m_nGlassSizeWidth/2; |
| | | cellResult.nUMOriginY = pDitRawClient->GetCellData(nCellIdx)->m_rectCellTop + pDitRawClient->GetGlassData()->m_nGlassSizeHeight / 2; |
| | | cellResult.nUMOriginWidth = pDitRawClient->GetCellData(nCellIdx)->m_rectCellRight - cellResult.nUMOriginX + pDitRawClient->GetGlassData()->m_nGlassSizeWidth / 2; |
| | |
| | | CString strCellID(pDitRawClient->GetCellData(nCellIdx)->m_strCellName); |
| | | cellResult.strCellID = strCellID; |
| | | |
| | | pGlassResult->AddCellResult(cellResult); // 추가 |
| | | pGlassResult->AddCellResult(cellResult); // �߰� |
| | | |
| | | } |
| | | pGlassResult->m_strGlassID = pDitRawClient->GetGlassData()->m_strGlassID; |
| | |
| | | if(pDefectResult->nDefectWBType == 1 || pDefectResult->nDefectWBType == 3 || pDefectResult->nDefectWBType ==5) pDefectResult->nDefectWBType =2; |
| | | else pDefectResult->nDefectWBType = 1; |
| | | |
| | | //이거슨 컷오프 대상 Review 제외 210205 |
| | | //�̰Ž� �ƿ��� ��� Review ���� 210205 |
| | | if (pSharedDefect->m_bDefectCutoff == 1) |
| | | { |
| | | continue; |
| | |
| | | pDefectResult->nUMOriginX = pSharedDefect->m_nUMOriginX;// |
| | | pDefectResult->nUMOriginY = pSharedDefect->m_nUMOriginY;// |
| | | |
| | | //pDefectResult->nDefectCode = GetCodeType(pDefectResult->strDefectCode); |
| | | //20210608 �ڵ�� �켱���� |
| | | pDefectResult->nDefectJudgeCode = GetCodeType(pSharedDefect->m_strDefectCode); |
| | | pDefectResult->strDefectJudgeCode = pSharedDefect->m_strDefectCode; |
| | | |
| | | |
| | | pDefectResult->nJudgeType = pSharedDefect->m_DefectJudgement; |
| | | pDefectResult->strJudgeType = GetGradeType(pDefectResult->nJudgeType); |
| | |
| | | |
| | | pDefectResult->nLocation = pSharedDefect->m_sDefectLoc; |
| | | |
| | | //멀티 모델별 Review/WSI 필터링을 위한 인자 |
| | | //��Ƽ �� Review/WSI ������ ���� ���� |
| | | pDefectResult->nMultiModel = pSharedDefect->m_nModelIdx; |
| | | |
| | | if (pSharedDefect->m_DefectBDType == 1) |
| | |
| | | |
| | | |
| | | ////20190311CHM |
| | | //if(pSharedDefect->m_StackInfo == 1) //스택 인데 리뷰 안함 |
| | | //if(pSharedDefect->m_StackInfo == 1) //���� �ε� ���� ���� |
| | | //{ |
| | | // pDefectResult->nStackType = 1; //3이 SD |
| | | // pDefectResult->nStackType = 1; //3�� SD |
| | | //} |
| | | //else if(pSharedDefect->m_StackInfo == 2) // 스택인데 리뷰 함 |
| | | //else if(pSharedDefect->m_StackInfo == 2) // �����ε� ���� �� |
| | | //{ |
| | | // pDefectResult->nStackType = 2; |
| | | //} |
| | | //else |
| | | //{ |
| | | // pDefectResult->nStackType = 0; //0이 ALL |
| | | // pDefectResult->nStackType = 0; //0�� ALL |
| | | //} |
| | | |
| | | pDefectResult->nStackType = pSharedDefect->m_StackInfo; |
| | |
| | | //#endif |
| | | // if (pResult->nResultIdx != -1) |
| | | // { |
| | | // // 20170831 smok 항목 추가 DEFECT_ZONE(AA/PAD/CRACK) 31 -> 32 |
| | | // // [2017:5:24]-[WEZASW] : AOI DFS(DFT) 항목 추가(Index 변경) |
| | | // // 20170831 smok �� �߰� DEFECT_ZONE(AA/PAD/CRACK) 31 -> 32 |
| | | // // [2017:5:24]-[WEZASW] : AOI DFS(DFT) �� �߰�(Index ����) |
| | | // pResultFileMgr->SetRawData(eB7Raw_DefectInfoData, nDefectCount + pResult->nResultIdx, 33, strTemp); // No.31 Image File Name |
| | | // |
| | | // pResultFileMgr->SetRawData(eB7Raw_DefectInfoData, nDefectCount + pResult->nResultIdx, 34, "***"); |