| 125 | } |
| 126 | |
| 127 | py::UniqueObj DTModelObject::getCountByTopic() const |
| 128 | { |
| 129 | auto* inst = getInst<tomoto::IDTModel>(); |
| 130 | auto l = inst->getCountByTopic(); |
| 131 | |
| 132 | int64_t* ptr; |
| 133 | auto ret = py::newEmptyArray(ptr, inst->getT(), inst->getK()); |
| 134 | for (size_t i = 0; i < inst->getT(); ++i) |
| 135 | { |
| 136 | memcpy(ptr + i * inst->getK(), &l[inst->getK() * i], sizeof(int64_t) * inst->getK()); |
| 137 | } |
| 138 | return ret; |
| 139 | } |
| 140 | |
| 141 | py::UniqueObj DTModelObject::getAlpha() const |
| 142 | { |
no test coverage detected