2018-01-09 06:44:43 -08:00
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
< html xmlns = "http://www.w3.org/1999/xhtml" >
< head >
< meta http-equiv = "Content-Type" content = "text/xhtml;charset=UTF-8" / >
< meta http-equiv = "X-UA-Compatible" content = "IE=9" / >
< meta name = "generator" content = "Doxygen 1.8.5" / >
< title > Faiss: faiss::ReconstructFromNeighbors Struct Reference< / title >
< link href = "tabs.css" rel = "stylesheet" type = "text/css" / >
< script type = "text/javascript" src = "jquery.js" > < / script >
< script type = "text/javascript" src = "dynsections.js" > < / script >
< link href = "search/search.css" rel = "stylesheet" type = "text/css" / >
< script type = "text/javascript" src = "search/search.js" > < / script >
< script type = "text/javascript" >
$(document).ready(function() { searchBox.OnSelectItem(0); });
< / script >
< link href = "doxygen.css" rel = "stylesheet" type = "text/css" / >
< / head >
< body >
< div id = "top" > <!-- do not remove this div, it is closed by doxygen! -->
< div id = "titlearea" >
< table cellspacing = "0" cellpadding = "0" >
< tbody >
< tr style = "height: 56px;" >
< td style = "padding-left: 0.5em;" >
< div id = "projectname" > Faiss
< / div >
< / td >
< / tr >
< / tbody >
< / table >
< / div >
<!-- end header part -->
<!-- Generated by Doxygen 1.8.5 -->
< script type = "text/javascript" >
var searchBox = new SearchBox("searchBox", "search",false,'Search');
< / script >
< div id = "navrow1" class = "tabs" >
< ul class = "tablist" >
< li > < a href = "index.html" > < span > Main  Page< / span > < / a > < / li >
< li > < a href = "namespaces.html" > < span > Namespaces< / span > < / a > < / li >
< li class = "current" > < a href = "annotated.html" > < span > Classes< / span > < / a > < / li >
< li > < a href = "files.html" > < span > Files< / span > < / a > < / li >
< li >
< div id = "MSearchBox" class = "MSearchBoxInactive" >
< span class = "left" >
< img id = "MSearchSelect" src = "search/mag_sel.png"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
alt=""/>
< input type = "text" id = "MSearchField" value = "Search" accesskey = "S"
onfocus="searchBox.OnSearchFieldFocus(true)"
onblur="searchBox.OnSearchFieldFocus(false)"
onkeyup="searchBox.OnSearchFieldChange(event)"/>
< / span > < span class = "right" >
< a id = "MSearchClose" href = "javascript:searchBox.CloseResultsWindow()" > < img id = "MSearchCloseImg" border = "0" src = "search/close.png" alt = "" / > < / a >
< / span >
< / div >
< / li >
< / ul >
< / div >
< div id = "navrow2" class = "tabs2" >
< ul class = "tablist" >
< li > < a href = "annotated.html" > < span > Class  List< / span > < / a > < / li >
< li > < a href = "classes.html" > < span > Class  Index< / span > < / a > < / li >
< li > < a href = "hierarchy.html" > < span > Class  Hierarchy< / span > < / a > < / li >
< li > < a href = "functions.html" > < span > Class  Members< / span > < / a > < / li >
< / ul >
< / div >
<!-- window showing the filter options -->
< div id = "MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
< a class = "SelectItem" href = "javascript:void(0)" onclick = "searchBox.OnSelectItem(0)" > < span class = "SelectionMark" >   < / span > All< / a > < a class = "SelectItem" href = "javascript:void(0)" onclick = "searchBox.OnSelectItem(1)" > < span class = "SelectionMark" >   < / span > Classes< / a > < a class = "SelectItem" href = "javascript:void(0)" onclick = "searchBox.OnSelectItem(2)" > < span class = "SelectionMark" >   < / span > Namespaces< / a > < a class = "SelectItem" href = "javascript:void(0)" onclick = "searchBox.OnSelectItem(3)" > < span class = "SelectionMark" >   < / span > Functions< / a > < a class = "SelectItem" href = "javascript:void(0)" onclick = "searchBox.OnSelectItem(4)" > < span class = "SelectionMark" >   < / span > Variables< / a > < a class = "SelectItem" href = "javascript:void(0)" onclick = "searchBox.OnSelectItem(5)" > < span class = "SelectionMark" >   < / span > Typedefs< / a > < a class = "SelectItem" href = "javascript:void(0)" onclick = "searchBox.OnSelectItem(6)" > < span class = "SelectionMark" >   < / span > Enumerations< / a > < a class = "SelectItem" href = "javascript:void(0)" onclick = "searchBox.OnSelectItem(7)" > < span class = "SelectionMark" >   < / span > Enumerator< / a > < a class = "SelectItem" href = "javascript:void(0)" onclick = "searchBox.OnSelectItem(8)" > < span class = "SelectionMark" >   < / span > Friends< / a > < / div >
<!-- iframe showing the search results (closed by default) -->
< div id = "MSearchResultsWindow" >
< iframe src = "javascript:void(0)" frameborder = "0"
name="MSearchResults" id="MSearchResults">
< / iframe >
< / div >
< div id = "nav-path" class = "navpath" >
< ul >
< li class = "navelem" > < a class = "el" href = "namespacefaiss.html" > faiss< / a > < / li > < li class = "navelem" > < a class = "el" href = "structfaiss_1_1ReconstructFromNeighbors.html" > ReconstructFromNeighbors< / a > < / li > < / ul >
< / div >
< / div > <!-- top -->
< div class = "header" >
< div class = "summary" >
< a href = "#pub-types" > Public Types< / a > |
< a href = "#pub-methods" > Public Member Functions< / a > |
< a href = "#pub-attribs" > Public Attributes< / a > |
< a href = "structfaiss_1_1ReconstructFromNeighbors-members.html" > List of all members< / a > < / div >
< div class = "headertitle" >
< div class = "title" > faiss::ReconstructFromNeighbors Struct Reference< / div > < / div >
< / div > <!-- header -->
< div class = "contents" >
< table class = "memberdecls" >
< tr class = "heading" > < td colspan = "2" > < h2 class = "groupheader" > < a name = "pub-types" > < / a >
Public Types< / h2 > < / td > < / tr >
< tr class = "memitem:a67dc908b2ace7c07b20075059b4bb454" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a67dc908b2ace7c07b20075059b4bb454" > < / a >
typedef < a class = "el" href = "structfaiss_1_1Index.html#a040c6aed1f224f3ea7bf58eebc0c31a4" > Index::idx_t< / a >   < / td > < td class = "memItemRight" valign = "bottom" > < b > idx_t< / b > < / td > < / tr >
< tr class = "separator:a67dc908b2ace7c07b20075059b4bb454" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a799355a749bf0e6632e7d2deeb0e7a0f" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a799355a749bf0e6632e7d2deeb0e7a0f" > < / a >
typedef < a class = "el" href = "structfaiss_1_1HNSW.html#ae1342fc2f07c325598a73b733e88ee74" > HNSW::storage_idx_t< / a >   < / td > < td class = "memItemRight" valign = "bottom" > < b > storage_idx_t< / b > < / td > < / tr >
< tr class = "separator:a799355a749bf0e6632e7d2deeb0e7a0f" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< / table > < table class = "memberdecls" >
< tr class = "heading" > < td colspan = "2" > < h2 class = "groupheader" > < a name = "pub-methods" > < / a >
Public Member Functions< / h2 > < / td > < / tr >
< tr class = "memitem:a8c02da3c304ddf56e8bc4e51bebc07ad" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a8c02da3c304ddf56e8bc4e51bebc07ad" > < / a >
  < / td > < td class = "memItemRight" valign = "bottom" > < b > ReconstructFromNeighbors< / b > (const < a class = "el" href = "structfaiss_1_1IndexHNSW.html" > IndexHNSW< / a > & index, size_t k=256, size_t nsq=1)< / td > < / tr >
< tr class = "separator:a8c02da3c304ddf56e8bc4e51bebc07ad" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a454b7a5f7437a257df7404f5778fc833" > < td class = "memItemLeft" align = "right" valign = "top" > void  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "structfaiss_1_1ReconstructFromNeighbors.html#a454b7a5f7437a257df7404f5778fc833" > add_codes< / a > (size_t n, const float *x)< / td > < / tr >
< tr class = "separator:a454b7a5f7437a257df7404f5778fc833" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:af20345ba564f892f51427a4a69facd73" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "af20345ba564f892f51427a4a69facd73" > < / a >
size_t  < / td > < td class = "memItemRight" valign = "bottom" > < b > compute_distances< / b > (size_t n, const idx_t *shortlist, const float *query, float *distances) const < / td > < / tr >
< tr class = "separator:af20345ba564f892f51427a4a69facd73" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a88ca99742dccc52ebb3324b507b6c872" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a88ca99742dccc52ebb3324b507b6c872" > < / a >
void  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "structfaiss_1_1ReconstructFromNeighbors.html#a88ca99742dccc52ebb3324b507b6c872" > estimate_code< / a > (const float *x, storage_idx_t i, uint8_t *code) const < / td > < / tr >
< tr class = "memdesc:a88ca99742dccc52ebb3324b507b6c872" > < td class = "mdescLeft" >   < / td > < td class = "mdescRight" > called by add_codes < br / > < / td > < / tr >
< tr class = "separator:a88ca99742dccc52ebb3324b507b6c872" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a6cf260c530e273e4d676804ac71128f8" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a6cf260c530e273e4d676804ac71128f8" > < / a >
void  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "structfaiss_1_1ReconstructFromNeighbors.html#a6cf260c530e273e4d676804ac71128f8" > reconstruct< / a > (storage_idx_t i, float *x, float *tmp) const < / td > < / tr >
< tr class = "memdesc:a6cf260c530e273e4d676804ac71128f8" > < td class = "mdescLeft" >   < / td > < td class = "mdescRight" > called by compute_distances < br / > < / td > < / tr >
< tr class = "separator:a6cf260c530e273e4d676804ac71128f8" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a2a33927952e85862e232292e6ea06d52" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a2a33927952e85862e232292e6ea06d52" > < / a >
void  < / td > < td class = "memItemRight" valign = "bottom" > < b > reconstruct_n< / b > (storage_idx_t n0, storage_idx_t ni, float *x) const < / td > < / tr >
< tr class = "separator:a2a33927952e85862e232292e6ea06d52" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:aed256bdd9f48dc93cb9e33cfdfd5bde7" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "aed256bdd9f48dc93cb9e33cfdfd5bde7" > < / a >
void  < / td > < td class = "memItemRight" valign = "bottom" > < a class = "el" href = "structfaiss_1_1ReconstructFromNeighbors.html#aed256bdd9f48dc93cb9e33cfdfd5bde7" > get_neighbor_table< / a > (storage_idx_t i, float *out) const < / td > < / tr >
< tr class = "memdesc:aed256bdd9f48dc93cb9e33cfdfd5bde7" > < td class = "mdescLeft" >   < / td > < td class = "mdescRight" > get the M+1 -by-d table for neighbor coordinates for vector i < br / > < / td > < / tr >
< tr class = "separator:aed256bdd9f48dc93cb9e33cfdfd5bde7" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< / table > < table class = "memberdecls" >
< tr class = "heading" > < td colspan = "2" > < h2 class = "groupheader" > < a name = "pub-attribs" > < / a >
Public Attributes< / h2 > < / td > < / tr >
< tr class = "memitem:a14034b43a0743e94ff70fab84fb7a66e" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a14034b43a0743e94ff70fab84fb7a66e" > < / a >
const < a class = "el" href = "structfaiss_1_1IndexHNSW.html" > IndexHNSW< / a > &   < / td > < td class = "memItemRight" valign = "bottom" > < b > index< / b > < / td > < / tr >
< tr class = "separator:a14034b43a0743e94ff70fab84fb7a66e" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:aa5a61e87d73f40064dd83c22ab94c3cc" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "aa5a61e87d73f40064dd83c22ab94c3cc" > < / a >
size_t  < / td > < td class = "memItemRight" valign = "bottom" > < b > M< / b > < / td > < / tr >
< tr class = "separator:aa5a61e87d73f40064dd83c22ab94c3cc" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a6a2ce9a449053820ce88aff51139805c" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a6a2ce9a449053820ce88aff51139805c" > < / a >
size_t  < / td > < td class = "memItemRight" valign = "bottom" > < b > k< / b > < / td > < / tr >
< tr class = "separator:a6a2ce9a449053820ce88aff51139805c" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a9d469402cdcfdfcf45b56e8406259d8b" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a9d469402cdcfdfcf45b56e8406259d8b" > < / a >
size_t  < / td > < td class = "memItemRight" valign = "bottom" > < b > nsq< / b > < / td > < / tr >
< tr class = "separator:a9d469402cdcfdfcf45b56e8406259d8b" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:aeae1c3969821123277b203a185362a4a" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "aeae1c3969821123277b203a185362a4a" > < / a >
size_t  < / td > < td class = "memItemRight" valign = "bottom" > < b > code_size< / b > < / td > < / tr >
< tr class = "separator:aeae1c3969821123277b203a185362a4a" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a6e5003517c06696a00f3e5c6b4bc18f1" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a6e5003517c06696a00f3e5c6b4bc18f1" > < / a >
int  < / td > < td class = "memItemRight" valign = "bottom" > < b > k_reorder< / b > < / td > < / tr >
< tr class = "separator:a6e5003517c06696a00f3e5c6b4bc18f1" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:ad7302ca13df0e8df9860ff649277c037" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "ad7302ca13df0e8df9860ff649277c037" > < / a >
std::vector< float >   < / td > < td class = "memItemRight" valign = "bottom" > < b > codebook< / b > < / td > < / tr >
< tr class = "separator:ad7302ca13df0e8df9860ff649277c037" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:af9cf27d32e77ed1768ec3de7485e56ee" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "af9cf27d32e77ed1768ec3de7485e56ee" > < / a >
std::vector< uint8_t >   < / td > < td class = "memItemRight" valign = "bottom" > < b > codes< / b > < / td > < / tr >
< tr class = "separator:af9cf27d32e77ed1768ec3de7485e56ee" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a4ed30d9a18a0d68c84a14ded6b91eba3" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a4ed30d9a18a0d68c84a14ded6b91eba3" > < / a >
size_t  < / td > < td class = "memItemRight" valign = "bottom" > < b > ntotal< / b > < / td > < / tr >
< tr class = "separator:a4ed30d9a18a0d68c84a14ded6b91eba3" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:aef8405a7dd11023f29f9a759ca900e5d" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "aef8405a7dd11023f29f9a759ca900e5d" > < / a >
size_t  < / td > < td class = "memItemRight" valign = "bottom" > < b > d< / b > < / td > < / tr >
< tr class = "separator:aef8405a7dd11023f29f9a759ca900e5d" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< tr class = "memitem:a108b1d722af230240f7092b3fc371a12" > < td class = "memItemLeft" align = "right" valign = "top" > < a class = "anchor" id = "a108b1d722af230240f7092b3fc371a12" > < / a >
size_t  < / td > < td class = "memItemRight" valign = "bottom" > < b > dsub< / b > < / td > < / tr >
< tr class = "separator:a108b1d722af230240f7092b3fc371a12" > < td class = "memSeparator" colspan = "2" >   < / td > < / tr >
< / table >
< a name = "details" id = "details" > < / a > < h2 class = "groupheader" > Detailed Description< / h2 >
< div class = "textblock" >
2018-12-19 17:48:35 +01:00
< p > Definition at line < a class = "el" href = "IndexHNSW_8h_source.html#l00026" > 26< / a > of file < a class = "el" href = "IndexHNSW_8h_source.html" > IndexHNSW.h< / a > .< / p >
2018-01-09 06:44:43 -08:00
< / div > < h2 class = "groupheader" > Member Function Documentation< / h2 >
< a class = "anchor" id = "a454b7a5f7437a257df7404f5778fc833" > < / a >
< div class = "memitem" >
< div class = "memproto" >
< table class = "memname" >
< tr >
< td class = "memname" > void faiss::ReconstructFromNeighbors::add_codes < / td >
< td > (< / td >
< td class = "paramtype" > size_t  < / td >
< td class = "paramname" > < em > n< / em > , < / td >
< / tr >
< tr >
< td class = "paramkey" > < / td >
< td > < / td >
< td class = "paramtype" > const float *  < / td >
< td class = "paramname" > < em > x< / em >   < / td >
< / tr >
< tr >
< td > < / td >
< td > )< / td >
< td > < / td > < td > < / td >
< / tr >
< / table >
< / div > < div class = "memdoc" >
< p > codes must be added in the correct order and the < a class = "el" href = "structfaiss_1_1IndexHNSW.html" > IndexHNSW< / a > must be populated and sorted < / p >
2018-12-19 17:48:35 +01:00
< p > Definition at line < a class = "el" href = "IndexHNSW_8cpp_source.html#l00807" > 807< / a > of file < a class = "el" href = "IndexHNSW_8cpp_source.html" > IndexHNSW.cpp< / a > .< / p >
2018-01-09 06:44:43 -08:00
< / div >
< / div >
< hr / > The documentation for this struct was generated from the following files:< ul >
2018-12-19 17:48:35 +01:00
< li > /tmp/faiss/< a class = "el" href = "IndexHNSW_8h_source.html" > IndexHNSW.h< / a > < / li >
< li > /tmp/faiss/< a class = "el" href = "IndexHNSW_8cpp_source.html" > IndexHNSW.cpp< / a > < / li >
2018-01-09 06:44:43 -08:00
< / ul >
< / div > <!-- contents -->
<!-- start footer part -->
< hr class = "footer" / > < address class = "footer" > < small >
Generated by   < a href = "http://www.doxygen.org/index.html" >
< img class = "footer" src = "doxygen.png" alt = "doxygen" / >
< / a > 1.8.5
< / small > < / address >
< / body >
< / html >