From 609e238d85f2376e2498ea47ffc21df32186ecfc Mon Sep 17 00:00:00 2001 From: to24toro Date: Wed, 16 Aug 2023 08:08:00 +0900 Subject: [PATCH] update_from_instruction_schedule_map --- qiskit/transpiler/target.py | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/qiskit/transpiler/target.py b/qiskit/transpiler/target.py index e61de07701c9..e2d573a46efe 100644 --- a/qiskit/transpiler/target.py +++ b/qiskit/transpiler/target.py @@ -501,9 +501,8 @@ def update_from_instruction_schedule_map(self, inst_map, inst_name_map=None, err props = None entry = get_calibration(inst_name, qargs) - if entry.user_provided and getattr(props, "_calibration", None) != entry: - # It only copies user-provided calibration from the inst map. - # Backend defined entry must already exist in Target. + + if getattr(props, "_calibration", None) != entry: if self.dt is not None: try: duration = entry.get_schedule().duration * self.dt @@ -516,11 +515,6 @@ def update_from_instruction_schedule_map(self, inst_map, inst_name_map=None, err duration=duration, calibration=entry, ) - else: - if props is None: - # Edge case. Calibration is backend defined, but this is not - # registered in the backend target. Ignore this entry. - continue try: # Update gate error if provided. props.error = error_dict[inst_name][qargs]