hybridlane.devices.default_hybrid.sampled¶
Functions¶
|
|
|
|
|
|
|
Sample basis states from the given state |
Module Contents¶
- hybridlane.devices.default_hybrid.sampled.measure_with_shots(measurements, state, shots, is_state_batched, rng=None, prng_key=None, wire_map=None, mid_measurements=None)[source]¶
- hybridlane.devices.default_hybrid.sampled.measure_with_diagonalizing_gates(mp, state, shots, is_state_batched, rng=None, prng_key=None, wire_map=None)[source]¶
- Parameters:
mp (SampleMeasurement)
state (pennylane.typing.TensorLike)
shots (Shots)
is_state_batched (bool)
rng (Any | None)
prng_key (Array | None)
wire_map (dict | None)
- Return type:
list[pennylane.typing.TensorLike]
- hybridlane.devices.default_hybrid.sampled.measure_hamiltonian(mp, state, shots, is_state_batched, rng=None, prng_key=None, wire_map=None)[source]¶
- Parameters:
mp (ExpectationMP)
state (pennylane.typing.TensorLike)
shots (Shots)
is_state_batched (bool)
rng (Any | None)
prng_key (Array | None)
wire_map (dict | None)
- Return type:
list[pennylane.typing.TensorLike]
- hybridlane.devices.default_hybrid.sampled.sample_state(state, shots, is_state_batched, wires=None, rng=None, prng_key=None)[source]¶
Sample basis states from the given state
This returns an array of shape (B, shots, num_wires) if the state is batched, or (shots, num_wires) if the state is not batched.