docs.unity3d.com
    Show / Hide Table of Contents

    Class RandomLayer

    Represents the abstract base class for layers which generate random values in the output tensor.

    Inheritance
    Object
    Layer
    RandomLayer
    Bernoulli
    Multinomial
    RandomNormal
    RandomNormalLike
    RandomUniform
    RandomUniformLike
    Inherited Members
    Layer.inputs
    Layer.name
    Layer.outputs
    Layer.flags
    Layer.Execute(Tensor[], ExecutionContext)
    Layer.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Unity.Sentis.Layers
    Syntax
    [Serializable]
    public abstract class RandomLayer : Layer

    Constructors

    RandomLayer(Nullable<Single>)

    Declaration
    protected RandomLayer(float? seed)
    Parameters
    Type Name Description
    Nullable<Single> seed

    Fields

    hasSeed

    Whether the layer has a provided seed value for the random number generator.

    Declaration
    public bool hasSeed
    Field Value
    Type Description
    Boolean

    seed

    The seed value for the random number generator. The layer does not use this value if hasSeed is false.

    Declaration
    public float seed
    Field Value
    Type Description
    Single

    Properties

    NextSeed

    Declaration
    protected float NextSeed { get; }
    Property Value
    Type Description
    Single

    Methods

    ResetSeed()

    Resets the state of the random number generator to its initial state.

    If hasSeed is false then the random number generator is seeded by System.Random().

    Declaration
    public void ResetSeed()
    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