diff --git a/ultralytics/engine/exporter.py b/ultralytics/engine/exporter.py index d0c241ba18..4565f86f46 100644 --- a/ultralytics/engine/exporter.py +++ b/ultralytics/engine/exporter.py @@ -476,7 +476,7 @@ class Exporter: m.agnostic_nms = self.args.agnostic_nms m.xyxy = self.args.nms and fmt != "coreml" m.shape = None # reset cached shape for new export input size - if hasattr(model, "pe") and hasattr(m, "fuse"): # for YOLOE models + if hasattr(model, "pe") and hasattr(m, "fuse") and not hasattr(m, "lrpc"): # for YOLOE models m.fuse(model.pe.to(self.device)) elif isinstance(m, C2f) and not is_tf_format: # EdgeTPU does not support FlexSplitV while split provides cleaner ONNX graph