Giter Site home page Giter Site logo

Comments (8)

woodsp-ibm avatar woodsp-ibm commented on July 29, 2024

From the link this looks like a performance enhancement when using MPS simulator when all qubits are being measured. You can pass in an Aer simulator set for MPS mode and configure it accordingly. Having only just skimmed over the PR you linked what is it that you are proposing is changed here?

As far as the title is concerned Allow measuring subset of qubits - I got the impression from reading the linked PR that the change did not cater to that, but it might be possible to do later. Can you explain further...

from qiskit-machine-learning.

omarshehab avatar omarshehab commented on July 29, 2024

@woodsp-ibm , The QuantumKernel.evaluate() API currently measures all qubits so we cannot take advantage of measuring subset of qubits when we are using the MPS simulator.

from qiskit-machine-learning.

woodsp-ibm avatar woodsp-ibm commented on July 29, 2024

I guess I am confused - the PR you linked says this as a summary

Performance improvement for the case where all qubits are measured.

and later

It is possible to implement for cases where a subset of the qubits is measured, but this will require additional effort to decide when propagation is necessary and when not.

which I took to mean that it was not implemented at present anyway.

from qiskit-machine-learning.

omarshehab avatar omarshehab commented on July 29, 2024

@woodsp-ibm , it has been implemented and merged as shown below.

image

Unfortunately, QuantumKernel.evaluate(), while running on MPS simulator, cannot take advantage of this at this moment.

from qiskit-machine-learning.

adekusar-drl avatar adekusar-drl commented on July 29, 2024

@omarshehab Could you please write a bit detailed description? I don't fully understand what is suggested to do here.

from qiskit-machine-learning.

omarshehab avatar omarshehab commented on July 29, 2024

@adekusar-drl , measurement of only specific qubits is required for qiskit.aqua.algorithms.VQC(). When this API is run on MPS simulator, we want to make sure that MPS simulator is taking advantage of this partial measurement.

from qiskit-machine-learning.

adekusar-drl avatar adekusar-drl commented on July 29, 2024

As I see in qiskit_machine_learning.kernels.QuantumKernel implementation, only a required number of qubits is measured, basically it is the number of qubits in the feature map passed to QuantumKernel. If you don't pass a feature map, then ZZFeatureMap(2) is used. So, that's why I don't fully understand what is wrong in the implementation.

By the way, aqua and qiskit.aqua.algorithms.VQC are deprecated, I don't think we will update them with new features.

from qiskit-machine-learning.

adekusar-drl avatar adekusar-drl commented on July 29, 2024

I'm closing this issue as stale and unclear. Feel free to re-open with more details provided.

from qiskit-machine-learning.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.