Quantum circuits for RGB images

I have a color image dataset. To represent these images through quantum circuit, how to send each RGB channels through a single quantum circuit? If I have 4 qubits, how to send these qubits through R-G-B channels?

I know how to do it in grayscale images as it has only single channel. If I have a quantum circuit:

n_qubits=4
q_depth=14

def quantum_circuit(noise, weights):

    weights = weights.reshape(q_depth, n_qubits)

    for i in range(n_qubits):
        qml.RY(noise[i], wires=i)

    for i in range(q_depth):
        for y in range(n_qubits):
            qml.RY(weights[i][y], wires=y)

        for y in range(n_qubits - 1):
            qml.CZ(wires=[y, y + 1])

    return qml.probs(wires=list(range(n_qubits)))

So I need 4 qubits in each three channels passing through the quantum circuit. Also the execution needs to be parallel. Any ideas, how to execute it?

Hi @mass_of_15,

I’m not sure about your code but one way of encoding RGB values onto a quantum circuit is by using qml.Rot(). Notice that it takes 3 angles so if you multiply each RGB value by 2pi/255 then you will be able to encode each RBG value in each pixel into a generalized rotation (Rot).

Please let me know if this is clear!