keras_utils#

Functions

call_accepts_kwarg(call, key)

Return whether a callable accepts a keyword argument.

inverse_shifted_softplus(x[, shift, beta, ...])

Inverse of the shifted softplus function.

inverse_softplus(x[, beta, threshold])

Numerically stabilized inverse softplus function.

logits_relative_to_target(logits, targets)

Express logits relative to the target model m = argmax(targets).

multinomial_allocation(weights, num_samples)

Allocate num_samples draws across weights via multinomial sampling.

resolve_seed(seed, seed_generator)

Resolve a user-provided seed against an instance's own seed generator.

shifted_softplus(x[, shift])

Shifted version of the softplus function such that shifted_softplus(0) = 1