From 2b9678f2c913b7059dfa2c6b2d392803333b4634 Mon Sep 17 00:00:00 2001 From: Jayn <694728662@qq.com> Date: Fri, 13 Nov 2015 01:51:26 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=A3=80=E6=B5=8B=E6=A8=AA?= =?UTF-8?q?=E5=90=91=E4=BF=A1=E5=8F=B7=E7=81=AF=E7=9A=84=E5=86=85=E5=AE=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Main_TrafficSignRecognition.cpp | 32 +++-- TrafficLightDetection/RectangleDetection.cpp | 131 ++++++++++++------ TrafficLightDetection/regionGrowFiltering.cpp | 100 ++++++++----- TrafficLightDetection/std_tlr.h | 3 + isTL.xml | 113 +++++++++++++++ traffic.h | 2 +- 6 files changed, 294 insertions(+), 87 deletions(-) create mode 100644 isTL.xml diff --git a/Main_TrafficSignRecognition.cpp b/Main_TrafficSignRecognition.cpp index c6e26b1..e83b4f1 100644 --- a/Main_TrafficSignRecognition.cpp +++ b/Main_TrafficSignRecognition.cpp @@ -20,8 +20,11 @@ HOGDescriptor RectHOG(Size(30,50),Size(10,10),Size(5,5),Size(5,5),9,1,-1.0,0,0.2 //识别信号灯类别的HOG特征 HOGDescriptor TLRecHOG(Size(12,12),Size(6,6),Size(3,3),Size(3,3),9,1,-1.0,0,0.2,true,20); +HOGDescriptor isTLHOG(Size(12,12),Size(6,6),Size(3,3),Size(3,3),9,1,-1.0,0,0.2,true,20);//识别是否是信号灯 + MySVM TriangleSVM,RoundRimSVM,RectBlueSVM; MySVM TLRecSVM;//识别红色信号灯类别的SVM分类器 +MySVM isTLSVM;//识别识别是否为信号灯的SVM分类器 int Frame_pos;//µ±Ç°Ö¡Î»Öà @@ -191,10 +194,14 @@ void TLDetectionPerFrame(IplImage *frame,float *TLDSend) imageSeg = colorSegmentationTL(resize_TLR); - /*IplImage *closeImg=cvCreateImage(Size(imageSeg->width,imageSeg->height),imageSeg->depth,imageSeg->nChannels); + + + IplImage *closeImg=cvCreateImage(Size(imageSeg->width,imageSeg->height),imageSeg->depth,imageSeg->nChannels); IplConvKernel *t=cvCreateStructuringElementEx(7,7,3,3,CV_SHAPE_ELLIPSE); cvMorphologyEx(imageSeg,closeImg,NULL,t,CV_MOP_CLOSE); - cvShowImage("closeImg",closeImg);*/ + cvShowImage("closeImg",closeImg); + + imageNoiseRem=noiseRemoval(imageSeg); #if ISDEBUG_TL cvNamedWindow("imgseg"); @@ -204,9 +211,10 @@ void TLDetectionPerFrame(IplImage *frame,float *TLDSend) cvWaitKey(5); #endif //componentExtraction(imageNoiseRem,resize_TLR,TLDSend,found_TL); - componentExtractionTL(imageNoiseRem,resize_TLR,TLDSend); + componentExtractionTL(closeImg,resize_TLR,TLDSend); cvReleaseImage(&imageSeg); cvReleaseImage(&imageNoiseRem); + cvReleaseImage(&closeImg); } void TSRecognitionPerFrame(IplImage *frame,float *TSRSend) @@ -534,7 +542,7 @@ int main() hogSVMTrainTL(myHOG_horz,TRAIN,HORZ); else hogSVMTrainTL(myHOG_vertical,TRAIN,HORZ); - + //信号灯识别训练 if (TLRecTrain) { @@ -542,8 +550,14 @@ int main() const int TLTypeNum=3;//包括非TL HOGTrainingTrafficSign(TLRecPath,TLRecHOG,TLTypeNum,TLREC_WIDTH,TLREC_HEIGHT,"src//TLRec.xml"); TLRecSVM.load("src//TLRec.xml"); + + const String isTLPath="D:\\JY\\JY_TrainingSamples\\isTL"; + const int isTLNum=2; + HOGTrainingTrafficSign(isTLPath,isTLHOG,isTLNum,TLREC_WIDTH,TLREC_HEIGHT,"src//isTL.xml"); + isTLSVM.load("src//isTL.xml"); }else{ TLRecSVM.load("src//TLRec.xml"); + isTLSVM.load("src//isTL.xml"); } //traffic sign training @@ -643,8 +657,8 @@ void openMP_MultiThreadVideo() bool saveFlag=false; IplImage * frame,*copyFrame; float connectResult[8]={0,0,0,0,0,0,0,0}; - //CvCapture * cap=cvCreateFileCapture("D:\\JY\\JY_TrainingSamples\\changshu data\\TL\\good5.avi"); - CvCapture * cap=cvCreateFileCapture("D:\\JY\\JY_TrainingSamples\\2014.11.16\\1_clip.mp4"); + CvCapture * cap=cvCreateFileCapture("D:\\JY\\JY_TrainingSamples\\changshu data\\TL\\TL_HORZ.avi"); + //CvCapture * cap=cvCreateFileCapture("D:\\JY\\JY_TrainingSamples\\2014.11.16\\1_clip.mp4"); float startTime=1000*(float)getTickCount()/getTickFrequency(); CvVideoWriter * writer=NULL; //findColorRange(); @@ -700,9 +714,9 @@ void openMP_MultiThreadVideo() cvShowImage("TL",resize_TLR); cvWaitKey(5); //show the detection result of TSR - namedWindow("TSR"); - imshow("TSR",re_src); - waitKey(5); + //namedWindow("TSR"); + //imshow("TSR",re_src); + //waitKey(5); #endif if (saveFlag) { diff --git a/TrafficLightDetection/RectangleDetection.cpp b/TrafficLightDetection/RectangleDetection.cpp index 395841c..752b8c1 100644 --- a/TrafficLightDetection/RectangleDetection.cpp +++ b/TrafficLightDetection/RectangleDetection.cpp @@ -1,8 +1,4 @@ #include "std_tlr.h" -extern HOGDescriptor TLRecHOG; -extern MySVM TLRecSVM;//ʶɫźŵSVM - -#define IS_CUTIMG 0 void GetImageRect(IplImage* orgImage, CvRect rectInImage, IplImage* imgRect) { @@ -62,15 +58,23 @@ bool isLighInBox(Mat src) IplImage* imageGrayScale = cvCreateImage(cvSize(iWidth,iHeight),IPL_DEPTH_8U,1); int iWidthStep = imageGrayScale->widthStep; cvCvtColor(srcImage,imageGrayScale,CV_BGR2GRAY); - - - bool returnStatus = false; + bool VerticalReturnStatus = false; + bool HorzReturnStatus=false; + + // + int HorzRectHeight=(iRect.width+iRect.height)/2 + 6; + int HorzRectWidth=3*(HorzRectHeight-4)+6; + int HorzRectX1=0, HorzRectY1=0; + int HorzRectX2=0, HorzRectY2=0; + + //int iSrcWidthStep = srcImage->widthStep; //thresholding for graylevel differences between seedpoints and its neibours const int grayThresholding =70;//70 const int RatioThreshold = 55;//кɫռ + // int iDrawRectWidth = (iRect.width+iRect.height)/2 + 6; int iDrawRectHeight = 3*(iDrawRectWidth-4)+6; int iDrawRectX1=0, iDrawRectY1=0; @@ -78,22 +82,32 @@ bool isLighInBox(Mat src) if(iColor==RED_PIXEL_LABEL){ iDrawRectY1 = iRect.y - 3; + HorzRectX1= iRect.x-3; } else if(iColor == GREEN_PIXEL_LABEL){ iDrawRectY1 = iRect.y-iDrawRectHeight/3*2; + HorzRectX1=iRect.x-HorzRectWidth/3*2; } iDrawRectY2 = iDrawRectY1 + iDrawRectHeight; iDrawRectX1 = iRect.x-3; iDrawRectX2 = iDrawRectX1 + iDrawRectWidth; + HorzRectX2= HorzRectX1+HorzRectWidth; + HorzRectY1= iRect.y-3; + HorzRectY2= HorzRectY1+HorzRectHeight; + if(HorzRectX1<0 || HorzRectY1<0 || HorzRectX2>=iWidth || HorzRectY2>=iHeight) + { + cvReleaseImage(&imageGrayScale);//when return the result, the image must be released, otherwise,the memory will be leaked + return HorzReturnStatus; + } + if( iDrawRectX1<0 || iDrawRectY1<0 || iDrawRectX2>=iWidth || iDrawRectY2>=iHeight) { cvReleaseImage(&imageGrayScale);//when return the result, the image must be released, otherwise,the memory will be leaked - return returnStatus; + return VerticalReturnStatus; } - int sum=0; int grayValue=0; @@ -110,10 +124,27 @@ bool isLighInBox(Mat src) } } + //ˮƽͳƺɫر + int HorzSum=0; + for(int j=HorzRectY1; j<=HorzRectY2; j++){ + pData = (unsigned char*)imageGrayScale->imageData + j*iWidthStep; + for(int i=HorzRectX1; i<=HorzRectX2; i++){ + grayValue = pData[i]; + if((grayValue<=grayThresholding)) + HorzSum++; + } + } + + //ֱⴰ iDrawRectHeight=iDrawRectY2-iDrawRectY1; iDrawRectWidth=iDrawRectX2-iDrawRectX1; - int ratio = (float)sum*100/(float)((iDrawRectWidth+1)*((float)iDrawRectHeight+1));//οкɫռ + //ˮƽⴰ + HorzRectHeight=HorzRectY2-HorzRectY1; + HorzRectWidth=HorzRectX2-HorzRectX1; + + int VerticalBlackRatio = (float)sum*100/(float)((iDrawRectWidth+1)*((float)iDrawRectHeight+1));//οкɫռ + int HorzBlackRatio=(float)HorzSum*100/(float)((HorzRectWidth+1)*((float)HorzRectHeight+1));//οкɫռ #if ISDEBUG_TL ofstream outfile; @@ -134,11 +165,20 @@ bool isLighInBox(Mat src) isLighInBox(tmpMat); #endif - if(ratio>=RatioThreshold&&ratio<=90&&BlackAroundLight(srcImage,iRect)) - returnStatus = true; + int DetectResult=isTL(srcImage,iRect);cout<<"źŵƣ"<=RatioThreshold&&VerticalBlackRatio<=90) + VerticalReturnStatus = true; + else if (HorzBlackRatio>=RatioThreshold&&HorzBlackRatio<=90) + { + HorzReturnStatus=true; + } + } + //ľοԭʼͼϻαʾ - if(returnStatus==true) + if(VerticalReturnStatus==true) { if(iColor==GREEN_PIXEL_LABEL) { @@ -153,34 +193,42 @@ bool isLighInBox(Mat src) //TODO:ʶźŵָ - CvSize cutSize; - cutSize.width=iRect.width; - cutSize.height=iRect.height; - IplImage *tmpCutImg=cvCreateImage(cutSize,srcImage->depth,srcImage->nChannels); - GetImageRect(srcImage,iRect,tmpCutImg); -#if IS_CUTIMG - cvShowImage("tmpCutImg",tmpCutImg); - cvWaitKey(1); - char tmpName[100]; - static int ppp=0; - ppp++; - sprintf_s(tmpName,"ImgCut//%d.jpg",ppp); - cvSaveImage(tmpName,tmpCutImg); -#endif + int result=RecognizeLight(srcImage,iRect); + switch(result) + { + case 0://Բ + //cout<<"Բ"< descriptor; - - //ʶźŵ - resize(cutMat,tmpTLRec,Size(TLREC_WIDTH,TLREC_HEIGHT)); - TLRecHOG.compute(tmpTLRec,descriptor,Size(8,8)); - int DescriptorDim=descriptor.size(); - Mat SVMTriangleMat(1,DescriptorDim,CV_32FC1); - for(int i=0; i(0,i) = descriptor[i]; - - int result=TLRecSVM.predict(SVMTriangleMat); + else if(iColor==RED_PIXEL_LABEL) + { + cvRectangle(srcImage,cvPoint(HorzRectX1,HorzRectY1),cvPoint(HorzRectX2,HorzRectY2),cvScalar(0,0,255),2); + //*p1=*p1+1; + + + //TODO:ʶźŵָ + int result=RecognizeLight(srcImage,iRect); switch(result) { case 0://Բ @@ -198,10 +246,9 @@ bool isLighInBox(Mat src) default: break; } - cvReleaseImage(&tmpCutImg);//ʹMatͷţIplImageMatͱ } } cvReleaseImage(&imageGrayScale); - return returnStatus; + return VerticalReturnStatus; } \ No newline at end of file diff --git a/TrafficLightDetection/regionGrowFiltering.cpp b/TrafficLightDetection/regionGrowFiltering.cpp index 3f048f0..614d141 100644 --- a/TrafficLightDetection/regionGrowFiltering.cpp +++ b/TrafficLightDetection/regionGrowFiltering.cpp @@ -1,6 +1,13 @@ #include "std_tlr.h" +#define IS_CUTIMG 1 + extern HOGDescriptor myHOG_vertical; extern HOGDescriptor myHOG_horz; +extern HOGDescriptor TLRecHOG; +extern HOGDescriptor isTLHOG; + +extern MySVM TLRecSVM;//ʶɫźŵSVM +extern MySVM isTLSVM;//ʶǷźŵ extern bool TRAIN; extern bool HORZ; @@ -66,49 +73,72 @@ bool BlackAroundLight(IplImage* srcImg,CvRect iRect) return flag; } -/* + //not using hole traffic ligh as samples,just use the square light -bool IsLight(IplImage* srcImg,CvRect iRect) +int RecognizeLight(IplImage* srcImg,CvRect iRect) { - bool returnStatus = false; - int iWidth = srcImg->width,topX=iRect.x; - int iHeight = srcImg->height,topY=iRect.y; - int RectWidth,RectHeight; - if(iRect.width<15)RectWidth=15; - RectWidth=iRect.width; - if(iRect.height<30)RectHeight=30; - RectHeight=iRect.height; - bool flag=false; - - + CvSize cutSize; + cutSize.width=iRect.width; + cutSize.height=iRect.height; + IplImage *tmpCutImg=cvCreateImage(cutSize,srcImg->depth,srcImg->nChannels); + GetImageRect(srcImg,iRect,tmpCutImg); +#if IS_CUTIMG + cvShowImage("tmpCutImg",tmpCutImg); + cvWaitKey(1); + char tmpName[100]; + static int ppp=0; + ppp++; + sprintf_s(tmpName,"ImgCut//%d.jpg",ppp); + cvSaveImage(tmpName,tmpCutImg); +#endif - //SVM+HOG - CvRect rect; - if(topX+25>iWidth||topX-20<0)return false; - else{ - rect.x=iRect.x-20; - rect.width=45; - } + Mat cutMat(tmpCutImg); + Mat tmpTLRec; + vector descriptor; + + //ʶźŵ + resize(cutMat,tmpTLRec,Size(TLREC_WIDTH,TLREC_HEIGHT)); + TLRecHOG.compute(tmpTLRec,descriptor,Size(8,8)); + int DescriptorDim=descriptor.size(); + Mat SVMTLRecMat(1,DescriptorDim,CV_32FC1); + for(int i=0; i(0,i) = descriptor[i]; + + int result=TLRecSVM.predict(SVMTLRecMat); + cvReleaseImage(&tmpCutImg); + return result; +} - if(topY+40>iHeight||topY-30<0)return false; - else{ - rect.y=iRect.y-30; - rect.height=70; - } - cvSetImageROI(srcImg,rect); - Mat SVMROI(srcImg); +int isTL(IplImage* srcImg,CvRect iRect) +{ + CvSize cutSize; + cutSize.width=iRect.width; + cutSize.height=iRect.height; + IplImage *tmpCutImg=cvCreateImage(cutSize,srcImg->depth,srcImg->nChannels); + GetImageRect(srcImg,iRect,tmpCutImg); +#if IS_CUTIMG + cvShowImage("tmpCutImg",tmpCutImg); + cvWaitKey(1); +#endif - cvResetImageROI(srcImg);//һ˾ͳ˰ - if(HORZ) - flag=BoxDetectTL(SVMROI,myHOG_horz,HORZ); - flag=BoxDetectTL(SVMROI,myHOG_vertical,HORZ); - //cvReleaseImage(&srcImg); - return flag; + Mat cutMat(tmpCutImg); + Mat tmpIsTL; + vector descriptor; + + //ʶźŵ + resize(cutMat,tmpIsTL,Size(TLREC_WIDTH,TLREC_HEIGHT)); + isTLHOG.compute(tmpIsTL,descriptor,Size(8,8)); + int DescriptorDim=descriptor.size(); + Mat SVMTLRecMat(1,DescriptorDim,CV_32FC1); + for(int i=0; i(0,i) = descriptor[i]; + + int result=isTLSVM.predict(SVMTLRecMat); + cvReleaseImage(&tmpCutImg); + return result; } -*/ - diff --git a/TrafficLightDetection/std_tlr.h b/TrafficLightDetection/std_tlr.h index 042c7f3..7275d07 100644 --- a/TrafficLightDetection/std_tlr.h +++ b/TrafficLightDetection/std_tlr.h @@ -55,6 +55,9 @@ bool regionGrowFiltering(IplImage* inputImage,IplImage*colorSeg,CvRect iRect,CvR bool rectangleDetection(IplImage* inputImage,IplImage* srcImage,CvRect iRect,int iColor,int* p1,int* p2); bool BoxDetectTL(Mat src_test,HOGDescriptor &myHOG,bool HORZ); bool BlackAroundLight(IplImage* srcImg,CvRect iRect); +int RecognizeLight(IplImage* srcImg,CvRect iRect);//return the TL recognition result +int isTL(IplImage* srcImg,CvRect iRect);//жǷΪźŵ +void GetImageRect(IplImage* orgImage, CvRect rectInImage, IplImage* imgRect); using namespace std; using namespace cv; diff --git a/isTL.xml b/isTL.xml new file mode 100644 index 0000000..24a59eb --- /dev/null +++ b/isTL.xml @@ -0,0 +1,113 @@ + + + + C_SVC + LINEAR + 1.0000000000000001e-001 + 1.1920928955078125e-007 + 1000 + 324 + 324 + 2 + + 1 + 2 +
i
+ + 0 1
+ 1 + + <_> + 1.56036884e-001 -1.55410200e-001 -2.01866969e-001 4.14274074e-002 + 6.94726929e-002 4.65383753e-002 6.28277808e-002 7.09838569e-002 + 1.21663369e-001 7.31278360e-002 -1.64729375e-002 -2.04167292e-001 + -6.82259202e-002 -5.51611278e-003 2.17052996e-002 4.86485884e-002 + 4.98296283e-002 1.07196525e-001 7.82411993e-002 -2.24886507e-001 + -2.71874696e-001 -9.86494794e-002 1.25687122e-001 1.20658644e-001 + 4.06613164e-002 6.79099038e-002 1.53325468e-001 1.22529693e-001 + -4.00939249e-002 -9.35682580e-002 -5.86220473e-002 4.66422997e-002 + 3.42046395e-002 5.45608625e-003 3.03352214e-002 1.17306046e-001 + 6.92723831e-003 6.97051361e-002 -6.36906177e-002 -6.82732761e-002 + -6.67658150e-002 -3.82032134e-002 -4.55159927e-003 2.07766555e-002 + -2.27734707e-002 1.50575906e-001 1.68935061e-001 5.93921281e-002 + 3.84022370e-002 -7.74629042e-002 -1.84293836e-001 -2.11851209e-001 + -1.05937727e-001 -3.74147631e-002 6.98328540e-002 7.32415617e-002 + -5.12451008e-002 -2.26342455e-002 -6.47476166e-002 + -7.19183758e-002 1.16215432e-002 3.70402820e-002 1.14437707e-001 + 1.41274124e-001 1.09327637e-001 1.11195529e-002 4.78796884e-002 + -1.58648808e-002 -1.43218726e-001 -1.40580520e-001 + -1.93535332e-002 3.69007885e-002 2.15092018e-001 1.11557022e-001 + 7.01970384e-002 8.37866068e-002 1.06217340e-003 -5.64414263e-002 + -2.54340291e-001 -1.62821755e-001 -8.33874196e-002 1.94156289e-001 + 1.27943456e-001 1.40295029e-001 1.18830234e-001 8.28565806e-002 + -1.19835045e-002 -3.01721036e-001 -1.46937117e-001 + -5.95533922e-002 4.30338718e-002 1.03374720e-001 7.56448135e-002 + 8.74492750e-002 6.01874851e-002 1.44489827e-002 -2.03338310e-001 + -2.50614304e-002 -7.31143868e-003 2.15247856e-003 1.94987506e-001 + 1.68845028e-001 2.12656215e-001 1.46948799e-001 -7.68441036e-002 + -2.93781132e-001 -5.76775894e-002 4.03338559e-002 2.39075460e-002 + -5.97934760e-002 -1.29885927e-001 -1.26589030e-001 + -3.76855955e-002 2.65170615e-002 -3.86675149e-002 1.66915245e-002 + 5.94513267e-002 5.82416579e-002 1.35351392e-002 1.81127973e-002 + -7.63457268e-002 -7.28994608e-002 -7.00188354e-002 + -6.26587495e-002 2.41685063e-002 5.79076186e-002 3.81255858e-002 + 6.19256832e-002 7.89657235e-002 9.50867012e-002 -8.64683390e-002 + -1.49970874e-001 -5.56673892e-002 -8.72978941e-002 + -1.47175556e-002 7.43101016e-002 8.60797539e-002 1.55985773e-001 + 2.14912836e-002 -9.33349207e-002 -2.01558113e-001 -8.49207267e-002 + -3.82880606e-002 2.19198549e-003 4.72889803e-002 2.18127258e-002 + 5.54234460e-002 -1.36239165e-002 -8.53878185e-002 -7.84353763e-002 + -2.42070341e-003 3.55904326e-002 7.10110217e-002 1.31019307e-002 + 3.94776613e-002 9.54635814e-002 1.94141939e-002 -5.31869344e-002 + -7.16326162e-002 -6.74846098e-002 -1.08612999e-002 1.03373993e-002 + 9.56162512e-002 6.90407678e-002 1.30511761e-001 -3.20903733e-002 + -8.12359825e-002 -1.25160113e-001 -4.79309522e-002 + -2.53596101e-002 -2.74991486e-002 5.67354336e-002 -8.64330903e-002 + -4.05427217e-002 -1.18163088e-002 1.21157393e-002 4.48283106e-002 + -1.40989944e-002 2.72303168e-002 -5.72508126e-002 -5.24675101e-002 + 5.78021333e-002 5.38130589e-002 4.91915084e-002 -8.24092794e-003 + -1.21752499e-002 -1.86048046e-001 -4.19445103e-003 + -4.51702848e-002 -6.16904162e-002 2.63639558e-002 5.48340529e-002 + 1.80467650e-001 1.82503425e-002 -1.19063802e-001 -2.52490520e-001 + 3.45796384e-002 6.63022231e-003 -6.80198073e-002 -1.09015055e-001 + -5.09467274e-002 3.11760008e-002 6.05069995e-002 7.51648247e-002 + -3.63552012e-002 4.68737707e-002 -5.29397875e-002 4.06733826e-002 + 1.09812459e-002 -1.28183013e-003 1.42601907e-001 8.39142576e-002 + 6.09576069e-002 3.59109007e-002 9.33900476e-002 1.46967284e-002 + 5.96003756e-002 4.65553291e-002 3.99092101e-002 1.34020954e-001 + 4.31154855e-002 -1.50818139e-001 -1.81441188e-001 -1.20097004e-001 + 5.35494797e-002 1.07319333e-001 8.15097094e-002 5.38924783e-002 + 1.01222783e-001 1.68098286e-002 -1.16695344e-001 -8.84555280e-002 + -1.16753310e-001 2.13977005e-002 1.85226664e-001 8.34598839e-002 + 6.94932863e-002 1.57387510e-001 5.72885796e-002 -1.63378760e-001 + -3.25934857e-001 -2.37415224e-001 1.69544905e-001 2.95434535e-001 + 1.90200031e-001 6.92697465e-002 1.96215540e-001 7.86449611e-002 + -7.73894787e-002 -1.47447020e-001 -2.14115113e-001 2.32258551e-002 + 6.89294562e-002 6.43628836e-002 4.43876982e-002 3.01110512e-003 + -6.06745295e-002 -5.05361594e-002 -8.62531886e-002 + -8.73161629e-002 -3.65096033e-002 2.56805625e-002 -7.61494339e-002 + -5.57822809e-002 -5.39904162e-002 3.33092250e-002 1.42641198e-002 + -1.63426697e-002 3.33168730e-003 -3.77073623e-002 1.90925896e-001 + 1.06870264e-001 4.45638895e-002 8.55093524e-002 -2.20268220e-002 + -4.56462055e-002 -7.82874003e-002 -1.21429577e-001 + -1.40921146e-001 6.12106845e-002 4.76668067e-002 -1.11054555e-002 + -5.34440838e-002 5.25335632e-002 5.18498681e-002 5.09985983e-002 + 1.12468889e-002 -1.26223594e-001 -7.37349465e-002 -1.35690689e-001 + -1.25087157e-001 -3.67802791e-002 3.56901400e-002 5.01857586e-002 + 2.41782591e-002 5.45808896e-002 1.14228902e-002 -7.66681880e-002 + -1.17870860e-001 -2.02913478e-001 2.50498392e-002 1.73717082e-001 + 1.22337490e-001 1.39574811e-001 7.24396557e-002 -5.26285097e-002 + -7.60265533e-003 -1.58792377e-001 -1.69140503e-001 + -2.09366214e-002 2.33074352e-002 1.07788809e-001 7.67055303e-002 + 1.04977414e-001 7.36823827e-002 1.73312854e-002 -2.16749817e-001 + -2.14010343e-001 7.24725053e-002 1.69069335e-001 1.91567838e-001 + 1.33366734e-001 1.07279412e-001 2.28625932e-003 + + <_> + 1 + -5.7395776800048726e-001 + + 1. + + 0
+
diff --git a/traffic.h b/traffic.h index 36b22df..7030794 100644 --- a/traffic.h +++ b/traffic.h @@ -8,7 +8,7 @@ #include #define IS_SAVE 0 //ͷɼϢǷ񱣴 -#define OPENMP 1//ǷʹOPENMPд +#define OPENMP 0//ǷʹOPENMPд #define ISDEBUG_TL 0//ʱмͼϢ(Traffic Light) #define ISDEBUG_TS 0//ʱмͼϢ(Traffic Sign) #define IS_SHOW_RESULT 1//Ƿʾ,ʾͼٶȸ