remove unnecessary assert
This commit is contained in:
parent
3a187c920c
commit
793b6139f2
|
@ -218,10 +218,8 @@ def prepare(dataset="mnist", return_floats=True, return_onehot=True,
|
||||||
test_images_data = test_images_data.transpose(0,1,3,2)
|
test_images_data = test_images_data.transpose(0,1,3,2)
|
||||||
|
|
||||||
if return_floats: # TODO: better name.
|
if return_floats: # TODO: better name.
|
||||||
train_images_data = train_images_data.astype(np.float32) / np.float32(255)
|
train_images_data = train_images_data.astype(np.float32) / 255
|
||||||
test_images_data = test_images_data.astype(np.float32) / np.float32(255)
|
test_images_data = test_images_data.astype(np.float32) / 255
|
||||||
assert train_images_data.dtype == 'float32'
|
|
||||||
assert test_images_data.dtype == 'float32'
|
|
||||||
|
|
||||||
# emnist_letters uses labels indexed from 1 instead of the usual 0.
|
# emnist_letters uses labels indexed from 1 instead of the usual 0.
|
||||||
# the onehot function assumes labels are contiguous from 0.
|
# the onehot function assumes labels are contiguous from 0.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user