diff --git a/CMakeLists.txt b/CMakeLists.txt index 5ceb0b3..a52d7b8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.25) -project(COSC-4P80-Final-Project VERSION 0.0.19) +project(COSC-4P80-Final-Project VERSION 0.0.20) option(ENABLE_ADDRSAN "Enable the address sanitizer" OFF) option(ENABLE_UBSAN "Enable the ub sanitizer" OFF) diff --git a/src/MNIST.cpp b/src/MNIST.cpp index 1e30af2..cc82bb3 100644 --- a/src/MNIST.cpp +++ b/src/MNIST.cpp @@ -632,7 +632,7 @@ namespace fp } // user can skip this if required. - state << i - 1; + state << std::max(i - 1, 0); state << '\n'; state << last_epoch_save; state << '\n';