3 writes to Dimensions
Microsoft.ML.DataView (3)
VectorType.cs (3)
49Dimensions = ImmutableArray.Create(Size); 66Dimensions = dimensions.ToImmutableArray(); 84Dimensions = dimensions;
70 references to Dimensions
Microsoft.ML.Data (12)
DataLoadSave\Binary\Codecs.cs (2)
806int count = _type.Dimensions.Length; 812writer.Write(_type.Dimensions[i]);
Evaluators\EvaluatorUtils.cs (1)
734type, new VectorDataViewType(keyType, ((VectorDataViewType)type).Dimensions), mapper, keyValueGetter, slotNamesGetter);
Scorers\FeatureContributionCalculation.cs (1)
344var featureContributionType = new VectorDataViewType(NumberDataViewType.Single, ((VectorDataViewType)FeatureColumn.Type).Dimensions);
Transforms\KeyToValue.cs (1)
238types[iinfo] = new VectorDataViewType((PrimitiveDataViewType)valsItemType, vectorType.Dimensions);
Transforms\KeyToVector.cs (2)
327var slotNamesType = new VectorDataViewType(TextDataViewType.Instance, _types[iinfo].Dimensions); 339var slotNamesType = new VectorDataViewType(TextDataViewType.Instance, _types[iinfo].Dimensions);
Transforms\LabelConvertTransform.cs (1)
191Interlocked.CompareExchange(ref _slotType, new VectorDataViewType(NumberDataViewType.Single, srcSlotType.Dimensions), null);
Transforms\Normalizer.cs (1)
482ctx.Writer.WriteIntArray(vectorType.Dimensions.ToArray());
Transforms\TypeConverting.cs (1)
429typeDst = new VectorDataViewType(itemType, vectorType.Dimensions);
Transforms\ValueMapping.cs (1)
1073colType = new VectorDataViewType((PrimitiveDataViewType)_parent.ValueColumnType, vectorType.Dimensions);
Transforms\ValueToKeyMappingTransformer.cs (1)
728colType = new VectorDataViewType(keyType, vectorType.Dimensions);
Microsoft.ML.DataView (19)
VectorType.cs (19)
26/// In the case where this is a multi-dimensional type, that is, a situation where <see cref="Dimensions"/> 29/// dimensions. We consider that the last dimension is the most "minor" index. In the case where <see cref="Dimensions"/> 56/// <param name="dimensions">The dimensions. Note that, like <see cref="Dimensions"/>, must be non-empty, with all 57/// non-negative values. Also, because <see cref="Size"/> is the product of <see cref="Dimensions"/>, the result of 67Size = ComputeSize(Dimensions); 74/// <param name="dimensions">The dimensions. Note that, like <see cref="Dimensions"/>, must be non-empty, with all 75/// non-negative values. Also, because <see cref="Size"/> is the product of <see cref="Dimensions"/>, the result of 85Size = ComputeSize(Dimensions); 117/// Note that this is always the product of the elements in <see cref="Dimensions"/>. 131if (Dimensions.Length != tmp.Dimensions.Length) 133for (int i = 0; i < Dimensions.Length; i++) 135if (Dimensions[i] != tmp.Dimensions[i]) 149hash = Hashing.CombineHash(hash, Dimensions.Length); 150for (int i = 0; i < Dimensions.Length; i++) 151hash = Hashing.CombineHash(hash, Dimensions[i].GetHashCode()); 160if (Dimensions.Length == 1) 167foreach (var dim in Dimensions)
Microsoft.ML.ImageAnalytics (1)
ImagePixelExtractor.cs (1)
309var dims = type.Dimensions;
Microsoft.ML.Mkl.Components (1)
VectorWhitening.cs (1)
224if ((vectorType != null && !vectorType.IsKnownSize && vectorType.Dimensions.Length > 1)
Microsoft.ML.OnnxConverter (2)
OnnxUtils.cs (2)
374for (int i = 0; i < vec.Dimensions.Length; i++) 375dimsLocal.Add(vec.Dimensions[i]);
Microsoft.ML.Samples (2)
Dynamic\TensorFlow\TextClassification.cs (2)
68featuresType.ItemType.RawType, featuresType.Dimensions[0]); 74predictionType.Dimensions[0]);
Microsoft.ML.Samples.GPU (2)
docs\samples\Microsoft.ML.Samples\Dynamic\TensorFlow\TextClassification.cs (2)
68featuresType.ItemType.RawType, featuresType.Dimensions[0]); 74predictionType.Dimensions[0]);
Microsoft.ML.TensorFlow (2)
TensorflowTransform.cs (2)
572var colTypeDims = vecType.Dimensions.Select(dim => (int)dim).ToArray(); 582var colTypeDims = vecType.Dimensions.Select(dim => (int)dim).ToArray();
Microsoft.ML.TensorFlow.Tests (15)
TensorFlowEstimatorTests.cs (2)
243var imageHeight = type.Dimensions[0]; 244var imageWidth = type.Dimensions[1];
TensorflowTests.cs (13)
583Assert.Equal(2, type.Dimensions.Length); 584Assert.Equal(28, type.Dimensions[0]); 585Assert.Equal(28, type.Dimensions[1]); 597Assert.Equal(new[] { 5, 5, 1, 32 }, type.Dimensions); 612Assert.Equal(new[] { 28, 28, 32 }, type.Dimensions); 627Assert.Equal(new[] { 10 }, type.Dimensions); 646Assert.Equal(new[] { 2, 2 }, type.Dimensions); 1006var imageHeight = type.Dimensions[0]; 1007var imageWidth = type.Dimensions[1]; 1065var imageHeight = type.Dimensions[0]; 1066var imageWidth = type.Dimensions[1]; 1109var imageHeight = type.Dimensions[0]; 1110var imageWidth = type.Dimensions[1];
Microsoft.ML.Tests (2)
Transformers\NormalizerTests.cs (2)
1063var dimensions1 = (transformedData.Schema["output"].Type as VectorDataViewType).Dimensions; 1064var dimensions2 = (transformedData2.Schema["output"].Type as VectorDataViewType).Dimensions;
Microsoft.ML.Transforms (8)
KeyToVectorMapping.cs (2)
244var slotNamesType = new VectorDataViewType(TextDataViewType.Instance, _types[iinfo].Dimensions); 262var slotNamesType = new VectorDataViewType(TextDataViewType.Instance, _types[iinfo].Dimensions);
MissingValueIndicatorTransform.cs (1)
145types[iinfo] = new VectorDataViewType(NumberDataViewType.Single, vectorType.Dimensions.Add(2));
MissingValueIndicatorTransformer.cs (2)
197outType = new VectorDataViewType(BooleanDataViewType.Instance, vectorType.Dimensions); 548new VectorDataViewType(BooleanDataViewType.Instance, vectorType.Dimensions);
MissingValueReplacing.cs (3)
295type = new VectorDataViewType(vectorType.ItemType, vectorType.Dimensions); 569vectorType = new VectorDataViewType(vectorType.ItemType, vectorType.Dimensions); 1052new VectorDataViewType(vectorType.ItemType, vectorType.Dimensions);
Microsoft.ML.Vision (4)
DnnRetrainTransform.cs (4)
246var colTypeDims = new int[vecType.Dimensions.Length + 1]; 248for (int indexLocal = 0; indexLocal < vecType.Dimensions.Length; indexLocal += 1) 249colTypeDims[indexLocal + 1] = vecType.Dimensions[indexLocal]; 793var colTypeDims = vecType.Dimensions.Select(dim => (int)dim).ToArray();