You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
올려주신 코드를 보고 연습을 하고 있는데 다음과 같은 문제가 생깁니다.
코드:
for i in range(total_batch):
batch_xs, batch_ys = data.next_batch(BatchSize=batch_size, shuffle=data_shuffle)
batch_xs = np.asarray(batch_xs)
batch_ys = np.asarray(batch_ys)
batch_xs = batch_xs.reshape(-1, 48, 48, 1)
올려주신 코드를 보고 연습을 하고 있는데 다음과 같은 문제가 생깁니다.
코드:
for i in range(total_batch):
batch_xs, batch_ys = data.next_batch(BatchSize=batch_size, shuffle=data_shuffle)
batch_xs = np.asarray(batch_xs)
batch_ys = np.asarray(batch_ys)
batch_xs = batch_xs.reshape(-1, 48, 48, 1)
*batch size = 50입니다.
X = tf.placeholder(tf.float32, [None, 48, 48, 1])
Y = tf.placeholder(tf.float32, [None, 7])
keep_prob = tf.placeholder(tf.float32)
이러식으로 돌렸을 때, 오류문이 다음과 같이 나옵니다.
ValueError : cannot reshape array of size 50 into shape (48,48,1)
현재 파이썬3에서 위 코드를 돌리고 있는데, 버전이 달라서 reshape 함수가 안돌아가는 건가요?
The text was updated successfully, but these errors were encountered: