Automatic Differentiation
 
Loading...
Searching...
No Matches

◆ softmax() [1/5]

template<typename T , require_std_vector_st< is_fvar, T > * = nullptr>
auto stan::math::softmax ( T &&  x)
inline

Return the softmax of each vector in a container of fvar values.

Return the softmax of the specified vector or row vector.

Return the softmax of each vector in an array.

Template Parameters
Tstd::vector whose scalar type is fvar
Parameters
xcontainer of vectors to transform
Returns
container of softmax results
Template Parameters
Tstd::vector whose scalar type is arithmetic
Parameters
[in]xArray of vectors to transform.
Returns
Array of unit simplex results.
Template Parameters
Ta var_value or Eigen vector/row_vector with var scalar
Parameters
xinput
Returns
softmax of the input
Template Parameters
Tstd::vector whose scalar type is var
Parameters
xarray of vectors to transform
Returns
array of softmax results

Definition at line 22 of file softmax.hpp.