Skip to content

Commit 8cb508d

Browse files
committed
Add a test of windows shorter than the sink - there is a flaw that needs to be fixed, so the sinks aren't working even though the rest of it seems to
1 parent 82bf207 commit 8cb508d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

stanza/tests/constituency/test_lstm_model.py

+4
Original file line numberDiff line numberDiff line change
@@ -436,10 +436,14 @@ def test_relative_attention_directional(pretrain_file):
436436
run_forward_checks(model)
437437

438438
def test_relative_attention_sinks(pretrain_file):
439+
model = build_model(pretrain_file, '--no_use_lattn', '--use_rattn', '--rattn_heads', '10', '--no_rattn_cat', '--rattn_window', '2', '--rattn_sinks', '1')
440+
run_forward_checks(model)
439441
model = build_model(pretrain_file, '--no_use_lattn', '--use_rattn', '--rattn_heads', '10', '--no_rattn_cat', '--rattn_sinks', '2')
440442
run_forward_checks(model)
441443

442444
def test_relative_attention_cat_sinks(pretrain_file):
445+
model = build_model(pretrain_file, '--no_use_lattn', '--use_rattn', '--rattn_heads', '10', '--rattn_cat', '--rattn_window', '2', '--rattn_sinks', '1')
446+
run_forward_checks(model)
443447
model = build_model(pretrain_file, '--no_use_lattn', '--use_rattn', '--rattn_heads', '10', '--rattn_cat', '--rattn_sinks', '2')
444448
run_forward_checks(model)
445449

0 commit comments

Comments
 (0)