A Quantum Binary Classifier based on Cosine Similarity
Davide Pastorello, Enrico Blanzieri · 2021
This proposal introduces the quantum implementation of a binary classifier based on cosine similarity between data vectors. The proposed quantum algorithm presents time complexity that is logarithmic in the product of the training set cardinality and the dimension of the vectors. It is based just on a suitable state preparation like the retrieval from a QRAM, a SWAP test circuit, and a measurement process on a single qubit. An implementation on an IBM quantum processor is presented.