Skip to content

Releases: stan-dev/math

v4.3.2 (25 March 2022)

25 Mar 08:20
Compare
Choose a tag to compare
  • Fixed template error for fma with matrix inputs.
  • Fixed bug that did not allow for var<Matrix> types with different compile-time rows/cols to be assigned to one another.

v4.3.1 (2 March 2022)

02 Mar 13:45
Compare
Choose a tag to compare
  • Fixed a bug with to_matrix(row_vector) and to_matrix(vector) that cause compile-time issues when the result was not stored in a temporary variable.

v4.3.0 (14 February 2022)

14 Feb 14:37
Compare
Choose a tag to compare
  • Changed constants to static constexpr for efficiency, added Euler's Gamma constant. (#2478)
  • Added lmultiply function that parallels multiply_log so that the language doesn't have to rename. (#2596)
  • Cleaned up tests to include <CL/opencl.hpp> instead of <CL/cl2.hpp>. (#2610)
  • Added missing implementations of that shadow the signatures of math functions in the std:: namespace. (#2612)
  • Bugfix for the bug where 2x2 matrix exponential function outputs NaN for matrices with large eigenvalues. (#2616)
  • Add compiler flag -D_BOOST_LGAMMA to allow users to force use of Boost lgamma implementation. (#2618)
  • More informative error messages for ODE solvers. (#2620)
  • Force linker to respect rpath set at compile time. (#2627)
  • Upgraded Sundials to 6.0.0. (#2629)
  • Added norm1() and norm2(). (#2636)
  • Add missing von_mises_cdf_log and von_mises_ccdf_log signatures. (#2640)
  • Refactored the DAE solver.(#2644)
  • Added the inverse of the complementary error function - inv_erfc(). (#2645)
  • Updated member functions for accessing tangents in scalar fvar types. (#2652)
  • Added support for the new matrix type for GLM functions. (#2655)

v4.3.0-rc1 (31 January 2022)

31 Jan 09:46
5fd79f8
Compare
Choose a tag to compare
Pre-release
Tagging v4.3.0-rc1

v4.2.1 (21 October 2021)

21 Oct 11:12
Compare
Choose a tag to compare
  • Fixed issues with Adjoint ODE memory management
  • Fixed included OpenCL headers

v4.2.0 (5 October 2021)

05 Oct 14:07
Compare
Choose a tag to compare

Miscellaneous:

  • Updated Powell and Newton solvers to use an adjoint method to propagate derivatives in reverse mode which should result in modest speed-up. Added variadic interfaces (algebra_solver_powell_impl and algebra_solver_newton_impl). (#2421)
  • Cleanup unused local typedefs. (#2505)
  • Fix tbb initialization so that if STAN_THREADS is not defined then the number of threads is set to 1. (#2514)
  • Bugfix for range checks not overriding STAN_THREADS. (#2530)
  • Bugfix for vectorized log include order. (#2542)
  • Added vectorized checks called by the stanc compiler. (#2556)
  • Adds an overload for the constrain functions on whether to accumulate jacobians into log probability argument.(#2559)
  • Updated algorithm for inv_Phi which is approximately 2x faster with precision of 16 digits. Based on the Fortran algorithm described in Wichura, M. J. (1988) Algorithm AS 241: The percentage points of the normal distribution. Applied Statistics, 37, 477–484.(#2566)
  • Vectorized unconstrain and constraing functions. (#2574, #2580)
  • Fixed generalized inverse so that it works for less than full rank symmetric matrices. (#2577)

Varmat:

  • Added var<Matrix> overloads for append_row(), append_col(), rep_vector(), rep_row_vector(), to_vector(), divide(). (#2484, #2487, #2521, #2557)
  • Added nested vectorized functions for the new matrix type. (#2502)
  • Added support for basic slicing and dimension queries operators support var types. (#2507)
  • Added several unary functions for var<Matrix> as well as division.(#2527)
  • Allow accumulator to accept var<Matrix> matrix types(#2535)

Complex:

  • Unary vectorized functions support containers of complex numbers(#2549)
  • Added complex scalar functions get_real(), get_imag(), and to_complex.(#2554)

OpenCL:

  • Added prim-only OpenCL implementations for qr_Q, qr_R, qr_thin_Q, qr_thin_R. (#2479)
  • Fixed a bug for kernel generator operation block, eigenvalues_sym, eigenvectors_sym. (#2479, #2512)
  • Added OpenCL implementation for cumulative_sum. (#2483)
  • Fixed a bug that made OpenCL identity_matrix unusable. (#2499)
  • Added reverse mode for indexing.(#2511)
  • Fixed a number of bugs related to conversions of arena_matrix_cl into matrix_cl. Before this PR such a conversion invoked kernel generator and made a copy of data. Now only references to data are updated.(#2538)
  • Fixes kernel generator allocating more local memory than it needed.(#2541)
  • Added OpenCL implementation of sorting (sort_asc and sort_desc).(#2550)
  • Bugfix OpenCL kernels so that they can no longer modify a const matrix_cl.(#2553)

v4.2.0-rc1

27 Sep 14:34
Compare
Choose a tag to compare
v4.2.0-rc1 Pre-release
Pre-release
Tagging v4.2.0-rc1

v4.1.0 (2 June 2021)

02 Jun 18:50
Compare
Choose a tag to compare
  • Added the Cash-Karp numerical integrator to improve numerical integration of ODEs with semi-stiffness and/or rapid oscillations.(#2336)
  • Added the quantile function.(#2398)
  • Added custom reverse mode for diag_pre_multiply() and diag_post_multiply() functions.(#2405, #2453)
  • Optimized multi_normal_cholesky for non-autodiff covariance. (#2439)
  • Updated Sundials to 5.7.0.(#2441)
  • Improved memory safety of nested paralellism.(#2445)
  • Updated TBB to 2020.3.(#2447)
  • Added the STAN_NO_RANGE_CHECKS macro which turns off bounds and range checks.(#2423, #2437)
  • Optimized gp_*_cov functions, especially for large amount of data.(#2464)
  • Fixed compilation errors when using unsigned and long types with apply_scalar_unary.(#2469)
  • Added the implementation of the loglogistic probability density function.(#2477)
  • Adds reverse mode specialization for `csr_matrix_times_vector(sparse data, dense parameter).(#2462)
  • Allow tbb init to set the number of threads by an argument.(#2455)
  • Fixed a bug with expressions in poisson distribution functions.(#2414)
  • Fixed the off by one error in set_zero_all_adjoints_nested.(#2399)
  • Fixed bug with printing Eigen expressions.(#2436)
  • Refactored operands and partials to avoid extra allocations.(#2418)
  • Tidied up distributions C++ code.(#2352)
  • Updated the integrate_1d internal interface updated in preparation for closures(#2397)
  • Added docs for new contributors with a getting started guide and docs for contributing new distributions.(#2350, #2466)
  • Added an ODE testing framework.(#2432)
  • Replaced the finite difference approximation of the Hessian from one that is based on function calls to one that is based on gradients.(#2348)
  • Updated code generation for expression tests.(#2419)
  • Fixed a bug in expression tests and benchmark generation, where downloading stanc.exe did not work on Windows.(#2480)
  • Varmat:
    • Add rep_* utility functions for new matrix type(#2358)
    • var<Matrix> overloads for digamma, distance, Phi, inv_Phi, Phi_approx, sqrt, tail, tgamma, rows_dot_self, fma, offset_multiplier, bessel first and second kind, beta, binary log loss, ceil, erf, erfc, exp2, expm1, falling_factorial and floor (#2362, #2378, #2396, #2461)
    • Added lb/ub/lub_constrain specializations.(#2373, #2382, #2387, #2379)
    • Added script to automatically check stanc3 signatures for varmat compatibility.(#2434)
  • OpenCL:
    • Fixed OpenCL implementations of distributions mostly not working with row vectors.(#2360)
    • Added prim and rev OpenCL implementations for to_matrix, to_vector, to_row_vector, to_array_1d, to_array_2d, append_array, reverse, symmetrize_from_lower_tri, symmetrize_from_upper_tri trace.(#2377, #2383, #2388)
    • Added OpenCL functions rep_matrix, rep_vector, rep_row_vector, rep_array and identity_matrix.(#2388)
    • Added operator %.()
    • Reorganized how work is distributed between threads in generated kernels that use colwise reductions (including all distributions), significantly improving GPU preformance.(#2392)
    • Removed .triangularTranspose() member funtion from matrix_cl and TriangularMapCL enum. .triangularTranspose() is replaced by symmetrize_from_lower_tri().(#2393)
    • Added support for two dimensional reductions to kernel generator.(#2403)
    • Added OpenCL implementations for functions log_mix, log_softmax, log_sum_exp, rank, sd, softmax and ˙variance.(#2426)
    • Added OpenCL implementations for ub_constrain, lb_constrain, lub_constrain, offset_multiplier_constrain and unit_vector_constrain.(#2427)
    • Added OpenCL implementation for prod function and kernel generator operation for rowwise, colwise and 2d product.(#2433)
    • Added OpenCL implementations for functions: bernoulli_cdf, bernoulli_lcdf, bernoulli_lccdf, cauchy_cdf, cauchy_lcdf, cauchy_lccdf.(#2446)
    • Added OpenCL implementations for functions double_exponential_cdf, double exponential_lcd, double_exponential_lccdf˙, exp_mod_normal_cdf, exp_mod_normal_lcdf and exp_mod_normal_lccdf.(#2449)
    • Added OpenCL implementations for functions exponential_cdf, exponential_lcdf, exponential_lccdf, frechet_cdf, frechet_lcdf and frechet_lccdf.(#2450)
    • Added OpenCL implementations for functions gumbel_cdf, gumbel_lcdf, gumbel_lccdf, logistic_cdf, logistic_lcdf and logistic_lccdf.(#2451)
    • Added a new kernel generator operation that allows writing custom OpenCL code.(#2454)
    • Added OpenCL implementations for functions pareto_cdf, pareto_lccdf, pareto_lcdf, pareto_type_2_cdf, pareto_type_2_lccdf, and pareto_type_2_lcdf.(#2456)
    • Added OpenCL implementations for functions: rayleigh_cdf, rayleigh_lccdf, rayleigh_lcdf, skew_double_exponential_cdf, skew_double_exponential_lccdf, skew_double_exponential_lcdf and skew_double_exponential_lpdf.(#2457)
    • Added OpenCL implementations for functions lognormal_cdf, lognormal_lccdf, lognormal_lcdf, normal_cdf, normal_lccdf, normal_lcdf.(#2458)
    • Added OpenCL implementations for functions std_normal_cdf, std_normal_lccdf, std_normal_lcdf, uniform_cdf, uniform_lccdf and uniform_lcdf.(#2459)
    • Added OpenCL implementations for functions weibull_cdf, weibull_lccdf and weibull_lcdf.(#2460)
    • Removed unused OpenCL kernels and checks.(#2463)
    • Added OpenCL prim implementation for functions: gp_exponential_cov, gp_matern32_cov, matern_52_cov and both prim and rev implementation for gp_dot_prod_cov.(#2471)
    • Added reference (ref_type) for kernel generator expressions.(#2404)
    • Added typecast operation to kernel generator.(#2472)

v4.1.0-rc1 (19 May 2021)

19 May 16:01
Compare
Choose a tag to compare
Pre-release
Tagging v4.1.0-rc1

v4.0.1 (17 February 2021)

17 Feb 13:06
Compare
Choose a tag to compare
  • Fixed issue with cholesky_decompose not propagating derivatives correctly .
  • Fixed OpenCL implementations of distributions mostly not working with row vectors.
  • Fixed handling of input expressions with reduce_sum.