onnx-coreml icon indicating copy to clipboard operation
onnx-coreml copied to clipboard

Support Path from pathlib

Open gunjunlee opened this issue 6 years ago • 0 comments

🌱 Describe your Feature Request

Support Path (from pathlib) as type of argument model

https://github.com/onnx/onnx-coreml/blob/7a630c113b27c8cc1a83412ce1dbfda77f9f8422/onnx_coreml/converter.py#L447

convert doesn't support Path as type of argument model but onnx.load supports Path

Use cases

from pathlib import Path
model_path = Path("path/to/onnx")
convert(model_path, ....)

Describe alternatives you've considered

if isinstance(model, Text): -> if isinstance(model, Text) or isinstance(model, Path):

gunjunlee avatar Dec 10 '19 07:12 gunjunlee