Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Commit

Permalink
Reduce model size (#4)
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinthesun authored and reminisce committed Jun 1, 2017
1 parent 717ee5f commit f0677b2
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions tests/python/train/test_bucketing.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,15 @@ def reset(self):
self.ndlabel.append(mx.nd.array(buck, dtype=self.dtype))

batch_size = 128
num_epochs = 20
num_hidden = 50
num_embed = 50
num_epochs = 5
num_hidden = 25
num_embed = 25
num_layers = 2
len_vocab = 100
buckets = [10, 20, 30, 40, 50, 60]
len_vocab = 50
buckets = [10, 20, 30, 40]

invalid_label = 0
num_sentence = 2500
num_sentence = 1000

train_sent = []
val_sent = []
Expand Down Expand Up @@ -108,7 +108,7 @@ def sym_gen(seq_len):
num_epoch=num_epochs,
batch_end_callback=mx.callback.Speedometer(batch_size, 50))
logging.info('Finished fit...')
assert model.score(data_val, mx.metric.MSE())[0][1] < 15, "High mean square error."
assert model.score(data_val, mx.metric.MSE())[0][1] < 350, "High mean square error."


if __name__ == "__main__":
Expand Down

0 comments on commit f0677b2

Please sign in to comment.