mirror of
https://github.com/huggingface/transformers.git
synced 2025-07-05 05:40:05 +06:00

* add * add * add * Add deepspeed.md * Add * add * Update docs/source/ja/main_classes/callback.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update docs/source/ja/main_classes/output.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update docs/source/ja/main_classes/pipelines.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update docs/source/ja/main_classes/processors.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update docs/source/ja/main_classes/processors.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update docs/source/ja/main_classes/text_generation.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update docs/source/ja/main_classes/processors.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update logging.md * Update toctree.yml * Update docs/source/ja/main_classes/deepspeed.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Add suggesitons * m * Update docs/source/ja/main_classes/trainer.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update toctree.yml * Update Quantization.md * Update docs/source/ja/_toctree.yml Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update toctree.yml * Update docs/source/en/main_classes/deepspeed.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> * Update docs/source/en/main_classes/deepspeed.md Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com> --------- Co-authored-by: Steven Liu <59462357+stevhliu@users.noreply.github.com>
2.1 KiB
2.1 KiB
Exporting 🤗 Transformers models to ONNX
🤗 Transformers は transformers.onnx
パッケージを提供します。
設定オブジェクトを利用することで、モデルのチェックポイントをONNXグラフに変換することができます。
詳細はガイド を参照してください。 を参照してください。
ONNX Configurations
以下の3つの抽象クラスを提供しています。 エクスポートしたいモデルアーキテクチャのタイプに応じて、継承すべき3つの抽象クラスを提供します:
- エンコーダーベースのモデルは [
~onnx.config.OnnxConfig
] を継承します。 - デコーダーベースのモデルは [
~onnx.config.OnnxConfigWithPast
] を継承します。 - エンコーダー・デコーダーモデルは [
~onnx.config.OnnxSeq2SeqConfigWithPast
] を継承しています。
OnnxConfig
autodoc onnx.config.OnnxConfig
OnnxConfigWithPast
autodoc onnx.config.OnnxConfigWithPast
OnnxSeq2SeqConfigWithPast
autodoc onnx.config.OnnxSeq2SeqConfigWithPast
ONNX Features
各 ONNX 構成は、次のことを可能にする一連の 機能 に関連付けられています。 さまざまなタイプのトポロジまたはタスクのモデルをエクスポートします。
FeaturesManager
autodoc onnx.features.FeaturesManager