Module Differentiable.Vector

Functions operating on vectors.

val to_scalar : (Algebra.Vector.t, float) t
val cadd : float -> (Algebra.Vector.t, Algebra.Vector.t) t

Add a constant.

val cmul : float -> (Algebra.Vector.t, Algebra.Vector.t) t

Multiply by a constant.

Add two vectors.

Hadamrd product of two vectors.

val sum : (Algebra.Vector.t, float) t

Sum.

val dot : (Algebra.Vector.t * Algebra.Vector.t, float) t

Dot product.

val squared_norm : (Algebra.Vector.t, float) t

Squared norm of a vector.

val squared_distance_to : Algebra.Vector.t -> (Algebra.Vector.t, float) t

Squared distance to a fixed vector.

Softmax function.

val map : (float, float) t -> (Algebra.Vector.t, Algebra.Vector.t) t

Pointwise application of a differentiable function.

Pointwise sigmoid.

Pointwise hyperbolic tangent.

Pointwise rectified linear unit.

Pointwise log.