


'''simple docstring'''

import numpy as np
import qiskit
from qiskit import Aer, ClassicalRegister, QuantumCircuit, QuantumRegister, execute

def _SCREAMING_SNAKE_CASE				(A = np.pi / 2  ,			A = np.pi / 2  ,			A = np.pi / 2	)	->	qiskit.result.counts.Counts:






       """simple docstring"""







       lowercase__				      =			QuantumRegister(3  ,			'''qr'''	)  # Define the number of quantum bits
       lowercase__				      =			ClassicalRegister(1  ,			'''cr'''	)  # Define the number of classical bits

       lowercase__				      =			QuantumCircuit(A  ,			A	)  # Define the quantum circuit.

       # Build the circuit
       quantum_circuit.u(A  ,			A  ,			A  ,			0	)  # Quantum State to teleport
       quantum_circuit.h(1	)  # add hadamard gate
       quantum_circuit.cx(
           1  ,			2	)  # add control gate with qubit 1 as control and 2 as target.
       quantum_circuit.cx(0  ,			1	)
       quantum_circuit.h(0	)
       quantum_circuit.cz(0  ,			2	)  # add control z gate.
       quantum_circuit.cx(1  ,			2	)

       quantum_circuit.measure([2]  ,			[0]	)  # measure the qubit.

       # Simulate the circuit using qasm simulator
       lowercase__				      =			Aer.get_backend('''aer_simulator'''	)
       lowercase__				      =			execute(A  ,			A  ,			shots=1_000	)

       return job.result().get_counts(A	)


if __name__ == "__main__":
 print(
     'Total count for teleported state is: '
     f"""{quantum_teleportation(np.pi/2, np.pi/2, np.pi/2)}"""
 )








'''simple docstring'''

from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available


lowerCamelCase							:       str  						=     {'configuration_nat': ['NAT_PRETRAINED_CONFIG_ARCHIVE_MAP', 'NatConfig']}


try:
 if not is_torch_available():
  raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
 pass
else:
 lowerCamelCase							:       Tuple  						=     [
     'NAT_PRETRAINED_MODEL_ARCHIVE_LIST',
     'NatForImageClassification',
     'NatModel',
     'NatPreTrainedModel',
     'NatBackbone',
 ]

if TYPE_CHECKING:
 from .configuration_nat import NAT_PRETRAINED_CONFIG_ARCHIVE_MAP, NatConfig

 try:
  if not is_torch_available():
   raise OptionalDependencyNotAvailable()
 except OptionalDependencyNotAvailable:
  pass
 else:
  from .modeling_nat import (
      NAT_PRETRAINED_MODEL_ARCHIVE_LIST,
      NatBackbone,
      NatForImageClassification,
      NatModel,
      NatPreTrainedModel,
  )

else:
 import sys

 lowerCamelCase							:       Optional[Any]  						=     _LazyModule(__name__, globals()['__file__'], _import_structure, module_spec=__spec__)




