Skip to content

Commit 344b0cc

Browse files
authored
1.0.2b (#68)
* Further improvement to ULTRA's automatic window sizing * If built without release optimizations, ULTRA will now note that in -h.
1 parent 39f5421 commit 344b0cc

File tree

3 files changed

+20
-6
lines changed

3 files changed

+20
-6
lines changed

CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ if (NOT CMAKE_BUILD_TYPE OR CMAKE_BUILD_TYPE STREQUAL "")
1010
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "" FORCE)
1111
endif()
1212

13+
if(NOT CMAKE_BUILD_TYPE STREQUAL "Release")
14+
add_definitions(-DDEBUG_PRAGMA=1)
15+
endif()
1316

1417
set(CMAKE_CXX_STANDARD 11)
1518
set(CMAKE_CXX_STANDARD_REQUIRED ON)

src/cli.cpp

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ void Settings::prepare_settings() {
6363
->group("Output");
6464

6565
app.add_option("--max_consensus", this->max_consensus_period,
66-
"The maximum length of consensus pattern to include in output")
66+
"The maximum length of consensus pattern to include in output")
6767
->default_val(this->max_consensus_period)
6868
->group("Output");
6969

@@ -626,21 +626,25 @@ void Settings::assign_settings() {
626626

627627
// Small models use less than 160 mb per thread
628628
else if (period_memory <= 200000) {
629-
this->window_size = 400 * this->max_period;
629+
this->window_size = 1000 * this->max_period;
630630
}
631631

632632
// medium models use less than 1 GB per thread
633633
else if (period_memory <= 2000000) {
634-
this->window_size = 100 * this->max_period;
634+
this->window_size = 500 * this->max_period;
635635
}
636636

637637
// medium models use less than 1 GB per thread
638-
else if (period_memory <= 4000000) {
638+
else if (period_memory <= 20000000) {
639+
this->window_size = 100 * this->max_period;
640+
}
641+
642+
else if (period_memory <= 50000000) {
639643
this->window_size = 50 * this->max_period;
640644
}
641645

642646
// Large models use less than 4 GB per thread
643-
else {
647+
else {
644648
this->window_size = 25 * this->max_period;
645649
}
646650

src/cli.hpp

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,13 @@
55
#ifndef ULTRA_CLI_HPP
66
#define ULTRA_CLI_HPP
77

8-
#define ULTRA_VERSION_STRING "1.0.2"
8+
#define ULTRA_VERSION_STRING "1.0.2b"
9+
#define DEBUG_STRING ""
10+
#ifdef DEBUG_PRAGMA
11+
#undef DEBUG_STRING
12+
#define DEBUG_STRING " **WARNING** BUILT WITHOUT RELEASE OPTIMIZATION **WARNING** \n"
13+
#endif
14+
915

1016

1117
#include "../lib/CLI11.hpp"
@@ -109,6 +115,7 @@ struct Settings {
109115
"(U)ltra (L)ocates (T)andemly (R)epetitive (A)reas\n"
110116
" Daniel R. Olson and Travis J. Wheeler\n"
111117
" Version " ULTRA_VERSION_STRING "\n"
118+
DEBUG_STRING
112119
" Use '--cite' for citation instructions\n"
113120
"=================================================\n"};
114121

0 commit comments

Comments
 (0)