CombinedStructure 関数

警告

このドキュメントでは、モダン QDK に置き換えられたクラシック QDK を参照しています。

モダン QDK の API ドキュメントについては、こちらをご覧 https://aka.ms/qdk.api ください。

名前空間: Microsoft.Quantum.MachineLearning

パッケージ: Microsoft.Quantum.MachineLearning

制御された回転の 1 つ以上のレイヤーを指定すると、個別のレイヤーが個別のモデル パラメーターによってパラメーター化されるように、モデル パラメーター インデックスがシフトされた単一レイヤーが返されます。

function CombinedStructure (layers : Microsoft.Quantum.MachineLearning.ControlledRotation[][]) : Microsoft.Quantum.MachineLearning.ControlledRotation[]

入力

layers : ControlledRotation[][]

結合するレイヤー。

出力: ControlledRotation[]

他のすべてのレイヤーの連結を表す、制御された回転の単一レイヤー。

以下は同等です。

let structure = CombinedStructure([
    LocalRotationLayer(2, PauliY),
    CyclicEntanglingLayer(3, PauliX, 2)
]);
let structure = [
    ControlledRotation((0, new Int[0]), PauliY, 0),
    ControlledRotation((1, new Int[0]), PauliY, 1),
    ControlledRotation((0, [2]), PauliX, 2),
    ControlledRotation((1, [0]), PauliX, 3),
    ControlledRotation((2, [1]), PauliX, 4)
];