首页 > 解决方案 > 预测数组为空 Mask RCNN

问题描述

我正在研究 Mask RCNN,我的预测数组是空的。我认为这与记忆有关。这就是我要求预测的代码:

model.eval()
with torch.no_grad():
prediction = model([img.to(device)], [target])

当我处于调试模式并评估表达式 model([img.to(device)], [target]) 时,我收到以下通知:

{RuntimeError}[enforce fail at CPUAllocator.cpp:64] . DefaultCPUAllocator: can't allocate memory: you 
tried to allocate 172738321924 bytes. Error code 12 (Cannot allocate memory). But when I run the code 
as a whole I do not get any errors, except that the predictions are empty. 

标签: neural-networkconv-neural-networkmaskfaster-rcnn

解决方案


推荐阅读