306 references to GetColumnOrNull
DnnAnalyzer (2)
DnnAnalyzer.cs (2)
40var metadataType = schema[i].Annotations.Schema.GetColumnOrNull("TensorflowOperatorType")?.Type; 43metadataType = schema[i].Annotations.Schema.GetColumnOrNull("TensorflowUpstreamOperators")?.Type;
Microsoft.ML.AutoML (4)
ColumnInference\ColumnInferenceValidationUtil.cs (1)
20if (dataView.Schema.GetColumnOrNull(columnName) == null)
ColumnInference\ColumnTypeInference.cs (1)
277var column = cursor.Schema.GetColumnOrNull("C").Value;
Utils\UserInputValidationUtil.cs (2)
214var validCol = validationData.Schema.GetColumnOrNull(trainCol.Name); 249var nullableColumn = trainData.Schema.GetColumnOrNull(columnName);
Microsoft.ML.AutoML.Tests (1)
TransformInferenceTests.cs (1)
784var featuresCol = data.Schema.GetColumnOrNull(DefaultColumnNames.Features);
Microsoft.ML.Core (10)
Data\AnnotationUtils.cs (6)
226var columnType = schema[col].Annotations.Schema.GetColumnOrNull(annotationKind)?.Type; 250var columnType = schema[col].Annotations.Schema.GetColumnOrNull(annotationKind)?.Type; 269var columnType = schema[col].Annotations.Schema.GetColumnOrNull(annotationKind)?.Type; 290var metaColumn = column.Annotations.Schema.GetColumnOrNull(Kinds.SlotNames); 363var annotationType = schema[col].Annotations.Schema.GetColumnOrNull(kind)?.Type; 388var type = schema[colIndex].Annotations.Schema.GetColumnOrNull(Kinds.CategoricalSlotRanges)?.Type;
Data\RoleMappedSchema.cs (1)
225var info = schema.GetColumnOrNull(kvp.Value);
Data\SchemaExtensions.cs (2)
21/// DO NOT USE: use <see cref="DataViewSchema.GetColumnOrNull"/> instead. 25col = schema.GetColumnOrNull(name)?.Index ?? -1;
EntryPoints\EntryPointUtils.cs (1)
114if (schema.GetColumnOrNull(value) == null)
Microsoft.ML.Core.Tests (125)
UnitTests\TestEntryPoints.cs (125)
472var scoreColumn = curs1.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 476scoreColumn = curs2.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 480scoreColumn = curs3.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 487scoreColumn = curs4.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score + i); 746Assert.NotNull(loadedData.Schema.GetColumnOrNull("FeatureName")); 747Assert.NotNull(loadedData.Schema.GetColumnOrNull("AreaUnderRocCurve")); 748Assert.NotNull(loadedData.Schema.GetColumnOrNull("Accuracy")); 749Assert.NotNull(loadedData.Schema.GetColumnOrNull("PositivePrecision")); 750Assert.NotNull(loadedData.Schema.GetColumnOrNull("PositiveRecall")); 751Assert.NotNull(loadedData.Schema.GetColumnOrNull("NegativePrecision")); 752Assert.NotNull(loadedData.Schema.GetColumnOrNull("NegativeRecall")); 753Assert.NotNull(loadedData.Schema.GetColumnOrNull("F1Score")); 754Assert.NotNull(loadedData.Schema.GetColumnOrNull("AreaUnderPrecisionRecallCurve")); 755Assert.NotNull(loadedData.Schema.GetColumnOrNull("AreaUnderRocCurveStdErr")); 756Assert.NotNull(loadedData.Schema.GetColumnOrNull("AccuracyStdErr")); 757Assert.NotNull(loadedData.Schema.GetColumnOrNull("PositivePrecisionStdErr")); 758Assert.NotNull(loadedData.Schema.GetColumnOrNull("PositiveRecallStdErr")); 759Assert.NotNull(loadedData.Schema.GetColumnOrNull("NegativePrecisionStdErr")); 760Assert.NotNull(loadedData.Schema.GetColumnOrNull("NegativeRecallStdErr")); 761Assert.NotNull(loadedData.Schema.GetColumnOrNull("F1ScoreStdErr")); 762Assert.NotNull(loadedData.Schema.GetColumnOrNull("AreaUnderPrecisionRecallCurveStdErr")); 894Assert.NotNull(loadedData.Schema.GetColumnOrNull("FeatureName")); 895Assert.NotNull(loadedData.Schema.GetColumnOrNull("MacroAccuracy")); 896Assert.NotNull(loadedData.Schema.GetColumnOrNull("MicroAccuracy")); 897Assert.NotNull(loadedData.Schema.GetColumnOrNull("LogLoss")); 898Assert.NotNull(loadedData.Schema.GetColumnOrNull("LogLossReduction")); 899Assert.NotNull(loadedData.Schema.GetColumnOrNull("TopKAccuracy")); 900Assert.NotNull(loadedData.Schema.GetColumnOrNull("PerClassLogLoss")); 901Assert.NotNull(loadedData.Schema.GetColumnOrNull("MacroAccuracyStdErr")); 902Assert.NotNull(loadedData.Schema.GetColumnOrNull("MicroAccuracyStdErr")); 903Assert.NotNull(loadedData.Schema.GetColumnOrNull("LogLossStdErr")); 904Assert.NotNull(loadedData.Schema.GetColumnOrNull("LogLossReductionStdErr")); 905Assert.NotNull(loadedData.Schema.GetColumnOrNull("TopKAccuracyStdErr")); 906Assert.NotNull(loadedData.Schema.GetColumnOrNull("PerClassLogLossStdErr")); 1055Assert.NotNull(loadedData.Schema.GetColumnOrNull("FeatureName")); 1056Assert.NotNull(loadedData.Schema.GetColumnOrNull("MacroAccuracy")); 1057Assert.NotNull(loadedData.Schema.GetColumnOrNull("MicroAccuracy")); 1058Assert.NotNull(loadedData.Schema.GetColumnOrNull("LogLoss")); 1059Assert.NotNull(loadedData.Schema.GetColumnOrNull("LogLossReduction")); 1060Assert.NotNull(loadedData.Schema.GetColumnOrNull("TopKAccuracy")); 1061Assert.NotNull(loadedData.Schema.GetColumnOrNull("PerClassLogLoss")); 1062Assert.NotNull(loadedData.Schema.GetColumnOrNull("MacroAccuracyStdErr")); 1063Assert.NotNull(loadedData.Schema.GetColumnOrNull("MicroAccuracyStdErr")); 1064Assert.NotNull(loadedData.Schema.GetColumnOrNull("LogLossStdErr")); 1065Assert.NotNull(loadedData.Schema.GetColumnOrNull("LogLossReductionStdErr")); 1066Assert.NotNull(loadedData.Schema.GetColumnOrNull("TopKAccuracyStdErr")); 1067Assert.NotNull(loadedData.Schema.GetColumnOrNull("PerClassLogLossStdErr")); 1198Assert.NotNull(loadedData.Schema.GetColumnOrNull("FeatureName")); 1199Assert.NotNull(loadedData.Schema.GetColumnOrNull("MeanAbsoluteError")); 1200Assert.NotNull(loadedData.Schema.GetColumnOrNull("MeanSquaredError")); 1201Assert.NotNull(loadedData.Schema.GetColumnOrNull("RootMeanSquaredError")); 1202Assert.NotNull(loadedData.Schema.GetColumnOrNull("LossFunction")); 1203Assert.NotNull(loadedData.Schema.GetColumnOrNull("RSquared")); 1204Assert.NotNull(loadedData.Schema.GetColumnOrNull("MeanAbsoluteErrorStdErr")); 1205Assert.NotNull(loadedData.Schema.GetColumnOrNull("MeanSquaredErrorStdErr")); 1206Assert.NotNull(loadedData.Schema.GetColumnOrNull("RootMeanSquaredErrorStdErr")); 1207Assert.NotNull(loadedData.Schema.GetColumnOrNull("LossFunctionStdErr")); 1208Assert.NotNull(loadedData.Schema.GetColumnOrNull("RSquaredStdErr")); 1345Assert.NotNull(loadedData.Schema.GetColumnOrNull("FeatureName")); 1346Assert.NotNull(loadedData.Schema.GetColumnOrNull("DiscountedCumulativeGains")); 1347Assert.NotNull(loadedData.Schema.GetColumnOrNull("NormalizedDiscountedCumulativeGains")); 1348Assert.NotNull(loadedData.Schema.GetColumnOrNull("DiscountedCumulativeGainsStdErr")); 1349Assert.NotNull(loadedData.Schema.GetColumnOrNull("NormalizedDiscountedCumulativeGainsStdErr")); 1442Assert.NotNull(loadedData.Schema.GetColumnOrNull("PredictedLabel")); 1443Assert.NotNull(loadedData.Schema.GetColumnOrNull("Score")); 1631var scoreCol = binaryScored.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1633var type = binaryScored.Schema[scoreCol.Value.Index].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreColumnKind)?.Type; 1640scoreCol = regressionScored.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1648scoreCol = anomalyScored.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1684var scoreColumn = curs0.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1687scoreColumn = curs1.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1690scoreColumn = curs2.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1693scoreColumn = curs3.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1696scoreColumn = curs4.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1699scoreColumn = cursReg.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1702scoreColumn = cursBin.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1705scoreColumn = cursBinCali.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1708scoreColumn = cursSaved.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1711scoreColumn = cursAnom.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1910var scoreColumn = curs0.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1913scoreColumn = curs1.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1916scoreColumn = curs2.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1919scoreColumn = curs3.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1922scoreColumn = curs4.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1925scoreColumn = cursReg.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1928scoreColumn = cursBin.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1931scoreColumn = cursBinCali.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 1934scoreColumn = cursSaved.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 2068var scoreColumn = curs0.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 2071scoreColumn = curs1.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 2074scoreColumn = curs2.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 2077scoreColumn = curs3.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 2080scoreColumn = curs4.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 2083scoreColumn = curs.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 2086scoreColumn = cursSaved.Schema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 2534var catColumn = loader.Schema.GetColumnOrNull("Cat"); 2537var catValueCol = loader.Schema.GetColumnOrNull("CatValue"); 2540var keyColumn = loader.Schema.GetColumnOrNull("Key"); 2781Assert.NotNull(loader.Schema.GetColumnOrNull("GroupId")); 2782Assert.NotNull(loader.Schema.GetColumnOrNull("Label")); 3617var aucCol = cursor.Schema.GetColumnOrNull("AUC"); 3722var aucCol = cursor.Schema.GetColumnOrNull("AUC"); 3889var aucCol = cursor.Schema.GetColumnOrNull("AUC"); 4080var aucColumn = cursor.Schema.GetColumnOrNull("AUC"); 4424var predictedLabelCol = loader.Schema.GetColumnOrNull("PredictedLabel"); 4480var treesCol = view.Schema.GetColumnOrNull("Trees"); 4483var leavesCol = view.Schema.GetColumnOrNull("Leaves"); 4486var pathsCol = view.Schema.GetColumnOrNull("Paths"); 4544var featColumn = result.Schema.GetColumnOrNull("Features"); 4999var aucCol = schema.GetColumnOrNull("AUC"); 5173var metricCol = schema.GetColumnOrNull("L1(avg)"); 5175var foldCol = schema.GetColumnOrNull("Fold Index"); 5177var isWeightedCol = schema.GetColumnOrNull("IsWeighted"); 5357var metricCol = schema.GetColumnOrNull("Accuracy(micro-avg)"); 5359var foldCol = schema.GetColumnOrNull("Fold Index"); 5402var countCol = schema.GetColumnOrNull("Count"); 5404foldCol = schema.GetColumnOrNull("Fold Index"); 5585var warningCol = schema.GetColumnOrNull("WarningText"); 5765var metricCol = schema.GetColumnOrNull("AUC"); 5767var foldCol = schema.GetColumnOrNull("Fold Index"); 6065var metricCol = schema.GetColumnOrNull("NDCG"); 6067var foldCol = schema.GetColumnOrNull("Fold Index"); 6120var nameCol = data.Schema.GetColumnOrNull("Instance"); 6284var accCol = schema.GetColumnOrNull(MulticlassClassificationEvaluator.AccuracyMacro); 6456var accCol = schema.GetColumnOrNull(MulticlassClassificationEvaluator.AccuracyMacro);
Microsoft.ML.Data (70)
Commands\ShowSchemaCommand.cs (1)
156if ((typeNames = schema[col].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type) == null)
Data\SchemaAnnotationsExtensions.cs (2)
57var metaColumn = column.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues); 82var metaColumn = column.Annotations.Schema.GetColumnOrNull((AnnotationUtils.Kinds.IsNormalized));
DataLoadSave\Text\TextSaver.cs (2)
167&& (typeNames = cursor.Schema[source].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType) != null 422var typeNames = data.Schema[cols[i]].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType;
Evaluators\AnomalyDetectionEvaluator.cs (4)
672DataViewSchema.Column? column = top.Schema.GetColumnOrNull(AnomalyDetectionEvaluator.TopKResultsColumns.Instance); 677column = top.Schema.GetColumnOrNull(AnomalyDetectionEvaluator.TopKResultsColumns.AnomalyScore); 682column = top.Schema.GetColumnOrNull(AnomalyDetectionEvaluator.TopKResultsColumns.Label); 716DataViewSchema.Column? numAnom = overall.Schema.GetColumnOrNull(AnomalyDetectionEvaluator.OverallMetrics.NumAnomalies);
Evaluators\BinaryClassifierEvaluator.cs (5)
178labelCol.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type is VectorDataViewType vecType && 915var thresholdColumn = prCurveView.Schema.GetColumnOrNull(BinaryClassifierEvaluator.Threshold); 916var precisionColumn = prCurveView.Schema.GetColumnOrNull(BinaryClassifierEvaluator.Precision); 917var recallColumn = prCurveView.Schema.GetColumnOrNull(BinaryClassifierEvaluator.Recall); 918var fprColumn = prCurveView.Schema.GetColumnOrNull(BinaryClassifierEvaluator.FalsePositiveRate);
Evaluators\EvaluatorBase.cs (1)
416var col = row.Schema.GetColumnOrNull(ColName);
Evaluators\EvaluatorUtils.cs (19)
87var columnType = schema[col].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreColumnKind)?.Type; 99var columnType = schema[col].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreColumnKind)?.Type; 121var col = schema.GetColumnOrNull(name); 142if (col.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreValueKind)?.Type == TextDataViewType.Instance) 150if (!string.IsNullOrWhiteSpace(defName) && schema.GetColumnOrNull(defName) is DataViewSchema.Column defCol) 176var col = schema.GetColumnOrNull(name); 186var type = schema[colScore].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreColumnSetId)?.Type; 203if (col.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreValueKind)?.Type == TextDataViewType.Instance) 222var type = schema[col].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreColumnKind)?.Type; 353var slotNamesType = schema[i].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType; 569var keyValueType = schema[indices[i]].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type; 867labelColKeyValuesType = dv.Schema[i].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type; 1027var slotNamesType = schema[i].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType; 1084var isWeightedColumn = data.Schema.GetColumnOrNull(MetricKinds.ColumnNames.IsWeighted); 1236var keyValuesType = schema[i].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType; 1362var weightColumn = confusionDataView.Schema.GetColumnOrNull(MetricKinds.ColumnNames.Weight); 1386var weightColumn = confusionDataView.Schema.GetColumnOrNull(MetricKinds.ColumnNames.Weight); 1392var type = countColumn.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType; 1736var warningTextColumn = warnings.Schema.GetColumnOrNull(MetricKinds.ColumnNames.WarningText);
Evaluators\Metrics\BinaryClassificationMetrics.cs (1)
90var column = row.Schema.GetColumnOrNull(name);
Evaluators\Metrics\RankingMetrics.cs (1)
51var column = row.Schema.GetColumnOrNull(name);
Evaluators\MulticlassClassificationEvaluator.cs (1)
101var mdType = schema.Schema[scoreInfo.Index].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType;
Evaluators\MultiOutputRegressionEvaluator.cs (2)
595var type = schema[column].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type; 668var isWeightedCol = fold.Schema.GetColumnOrNull(MetricKinds.ColumnNames.IsWeighted);
Evaluators\QuantileRegressionEvaluator.cs (2)
47var type = schema.Schema[scoreInfo.Index].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType; 74var slotNamesType = schema.Schema[scoreInfo.Index].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType;
Prediction\Calibrator.cs (1)
956var weightCol = weightColumn == null ? null : scored.Schema.GetColumnOrNull(weightColumn);
Prediction\CalibratorCatalog.cs (4)
256_scoreColIndex = inputSchema.GetColumnOrNull(_scoreColumnName)?.Index ?? -1; 287if (schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreColumnSetId) is DataViewSchema.Column setIdCol && 289schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreColumnKind) is DataViewSchema.Column kindCol && 291schema.GetColumnOrNull(AnnotationUtils.Kinds.ScoreValueKind) is DataViewSchema.Column valueKindCol &&
Scorers\BinaryClassifierScorer.cs (4)
67var keyType = trainSchema.Label.Value.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType; 99if (mapper.OutputSchema[scoreIdx].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.TrainingLabelValues)?.Type != null) 115var type = labelColumn.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType; 219var predictedLabelCol = OutputSchema.GetColumnOrNull(outColumnNames[0]);
Scorers\MulticlassClassificationScorer.cs (4)
417var keyType = trainSchema.Label.Value.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType; 456var scoreCol = outSchema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 459if (outSchema[scoreIdx].Annotations.Schema.GetColumnOrNull(metaKind)?.Type != null) 493var type = trainSchema.Label.Value.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type;
Scorers\PredictedLabelScorerBase.cs (2)
74var trainLabelColumn = scoreColMetadata.Schema.GetColumnOrNull(AnnotationUtils.Kinds.TrainingLabelValues); 233var mcol = _predColMetadata.Schema.GetColumnOrNull(kind);
Scorers\RowToRowScorerBase.cs (1)
452return Mapper.OutputSchema[iinfo - DerivedColumnCount].Annotations.Schema.GetColumnOrNull(kind)?.Type;
Transforms\ColumnBindingsBase.cs (1)
529return Input[index].Annotations.Schema.GetColumnOrNull(kind)?.Type;
Transforms\Hashing.cs (1)
202DataViewSchema.Column? srcCol = input.Schema.GetColumnOrNull(ColumnPairs[i].inputColumnName);
Transforms\KeyToValue.cs (1)
230var typeVals = schema[ColMapNewToOld[iinfo]].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type;
Transforms\KeyToVector.cs (2)
313var keyValuesColumn = inputMetadata.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues); 379var typeSlotSrc = inputMetadata.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType;
Transforms\MetadataDispatcher.cs (1)
268return info.SchemaSrc[info.IndexSrc].Annotations.Schema.GetColumnOrNull(kind)?.Type;
Transforms\ValueMapping.cs (4)
446column = dataView.Schema.GetColumnOrNull(keyColumn.Name); 454column = dataView.Schema.GetColumnOrNull(valueColumn.Name); 992if (!schema.GetColumnOrNull(keyColumn).HasValue) 994if (!schema.GetColumnOrNull(valueColumn).HasValue)
Transforms\ValueToKeyMappingTransformer.cs (1)
455if (keyData.Schema.GetColumnOrNull(src) == null)
Transforms\ValueToKeyMappingTransformerImpl.cs (2)
1098VectorDataViewType srcMetaType = _schema[srcCol].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType; 1179VectorDataViewType srcMetaType = _schema[srcCol].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType;
Microsoft.ML.DataView (1)
DataViewSchema.cs (1)
239var column = Schema.GetColumnOrNull(kind);
Microsoft.ML.Ensemble (4)
PipelineEnsemble.cs (4)
55var col = InputRoleMappedSchema.Schema.GetColumnOrNull(name); 77var scoreCol = Mappers[i].OutputSchema.GetColumnOrNull(AnnotationUtils.Const.ScoreValueKind.Score); 608var mdType = labelCol.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType; 669var mdType = labelCol.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type;
Microsoft.ML.EntryPoints (5)
FeatureCombiner.cs (5)
120var col = schema.GetColumnOrNull(colName); 123var type = col.Value.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType; 235var labelCol = input.Data.Schema.GetColumnOrNull(input.LabelColumn); 271var predictedLabelCol = input.Data.Schema.GetColumnOrNull(input.PredictedLabelColumn); 293var labelCol = input.Data.Schema.GetColumnOrNull(input.LabelColumn);
Microsoft.ML.FastTree (1)
TreeEnsembleFeaturizer.cs (1)
799var col = input.Schema.GetColumnOrNull(labelName);
Microsoft.ML.IntegrationTests (11)
IntrospectiveTraining.cs (1)
316var column = currentSchema.GetColumnOrNull(expectedColumn);
ModelFiles.cs (10)
368loadedSchema.GetColumnOrNull("Label") != null 369&& loadedSchema.GetColumnOrNull("Features") != null 376schema.GetColumnOrNull("Label") != null 377&& schema.GetColumnOrNull("Features") != null 404Assert.NotNull(expectedSchema.GetColumnOrNull("Label")); 405Assert.NotNull(expectedSchema.GetColumnOrNull("Features")); 433Assert.NotNull(expectedInputSchema.GetColumnOrNull("Label")); 434Assert.NotNull(expectedInputSchema.GetColumnOrNull("Features")); 469loadedSchema.GetColumnOrNull("Label") != null 470&& loadedSchema.GetColumnOrNull("Features") != null
Microsoft.ML.Mkl.Components (1)
VectorWhitening.cs (1)
286var col = inputSchema.GetColumnOrNull(columns[i].InputColumnName);
Microsoft.ML.OnnxConverter (2)
SaveOnnxCommand.cs (2)
251var metaColumn = column.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues); 364var predictedLabelColumn = scorePipe.Schema.GetColumnOrNull(DefaultColumnNames.PredictedLabel);
Microsoft.ML.OnnxTransformer (1)
OnnxTransform.cs (1)
531var col = inputSchema.GetColumnOrNull(_parent.Inputs[i]);
Microsoft.ML.PerformanceTests (1)
CacheDataViewBench.cs (1)
39var col = cacheDv.Schema.GetColumnOrNull("A").Value;
Microsoft.ML.Predictor.Tests (6)
TestPredictors.cs (6)
675var scoreColumn = scored.Schema.GetColumnOrNull("Score"); 677var probabilityColumn = scored.Schema.GetColumnOrNull("Probability"); 679var predictedLabelColumn = scored.Schema.GetColumnOrNull("PredictedLabel"); 691scoreColArray[i] = scoredArray[i].Schema.GetColumnOrNull("Score"); 693probColArray[i] = scoredArray[i].Schema.GetColumnOrNull("Probability"); 695predColArray[i] = scoredArray[i].Schema.GetColumnOrNull("PredictedLabel");
Microsoft.ML.Samples (1)
Dynamic\DataOperations\LoadingText.cs (1)
102var featuresColumn = dataWithInferredLength.Schema.GetColumnOrNull("Features");
Microsoft.ML.StandardTrainers (1)
Standard\LogisticRegression\MulticlassLogisticRegression.cs (1)
182var labelMetadataType = labelCol.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type;
Microsoft.ML.TensorFlow.Tests (9)
TensorflowTests.cs (9)
593metadataType = schema[col].Annotations.Schema.GetColumnOrNull(TensorFlowUtils.TensorflowUpstreamOperatorsKind)?.Type; 1375Assert.True(schema.GetColumnOrNull("input1").HasValue); 1376Assert.True(schema.GetColumnOrNull("input1").Value.Type is TextDataViewType); 1377Assert.True(schema.GetColumnOrNull("input2").HasValue); 1378Assert.True(schema.GetColumnOrNull("input2").Value.Type is TextDataViewType); 1577var labelColumnFirst = schema.GetColumnOrNull("Label").Value; 1580var labelColumnSecond = schema.GetColumnOrNull("Label").Value; 1736var labelColumnFirst = schema.GetColumnOrNull("Label").Value; 1739var labelColumnSecond = schema.GetColumnOrNull("Label").Value;
Microsoft.ML.TestFramework (10)
DataPipe\TestDataPipe.cs (8)
222var col = c.Schema.GetColumnOrNull(cols[i]); 578var col1 = c.Schema.GetColumnOrNull("F13"); 581var col2 = c.Schema.GetColumnOrNull("F23"); 620var col1 = c.Schema.GetColumnOrNull("F1"); 623var col2 = c.Schema.GetColumnOrNull("F2"); 774var col1 = c.Schema.GetColumnOrNull("WB1"); 775var col2 = c.Schema.GetColumnOrNull("WB2"); 921var col = c.Schema.GetColumnOrNull("T");
DataPipe\TestDataPipeBase.cs (2)
476var typeSlot = sch[col].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type; 477var typeKeys = sch[col].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type;
Microsoft.ML.TestFrameworkCommon (3)
TestCommon.cs (3)
228col = schema.GetColumnOrNull(name)?.Index ?? -1; 237var t1 = sch1[col].Annotations.Schema.GetColumnOrNull(kind)?.Type; 238var t2 = sch2[col].Annotations.Schema.GetColumnOrNull(kind)?.Type;
Microsoft.ML.Tests (13)
Scenarios\Api\Estimators\PredictAndMetadata.cs (2)
92Assert.NotNull(scoredData.Schema["Score"].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)); 126Assert.Null(scoredData2.Schema["Score"].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames));
Scenarios\Api\TestApi.cs (2)
486Assert.NotNull(split.TrainSet.Schema.GetColumnOrNull("KeyStrat")); // Check that the key column used as SamplingKeyColumn wasn't deleted by the split 508Assert.NotNull(split.TrainSet.Schema.GetColumnOrNull(colname));
TextLoaderTests.cs (8)
598Assert.NotNull(data.Schema.GetColumnOrNull("Label")); 599Assert.NotNull(data.Schema.GetColumnOrNull("Features")); 602Assert.NotNull(data2.Schema.GetColumnOrNull("String1")); 603Assert.NotNull(data2.Schema.GetColumnOrNull("Number1")); 613Assert.NotNull(data.Schema.GetColumnOrNull("Label")); 614Assert.NotNull(data.Schema.GetColumnOrNull("Workclass")); 615Assert.NotNull(data.Schema.GetColumnOrNull("Categories")); 616Assert.NotNull(data.Schema.GetColumnOrNull("NumericFeatures"));
Transformers\TextFeaturizerTests.cs (1)
663var featureColumn = result.Schema.GetColumnOrNull("Features");
Microsoft.ML.TimeSeries (1)
SeasonalityDetector.cs (1)
63var column = input.Schema.GetColumnOrNull(inputColumnName);
Microsoft.ML.TorchSharp (5)
AutoFormerV2\ObjectDetectionTrainer.cs (2)
181var labelCol = input.Schema.GetColumnOrNull(Option.LabelColumnName); 755var keyType = _parent.LabelColumn.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType;
NasBert\NasBertTrainer.cs (2)
520var keyType = Parent.LabelColumn.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType; 542var keyType = Parent.LabelColumn.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues)?.Type as VectorDataViewType;
TorchSharpBaseTrainer.cs (1)
118var labelCol = input.Schema.GetColumnOrNull(Option.LabelColumnName);
Microsoft.ML.Transforms (17)
Dracula\CountTableTransformer.cs (3)
131var labelCol = input.Schema.GetColumnOrNull(_labelColumnName); 145var col = input.Schema.GetColumnOrNull(_columns[i].InputColumnName); 163var col = input.Schema.GetColumnOrNull(c.InputColumnName);
ExpressionTransformer.cs (1)
139var col = inputSchema.GetColumnOrNull(inputColumnNames[isrc]);
GroupTransform.cs (1)
351var retrievedColumn = schema.GetColumnOrNull(names[i]);
KeyToVectorMapping.cs (1)
295typeSlotSrc = inputMetadata.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType;
MissingValueIndicatorTransform.cs (2)
150(typeNames = Source.Schema[Infos[iinfo].Source].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType) == null || 199var typeNames = Source.Schema[Infos[iinfo].Source].Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.SlotNames)?.Type as VectorDataViewType;
SvmLight\SvmLightLoader.cs (3)
582var keyCol = _keyVectorsToIndexVectors.GetOutputSchema(data.Schema).GetColumnOrNull(nameof(Indices.FeatureKeys)); 677var col = view.Schema.GetColumnOrNull(nameof(IntermediateInput.FeatureKeys)); 728var keyValuesCol = col.Annotations.Schema.GetColumnOrNull(AnnotationUtils.Kinds.KeyValues);
SvmLight\SvmLightSaver.cs (4)
98var labelCol = data.Schema.GetColumnOrNull(_labelCol); 102var featureCol = data.Schema.GetColumnOrNull(_featureCol); 106var groupCol = !string.IsNullOrWhiteSpace(_groupCol) ? data.Schema.GetColumnOrNull(_groupCol) : default; 110var weightCol = !string.IsNullOrWhiteSpace(_weightCol) ? data.Schema.GetColumnOrNull(_weightCol) : default;
Text\WordBagTransform.cs (2)
303ValueGetter<ReadOnlyMemory<char>> srcGetter = input.GetGetter<ReadOnlyMemory<char>>(input.Schema.GetColumnOrNull(_parent._columnName).Value); 335active[InputSchema.GetColumnOrNull(_parent._columnName).Value.Index] = true;
Microsoft.ML.Vision (1)
ImageClassificationTrainer.cs (1)
600var labelColumn = input.Schema.GetColumnOrNull(_options.LabelColumnName).Value;