从后台运行到前台运行Coreml批次预测时崩溃

时间:2018-12-28 07:50:28

标签: coreml

这是我的代码:

id<MLBatchProvider> outBatch = [_model predictionsFromBatch:inBatch options:options error:error];

当应用程序位于前台时,我提交了批次预测,然后将其置于后台,然后将其置于前台,该应用程序崩溃了。

崩溃是:

  

最后的异常回溯:

     

0 CoreFoundation 0x00000001d427bea0   ___exceptionPreprocess + 228

     

1 libobjc.A.dylib 0x00000001d344da40   objc_exception_throw + 56

     

2 CoreFoundation 0x00000001d41f3470 _CFArgv + 0

     

3 CoreFoundation 0x00000001d4185f4c-[__ NSArrayM   setObject:atIndexedSubscript:] + 704

     

4个CoreML 0x00000001e31273d4   ___ 53- [MLNeuralNetworkEngine EvaluationBatch:options:error:] _ block_invoke.649 + 928

     

5 libdispatch.dylib 0x00000001d3cb56c8   __dispatch_call_block_and_release + 24

     

6 libdispatch.dylib 0x00000001d3cb6484   __dispatch_client_callout + 16

     

7 libdispatch.dylib 0x00000001d3c5dbe0   __dispatch_lane_serial_drain $ VARIANT $ mp + 592

     

8 libdispatch.dylib 0x00000001d3c5e75c   __dispatch_lane_invoke $ VARIANT $ mp + 484

     

9 libdispatch.dylib 0x00000001d3c66ec8   __dispatch_workloop_worker_thread + 600

     

10 libsystem_pthread.dylib 0x00000001d3e980dc _pthread_wqthread   + 300

     

11 libsystem_pthread.dylib 0x00000001d3e9acec _start_wqthread +   4

     

异常类型:NSRangeException(SIGABRT)

     

异常代码:***-[__ NSArrayM setObject:atIndexedSubscript:]:   空数组在0x00000001d3e13104的范围超出索引12   线程:65

0 个答案:

没有答案