§
    ¹³Ùg´  ã                   ó¸  — d Z ddlZddlmZ ddlmZmZmZ ddlmZ ddl	m
Z
 ddlmZmZ ddlmZ dd	lmZ dd
lmZ ddlmZ ddlmZ  ej        e¦  «        Zd„ Z ed¬¦  «        	 	 	 	 	 ddeeee         f         dee         dee         deeee                           dee         deeeee         f                  deeee         f         fd„¦   «         ZdS )z­
Convenience entry point into pulse scheduling, requiring only a circuit and a backend. For more
control over pulse scheduling, look at `qiskit.scheduler.schedule_circuit`.
é    N)Útime)ÚListÚOptionalÚUnion)ÚQuantumCircuit)ÚQiskitError)ÚInstructionScheduleMapÚSchedule)ÚBackend)ÚScheduleConfig)Úschedule_circuit)Úparallel_map)Údeprecate_pulse_dependencyc                 óT   — d|| z
  dz  d›d�}t                                |¦  «         d S )NzTotal Scheduling Time - iè  z.5fz (ms))ÚloggerÚinfo)Ú
start_timeÚend_timeÚlog_msgs      úO/granary/edev/quantum/lib/python3.11/site-packages/qiskit/compiler/scheduler.pyÚ_log_schedule_timer   "   s7   € ØT¨8°jÑ+@ÀDÑ*HÐTÐTÐTÐT€GÝ
‡K‚K�ÑÔÐÐÐó    T)Úmoving_to_dynamicsÚcircuitsÚbackendÚinst_mapÚmeas_mapÚdtÚmethodÚreturnc                 óœ  — t          | t          ¦  «        }t          ¦   «         }|r1t          |dd¦  «        dk    r|€|j        }|€|j        }|€|j        }nˆ|€=|€t          d¦  «        ‚|                     ¦   «         }|€t          d¦  «        ‚|j        }|€*|€t          d¦  «        ‚| 	                    ¦   «         j        }|€|�| 	                    ¦   «         j        }t          |||¬¦  «        }	t          | t          ¦  «        r| n| g} t          t          | |	||f¦  «        }
t          ¦   «         }t          ||¦  «         |r|
S |
d         S )	a„  
    Schedule a circuit to a pulse ``Schedule``, using the backend, according to any specified
    methods. Supported methods are documented in :py:mod:`qiskit.scheduler.schedule_circuit`.

    Args:
        circuits: The quantum circuit or circuits to translate
        backend: A backend instance, which contains hardware-specific data required for scheduling
        inst_map: Mapping of circuit operations to pulse schedules. If ``None``, defaults to the
                  ``backend``'s ``instruction_schedule_map``
        meas_map: List of sets of qubits that must be measured together. If ``None``, defaults to
                  the ``backend``'s ``meas_map``
        dt: The output sample rate of backend control electronics. For scheduled circuits
            which contain time information, dt is required. If not provided, it will be
            obtained from the backend configuration
        method: Optionally specify a particular scheduling method

    Returns:
        A pulse ``Schedule`` that implements the input circuit

    Raises:
        QiskitError: If ``inst_map`` and ``meas_map`` are not passed and ``backend`` is not passed
    Úversionr   é   NzMMust supply either a backend or InstructionScheduleMap for scheduling passes.zHThe backend defaults are unavailable. The backend may not support pulse.zAMust supply either a backend or a meas_map for scheduling passes.)r   r   r   )Ú
isinstanceÚlistr   ÚgetattrÚinstruction_schedule_mapr   r   r   ÚdefaultsÚconfigurationr   r   r   r   )r   r   r   r   r   r   Úarg_circuits_listr   r(   Úschedule_configÚ	schedulesr   s               r   Úscheduler-   '   sŠ  € õ> # 8­TÑ2Ô2ÐÝ‘”€JØð 0•7˜7 I¨qÑ1Ô1°AÒ5Ð5ØÐØÔ7ˆHØÐØÔ'ˆHØˆ:Ø”ˆBøàÐØˆÝ!Øcñô ð ð ×'Ò'Ñ)Ô)ˆHØÐÝ!Ø^ñô ð ð  Ô8ˆHØÐØˆÝ!ØWñô ð ð ×,Ò,Ñ.Ô.Ô7ˆHØˆ:ØÐ"Ø×*Ò*Ñ,Ô,Ô/�å$¨hÀÈbÐQÑQÔQ€OÝ% hµÑ5Ô5ÐEˆxˆx¸H¸:€HÝÕ-¨x¸/È6ÐSZÐ9[Ñ\Ô\€IÝ‰vŒv€HÝ�z 8Ñ,Ô,Ð,Øð ØÐà˜Œ|Ðr   )NNNNN) Ú__doc__Úloggingr   Útypingr   r   r   Úqiskit.circuit.quantumcircuitr   Úqiskit.exceptionsr   Úqiskit.pulser	   r
   Úqiskit.providers.backendr   Úqiskit.scheduler.configr   Ú!qiskit.scheduler.schedule_circuitr   Úqiskit.utils.parallelr   Úqiskit.utils.deprecate_pulser   Ú	getLoggerÚ__name__r   r   ÚintÚfloatÚstrr-   © r   r   ú<module>r?      së  ððð ð €€€à Ð Ð Ð Ð Ð Ø (Ð (Ð (Ð (Ð (Ð (Ð (Ð (Ð (Ð (à 8Ð 8Ð 8Ð 8Ð 8Ð 8Ø )Ð )Ð )Ð )Ð )Ð )Ø 9Ð 9Ð 9Ð 9Ð 9Ð 9Ð 9Ð 9Ø ,Ð ,Ð ,Ð ,Ð ,Ð ,Ø 2Ð 2Ð 2Ð 2Ð 2Ð 2Ø >Ð >Ð >Ð >Ð >Ð >Ø .Ð .Ð .Ð .Ð .Ð .Ø CÐ CÐ CÐ CÐ CÐ Cà	ˆÔ	˜8Ñ	$Ô	$€ðð ð ð
 Ð¨tÐ4Ñ4Ô4ð "&Ø15Ø*.ØØ.2ðEð EØ�N D¨Ô$8Ð8Ô9ðEà�gÔðEð Ð-Ô.ðEð �t˜D œI”Ô'ð	Eð
 	�ŒðEð �U˜3  S¤	˜>Ô*Ô+ðEð ˆ8�T˜(”^Ð#Ô$ðEð Eð Eñ 5Ô4ðEð Eð Er   