목록pytorch (16)
rueki

https://github.com/facebookresearch/fvcore GitHub - facebookresearch/fvcore: Collection of common code that's shared among different research projects in FAIR computer vis Collection of common code that's shared among different research projects in FAIR computer vision team. - GitHub - facebookresearch/fvcore: Collection of common code that's shared among dif... github.com from fvcore.nn import ..
예전부터 계속 파이토치를 써오기는 했지만, 다시 공부하는 차원에서 CNN을 이용한 mnist 분류를 리뷰해보고자 한다. 1. 필요한 라이브러리 호출하기 import os import torch import numpy as np import torch.nn as nn import torch.optim as optim from torch.utils.data import DataLoader from torch.utils.tensorboard import SummaryWriter from torchvision import transforms, datasets torch -> pytorch 불러오기 numpy -> linear algebra를 계산 위한 넘파이 torch.nn -> layer, function들이..

이번에는 Recurent Neural Network , RNN을 구현해보는 시간이다. 보통 시계열 데이터 및 텍스트 데이터에서 많이 사용하는 신경망 구조이다. 이번 시간에는 데이터를 시계열 특성을 가지게 직접 sin함수를 구현해서 사용하였다. import torch from torch import nn import numpy as np import matplotlib.pyplot as plt %matplotlib inline plt.figure(figsize=(8,5)) seq_length = 20 time_steps = np.linspace(0, np.pi, seq_length+1)#start, stop, num data = np.sin(time_steps) data.resize((seq_length ..