Skip to content

Commit

Permalink
update use all data.
Browse files Browse the repository at this point in the history
  • Loading branch information
taeguk committed Sep 24, 2016
1 parent 7e17557 commit 82bdf0a
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 14 deletions.
17 changes: 4 additions & 13 deletions io_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,20 +31,11 @@ def get_data(csv_name, one_hot):


def get_train_test_data(one_hot = True):
data_x, data_y = get_data('data/data.csv', one_hot)
data_cnt = len(data_x)
train_cnt = data_cnt*3//4
train_x = data_x[0:train_cnt]
train_y = data_y[0:train_cnt]
test_x = data_x[train_cnt:]
test_y = data_y[train_cnt:]


print(train_x)
print(train_y)
print(test_x)
print(test_y)
train_x, train_y = get_data('data/train.csv', one_hot)
test_x, test_y = get_data('data/test.csv', one_hot)

train_x = test_x = np.concatenate((train_x, test_x), axis=0)
train_y = test_y = np.concatenate((train_y, test_y), axis=0)

return train_x, train_y, test_x, test_y

Expand Down
2 changes: 1 addition & 1 deletion model/inception_cnn.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import tensorflow as tf


VERSION = "v.beta3.auto_train_data"
VERSION = "v.beta3.all_train_data"


initializer = tf.contrib.layers.xavier_initializer()
Expand Down
1 change: 1 addition & 0 deletions train.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
train_x_data, train_y_data, test_x_data, test_y_data = io_data.get_train_test_data(one_hot=True)
train_data_len = len(train_x_data)
test_data_len = len(test_x_data)
print(train_data_len, test_data_len)

X = tf.placeholder("float", [None, 225])
Y = tf.placeholder("float", [None, 225])
Expand Down

0 comments on commit 82bdf0a

Please sign in to comment.