I am doing a project in which I have image of electricity meter reading. I need to extract the digits in the image.
I converted the image to a numpy array using the PIL Image function.
This is the code I typed
import numpy as np
from PIL import Image
img_data = Image.open('meter1.jpg' )
img_arr = np.array(img_data)
print(img_arr)
I got this numpy array as the output
[[[ 2 96 10]
[ 2 96 10]
[ 2 96 10]
...
[ 18 144 47]
[ 13 141 48]
[ 10 139 46]]
[[ 11 105 19]
[ 10 106 19]
[ 10 104 18]
...
[ 28 156 59]
[ 26 156 60]
[ 24 155 59]]
[[ 19 115 26]
[ 16 115 25]
[ 17 113 24]
...
[ 30 162 60]
[ 28 164 62]
[ 26 165 64]]
...
[[ 0 126 18]
[ 0 126 18]
[ 0 126 18]
...
[ 4 211 77]
[ 4 211 79]
[ 6 213 83]]
[[ 0 126 18]
[ 0 126 18]
...
[ 4 212 76]
[ 4 211 79]
[ 6 213 83]]
[[ 1 124 17]
[ 1 124 17]
[ 1 124 17]
...
[ 5 211 76]
[ 5 210 79]
[ 7 212 81]]]
How do I use this numpy array to extract the numerical values or the digits or the numbers from this image?
It is a seven segment display. Was is useful to convert the image to numpy array? Is there any other approach to do this. I have not done much of hand-on python so please help
