From 16ad525d938e86a58036034952765766755edd00 Mon Sep 17 00:00:00 2001 From: Jian Sun Date: Thu, 19 Sep 2024 15:54:00 -0600 Subject: [PATCH] Misc updates (#665) * add back the getnumberofreactions function * update cuda thread count to 512 --- include/micm/cuda/util/cuda_param.hpp | 2 +- include/micm/solver/solver.hpp | 5 +++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/include/micm/cuda/util/cuda_param.hpp b/include/micm/cuda/util/cuda_param.hpp index f33fb78fd..d415a3fa2 100644 --- a/include/micm/cuda/util/cuda_param.hpp +++ b/include/micm/cuda/util/cuda_param.hpp @@ -7,7 +7,7 @@ // To make the NormalizedError function works properly on GPU, // make sure to choose the BLOCK_SIZE from [32, 64, 128, 256, 512, 1024] -const std::size_t BLOCK_SIZE = 32; +const std::size_t BLOCK_SIZE = 512; /// This struct holds the (1) pointer to, and (2) size of /// each constatnt data member from the class "ProcessSet"; diff --git a/include/micm/solver/solver.hpp b/include/micm/solver/solver.hpp index 8d7dc2df1..f8fc816d0 100644 --- a/include/micm/solver/solver.hpp +++ b/include/micm/solver/solver.hpp @@ -77,6 +77,11 @@ namespace micm return state_parameters_.number_of_species_; } + std::size_t GetNumberOfReactions() const + { + return state_parameters_.number_of_rate_constants_; + } + StatePolicy GetState() const { auto state = std::move(StatePolicy(state_parameters_));