MCPcopy Create free account
hub / github.com/Acly/krita-vision-tools / encodeSegmentationImage

Method encodeSegmentationImage

src/VisionML.cpp:172–181  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

170}
171
172void VisionModels::encodeSegmentationImage(visp::image_view const &image)
173{
174 QMutexLocker lock(&m_mutex);
175 if (!m_sam.weights) {
176 unloadModels();
177 QByteArray path = modelPath(VisionMLTask::segmentation);
178 m_sam = visp::sam_load_model(path.data(), m_backend);
179 }
180 visp::sam_encode(m_sam, image);
181}
182
183bool VisionModels::hasSegmentationImage() const
184{

Callers 1

processImageMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected