Skip to content

Commit

Permalink
Improve naming due to codemod (#4064)
Browse files Browse the repository at this point in the history
Summary:
Pull Request resolved: #4064

Apply matthijs' comments on better naming in D52582914

Reviewed By: junjieqi

Differential Revision: D66822957

fbshipit-source-id: d899dbe89ebd716a18901c734c65dac428856954
  • Loading branch information
mengdilin authored and junjieqi committed Dec 6, 2024
1 parent e0ce433 commit 92d6e3c
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions faiss/IndexFastScan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,22 +33,22 @@ inline size_t roundup(size_t a, size_t b) {

void IndexFastScan::init_fastscan(
int d,
size_t M_2,
size_t nbits_2,
size_t M_init,
size_t nbits_init,
MetricType metric,
int bbs) {
FAISS_THROW_IF_NOT(nbits_2 == 4);
FAISS_THROW_IF_NOT(nbits_init == 4);
FAISS_THROW_IF_NOT(bbs % 32 == 0);
this->d = d;
this->M = M_2;
this->nbits = nbits_2;
this->M = M_init;
this->nbits = nbits_init;
this->metric_type = metric;
this->bbs = bbs;
ksub = (1 << nbits_2);
ksub = (1 << nbits_init);

code_size = (M_2 * nbits_2 + 7) / 8;
code_size = (M_init * nbits_init + 7) / 8;
ntotal = ntotal2 = 0;
M2 = roundup(M_2, 2);
M2 = roundup(M_init, 2);
is_trained = false;
}

Expand Down

0 comments on commit 92d6e3c

Please sign in to comment.