Have 3 questions from lesson 7 on super resolution notebook.
p,img_hr,b = my_unet_learner.predict(img)
The file sizes in bytes for p.save("my-file.jpg")
and Image(img_hr).save("my-file2.jpg")
are different. What is the right way to save the prediction as a file?
- Is there a way to get size in bytes without saving the predicted image file to disk?
- Another small confusion is the string representation of DataBunch instance shows
x
andy
like below. Paths for train and validation sets are also printed. Are these the paths fory
orx
? Because ideally, path forx
should be small-96 andy
should be small-96-compressed in my case.
ImageDataBunch;
Train: LabelList (6651 items)
x: ImageImageList
Image (3, 96, 128),Image (3, 96, 141),Image (3, 96, 128),Image (3, 96, 136),Image (3, 96, 128)
y: ImageList
Image (3, 96, 128),Image (3, 96, 141),Image (3, 96, 128),Image (3, 96, 136),Image (3, 96, 128)
Path: /home/username/.fastai/data/oxford-iiit-pet/small-96;
Valid: LabelList (739 items)
x: ImageImageList
Image (3, 96, 128),Image (3, 144, 96),Image (3, 96, 128),Image (3, 96, 112),Image (3, 96, 128)
y: ImageList
Image (3, 96, 128),Image (3, 144, 96),Image (3, 96, 128),Image (3, 96, 112),Image (3, 96, 128)
Path: /home/username/.fastai/data/oxford-iiit-pet/small-96;
Test: None
Thank you