mirror of
				https://github.com/StefBuwalda/ProjectIOT.git
				synced 2025-10-30 19:29:57 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			20 lines
		
	
	
		
			465 B
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			20 lines
		
	
	
		
			465 B
		
	
	
	
		
			Python
		
	
	
	
	
	
| import io
 | |
| 
 | |
| 
 | |
| async def process_image(image: bytes) -> str:
 | |
|     print("Saving file to memory")
 | |
|     image_file = io.BytesIO(image)
 | |
| 
 | |
|     print("Processing image")
 | |
|     # anpr_info = await anpr.detect(image_file)  # type: ignore
 | |
| 
 | |
|     # if anpr_info is None:
 | |
|     #    print("Something went wrong with ANPR")
 | |
|     #    return ""
 | |
| 
 | |
|     # if not anpr_info["is_plate"]:
 | |
|     #     return ""
 | |
| 
 | |
|     # print(anpr_info["plate_number"])
 | |
|     return ""  # str(anpr_info["plate_number"])
 |