Skip to content

Commit

Permalink
Merge 6c04c9d into 938ce33
Browse files Browse the repository at this point in the history
  • Loading branch information
ezyang committed Feb 20, 2018
2 parents 938ce33 + 6c04c9d commit 4aad5fd
Show file tree
Hide file tree
Showing 5 changed files with 61 additions and 5 deletions.
46 changes: 44 additions & 2 deletions docs/Changelog.md
Expand Up @@ -606,8 +606,8 @@ opset_import {
#### Attributes

<dl>
<dt><tt>axis</tt> : int (required)</dt>
<dd>Which axis to concat on</dd>
<dt><tt>axis</tt> : int</dt>
<dd>Which axis to concat on. Default value is 1.</dd>
</dl>

#### Inputs (1 - &#8734;)
Expand Down Expand Up @@ -5780,6 +5780,48 @@ opset_import {
</dl>

## Version 3 of the default ONNX operator set
### <a name="Concat-3"></a>**Concat-3**</a>

Concatenate a list of tensors into a single tensor

#### Versioning

This operator is used if you are using version 3 of the default ONNX operator set until the next BC-breaking change to this operator; e.g., it will be used if your protobuf has:

~~~~
opset_import {
version = 3
}
~~~~

#### Attributes

<dl>
<dt><tt>axis</tt> : int (required)</dt>
<dd>Which axis to concat on</dd>
</dl>

#### Inputs (1 - &#8734;)

<dl>
<dt><tt>inputs</tt> (variadic) : T</dt>
<dd>List of tensors for concatenation</dd>
</dl>

#### Outputs

<dl>
<dt><tt>concat_result</tt> : T</dt>
<dd>Concatenated tensor</dd>
</dl>

#### Type Constraints

<dl>
<dt><tt>T</tt> : tensor(float16), tensor(float), tensor(double)</dt>
<dd>Constrain output types to float tensors.</dd>
</dl>

### <a name="GRU-3"></a>**GRU-3**</a>

Computes an one-layer GRU. This operator is usually supported via some custom
Expand Down
6 changes: 4 additions & 2 deletions docs/Operators.md
Expand Up @@ -915,14 +915,16 @@ expect(node, inputs=[x], outputs=[y],

#### Versioning

This operator is used if you are using version 1 of the default ONNX operator set until the next BC-breaking change to this operator; e.g., it will be used if your protobuf has:
This operator is used if you are using version 3 of the default ONNX operator set until the next BC-breaking change to this operator; e.g., it will be used if your protobuf has:

~~~~
opset_import {
version = 1
version = 3
}
~~~~

Other versions of this operator: <a href="Changelog.md#Concat-1">Concat-1</a>

#### Attributes

<dl>
Expand Down
2 changes: 1 addition & 1 deletion onnx/defs/schema.h
Expand Up @@ -488,7 +488,7 @@ class OpSchemaRegistry {
// Increase the highest version when you make BC-breaking changes to the
// operator schema on specific domain. Update the lowest version when it's
// determined to remove too old version history.
map_[ONNX_DOMAIN] = std::make_pair(1, 3);
map_[ONNX_DOMAIN] = std::make_pair(1, 4);
map_["ai.onnx.ml"] = std::make_pair(1, 1);
}

Expand Down
1 change: 1 addition & 0 deletions onnx/defs/tensor/defs.cc
Expand Up @@ -50,6 +50,7 @@ from the shape argument.)DOC")
"Constrain input and output types to float tensors.");

ONNX_OPERATOR_SCHEMA(Concat)
.SinceVersion(4)
.Attr("axis",
"Which axis to concat on",
AttributeProto::INT)
Expand Down
11 changes: 11 additions & 0 deletions onnx/defs/tensor/old.cc
Expand Up @@ -5,6 +5,17 @@

using namespace ONNX_NAMESPACE;

ONNX_OPERATOR_SCHEMA(Concat)
.Attr("axis",
"Which axis to concat on. Default value is 1.",
AttributeProto::INT,
OPTIONAL)
.SetDoc("Concatenate a list of tensors into a single tensor")
.Input(0, "inputs", "List of tensors for concatenation", "T", OpSchema::Variadic)
.Output(0, "concat_result", "Concatenated tensor", "T")
.TypeConstraint("T", { "tensor(float16)", "tensor(float)", "tensor(double)" },
"Constrain output types to float tensors.");

ONNX_OPERATOR_SCHEMA(Split)
.SinceVersion(1)
.Input(0, "input", "The tensor to split", "T")
Expand Down

0 comments on commit 4aad5fd

Please sign in to comment.