Sha256: a9167854336fa96c6010e01ba3505cdc57d1fbe9a1b05daa1d405ceaf169ad90
Contents?: true
Size: 456 Bytes
Versions: 58
Compression:
Stored size: 456 Bytes
Contents
module Torch module NN class CTCLoss < Loss def initialize(blank: 0, reduction: "mean", zero_infinity: false) super(reduction) @blank = blank @zero_infinity = zero_infinity end def forward(log_probs, targets, input_lengths, target_lengths) F.ctc_loss(log_probs, targets, input_lengths, target_lengths, blank: @blank, reduction: @reduction, zero_infinity: @zero_infinity) end end end end
Version data entries
58 entries across 58 versions & 1 rubygems