Hybrid quantum-classical adversarial generator
A method for training an adversarial generator from a data set and a classifier includes: (A) training a classical noise generator whose input includes an output of a quantum generator, the classical noise generator having a first set of parameters, the training comprising: sampling from the data set to produce a first sample and a first corresponding label for the first sample; producing an output of the classical noise generator based on the output of the quantum generator and the first sample; producing a noisy example based on the output of the classical noise generator and the first sample; providing the noisy example to the classifier to produce a second corresponding label for the first sample; updating the first set of parameters such that the first corresponding label of the first sample differs from the second corresponding label of the first sample.
1. A method for training an adversarial generator from a data set and a classifier, the method comprising:
(A) training a classical noise generator whose input includes an output of a quantum generator, the classical noise generator having a first set of parameters, the training comprising:
(A) (1) sampling from the data set to produce a first sample {right arrow over (x)} and a first corresponding label for the first sample {right arrow over (x)},
(A) (2) producing an output {right arrow over (n)} of the classical noise generator based on the output of the quantum generator and the first sample,
(A) (3) producing a noisy example {right arrow over (x)}+{right arrow over (n)}, comprising adding the output {right arrow over (n)} of the classical noise generator to the first sample {right arrow over (x)},
(A) (4) providing the noisy example {right arrow over (x)}+{right arrow over (n)} to the classifier to produce a second corresponding label for the first sample {right arrow over (x)},
(A) (5) updating the first set of parameters such that the first corresponding label of the first sample {right arrow over (x)} differs from the second corresponding label of the first sample {right arrow over (x)}.
2. The method of claim 1 , further comprising:
(B) before (A), training an initial sample generator on a hybrid quantum-classical computer to produce the output of the quantum generator, the initial sample generator having a second set of parameters, the hybrid quantum-classical computer including a classical computer and a quantum computer, the quantum computer including the initial sample generator, the training comprising:
(B) (1) sampling, on the classical computer, from the classifier to produce a second sample;
(B) (2) updating, on the quantum computer, the second set of parameters based on the second sample to produce the quantum generator.
3. The method of claim 2 , further comprising:
(C) after (B) and before (A), sampling from the quantum generator to produce the output of the quantum generator.
4. The method of claim 2 , wherein the initial sample generator comprises a quantum Boltzmann machine.
5. The method of claim 1 , wherein the data set comprises a collection of images.
6. A system for training an adversarial generator from a data set and a classifier, the system comprising at least one non-transitory computer-readable medium having computer program instructions stored thereon, the computer program instructions being executable by at least one computer processor to perform a method, the method comprising:
(A) training a classical noise generator whose input includes an output of a quantum generator, the classical noise generator having a first set of parameters, the training comprising:
(A) (1) sampling from the data set to produce a first sample {right arrow over (x)} and a first corresponding label for the first sample {right arrow over (x)},
(A) (2) producing an output {right arrow over (n)} of the classical noise generator based on the output of the quantum generator and the first sample,
(A) (3) producing a noisy example {right arrow over (x)}+{right arrow over (n)}, comprising adding the output {right arrow over (n)} of the classical noise generator to the first sample {right arrow over (x)},
(A) (4) providing the noisy example {right arrow over (x)}+{right arrow over (n)} to the classifier to produce a second corresponding label for the first sample {right arrow over (x)},
(A) (5) updating the first set of parameters such that the first corresponding label of the first sample {right arrow over (x)}differs from the second corresponding label of the first sample {right arrow over (x)}.
7. The system of claim 6 , further comprising a classical computer and a quantum computer, the classical computer including the at least one computer processor and the at least one non-transitory computer-readable medium, the method further comprising:
(B) before (A), training an initial sample generator on a hybrid quantum-classical computer to produce the output of the quantum generator, the initial sample generator having a second set of parameters, the hybrid quantum-classical computer including a classical computer and a quantum computer, the quantum computer including the initial sample generator, the training comprising:
(B) (1) sampling, on the classical computer, from the classifier to produce a second sample;
(B) (2) updating, on the quantum computer, the second set of parameters based on the second sample to produce the quantum generator.
8. The system of claim 7 , wherein the method further comprises:
(C) after (B) and before (A), sampling from the quantum generator to produce the output of the quantum generator.
9. The system of claim 7 , wherein the initial sample generator comprises a quantum Boltzmann machine.
10. The system of claim 6 , wherein the data set comprises a collection of images.