Get the App
SLTechnology News&Howtos  ›  Development  › 

How to realize Intelligent parking license Plate recognition and Accounting system based on Python

Shulou Source: shulou.com Published: 2022-05-31 18:58:04 10月04日 Update

This article mainly introduces "how to realize intelligent parking lot license plate recognition and billing system based on Python". In daily operation, I believe many people have doubts about how to realize intelligent parking lot license plate recognition and billing system based on Python. Xiaobian consulted all kinds of materials and sorted out simple and easy operation methods. I hope to answer your doubts about "how to realize intelligent parking lot license plate recognition and billing system based on Python"! Next, please follow the small series to learn together!

project structure

Description:

datefile folder: xlsx file holding vehicle information table

file folder: Save pictures folder. ic_launcher.jpg is the icon file in the upper right corner of the form; income.png is the histogram for income statistics (implemented in the next article); key.txt is the key applied for using Baidu's image recognition AI interface; test.jpg saves images captured by the camera

venv folder: various modules required by the project, i.e. project running environment

btn.py file: button module

main.py file: program main file

ocrutil.py file: License plate recognition module

timeutil.py file: time processing module

Primary Code #Parking Text def text1(screen): #Remaining parking spaces k = Total - carn if k

< 10: # 剩余车位 sk = '0' + str(k) else: sk = str(k) # 使用系统字体 xtfont = pygame.font.SysFont('SimHei', 20) # 重新开始按钮 textstart = xtfont.render('共有车位:' + str(Total) + ' 剩余车位:' + sk, True, WHITE) # 获取文字图像位置 text_rect = textstart.get_rect() # 设置文字图像中心点 text_rect.centerx = 820 text_rect.centery = 30 # 绘制内容 screen.blit(textstart, text_rect)# 停车场信息表头def text2(screen): # 使用系统字体 xtfont = pygame.font.SysFont('SimHei', 15) # 重新开始按钮 textstart = xtfont.render(' 车号 时间 ', True, WHITE) # 获取文字图像位置 text_rect = textstart.get_rect() # 设置文字图像中心点 text_rect.centerx = 820 text_rect.centery = 70 # 绘制内容 screen.blit(textstart, text_rect) pass# 停车场车辆信息def text3(screen): # 使用系统字体 xtfont = pygame.font.SysFont('SimHei', 12) # 获取文档表信息 cars = pi_table[['carnumber', 'date', 'state']].values # 页面就绘制10辆车信息 if len(cars) >

10: cars = pd.read_excel(path + 'parking lot vehicle table.xlsx', skirows =len(cars)-10, sheet_name=' data').values #Dynamically draw y point variables n = 0 #Circular Document Information for car in cars: n += 1 #Vehicle number Vehicle entry time textstart = xtfont.render(str(car[0]) + ' ' + str(car[1]), True, WHITE) #Get text image location text_rect = textstart.get_rect() #Set text image center point text_rect.centerx = 820 text_rect.centery = 70 + 20 * n #Draw content screen.blit(textstart, text_rect) pass to achieve effect

At this point, the study of "how to realize intelligent parking lot license plate recognition and billing system based on Python" is over, hoping to solve everyone's doubts. Theory and practice can better match to help everyone learn, go and try it! If you want to continue learning more relevant knowledge, please continue to pay attention to the website, Xiaobian will continue to strive to bring more practical articles for everyone!

Tags: Files parking lots license plates intelligence systems billing systems folders modules vehicles learning pictures text projects information images time more articles parking spaces help Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Apple NVidia macOS Microsoft vpn