lamp.data.bert

package lamp.data.bert

Members list

Value members

Concrete methods

def makeMaskForMaskedLanguageModel(bertTokens: Array[Int], maximumTokenId: Int, clsToken: Int, sepToken: Int, maskToken: Int, rng: Random): (Array[Int], Array[Int], Array[Int])
def minibatchesFromParagraphs(minibatchSize: Int, dropLast: Boolean, paragraphs: Vector[Vector[Array[Int]]], maximumTokenId: Int, clsToken: Int, sepToken: Int, padToken: Int, maskToken: Int, maxLength: Int, rng: Random): BatchStream[(BertLossInput, STen), Int, Unit]
def pad(v: Array[Int], paddedLength: Int, padElem: Int): Array[Int]
def prepareParagraph[S : Sc](paragraph: Vector[Array[Int]], maximumTokenId: Int, clsToken: Int, sepToken: Int, padToken: Int, maskToken: Int, maxLength: Int, rng: Random): Vector[(Boolean, STen, STen, STen, STen, Long)]