mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-07-17 18:40:28 +00:00
* initial setup and rename "how to" to "setup" * move API to main nav * move api to main nav * add get starated, rework nav order * rename to install move mds out of install section * update api nav and home page * add install docs and python qs updates * python get started work * remove c and obj c for now * move java, python, and obj-c docs under api folder * move java api html to iframe (ugh) * remove api docs w/o details, move api text getstar * remove api docs wo detail updates get started * remvoe iframes * move eco system to main nav * fix api buttons * added more examples moved intro to ORT * fix links * fix get started titles * fix get started titles * fix more links * fix more links * more link fixes * fix nav remove inferencing and training subnav * fix top nav remove inference and training nav * fix title * fix tutorials nav hierarchy * fix python api button * add tenorflow keras example * fix quickstart toc * add imports fix spacing * fix links * update nav and python get started page * move ort training example, add coming soon for iot * update C# get started * fix spacing on quantization * Add some js get started content * fix formatting * fix typo * removed onnx-pytorch and onnx-tf * updated pip install torch and added links iot page * added pytorch tutorial heirarchy * updated web to docs soon added release blog link * add web link
38 lines
No EOL
879 B
Markdown
38 lines
No EOL
879 B
Markdown
---
|
|
title: ORT Training with PyTorch
|
|
parent: Get Started
|
|
nav_order: 10
|
|
---
|
|
|
|
# Get started with ORT for Training API (PyTorch)
|
|
{: .no_toc }
|
|
The ORT Training API is a PyTorch frontend that implements the torch.nn.Module interface.
|
|
|
|
|
|
## ORT Training Example
|
|
In this example we will go over how to use ORT for Training a model with PyTorch.
|
|
|
|
```
|
|
pip install torch-ort
|
|
python -m torch_ort.configure
|
|
```
|
|
|
|
**Note**: This installs the default version of the `torch-ort` and `onnxruntime-training` packages that are mapped to specific versions of the CUDA libraries. Refer to the install options in [ONNXRUNTIME.ai](https://onnxruntime.ai).
|
|
|
|
- Add ORTModule in the `train.py`
|
|
```python
|
|
from torch_ort import ORTModule
|
|
.
|
|
.
|
|
.
|
|
model = ORTModule(model)
|
|
```
|
|
|
|
## Contents
|
|
{: .no_toc }
|
|
|
|
* TOC placeholder
|
|
{:toc}
|
|
|
|
## Samples
|
|
[ONNX Runtime Training Examples](../tutorials/training) |