Minor aesthetic improvements

This commit is contained in:
Crista Lopes
2019-12-31 16:52:39 -08:00
parent a6fc28a123
commit 69e9934ae9

View File

@@ -30,13 +30,11 @@ def decode_one_hot(y):
return ''.join(s)
def normalization_layer_set_weights(n_layer):
print(n_layer.get_weights()[0].shape)
print(n_layer.get_weights()[1].shape)
wb = []
w = np.zeros((LINE_SIZE*INPUT_VOCAB_SIZE, LINE_SIZE*INPUT_VOCAB_SIZE), dtype=np.float32)
b = np.zeros((LINE_SIZE*INPUT_VOCAB_SIZE), dtype=np.float32)
# Let lower case letters go through
for r in range(0, LINE_SIZE*INPUT_VOCAB_SIZE, INPUT_VOCAB_SIZE):
# Let lower case letters go through
for c in string.ascii_lowercase:
i = char_indices[c]
w[r+i, r+i] = 1