Face Engine SDK  4.6.0
A face detection, recognition and tracking engine.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
fsdk::IDynamicIndex Struct Referenceabstract

Dynamic index interface. More...

#include <IIndex.h>

Inheritance diagram for fsdk::IDynamicIndex:
fsdk::IDynamicDescriptorStorage fsdk::IIndex fsdk::IStaticDescriptorStorage fsdk::IRefCounted

Public Member Functions

virtual Result< FSDKErrorsaveToDenseIndex (const char *path) const noexcept=0
 Saves index as dense. More...
 
virtual Result< FSDKErrorsaveToDynamicIndex (const char *path) const noexcept=0
 Saves index as dynamic. More...
 
virtual uint64_t countOfIndexedDescriptors () const noexcept=0
 Returns count of indexed descriptors. More...
 
- Public Member Functions inherited from fsdk::IDynamicDescriptorStorage
virtual ResultValue< FSDKError,
DescriptorId
appendDescriptor (const IDescriptor *desciptor) noexcept=0
 Appends descriptor to internal storage. If used on. More...
 
virtual ResultValue< FSDKError,
DescriptorId
appendBatch (const IDescriptorBatch *batch) noexcept=0
 Appends batch of descriptors to internal storage. If used on. More...
 
virtual Result< FSDKErrorremoveDescriptor (const DescriptorId index) noexcept=0
 Removes descriptor out of internal storage. If used on. More...
 
- Public Member Functions inherited from fsdk::IStaticDescriptorStorage
virtual Result< FSDKErrordescriptorByIndex (const DescriptorId index, IDescriptor *descriptor) const noexcept=0
 Requests descriptor data out of internal storage. More...
 
virtual uint64_t size () const noexcept=0
 Return size of internal storage. More...
 
- Public Member Functions inherited from fsdk::IIndex
virtual ResultValue< FSDKError,
int > 
search (const IDescriptor *reference, int maxResultsCount, SearchResult *results) const noexcept=0
 Search for descriptors with the shorter distance to passed descriptor. More...
 
- Public Member Functions inherited from fsdk::IRefCounted
virtual int32_t retain () noexcept=0
 Increase strong reference count. More...
 
virtual int32_t release () noexcept=0
 Decrease strong reference count. More...
 
virtual int32_t getRefCount () const noexcept=0
 Get actual strong reference count. More...
 
virtual int32_t retainWeak () noexcept=0
 Increase weak reference count. More...
 
virtual int32_t releaseWeak () noexcept=0
 Decrease weak reference count. More...
 
virtual int32_t getWeakRefCount () const noexcept=0
 Get actual weak reference count. More...
 

Detailed Description

Dynamic index interface.

Member Function Documentation

virtual uint64_t fsdk::IDynamicIndex::countOfIndexedDescriptors ( ) const
pure virtualnoexcept

Returns count of indexed descriptors.

You may wonder why this method exists if IDynamicIndex already inherits IStaticDescriptorStorage::size method. The reason is that

See Also
IDynamicDescriptorStorage::removeDescriptor behaves differently on
IIndexBuild and IDynamicIndex. On builder it does actually erases descriptor out of internal storage, but it does not erase it if used on IDynamicIndex. The reason is that graph data structure relies on indexes being constant, so removeDescriptor only removes it out of graph, so it is not discoverable by
IIndex::search. So this methods returns actuall data storage size minus count of removed descriptors.
Returns
Count of indexed descriptors.
virtual Result<FSDKError> fsdk::IDynamicIndex::saveToDenseIndex ( const char *  path) const
pure virtualnoexcept

Saves index as dense.

To load saved index use

See Also
IFaceEngine::loadDenseIndex method. Dense index cannot be loaded as dynamic.
Parameters
pathPath to file to be created and filled with index data. Any extension is acceptable.
Returns
One of the error codes specified by
See Also
FSDKError.
virtual Result<FSDKError> fsdk::IDynamicIndex::saveToDynamicIndex ( const char *  path) const
pure virtualnoexcept

Saves index as dynamic.

To load saved index use

See Also
IFaceEngine::loadDynamicIndex method. Dynamic index cannot be loaded as dense.
Parameters
pathPath to file to be created and filled with index data. Any extension is acceptable.
Returns
One of the error codes specified by
See Also
FSDKError.

The documentation for this struct was generated from the following file: