Skip to content

Commit 0898eb9

Browse files
committed
Set split 1 at the start of Pref Index Reader so it writes correct meta
1 parent d9823e8 commit 0898eb9

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/prefiltering/PrefilteringIndexReader.cpp

+4-5
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,10 @@ void PrefilteringIndexReader::createIndexFile(const std::string &outDB,
5858
bool compBiasCorrection, int alphabetSize, int kmerSize, int maskMode,
5959
int maskLowerCase, float maskProb, int maskNrepeats, int kmerThr, int targetSearchMode, int splits,
6060
int indexSubset) {
61+
const bool noKmerIndex = (indexSubset & Parameters::INDEX_SUBSET_NO_PREFILTER) != 0;
62+
if (noKmerIndex) {
63+
splits = 1;
64+
}
6165

6266
const int SPLIT_META = splits > 1 ? 0 : 0;
6367
const int SPLIT_SEQS = splits > 1 ? 1 : 0;
@@ -190,11 +194,6 @@ void PrefilteringIndexReader::createIndexFile(const std::string &outDB,
190194
(Parameters::isEqualDbtype(seqType, Parameters::DBTYPE_NUCLEOTIDES) || Parameters::isEqualDbtype(seqType, Parameters::DBTYPE_AMINO_ACIDS))
191195
? alphabetSize -1: alphabetSize;
192196

193-
const bool noKmerIndex = (indexSubset & Parameters::INDEX_SUBSET_NO_PREFILTER) != 0;
194-
if (noKmerIndex) {
195-
splits = 1;
196-
}
197-
198197
ScoreMatrix s3;
199198
ScoreMatrix s2;
200199
if (Parameters::isEqualDbtype(seqType, Parameters::DBTYPE_HMM_PROFILE) == false && noKmerIndex == false) {

0 commit comments

Comments
 (0)