본문 바로가기

tensorflow

TensorFlow - RNN 기초 @markdown# RNN(Recurrent Neural Network)____- Sequence 데이터를 처리하는 모델- 현재의 상태가 다음 state에 영향을 미치는 Network으로 RNN의 아웃풋이 다음의 인풋이 된다. - 하나의 네트워크가 여러개 복사된 형태를 띄고 있다. - 음성인식, 언어 모델링, 번역, 이미지 인식 등 여러분야에서 사용된다.![](https://user-images.githubusercontent.com/12658717/29610217-7e3bb5e0-8834-11e7-914d-5a13d4aa66d9.png) 아래의 그림 처럼 다음 state의 값에 입력되어 영향을 미친다.![](https://user-images.githubusercontent.com/12658717/29.. 더보기
TensorFlow - MNIST 데이터 셋 활용한 손 글씨 인식 모델 구현 @markdown# TensorFlow MNIST 데이터 셋 이용한 손 글씨 인식 학습모델 구현 ## MNIST 손글씨 인식 모델 기본 소스코드____import tensorflow as tfimport randomimport matplotlib.pyplot as pltfrom tensorflow.examples.tutorials.mnist import input_data# one_hot encoding 옵션mnist = input_data.read_data_sets("MNIST_data/", one_hot=True)# 0~9까지 숫자 10개nb_classes = 10X = tf.placeholder(tf.float32, [None, 784])Y = tf.placeholder(tf.float32, [No.. 더보기
TensorFlow - Multi Variable Linear Regression(다중 선형회귀) @markdown# Multi Variable Linear Regression(다중 선형회귀)____- 두 개 이상의 독립 변수들과 하나의 종속변수의 관계를 분석하는 기법(단순 회귀의 확장)- 기존의 선형회귀 식에서 `X`가 앞으로 온 것이 특징(행렬 곱셈 시 별도의 처리를 하지 않기 위함)![](https://user-images.githubusercontent.com/12658717/27956319-4024aa5a-6354-11e7-86d0-9491987ff3ac.png)![](https://user-images.githubusercontent.com/12658717/27956767-33ebc172-6356-11e7-8b84-c2035aab8366.png)- 보정값 b를 추가해 계산을 한다면 아래와 .. 더보기
TensorFlow - 변수형 종류, 행렬 다루기 @markdown# TensorFlow 변수형 종류, 행렬 다루기____## TensorFlow 상수형- `tf.constant(value, dtype=tf.float32, shape=None, name='const', verify_shape=False)` - value : 지정할 상수 값- dtype : 상수형 데이터(실수 정수 등)- shape : 행렬의 차원 지정, (shape = [3,3]은 3x3 행렬을 저장)- name : 상수 선언 후 사용할 상수 이름 ## TensorFlow Placeholder 변수____- `tf.placeholder(dtype, shape, name)`x = tf.placeholder(tf.float32, shape=[None, 784])- x에 값이 할당한 것이 아.. 더보기
TensorFlow - Windows 7 설치하기 @markdown# Windows 7에 TensorFlow 설치하기_____## 설치환경- Windows 7 Pro 64bit- Python 3.6, Anaconda 4.4.0 for Windows- [TensorFlow install 참고](https://www.tensorflow.org/install/install_windows)## Anaconda 사용하여 TensorFLow 설치하기_____- 2016년 12월 이전까지는 윈도우에 `TensorFlow`를 설치하려면 `Virtual Box`, `Docker`로 우분투(리눅스OS)에 설치해 사용했다.- 2016년 12월 이후에 `TensorFlow`에서 윈도우 정식 버전이 출시하면서 `Python Anaconda` 설치만으로 사용할 수 있게 됐다.-.. 더보기