shreyapamecha / Speed-Estimation-of-Vehicles-with-Plate-Detection

The main objective of this project is to identify overspeed vehicles, using Deep Learning and Machine Learning Algorithms. After acquisition of series of images from the video, trucks are detected using Haar Cascade Classifier. The model for the classifier is trained using lots of positive and negative images to make an XML file. This is followed by tracking down the vehicles and estimating their speeds with the help of their respective locations, ppm (pixels per meter) and fps (frames per second). Now, the cropped images of the identified trucks are sent for License Plate detection. The CCA (Connected Component Analysis) assists in Number Plate detection and Characters Segmentation. The SVC model is trained using characters images (20X20) and to increase the accuracy, 4 cross fold validation (Machine Learning) is also done. This model aids in recognizing the segmented characters. After recognition, the calculated speed of the trucks is fed into an excel sheet along with their license plate numbers. These trucks are also assigned some IDs to generate a systematized database.
158 stars 38 forks source link

Scikit-learn version issue #1

Open Muhammad-MujtabaSaeed opened 5 years ago

Muhammad-MujtabaSaeed commented 5 years ago

Hi, I am running your code for car number plate recognition, but it is giving me following error.

File "C:/Users/mujta/Desktop/Wizdojo/upwork projects/car project israel/Speed-Estimation-of-Vehicles-with-Plate-Detection/SpeedEstimation&_License_Plate_Detection.py", line 886, in trackMultipleObjects()

File "C:/Users/mujta/Desktop/Wizdojo/upwork projects/car project israel/Speed-Estimation-of-Vehicles-with-Plate-Detection/SpeedEstimation&_License_Plate_Detection.py", line 837, in trackMultipleObjects LPN[i] = detection(cropped_image[i])

File "C:/Users/mujta/Desktop/Wizdojo/upwork projects/car project israel/Speed-Estimation-of-Vehicles-with-Plate-Detection/SpeedEstimation&_License_Plate_Detection.py", line 343, in detection result = model.predict(each_character)

File "C:\Anaconda\Anaconda3\lib\site-packages\sklearn\svm\base.py", line 548, in predict y = super(BaseSVC, self).predict(X)

File "C:\Anaconda\Anaconda3\lib\site-packages\sklearn\svm\base.py", line 310, in predict return predict(X)

File "C:\Anaconda\Anaconda3\lib\site-packages\sklearn\svm\base.py", line 326, in _dense_predict svm_type = LIBSVM_IMPL.index(self._impl)

AttributeError: 'SVC' object has no attribute '_impl'

Can you please tell that which version of Scikit-learn you have used to train the SVM model. So that I may use the same version to get the code running. Thanks