Skip to content

Commit

Permalink
Explicit error message for deprecated function (cf stan-dev/stanc3#1470
Browse files Browse the repository at this point in the history
…).
  • Loading branch information
tillahoffmann committed Dec 11, 2024
1 parent 29219ac commit 9b93c08
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions stan/gptools/stan/gptools/fft1.stan
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,9 @@ real gp_rfft_log_abs_det_jac(vector cov_rfft, int n) {
return - sum(log(rfft_scale[1:n %/% 2 + 1])) -sum(log(rfft_scale[2:(n + 1) %/% 2]))
- log(2) * ((n - 1) %/% 2) + n * log(n) / 2;
}
real gp_rfft_log_abs_det_jacobian(vector cov_rfft, int n) {
reject("`gp_rfft_log_abs_det_jacobian` has been renamed to `gp_rfft_log_abs_det_jac` to comply with upcoming changes (see https://github.com/stan-dev/stanc3/issues/1470 for details).");
}


/**
Expand Down
3 changes: 3 additions & 0 deletions stan/gptools/stan/gptools/fft2.stan
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,9 @@ real gp_rfft2_log_abs_det_jac(matrix cov_rfft2, int width) {
ladj += - log2() * nterms + n * log(n) / 2;
return ladj;
}
real gp_rfft2_log_abs_det_jacobian(matrix cov_rfft2, int width) {
reject("`gp_rfft2_log_abs_det_jacobian` has been renamed to `gp_rfft2_log_abs_det_jac` to comply with upcoming changes (see https://github.com/stan-dev/stanc3/issues/1470 for details).");
}


/**
Expand Down

0 comments on commit 9b93c08

Please sign in to comment.