We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3adbe7c commit fc20148Copy full SHA for fc20148
optimum/onnx/utils.py
@@ -84,7 +84,7 @@ def _get_model_external_data_paths(model_path: Path) -> List[Path]:
84
for tensor in model_tensors
85
if tensor.HasField("data_location") and tensor.data_location == onnx.TensorProto.EXTERNAL
86
]
87
- return [model_path.parent / tensor_name for tensor_name in model_tensors_ext]
+ return list(dict.fromkeys([model_path.parent / tensor_name for tensor_name in model_tensors_ext]))
88
89
90
def check_model_uses_external_data(model: onnx.ModelProto) -> bool:
0 commit comments