Dates are in YYYY-MM-DD format.
- Fixed a bug where graph inputs and outputs could be assigned
SynchronizedList
instances, and would therefore be modified if nodes in the graph were.
- Changed the default value of
remove_unused_node_outputs
incleanup()
toFalse
, as a value ofTrue
can lead to unintuitive behavior, especially with looping constructs likeScan
andLoop
.
- Fixed a bug where calling
graph.tensors()
would cause the inputs or outputs of some tensors to be modified.
SynchronizedList.__add__()
no longer modifies the left operand.
- Fixed a bug where nodes including subgraphs whose inputs/outputs had the same names as the node's inputs/outputs would not be imported correctly.
fold_constants()
will no longer fail if there is nothing to fold in the graphcleanup()
will now properly remove the producer nodes of graph inputs.- Fixed a bug where graph input/output tensors not attached to nodes would not be correctly exported.
Graph.register()
now accepts anopsets
argument so that functions can be registered for specific opsets.
has_metadata
has been removed fromTensor
, since the function is no longer used.
- ONNX GraphSurgeon now enforces the constraint that graph inputs/outputs must include type information.
- Fixed a bug where
opset
was not being considering when running inference for constant folding.
- Added
layer()
function toGraph
to make it easier to generate models from scratch - Added
i()
ando()
convenience functions toTensor
, which are similar to the functions forNode
, but returnTensor
s instead ofNode
s
- Added an
examples
directory - Added
has_metadata()
toTensor
classes to determine if dtype/shape are known. - Added a
check_duplicates
parameter toGraph.tensors()
to make it easy to check for duplicate tensors in the graph.
- Various improvements to the logger
- Updated
OnnxImporter
so that it can correctly import shapes and types from an ONNX graph after shape inference. - Made
Tensor
an abstract class - all tensors in a graph are now eitherVariable
orConstant
- Renames
generate_tensor_map()
totensors()
inGraph
- Removed
Tensor
suffix from Tensor classes.
- The
import_onnx
andexport_onnx
functions will now preserve opset information anddim_param
values in shapes.
- Added
i()
ando()
convenience functions toNode
for retrieving input/output nodes. - Added
fold_constants()
toGraph
to allow for folding constants in the graph. - Added
__deepcopy__()
toGraph
. - Added
to_constant()
andto_variable()
functions toVariable
andConstant
respectively to transmute them in-place.
- Removed some type annotations to allow compatibility with Python 3.5.
- Added
Node
,Tensor
andGraph
classes. - Added
BaseImporter
andOnnxImporter
classes. - Added support for importing initializers in the
OnnxImporter
- Added
Variable
andConstant
- Consolidates inputs/outputs of Nodes/Tensors. Now, inputs/outputs should generally only be added to
Node
s. - Added
OnnxExporter
to exportGraph
toonnx.GraphProto
- Added
OnnxExporter
andOnnxImporter
to public imports - Added
toposort
function toGraph
, which will topologically sort it. - Added
cleanup
function toGraph
, which will remove unused nodes and tensors. - Added high-level API for importing/exporting
Graph
s from/to ONNX models. Graph
s are now generated with a default name ofonnx_graphsurgeon