Skip to content

Instantly share code, notes, and snippets.

@sodeyama
sodeyama / gist:4243787
Created Dec 9, 2012
逆配列のユニーク性
View gist:4243787
Require Import Bool.
Require Import Lists.List.
Require Import String.
Require Import Ascii.
Definition eqc (x y : ascii) : bool :=
if ascii_dec x y
then true
else false.
View cifar10_sample1.py
from __future__ import print_function
import keras
from keras.datasets import cifar10
from keras.preprocessing.image import ImageDataGenerator
from keras.models import Sequential
from keras.layers import Dense, Dropout, Activation, Flatten
from keras.layers import Convolution2D, Conv2D, MaxPooling2D
batch_size = 32
num_classes = 10
View keras_exp2.py
import nuimport numpy as np
import keras
from keras.models import Sequential
from keras.datasets import mnist
from keras.layers.convolutional import Convolution2D, MaxPooling2D
from keras.layers.core import Dense, Activation, Dropout, Flatten
from keras.utils import np_utils
View keras_exp1.py
from keras.models import Sequential
from keras.layers import Dense, Activation
from keras.datasets import mnist
from keras.utils import np_utils
from keras.optimizers import SGD
model = Sequential()
(X_train, Y_train), (X_test, Y_test) = mnist.load_data()
X_train = X_train.reshape(-1, 28*28).astype('float32')/255
Y_train = np_utils.to_categorical(Y_train, 10)
View experiment2.py
import sys, os
sys.path.append(os.pardir)
from dataset.mnist import load_mnist
import tensorflow as tf
import numpy as np
(x_train, t_train), (x_test, t_test) = load_mnist(normalize=True, one_hot_label=True)
View experiment1.py
from __future__ import absolute_import
from __future__ import division
from __future__ import print_function
import argparse
import sys
from tensorflow.examples.tutorials.mnist import input_data
import tensorflow as tf
You can’t perform that action at this time.