dotnet / machinelearning-samples

Samples for ML.NET, an open source and cross-platform machine learning framework for .NET.
https://dot.net/ml
MIT License
4.49k stars 2.69k forks source link

[DetectSpikeBySsa] System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt. #1008

Open busra-cinar opened 1 year ago

busra-cinar commented 1 year ago

I get the following error when using ML.NET's DetectSpikeBySsa method. I run the project in a docker container running Kubernetes. I'm using the latest stable versions 2.0.1 of Microsoft.ML and Microsoft.ML.TimeSeries

<PackageReference Include="Microsoft.ML" Version="2.0.1" />
<PackageReference Include="Microsoft.ML.TimeSeries" Version="2.0.1" />

DetectSpikeBySsa

Fatal error. System.AccessViolationException: Attempted to read or write protected memory. This is often an indication that other memory is corrupt. at Microsoft.ML.Internal.CpuMath.AvxIntrinsics.MatMulTran(Microsoft.ML.Internal.CpuMath.AlignedArray, Microsoft.ML.Internal.CpuMath.AlignedArray, Microsoft.ML.Internal.CpuMath.AlignedArray, Int32, Int32) at Microsoft.ML.Transforms.TimeSeries.AdaptiveSingularSpectrumSequenceModelerInternal.Consume(Single ByRef, Boolean) at Microsoft.ML.Transforms.TimeSeries.SsaAnomalyDetectionBaseWrapper+SsaAnomalyDetectionBase+State.ComputeRawAnomalyScore(Single ByRef, Microsoft.ML.Internal.Utilities.FixedSizeQueue1<Single>, Int64) at Microsoft.ML.Transforms.TimeSeries.SequentialAnomalyDetectionTransformBase2+AnomalyDetectionStateBase[[System.Single, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].TransformCore(Single ByRef, Microsoft.ML.Internal.Utilities.FixedSizeQueue1<Single>, Int64, Microsoft.ML.Data.VBuffer1 ByRef) at Microsoft.ML.Transforms.LambdaTransform+<>cDisplayClass5_03[[System.__Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.__Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.__Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].<CreateMap>b__0(System.__Canon, System.__Canon, System.__Canon) at Microsoft.ML.Transforms.StatefulFilterTransform3+Cursor[[System.Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].RunLambda(Boolean ByRef) at Microsoft.ML.Transforms.StatefulFilterTransform`3+Cursor[[System.Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e],[System.Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].MoveNextCore() at Microsoft.ML.Data.RootCursorBase.MoveNext() at Microsoft.ML.PipeEngine1+<RunPipe>d__2[[System.__Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]].MoveNext() at System.Collections.Generic.List1[[System.Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e]]..ctor(System.Collections.Generic.IEnumerable`1<System.Canon>) at System.Linq.Enumerable.ToList[System.__Canon, System.Private.CoreLib, Version=6.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e] at