CPC G06F 12/023 (2013.01) [G06N 3/08 (2013.01)] | 17 Claims |
1. A video memory management method, comprising:
determining priorities of a plurality of machine learning tasks executed by a graphics processing unit;
if video memory resources are to be allocated for a higher-priority task, and an amount of allocatable video memory resources is smaller than an amount of video memory resources required by the higher-priority task, releasing at least a part of video memory resources occupied by a lower-priority task; and
allocating video memory resources to the higher-priority task, wherein the higher-priority task is executed at least according to tensor data in a video memory space; wherein the lower-priority task comprises an iterative learning task and releasing at least a part of the video memory resources occupied by the lower-priority task comprises:
if an amount of idle video memory resources of the lower-priority task is smaller than the amount of video memory resources required by the higher-priority task,
allocating internal memory resources to the lower-priority task for the at least a part of tensor data;
after the lower-priority task completes current iterative learning, releasing at least a part of the video memory resources occupied by the lower-priority task, wherein the at least a part of tensor data is transferred to an internal memory space and the lower-priority task is executed at least according to the tensor data in the internal memory space.
|