При запуске модели, обученной обнаружению объектов, у меня не хватает памяти при вызове tf.run ()
2018-06-26 18:32:16.914049: W tensorflow/core/common_runtime/bfc_allocator.cc:219] Allocator (GPU_0_bfc) ran out of memory trying to allocate 2.55GiB. The caller indicates that this is not a failure, but may mean that there could be performance gains if more memory were available.
2018-06-26 18:32:17.393037: W tensorflow/core/common_runtime/bfc_allocator.cc:219] Allocator (GPU_0_bfc) ran out of memory trying to allocate 2.31GiB. The caller indicates that this is not a failure, but may mean that there could be performance gains if more memory were available.
2018-06-26 18:32:23.825495: W tensorflow/core/common_runtime/bfc_allocator.cc:219] Allocator (GPU_0_bfc) ran out of memory trying to allocate 2.31GiB. The caller indicates that this is not a failure, but may mean that there could be performance gains if more memory were available.
2018-06-26 18:32:24.659582: W tensorflow/core/common_runtime/bfc_allocator.cc:219] Allocator (GPU_0_bfc) ran out of memory trying to allocate 3.11GiB. The caller indicates that this is not a failure, but may mean that there could be performance gains if more memory were available.
2018-06-26 18:32:29.902840: W tensorflow/core/common_runtime/bfc_allocator.cc:219] Allocator (GPU_0_bfc) ran out of memory trying to allocate 2.20GiB. The caller indicates that this is not a failure, but may mean that there could be performance gains if more memory were available.
2018-06-26 18:32:30.955526: W tensorflow/core/common_runtime/bfc_allocator.cc:219] Allocator (GPU_0_bfc) ran out of memory trying to allocate 2.29GiB. The caller indicates that this is not a failure, but may mean that there could be performance gains if more memory were available.
2018-06-26 18:32:37.434223: W tensorflow/core/framework/op_kernel.cc:1328] OP_REQUIRES failed at where_op.cc:286 : Internal: WhereOp: Could not launch cub::DeviceReduce::Sum to count number of true / nonzero indices. temp_storage_bytes: 1, status: too many resources requested for launch
Существует ли какой-то процесс обучения модели, чтобы гарантировать, что модели не требуется большой объем оперативной памяти для вывода?
Есть ли какой-нибудь способ, которым я могу преобразовать свою модель, чтобы использовать меньше памяти?
Я пробовал некоторые графические преобразования, но, похоже, они мало что сделали.
Я также установил ограничение GPU равным 40% от оперативной памяти, но это тоже не помогло.
У меня должно быть около 4-5 ГБ оперативной памяти.
Это основные проблемы, которые, я думаю, у меня могут быть.
1) Модель, которая была обучена с начала V3 вместо мобильной модели.
2) Изображения некоторого большого размера были помечены и использованы для трансферного обучения.
-EDIT По-видимому, это связано с плохим распределением памяти с тензорным потоком и Cuda на архитектурах ARM.