モジュール

  • レイヤーの入力タイプ。

    宣言

    associatedtype Input
  • レイヤーの出力タイプ。

    宣言

    associatedtype Output : Differentiable
  • 指定された入力にレイヤーを適用して得られた出力を返します。

    宣言

    @differentiable(wrt: self)
    func callAsFunction(_ input: Input) -> Output

    パラメーター

    input

    レイヤーへの入力。

    戻り値

    出力。

  • フォワード(_:)デフォルトの実装

    指定された入力にレイヤーを適用して得られた出力を返します。

    デフォルトの実装

    指定された入力にレイヤーを適用して得られた出力を返します。

    宣言

    @differentiable(wrt: self)
    func forward(_ input: Input) -> Output

    パラメーター

    input

    レイヤーへの入力。

    戻り値

    出力。

`Input`: `TensorProtocol`、`Output`: `DifferentiableTensorProtocol` で利用可能です。
  • callAsFunction(_:)デフォルトの実装

    デフォルトの実装

    指定された入力にレイヤーを適用することで得られる、注釈付きの出力を返します。

    宣言

    @differentiable(wrt: self)
    public func callAsFunction(_ input: Input) -> Output

    パラメーター

    input

    レイヤーへの入力。

    戻り値

    注釈付きの出力。

  • 注釈付き(_:)拡張方法

    outputに注釈を付けます。

    注: 注釈をサポートしていないバックエンドを使用している場合は、 outputが返されます。

    宣言

    @differentiable
    public func annotated(_ output: Output) -> Output

    パラメーター

    output

    レイヤーへの出力。

    戻り値

    注釈付きの出力。

  • 概要(入力:)拡張方法

    指定された入力にレイヤーを適用することで取得したアノテーションを返します。

    宣言

    public func summary(input: Input) -> String

    パラメーター

    input

    レイヤーへの入力。

    戻り値

    XLA グラフから収集されたすべての注釈。