This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#tensorflowとインポート。MNISTデータをロード | |
import tensorflow as tf | |
from tensorflow.examples.tutorials.mnist import input_data | |
mnist= input_data.read_data_sets('MNIST_data',one_hot=True) | |
#プレースホルダー作成 | |
X = tf.placeholder(tf.float32, shape=[None, 784]) | |
Y = tf.placeholder(tf.float32, shape=[None, 10]) | |
#重み(w)とバイアス(b) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#必要なライブラリをインポート | |
import matplotlib.pyplot as plt | |
import dlib | |
import urllib | |
import cv2 | |
import numpy as np | |
from PIL import Image | |
import cStringIO | |
#画像のURLを読み込む |