docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Class LabelEntryMatchCache

    Cache of instance id -> label entry index for a LabelConfig. This is not well optimized and is the source of a known memory leak for apps that create new instances frequently.

    Inheritance
    object
    LabelEntryMatchCache
    Implements
    IGroundTruthGenerator
    IDisposable
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: UnityEngine.Perception.GroundTruth.LabelManagement
    Assembly: Unity.Perception.Runtime.dll
    Syntax
    [MovedFrom("UnityEngine.Perception.GroundTruth")]
    public class LabelEntryMatchCache : IGroundTruthGenerator, IDisposable

    Methods

    Dispose()

    Disposes cache

    Declaration
    public void Dispose()

    TryGetLabelEntryFromInstanceId(uint, out IdLabelEntry, out int)

    Retrieves the label entry for the given instance id.

    Declaration
    public bool TryGetLabelEntryFromInstanceId(uint instanceId, out IdLabelEntry labelEntry, out int index)
    Parameters
    Type Name Description
    uint instanceId

    The instance id to look up

    IdLabelEntry labelEntry

    The IdLabelEntry of the match if found. Otherwise returns

    default(IdlabelEntry)
    .
    int index

    The index of the matched IdLabelEntry in the IdLabelConfig if found. Otherwise returns -1.

    Returns
    Type Description
    bool

    True if a the instance id was found in the cache.

    Implements

    IGroundTruthGenerator
    IDisposable
    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)