Skip to content

VectorType attribute with dynamic dimension #164

@mjmckp

Description

@mjmckp

The VectorType attribute can be added to an array-valued field when the length of the array is known at compile time, e.g.,

        public class Data
        {
            [ColumnName("Features")]
            [VectorType(2)]
            public float[] Features;

            [ColumnName("Label")]
            public bool Label;
        }

However, what if the length of the array is only known at run time?

For example, given IEnumerable<Data> data where the length of the Features array is given by int numFeatures, I need to be able to pass numFeatures to CollectionDataSource.Create(data) somehow, and remove the static 2 argument to the VectorType attribute on the Features field.

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions