python – Is there any specific format of primary address number/building number/apartment number in United States Address?-ThrowExceptions

Exception or error:

I am doing OCR of US Driving License where I get stuck at Driving License Address Field where I have to fetch the address with eliminating leading any extra number. In US Driving License the 8th number field is Address.

Here in below example, 227 is the primary address number

Note: Under US Driving License is not an original, its just a sample image.

I am explaining through example, Here is the sample us driving license:

US Driving License Sample

In the following image, i am fetching all the field by using my OCR Server.

My Server is returning the data in JSON format like this:

{
  "address": "8 227 YALE AVE N SEATTLE WA 98109-4567",
  "fristName": "WA WASHINGTON",
  "gender": "F",
  "dlNo": "Dl not Found ",
  "cls": "9a",
  "LastName": "USA DRIVER LICENSE",
  "state": "WA",
  "eyes": "BLU",
  "DOI": "DOI not found",
  "height": "5-07",
  "status": "SUCCESS"
}

You can see the address field in JSON, it returning address along with the leading 8 number in Driving License.

So, I am just stuck here how to filter the particular field. I have to remove that 8 number from address. Some times 8 gets detected and some times its not get detected. So, I am stuck here…. please guide me how to solve this problem.

How to solve:

Leave a Reply

Your email address will not be published. Required fields are marked *