Qiskit / qiskit

Qiskit is an open-source SDK for working with quantum computers at the level of extended quantum circuits, operators, and primitives.
https://www.ibm.com/quantum/qiskit
Apache License 2.0
5.1k stars 2.34k forks source link

Sample pulse dunder methods #1932

Closed taalexander closed 4 years ago

taalexander commented 5 years ago

What is the expected enhancement?

The base output command for pulse is the SamplePulse and all other terra output pulses are eventually compiled to the SamplePulse. Internally the SamplePulse is a complex numpy array of samples. The SamplePulse should support being treated as a numpy array by implementing the proper numpy interface. See NEP 22 — Duck typing for NumPy arrays for more information on what must be implemented. This should also extend to DiscreteFunctionalPulses and AnalyticFunctionalPulses with delayed evaluation.

As a consequence pulse composition should be supported AnalyticFunctionPulses and DiscreteFunctionPulses.

taalexander commented 4 years ago

Closing as the need for this is no longer clear.