Giter Club home page Giter Club logo

Comments (4)

owulveryck avatar owulveryck commented on June 19, 2024

Good catch!

The model has multiple "root" nodes which is not handled yet by the backend. This is an extract of the model rendered with netron:

ssd

Two things to do:

  • setting a more explicit error message
  • implement the feature

I will split this into two issues.

from onnx-go.

owulveryck avatar owulveryck commented on June 19, 2024

I am changing the title of this issue; I have created a "project" to follow the implementation steps to make the SSD model working.

Note: I have analyzed the model, and it will require a lot of effort to make it work with gorgonia.

from onnx-go.

owulveryck avatar owulveryck commented on June 19, 2024

There is a work-in-progress with the branch issue-48 but it needs some more investigation.

The actual design of "gorgonnx" does not handle operators with multiple output.

the signature of the apply method will probably require some changes:

type operator interface {
        // apply analyse the graph to find the children of the node
        // then extract its gorgonia.Node references
        // and assign the result of the operation to the node n
        apply(g *Graph, n *Node) error
        // init the operator with name and attributes as carried by the onnx.Operator
        init(o onnx.Operation) error
}

from onnx-go.

owulveryck avatar owulveryck commented on June 19, 2024

PR #115 fixes this error, but it introduces a breaking change.
The OperationCarrier interface needed to be changed to handle nodes with multiple outputs.

onnx-go/backend.go

Lines 19 to 27 in f9baf80

// OperationCarrier should be a method of the graph
// because the operation needs the topology of the graph
// to check the arity of the node for example
type OperationCarrier interface {
// ApplyOperation on the graph nodes
// graph.Node is an array because it allows to handle multiple output
// for example a split operation returns n nodes...
ApplyOperation(Operation, ...graph.Node) error
}

This will require to change any backend implementation.
As far as I know, the only backend implemented so far is Gorgonia (via gorgonnx), and it has been patched.

from onnx-go.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.