sentenceTransformer to onnx

    [NLP]. Sentence-Transformer 모델 onnx 형식으로 변환하기

    HuggingFace에 등록된 모델을 불러와 onnx 파일 형식으로 저장하기 from pathlib import Path from transformers.convert_graph_to_onnx import convert convert(framework="pt", model="j5ng/sentence-klue-roberta-base", output=Path("onnx_models/trfs-model.onnx"), opset=11)​ Logs ransformers.convert_graph_to_onnx` package is deprecated and will be removed in version 5 of Transformers warnings.warn( ONNX opset version set to: 11..