9#include "../../query.h"
10#include "../Iterator/knnGraphKNearestIterator.h"
15 template <
typename Traits>
16 class StaticKnnGraphBase;
18#ifndef PARSED_WITH_DOXYGEN
19 struct KnnGraphQueryOutputType :
public QueryOutputBase
21 using OutputParameter =
typename QueryOutputBase::DummyOutputParameter;
33 template <
typename Traits>
36 :
public KNearestIndexQuery<typename Traits::IndexType, typename Traits::DataPoint::Scalar>
39 :
public Query<QueryInputIsIndex<typename Traits::IndexType>, KnnGraphQueryOutputType>
44#ifdef PARSED_WITH_DOXYGEN
62 return Iterator(m_graph->getIndexPtr()) + QueryType::input() * m_graph->k();
68 return Iterator(m_graph->getIndexPtr()) + (QueryType::input() + 1) * m_graph->k();
Aggregator class used to declare specialized structures using CRTP.
Extension of the Query class that allows to read the result of a k-nearest neighbors search on the Kn...
Self & operator()(int index)
Call the k-nearest neighbors query with new input parameter.
Iterator end() const
Returns an iterator to the end of the k-nearest neighbors query.
Iterator begin() const
Returns an iterator to the beginning of the k-nearest neighbors query.
Composes the Query object depending on an input type and output type.
This Source Code Form is subject to the terms of the Mozilla Public License, v.