class_docstr: Default qubit device for PennyLane.
  
  .. warning::
  
      This is the legacy implementation of DefaultQubit. It has been replaced by
      ``qml.devices.DefaultQubit``, which can be accessed with the familiar constructor,
      ``qml.device("default.qubit")``.
  
      This change will not alter device behaviour for most workflows, but may have implications for
      plugin developers and users who directly interact with device methods. Please consult
      :class:`pennylane.devices.Device` and the implementation in
      :class:`pennylane.devices.DefaultQubit` for more information on what the new
      interface will look like and be prepared to make updates in a coming release. If you have any
      feedback on these changes, please create an
      `issue <https://github.com/PennyLaneAI/pennylane/issues>`_ or post in our
      `discussion forum <https://discuss.pennylane.ai/>`_.
  
  Args:
      wires (int, Iterable[Number, str]): Number of subsystems represented by the device,
          or iterable that contains unique labels for the subsystems as numbers (i.e., ``[-1, 0, 2]``)
          or strings (``['ancilla', 'q1', 'q2']``). Default 1 if not specified.
      shots (None, int): How many times the circuit should be evaluated (or sampled) to estimate
          the expectation values. Defaults to ``None`` if not specified, which means that the device
          returns analytical results.
class_docstr_tok: ["Default","qubit","device","for","PennyLane",".","..","warning",":",":","This","is","the","legacy","implementation","of","DefaultQubit",".","It","has","been","replaced","by","``","qml.devices.DefaultQubit","``",",","which","can","be","accessed","with","the","familiar","constructor",",","``","qml.device","(","``","default.qubit","''",")","``",".","This","change","will","not","alter","device","behaviour","for","most","workflows",",","but","may","have","implications","for","plugin","developers","and","users","who","directly","interact","with","device","methods",".","Please","consult",":","class",":","`","pennylane.devices.Device","`","and","the","implementation","in",":","class",":","`","pennylane.devices.DefaultQubit","`","for","more","information","on","what","the","new","interface","will","look","like","and","be","prepared","to","make","updates","in","a","coming","release",".","If","you","have","any","feedback","on","these","changes",",","please","create","an","`","issue","<","https",":","\/\/github.com\/PennyLaneAI\/pennylane\/issues",">","`","_","or","post","in","our","`","discussion","forum","<","https",":","\/\/discuss.pennylane.ai\/",">","`","_",".","Args",":","wires","(","int",",","Iterable","[","Number",",","str","]",")",":","Number","of","subsystems","represented","by","the","device",",","or","iterable","that","contains","unique","labels","for","the","subsystems","as","numbers","(","i.e.",",","``","[","-1",",","0",",","2","]","``",")","or","strings","(","``","[","'ancilla","'",",","'q1","'",",","'q2","'","]","``",")",".","Default","1","if","not","specified",".","shots","(","None",",","int",")",":","How","many","times","the","circuit","should","be","evaluated","(","or","sampled",")","to","estimate","the","expectation","values",".","Defaults","to","``","None","``","if","not","specified",",","which","means","that","the","device","returns","analytical","results","."]
code: def capabilities(cls):
      capabilities = super().capabilities().copy()
      capabilities.update(
          model="qubit",
          supports_inverse_operations=True,
          supports_analytic_computation=True,
          supports_broadcasting=True,
          returns_state=True,
          passthru_devices={
              "tf": "default.qubit.tf",
              "torch": "default.qubit.torch",
              "autograd": "default.qubit.autograd",
              "jax": "default.qubit.jax",
          },
      )
      return capabilities
  
imports: import functools
  import itertools
  from string import ascii_letters
  from typing import List
  import numpy
  from scipy.sparse import csr_matrix
  import pennylane
  from pennylane import BasisState, DeviceError, QubitDevice, StatePrep, Snapshot
  from pennylane.devices.qubit import measure
  from pennylane.operation import Operation
  from pennylane.ops import Sum
  from pennylane.ops.qubit.attributes import diagonal_in_z_basis
  from pennylane.pulse import ParametrizedEvolution
  from pennylane.measurements import ExpectationMP
  from pennylane.typing import TensorLike
  from pennylane.wires import WireError
  from .._version import __version__
label_desc: Use image node_id 24 for calling the DefaultQubitLegacy obj's underlying member method code with example usage: obj.capabilities(cls) and returns: capabilities