-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
449 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
--- | ||
title: Adapter file spec | ||
description: Specification for the .onnx_adapter file format | ||
has_children: false | ||
parent: Reference | ||
grand_parent: Generate API (Preview) | ||
nav_order: 2 | ||
--- | ||
|
||
# Adapter file specification | ||
|
||
|
||
## File format | ||
|
||
The adapter file format is flatbuffers | ||
|
||
## File extension | ||
|
||
The file extension is ".onnx_adapter" | ||
|
||
## Schema | ||
|
||
Link to live [schema definition](https://github.com/microsoft/onnxruntime/blob/main/onnxruntime/lora/adapter_format/adapter_schema.fbs). | ||
|
||
The schema definition is as follows | ||
|
||
``` | ||
File:= | ||
format_version := integer | ||
adapter_version := integer | ||
model_version := integer | ||
[parameter := Parameter] | ||
``` | ||
|
||
``` | ||
Parameter:= | ||
name := string | ||
dimensions := [int64] | ||
data_type := TensorDataType | ||
[data := uint8] | ||
``` | ||
|
||
``` | ||
TensorDataType:= | ||
UNDEFINED = 0 | | ||
FLOAT = 1 | | ||
UINT8 = 2 | | ||
INT8 = 3 | | ||
UINT16 = 4 | | ||
INT16 = 5 | | ||
INT32 = 6 | | ||
INT64 = 7 | | ||
STRING = 8 | | ||
BOOL = 9 | | ||
FLOAT16 = 10 | | ||
DOUBLE = 11 | | ||
UINT32 = 12 | | ||
UINT64 = 13 | | ||
COMPLEX64 = 14 | | ||
COMPLEX128 = 15 | | ||
BFLOAT16 = 16 | | ||
FLOAT8E4M3FN = 17 | | ||
FLOAT8E4M3FNUZ = 18 | | ||
FLOAT8E5M2 = 19 | | ||
FLOAT8E5M2FNUZ = 20 | ||
``` |
Oops, something went wrong.