New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
System.Runtime.InteropServices.SEHException (0x80004005): External component has thrown an exception. #225
Comments
@takuya-takeuchi LossMetric_operator_matrixs is invoked when inference. Thanks. |
The code:
The function " GetFeature" was invoked by multiple thread.By my understanding,the “shape_predictor_68_face_landmarks.dat” loaded once can improve the performance.I have tried to load the .dat for each image,the cpu can't support. |
In GetFeature, net.Operator is invoked from multiple thread, doesn't it? If so, this schenario is not be supported. You have to create FaceRecognitionEx instance for each thread. DlibDotNet.Dnn.LossMetric would not be slow operation different from face detection. |
Thank you very much!net.Operator invoked from multiple thread lead to the problem.I have sovled the problem. |
The exception is an accidental exception,but it makes the program crash. The following is the exception:
System.Runtime.InteropServices.SEHException (0x80004005): External component has thrown an exception.
at DlibDotNet.NativeMethods.LossMetric_operator_matrixs(Int32 id, IntPtr obj, MatrixElementType element_type, IntPtr[] matrix_array, Int32 matrix_array_len, Int32 templateRows, Int32 templateColumns, UInt32 batch_size, IntPtr& ret)
at DlibDotNet.Dnn.LossMetric.Operator[T](IEnumerable`1 images, UInt64 batchSize)
The initialization of ShapePredictor was written in the initialization of a class by singleton pattern.
I have scanned the related issues like #5,I have checked the model file full path(D:\RoomCX\VideoToPicture) , I also download the .dat files serveral times,the problem still exist.
Please let me know how i can correct this
Thanks
The text was updated successfully, but these errors were encountered: