Day 1: Explore loading model code

Yesterday, I started with running dog classification project. However, I found out the Lesson 2 Deep Learning with PyTorch: 21 Loading image was more suitable as the basis to study the code.

Today, I revisit the material on Lesson 2: 21 Loading image. Images are the real high quality images, but probably in different sizes. The first step would be to make this images have the same sizes and probably crop them as well using transforms compose. In the example, 

transform = transforms.Compose([transforms.Resize(255),
                                 transforms.CenterCrop(224),
                                 transforms.ToTensor()])

I think I need to ask this in tech_help channel, Resize and CenterCrop which one is executed first and 255 and 224 is pixel or other?


Quick help from the channel. It make sense now.

Running Part 7 exercise locally, I got an error on torchvision. It seemed yesterday code to install pytorch was not correct. Below the correct one,

conda install pytorch-cpu torchvision-cpu -c pytorch
I also need to install matplotlib library. The rewritten instructions would be

conda create -n pysyft python=3

conda activate pysyft
conda install pytorch-cpu torchvision-cpu -c pytorch
conda install jupyter notebook
pip install numpy
pip install matplotlib
pip install syft

I misunderstood the jupyter power. I thought since it was online, the images were only few. I only knew this after run it locally. They were 1000+ images for cats and 1000+ images for dogs. The thing is I do not have jars with me at the moment. I cannot take more pictures until next week. Let us see what I can do with this.  

Next question is Data Augmentation. What is data augmentation? I think I would need to find out about this tomorrow.

Comments

Popular posts from this blog