How To Start Experimenting With Quantum Image Processing

Qiskit
Qiskit
Published in
3 min readApr 2, 2021

By Robert Loredo and Mehdi Bozzo-Rey

Circuit implementing an FRQI state

Quantum computing is amid an exciting period of growth and exploration, where we’re trying to see what advantages this new computing paradigm might bring us. The two of us recently began experimenting with an exciting idea: encoding and manipulating images with quantum computers. We want to give you a chance to experiment in this space as well.

We’re excited to show off the result of our collaboration: a section on Quantum Image Processing in the Qiskit textbook. While we don’t expect quantum computers to revolutionize the image processing space any time soon, this is an interesting case study to help you understand what it takes to apply quantum computing to a new potential application.

Image processing represents an important use case in artificial intelligence — self driving cars, for example, rely on processing of images taken by a camera in order to navigate. Some early evidence points to a potential for speedups when using quantum computers for specific image processing tasks, such as edge detection, though obviously more work is needed.

Quantum image processing follows similar workflows to classical image processing. In classical image processing, we encode a representation of the image in various ways, such as encoding each pixel in the image based on the color intensity. Once encoded, we process the image — we can make any changes to the original using a variety of computations, such as cropping, filtering, enhancing, etc. Once completed, there are various post processing techniques we can leverage such as edge detection, object and pattern recognition, to name a few.

In the current release of the quantum image processing chapter, we first review the various ways to represent images, then focus on two forms which seem to represent the fundamental features of superposition and entanglement, Flexible Representation of Quantum Images (FRQI) and the Novel Enhanced Quantum Representation (NEQR). FRQI encodes the intensity value by rotating a single qubit to a specific angle, whereas NEQR uses a series of qubits to represent the intensity value which is set by a set of CNOT gates. Both have advantages and disadvantages which we discuss in the chapter, and there are many other algorithms which build off these two forms.

This chapter represents not only an exciting way to get started learning quantum image processing, but is quite personal to the two of us. During the ongoing pandemic, Robert replaced his typical activities like work travel, attending events, and hanging out with friends with online courses, drawing, and taking pictures — all of which piqued his interest in image processing. Mehdi, meanwhile, had long been interested in becoming an astronaut, but could not due to his need for corrective lenses. He eventually became a scientist, and realized he could whet his appetite for space by processing the free and publicly available images from the Hubble Space Telescope.

While we were both employed at IBM, the two of us began chatting about our joint interest in image processing, Robert about applying it to medical applications and Mehdi applying it to space images. Collaborating on a quantum image processing project like this was a natural fit, and that collaboration turned into this textbook chapter. Today, Mehdi works at Cambridge Quantum Computing, and this chapter represents an open source collaboration between CQC and IBM for all in the Qiskit community to take advantage of and improve.

So what’s next? Obviously, there is some necessary research, plus maturing at the code level to tackle larger images. However, our eyes are on the future; perhaps images from the upcoming Vera C. Rubin Observatory, could serve as a testbed for QIP (or maybe even an opportunity for an advantage — who knows!). We’re hopeful that this entry in the Qiskit textbook will lead to contributions from the extended Qiskit community that will help grow this field to eventually tackle some of these future problems.

Check out Robert and Mehdi’s section on QIP here.

--

--

Qiskit
Qiskit

An open source quantum computing framework for writing quantum experiments and applications