딥러닝
-
[Pytorch] EMNIST CNN딥러닝 2020. 4. 3. 00:33
EMNIST 데이터는 알파벳과 숫자로 이루어진 데이터입니다. 아래 사이트에 MNIST 데이터에 대한 설명이 잘되어 있습니다. https://www.simonwenkel.com/2019/07/16/exploring-EMNIST.html Exploring EMNIST - another MNIST-like dataset // SimonWenkel.com MNIST is not part of my exploring less known datasets series. However, we will have a look at EMNIST. EMNIST [1] is another MNIST-like [2] dataset similar to Fashion-MNIST [3] and Kuzushiji-MNIST [4]. C..
-
[Pytorch] MNIST CNN딥러닝 2020. 3. 31. 01:01
이번에는 MNIST CNN 모델을 만들어보겠습니다. 이번 포스트도 https://adventuresinmachinelearning.com/convolutional-neural-networks-tutorial-in-pytorch/을 참고하였습니다. CNN에 관한 이론은 생략하겠습니다. Convolutional Neural Networks Tutorial in PyTorch - Adventures in Machine Learning Learn all about the powerful deep learning method called Convolutional Neural Networks in an easy to understand, step-by-step tutorial. Also learn how to im..
-
[Pytorch] MNIST 신경망 구현딥러닝 2020. 3. 28. 23:34
Pytorch를 이용해 간단한 MNIST 신경망을 구현하겠습니다. Convolution을 사용하는 것이 아닌 단순한 신경망으로 이루어진 네트워크입니다. https://adventuresinmachinelearning.com/pytorch-tutorial-deep-learning/을 참고하였습니다. 코드에 대한 설명은 주석에 첨부하였습니다. import torch.nn as nn import torch.nn.functional as F class NeuralNetwork(nn.Module): # 상속 def __init__(self): super().__init__() # 기본 nn.Module 모델 생성 self.fc1 = nn.Linear(in_features=28*28, out_features=200..
-
[Pytorch] 간단한 신경망 구현딥러닝 2020. 3. 16. 00:13
Pytorch 공식 튜토리얼 중 신경망 관련 내용에 대한 저의 코드입니다. Medium https://medium.com/dair-ai/a-simple-neural-network-from-scratch-with-pytorch-and-google-colab-c7f3830618e0 예제에서는 직접 설정한 도함수를 이용해 BackPropagation을 실행하지만 저는 Pytorch의 backwatd 함수를 사용하였습니다. 본 예제에서 만드는 딥러닝 모델은 다음과 같은 간단한 모델입니다. 보시는 바와 같이 1개의 Hidden Layer로 구성된 매우 간단한 신경망입니다. 본 예제에서는 1x2 크기의 벡터를 입력으로 하고 1x1 텐서 (스칼라)를 출력으로 합니다. 먼저 학습 데이터입니다. X 텐서에 학습 데이터와..