VectorTypeAttribute Class

Definition

Allows a member to be marked as a VectorDataViewType, primarily allowing one to set the dimensionality of the resulting array.

[System.AttributeUsage(System.AttributeTargets.Field | System.AttributeTargets.Property, AllowMultiple=false, Inherited=true)]
public sealed class VectorTypeAttribute : Attribute
[<System.AttributeUsage(System.AttributeTargets.Field | System.AttributeTargets.Property, AllowMultiple=false, Inherited=true)>]
type VectorTypeAttribute = class
    inherit Attribute
Public NotInheritable Class VectorTypeAttribute
Inherits Attribute
Inheritance
VectorTypeAttribute
Attributes

Constructors

VectorTypeAttribute()

Mark member as single-dimensional array with unknown size.

VectorTypeAttribute(Int32)

Mark member as single-dimensional array with specified size.

VectorTypeAttribute(Int32[])

Mark member with expected dimensions of array. Notice that this attribute is expected to be added to one dimensional arrays, and it shouldn't be added to multidimensional arrays. Internally, ML.NET will use the shape information provided as the "dimensions" param of this constructor, to use it as a multidimensional array.

Applies to