From c42f9f385858bc74beb0b52c9fabe56df0d8b4b5 Mon Sep 17 00:00:00 2001 From: Nathanael Bosch Date: Wed, 11 Oct 2023 13:21:47 +0200 Subject: [PATCH] Make `make_transition_matrices!` allocate less again --- src/priors/common.jl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/priors/common.jl b/src/priors/common.jl index 559ac3f75..46f4658a3 100644 --- a/src/priors/common.jl +++ b/src/priors/common.jl @@ -73,8 +73,8 @@ function make_transition_matrices!(cache, prior::AbstractODEFilterPrior, dt) _Ah, _Qh = discretize(cache.prior, dt) copy!(Ah, _Ah) copy!(Qh, _Qh) - A .= P * Ah * PI - @warn "`make_transition_matrices!` currently allocates more than it should!" + # A = P * Ah * PI + _matmul!(A, P, _matmul!(A, Ah, PI)) fast_X_A_Xt!(Q, Qh, P) end