Class ComputeTensorData | Barracuda | 0.7.1-preview
docs.unity3d.com
    Show / Hide Table of Contents

    Class ComputeTensorData

    Inheritance
    Object
    ComputeTensorData
    SharedComputeTensorData
    Inherited Members
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Unity.Barracuda
    Syntax
    public class ComputeTensorData : ITensorData, IDisposable

    Constructors

    ComputeTensorData(ComputeBuffer, TensorShape, Int32, String, ComputeInfo.ChannelsOrder)

    Declaration
    public ComputeTensorData(ComputeBuffer buffer, TensorShape shape, int offset, string buffername, ComputeInfo.ChannelsOrder onDeviceChannelsOrder)
    Parameters
    Type Name Description
    ComputeBuffer buffer
    TensorShape shape
    Int32 offset
    String buffername
    ComputeInfo.ChannelsOrder onDeviceChannelsOrder

    ComputeTensorData(TensorShape, String, ComputeInfo.ChannelsOrder, Boolean)

    Declaration
    public ComputeTensorData(TensorShape shape, string buffername, ComputeInfo.ChannelsOrder onDeviceChannelsOrder, bool clearOnInit = true)
    Parameters
    Type Name Description
    TensorShape shape
    String buffername
    ComputeInfo.ChannelsOrder onDeviceChannelsOrder
    Boolean clearOnInit

    Fields

    name

    Declaration
    public string name
    Field Value
    Type Description
    String

    Properties

    buffer

    Declaration
    public ComputeBuffer buffer { get; }
    Property Value
    Type Description
    ComputeBuffer

    offset

    Declaration
    public int offset { get; }
    Property Value
    Type Description
    Int32

    Methods

    Dispose()

    Declaration
    public virtual void Dispose()
    Implements
    IDisposable.Dispose()

    Download(TensorShape)

    Declaration
    public virtual float[] Download(TensorShape shape)
    Parameters
    Type Name Description
    TensorShape shape
    Returns
    Type Description
    Single[]
    Implements
    ITensorData.Download(TensorShape)

    Finalize()

    Declaration
    protected void Finalize()

    GetMaxCount()

    Declaration
    public virtual int GetMaxCount()
    Returns
    Type Description
    Int32
    Implements
    ITensorData.GetMaxCount()

    Reserve(Int32)

    Declaration
    public virtual void Reserve(int count)
    Parameters
    Type Name Description
    Int32 count
    Implements
    ITensorData.Reserve(Int32)

    ScheduleAsyncDownload(Int32)

    Declaration
    public virtual bool ScheduleAsyncDownload(int count)
    Parameters
    Type Name Description
    Int32 count
    Returns
    Type Description
    Boolean
    Implements
    ITensorData.ScheduleAsyncDownload(Int32)

    SharedAccess(out Int32)

    Declaration
    public virtual float[] SharedAccess(out int offset)
    Parameters
    Type Name Description
    Int32 offset
    Returns
    Type Description
    Single[]
    Implements
    ITensorData.SharedAccess(out Int32)

    ToString()

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

    Upload(Single[], TensorShape, Int32)

    Declaration
    public virtual void Upload(float[] data, TensorShape shape, int managedBufferStartIndex = 0)
    Parameters
    Type Name Description
    Single[] data
    TensorShape shape
    Int32 managedBufferStartIndex
    Implements
    ITensorData.Upload(Single[], TensorShape, Int32)
    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