neuralmonkey.tests package

Submodules

neuralmonkey.tests.test_bleu module

class neuralmonkey.tests.test_bleu.TestBLEU(methodName='runTest')

Bases: unittest.case.TestCase

test_bleu()
test_empty_decoded()
test_empty_reference()
test_empty_sentence()
test_identical()

neuralmonkey.tests.test_config module

Tests the config parsing module.

class neuralmonkey.tests.test_config.TestParsing(methodName='runTest')

Bases: unittest.case.TestCase

test_splitter_bad_brackets()
neuralmonkey.tests.test_config.test_splitter_gen(a, b)

neuralmonkey.tests.test_dataset module

class neuralmonkey.tests.test_dataset.TestDataset(methodName='runTest')

Bases: unittest.case.TestCase

test_nonexistent_file()

neuralmonkey.tests.test_decoder module

Unit tests for the decoder. (Tests only initialization so far)

class neuralmonkey.tests.test_decoder.TestDecoder(methodName='runTest')

Bases: unittest.case.TestCase

test_init()

neuralmonkey.tests.test_encoders_init module

Test init methods of encoders.

class neuralmonkey.tests.test_encoders_init.TestEncodersInit(methodName='runTest')

Bases: unittest.case.TestCase

test_post_cnn_encoder()
test_sentence_cnn_encoder()
test_sentence_encoder()
test_vector_encoder()
neuralmonkey.tests.test_encoders_init.traverse_combinations(params: typing.Dict[str, typing.List[typing.Any]], partial_params: typing.Dict[str, typing.Any]) → typing.Iterable[typing.Dict[str, typing.Any]]

neuralmonkey.tests.test_eval_wrappers module

class neuralmonkey.tests.test_eval_wrappers.TestAccuracyEvaluator(methodName='runTest')

Bases: unittest.case.TestCase

setUp()
test_seq_level_acc()
test_word_level_acc()
class neuralmonkey.tests.test_eval_wrappers.TestExternalEvaluators(methodName='runTest')

Bases: unittest.case.TestCase

test_beer()
test_f1()
test_gleu()
test_multeval_bleu()
test_multeval_meteor()
test_multeval_ter()

neuralmonkey.tests.test_functions module

Unit tests for functions.py.

class neuralmonkey.tests.test_functions.TestPiecewiseFunction(methodName='runTest')

Bases: unittest.case.TestCase

test_piecewise_constant()

neuralmonkey.tests.test_model_part module

Test ModelPart class.

class neuralmonkey.tests.test_model_part.Test(methodName='runTest')

Bases: unittest.case.TestCase

Test capabilities of model part.

test_save_and_load()

Try to save and load encoder.

neuralmonkey.tests.test_nn_utils module

class neuralmonkey.tests.test_nn_utils.TestDropout(methodName='runTest')

Bases: unittest.case.TestCase

test_invalid_keep_prob()

Tests invalid dropout values

test_keep_prob()

Counts dropped items and compare with the expectation

test_train_false()

Checks that dropout is not used when not training

neuralmonkey.tests.test_readers module

Unit tests for readers

class neuralmonkey.tests.test_readers.TestStringVectorReader(methodName='runTest')

Bases: unittest.case.TestCase

setUp()
tearDown()
test_columns()
test_reader()

neuralmonkey.tests.test_ter module

class neuralmonkey.tests.test_ter.TestBLEU(methodName='runTest')

Bases: unittest.case.TestCase

test_empty_decoded()
test_empty_reference()
test_empty_sentence()
test_identical()
test_ter()

neuralmonkey.tests.test_vocabulary module

class neuralmonkey.tests.test_vocabulary.TestVocabulary(methodName='runTest')

Bases: unittest.case.TestCase

test_all_words_in()
test_count_fail()
test_min_freq()
test_padding()
test_there_and_back_self()
test_unknown_word()
test_weights()

Module contents