Hell All,

How can I save Image file(JPG format) into my local system. I used
BinaryFiles to load the pictures into spark, converted them into Array and
processed them. Below is the code

*images = sc.binaryFiles("path/car*") *
*imagerdd = images.map(lambda (x,y):
(x,(np.asarray(Image.open(StringIO(y)))))*

*#did some image processing - now key has path and value has Array for
Image*

*imageOutuint = imagelapRDD.map(lambda (x,y): (x,(y.astype(np.uint8))))*
*imageOutIMG = imageOutuint.map(lambda (x,y): (x,(Image.fromarray(y))))*

How can I save the Image to my local system, I see there is no option
pertaining to it.

Reply via email to