stan-dev / stanc3

The Stan transpiler (from Stan to C++ and beyond).
BSD 3-Clause "New" or "Revised" License
140 stars 44 forks source link

Vectorize abs, deprecate fabs #1195

Closed WardBrian closed 2 years ago

WardBrian commented 2 years ago

This closes #475. It won't be ready to merge until @bob-carpenter figures out some things on the C++ side (see https://github.com/stan-dev/math/issues/2729), but I'm opening it now so we can run tests against it.

Submission Checklist

Release notes

abs is now vectorized for container types. fabs is now deprecated, as all usages can be replaced with abs thanks to array promotion rules.

Copyright and Licensing

By submitting this pull request, the copyright holder is agreeing to license the submitted work under the BSD 3-clause license (https://opensource.org/licenses/BSD-3-Clause)

WardBrian commented 2 years ago

I'm now running this with https://github.com/stan-dev/math/pull/2734

WardBrian commented 2 years ago

This depends on https://github.com/stan-dev/math/pull/2741 but is otherwise ready for review