MCPcopy Create free account
hub / github.com/bab2min/tomotopy / getWords

Method getWords

src/python/handler/py_utils.cpp:981–986  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

979}
980
981std::vector<std::pair<std::string, tomoto::Float>> DocumentObject::getWords(size_t topN) const
982{
983 if (corpus->isIndependent()) throw py::RuntimeError{ "This method can only be called by documents bound to the topic model." };
984 if (!corpus->tm->inst) throw py::RuntimeError{ "inst is null" };
985 return corpus->tm->inst->getWordsByDocSorted(getBoundDoc(), topN);
986}
987
988py::UniqueObj DocumentObject::getZ() const
989{

Callers

nothing calls this directly

Calls 2

isIndependentMethod · 0.80
getWordsByDocSortedMethod · 0.80

Tested by

no test coverage detected