From 143725604e05062f653c0a5d5bd20a00284b5ebe Mon Sep 17 00:00:00 2001 From: Yi Zhang Date: Sat, 22 Oct 2022 13:54:24 +0800 Subject: [PATCH] Skip some models failed in Windows CPU C# tests (#13395) ### Description For models from model zoo, in C# tests of Windows CPU CI skip models whose name contains int8 or qdq. skip some models (VGG16, VGG19) in x86 workflow ### Motivation and Context These models always failed in Windows CPU C# tests (https://dev.azure.com/onnxruntime/onnxruntime/_build/results?buildId=789442&view=results) ### verified https://dev.azure.com/onnxruntime/onnxruntime/_build/results?buildId=789861&view=results C# tests passed --- .../InferenceTest.netcore.cs | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/csharp/test/Microsoft.ML.OnnxRuntime.Tests.NetCoreApp/InferenceTest.netcore.cs b/csharp/test/Microsoft.ML.OnnxRuntime.Tests.NetCoreApp/InferenceTest.netcore.cs index 6da409c49c..81d6b344cf 100644 --- a/csharp/test/Microsoft.ML.OnnxRuntime.Tests.NetCoreApp/InferenceTest.netcore.cs +++ b/csharp/test/Microsoft.ML.OnnxRuntime.Tests.NetCoreApp/InferenceTest.netcore.cs @@ -409,6 +409,13 @@ namespace Microsoft.ML.OnnxRuntime.Tests skipModels["coreml_VGG16_ImageNet"] = "System out of memory"; skipModels["test_ssd"] = "System out of memory"; skipModels["roberta_sequence_classification"] = "System out of memory"; + // models from model zoo + skipModels["VGG 19"] = "bad allocation"; + skipModels["VGG 19-caffe2"] = "bad allocation"; + skipModels["VGG 19-bn"] = "bad allocation"; + skipModels["VGG 16"] = "bad allocation"; + skipModels["VGG 16-bn"] = "bad allocation"; + skipModels["VGG 16-fp32"] = "bad allocation"; } return skipModels; @@ -425,7 +432,11 @@ namespace Microsoft.ML.OnnxRuntime.Tests //var modelRoot = new DirectoryInfo(Path.Combine(modelsDir, opsetDir.Name)); foreach (var modelDir in opsetDir.EnumerateDirectories()) { +#if USE_CUDA if (!skipModels.ContainsKey(modelDir.Name)) +#else + if (!(skipModels.ContainsKey(modelDir.Name) || modelDir.Name.Contains("int8", StringComparison.OrdinalIgnoreCase) || modelDir.Name.Contains("qdq", StringComparison.OrdinalIgnoreCase))) +#endif { yield return new object[] { modelDir.Parent.FullName, modelDir.Name }; } @@ -443,7 +454,11 @@ namespace Microsoft.ML.OnnxRuntime.Tests { foreach (var modelDir in opsetDir.EnumerateDirectories()) { +#if USE_CUDA if (skipModels.ContainsKey(modelDir.Name)) +#else + if (skipModels.ContainsKey(modelDir.Name) || modelDir.Name.Contains("int8", StringComparison.OrdinalIgnoreCase) || modelDir.Name.Contains("qdq", StringComparison.OrdinalIgnoreCase)) +#endif { //Console.WriteLine("Model {0} is skipped due to the error: {1}", modelDir.FullName, skipModels[modelDir.Name]); yield return new object[] { modelDir.Parent.FullName, modelDir.Name };