コード例 #1
0
def main():
    """Main function, that train and validade the model for the Quotation Extractor Task.

    """
    w = train.train()
    print(w)

    dataset = train_example.load(fileName=INPUT_TEST_FILE)

    precision, recall = metrics.validate(w, dataset=dataset, argmax=quotation.argmax)

    print("On the test set:\n")
    print("precision:", precision)
    print("recall:", recall)
コード例 #2
0
ファイル: application.py プロジェクト: rafael2reis/iquotesx
def main():
    """Main function, that train and validade the model for the Quotation Extractor Task.

    """
    w = train.train()
    print(w)

    dataset = train_example.load(fileName=INPUT_TEST_FILE)

    precision, recall = metrics.validate(w,
                                         dataset=dataset,
                                         argmax=quotation.argmax)

    print("On the test set:\n")
    print("precision:", precision)
    print("recall:", recall)
コード例 #3
0
	def test_train(self):
		w = train.train()
		#print("w:", w)

		self.assertEqual(len(w), 537)