PhotonRecycling
Photon recycling uses the measured events in which one or two photons were lost to estimate the ideal-photon-number output distribution. The method was introduced in Mills and Mezher [53].
Automatic use with a Computer
Add PhotonRecycling to the computer’s mitigation list:
>>> import perceval as pcvl
>>>
>>> computer.mitigations = [pcvl.PhotonRecycling()]
The mitigation automatically requests the lower-photon events required by the algorithm and returns the corrected distribution through the normal execution result.
Photon recycling is not part of any MitigationFactory preset. It can be enabled explicitly:
>>> factory = pcvl.MitigationFactory(pcvl.MitigationLevel.medium)
>>> factory.set_photon_recycling()
>>> computer.mitigations = factory.build()
Practical considerations
The experiment must be unitary and have a fixed input photon count of at least three.
The technique estimates a probability distribution, and does not need prior characterization of the computer.
- class perceval.runtime.error_mitigation.photon_recycling.PhotonRecycling
Mitigate photon loss by applying photon recycling to computation results.
The automatic layer applies only to compatible unitary experiments with a photon count of at least 3.
- extend_computation(computation, imperfections)
- Parameters:
computation (
Computation) – The computation asked by the upper layerimperfections (
Imperfections) – The Computer imperfections
- Return type:
list[Computation]- Returns:
a list of all computations to execute to apply the mitigation
Applying photon recycling directly
The standalone photon_recycling() function can correct an existing BSCount or
BSDistribution when its ideal photon count is known:
>>> mitigated_distribution = pcvl.photon_recycling(
... noisy_distribution,
... ideal_photon_count=4,
... )
The input must contain both three-photon and two-photon events for an ideal count of four. Passing a lossless distribution, an incompatible result type, or insufficient loss statistics raises an error.
- perceval.runtime.error_mitigation.photon_recycling.photon_recycling(noisy_input, ideal_photon_count)
A classical technique to mitigate errors in the output distribution caused by photon loss in LO quantum circuits (ref: https://arxiv.org/abs/2405.02278)
The input must contain events with one and two fewer photons than the ideal photon count.
- Parameters:
noisy_input (
BSCount|BSDistribution) – Noisy output counts or probability distribution.ideal_photon_count (
int) – Expected photon count for a lossless system.
- Return type:
BSDistribution- Returns:
Photon-loss-mitigated probability distribution.