openfoodfacts / openfoodfacts-ai

This is a tracking repo for all our AI projects. 🍕 🤖🍼
220 stars 51 forks source link

Flatten images #26

Open teolemon opened 6 years ago

teolemon commented 6 years ago

What

yashpungaliya commented 6 years ago

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()

Anubhav-Bhargava commented 6 years ago

@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.