I am trying to extract the values associated to each pixel in a tiff image using the gdal library.
# Create a polygon from the pixel coordinates
polygon = Polygon([(x_min, y_min), (x_min, y_max), (x_max, y_max), (x_max, y_min)])
# Associate the polygon with the value
polygon.value = value
When I try to access the value of the polygon I got the error
AttributeError: 'Polygon' object has no attribute 'value'
Polygon?valueattribute come from!?