docs.unity3d.com
    Show / Hide Table of Contents

    Class Model

    Represents a Sentis neural network.

    Inheritance
    Object
    Model
    Inherited Members
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Unity.Sentis
    Syntax
    public class Model

    Fields

    constants

    The constants of the model.

    Declaration
    public List<Constant> constants
    Field Value
    Type Description
    List<Constant>

    DefaultOpsetVersion

    The opset version number of the ONNX model, for the default domain.

    Declaration
    public long DefaultOpsetVersion
    Field Value
    Type Description
    Int64

    inputs

    The inputs of the model.

    Declaration
    public List<Model.Input> inputs
    Field Value
    Type Description
    List<Model.Input>

    IrSource

    The metadata of the model, as a string.

    Declaration
    public string IrSource
    Field Value
    Type Description
    String

    IrVersion

    The metadata of the ONNX model, as a string.

    Declaration
    public long IrVersion
    Field Value
    Type Description
    Int64

    layers

    The layers of the model.

    Declaration
    public List<Layer> layers
    Field Value
    Type Description
    List<Layer>

    OpsetDescriptions

    The opsets of the ONNX model.

    Declaration
    public List<Model.OpsetDescription> OpsetDescriptions
    Field Value
    Type Description
    List<Model.OpsetDescription>

    outputs

    The outputs of the model.

    Declaration
    public List<string> outputs
    Field Value
    Type Description
    List<String>

    ProducerName

    The producer of the model, as a string.

    Declaration
    public string ProducerName
    Field Value
    Type Description
    String

    Version

    The version of the model. The value increments each time the data structure changes.

    Declaration
    public const int Version = 26
    Field Value
    Type Description
    Int32

    Properties

    Metadata

    The metadata properties associated with the model.

    Declaration
    public Dictionary<string, string> Metadata { get; }
    Property Value
    Type Description
    Dictionary<String, String>

    Warnings

    The warnings from the model importer.

    Declaration
    public List<Model.ImporterWarning> Warnings { get; }
    Property Value
    Type Description
    List<Model.ImporterWarning>

    Methods

    AddConstant(Constant)

    Adds a constant to the model.

    Declaration
    public void AddConstant(Constant constant)
    Parameters
    Type Name Description
    Constant constant

    AddInput(String, DataType, SymbolicTensorShape)

    Adds an input called name to the model.

    Declaration
    public void AddInput(string name, DataType dataType, SymbolicTensorShape shape)
    Parameters
    Type Name Description
    String name
    DataType dataType
    SymbolicTensorShape shape

    AddLayer(Layer)

    Adds a layer to the model.

    Declaration
    public void AddLayer(Layer layer)
    Parameters
    Type Name Description
    Layer layer

    AddOutput(String)

    Adds an output called name to the model.

    Declaration
    public void AddOutput(string name)
    Parameters
    Type Name Description
    String name

    ShallowCopy()

    Returns a shallow copy of the model.

    Declaration
    public Model ShallowCopy()
    Returns
    Type Description
    Model

    ToString()

    Returns a string that represents the Model.

    Declaration
    public override string ToString()
    Returns
    Type Description
    String
    Overrides
    Object.ToString()

    Extension Methods

    ModelExtensions.CreateWorker(Model, DeviceType, Boolean)

    Did you find this page useful? Please give it a rating:

    Thanks for rating this page!

    Report a problem on this page

    What kind of problem would you like to report?

    • This page needs code samples
    • Code samples do not work
    • Information is missing
    • Information is incorrect
    • Information is unclear or confusing
    • There is a spelling/grammar error on this page
    • Something else

    Thanks for letting us know! This page has been marked for review based on your feedback.

    If you have time, you can provide more information to help us fix the problem faster.

    Provide more information

    You've told us this page needs code samples. If you'd like to help us further, you could provide a code sample, or tell us about what kind of code sample you'd like to see:

    You've told us there are code samples on this page which don't work. If you know how to fix it, or have something better we could use instead, please let us know:

    You've told us there is information missing from this page. Please tell us more about what's missing:

    You've told us there is incorrect information on this page. If you know what we should change to make it correct, please tell us:

    You've told us this page has unclear or confusing information. Please tell us more about what you found unclear or confusing, or let us know how we could make it clearer:

    You've told us there is a spelling or grammar error on this page. Please tell us what's wrong:

    You've told us this page has a problem. Please tell us more about what's wrong:

    Thank you for helping to make the Unity documentation better!

    Your feedback has been submitted as a ticket for our documentation team to review.

    We are not able to reply to every ticket submitted.

    In This Article
    • Fields
      • constants
      • DefaultOpsetVersion
      • inputs
      • IrSource
      • IrVersion
      • layers
      • OpsetDescriptions
      • outputs
      • ProducerName
      • Version
    • Properties
      • Metadata
      • Warnings
    • Methods
      • AddConstant(Constant)
      • AddInput(String, DataType, SymbolicTensorShape)
      • AddLayer(Layer)
      • AddOutput(String)
      • ShallowCopy()
      • ToString()
    • Extension Methods
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023