onnxruntime/docs/How_To_Update_ONNX_Dev_Notes.md
Yulong Wang 1b902d0227
doc: add ort-web related instructions to update onnx doc (#8500)
* doc: update instructions for ort web docs

* revise readme
2021-08-06 15:09:11 -07:00

2.1 KiB

This is a note only for ONNX Runtime developers.

It's very often, you need to update the ONNX submodule to a newer version in the upstream. Please follow the steps below, don't miss any!

  1. Update the ONNX subfolder
cd cmake/external/onnx
git remote update
git reset --hard <commit_id>
cd ..
git add onnx

(Change the <commit_id> to yours. If you are not sure, use 'origin/master'. Like 'git reset --hard origin/master')

  1. Update cgmanifests/submodules/cgmanifest.json. This file should be generated. See cgmanifests/README for instructions.

  2. Update tools/ci_build/github/linux/docker/scripts/install_onnx.sh. Search 'for version2tag', update the commit hashes. The list should contain every release version from ONNX 1.2, and the latest one in our cmake/external/onnx folder.

  3. If there is any change to cmake/external/onnx/onnx/*.in.proto, update onnxruntime/core/protobuf as follows :

- Apply these changes to onnxruntime/core/protobuf/*.in.proto
- Copy cmake/external/onnx/onnx/gen_proto.py to onnxruntime/core/protobuf and use this script to generate the new \*.proto and \*.proto3 files
- Regenerate csharp/test/Microsoft.ML.OnnxRuntime.Tests/OnnxMl.cs
  1. Send you PR, and run the CI builds.

  2. If there is a build failure in stage "Check out of dated documents" in WebAssembly CI pipeline, update ONNX Runtime Web WebGL operator support document:

    • Make sure Node.js is installed (see Prerequisites for instructions).
    • Follow step 1 in js/Build to install dependencies).
    • Follow instructions in Generate document to update document. Commit changes applied to file docs/operators.md.
  3. If there is any unitest failure, caught by onnx_test_runner. Please also update