![]() Print("Vocabulary saved to file \"%s\"" % vocab_filename) Utils.save_file(vocabulary.keys(), vocab_filename) '.split())ĭoc = nlp("El copal se usa principalmente para sahumar en distintas ocasiones como lo son las fiestas religiosas.")ĭisplacy.render(doc, style='dep', jupyter = True, options = Print ('Mi colega me ayuda a programar cosas. Self.bi = loadtagger('cess_nomwe_bigram.tagger') Self.uni = loadtagger('cess_nomwe_unigram.tagger') Self.bi = loadtagger('cess_bigram.tagger') Self.uni = loadtagger('cess_unigram.tagger') ![]() ![]() Print "*** First-time use of cess tagger ***"Ĭess_nomwe = unchunk(cess.tagged_sents()) # Train tagger if it's used for the first time. Print "Tagger trained with",corpusname,"using" \ Savetagger(corpusname '_bigram.tagger',bi_tag) # Evaluates on testing data remaining 10% # Train a bigram tagger with only training data. ![]() # Split corpus into training and testing set. # each entry in the list is one sentence. Here's an example code: from rpus import cess_esp as cess from nltk import UnigramTagger as ut from nltk import BigramTagger as bt # Read the corpus into a list, # … from rpus import cess_esp as cess Previous Post Next Post NLTK Tagging spanish words using a corpus ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |