Chalkboard - v3.0.4
    Preparing search index...

    Function fill

    • Initializes a tensor filled with one number.

      Parameters

      • element: number

        The number to fill the elements with

      • ...size: number[]

        The size

      Returns ChalkboardTensor

      const result = Chalkboard.tens.fill(1, 2, 2, 2); // Returns a 2-by-2-by-2 tensor of ones