openfoodfacts-ai icon indicating copy to clipboard operation
openfoodfacts-ai copied to clipboard

Flatten images

Open teolemon opened this issue 6 years ago • 2 comments

What

  • Not AI per se, but need to flatten images (on bottles for instance) to enable better recognition on other projects

Part of

  • #8
  • #76

teolemon avatar Feb 28 '18 10:02 teolemon

Hi @teolemon we can use the imread function in scipy for flattening the images as follows-

from scipy.misc import imread img = imread("imgname.jpg") img.flatten()

yashpungaliya avatar Mar 01 '18 17:03 yashpungaliya

@yashpungaliya I think we need to flatten image as in change the angle by which the image is taken, as you see in Google earth images. The above flatten function only converts the image from 2-D (grayscale) to 1-D array.

Anubhav-Bhargava avatar Mar 08 '18 04:03 Anubhav-Bhargava