In this section, we design the memory management mechanism for determining which task to be stored in the memory and which task to be moved out. The mechanism, named Memory Management with Domain Distribution and Difficulty Awareness (M2D3), jointly considers the difficulty and distribution of few shot tasks in our setting. M2D3 first estimates the probability of the current task Tt to be moved into the memory. The model will then determine the task to be moved out in the event that a new task move-in happens. To improve efficiency, we utilize the obtained latent domain information associated with each task (as described in previous section) to first estimate this move-out probability at cluster-level before sampling single task, as in Figure 3.
作者对于其中的细节给出了定义:在这里,我们定义了以下所涉及的符号方法描述。内存中的每个任务Tt都是关联的。具有潜在域标签Lt和所有具有相同潜在域标签形成一个簇。Mi表示集群由内存中具有潜在域标签i的所有任务组成M、 ni=| Mi |表示Mi中的任务数,并且n=| M |表示内存中的任务总数,以及Ii表示聚类Mi的重要性得分。
During meta training, a mini-batch of tasks are sampled from the memory and are jointly trained with current tasks to mitigate catastrophic forgetting. Direct uniform sampling tasks from memory incurs high variance, and results in unstable training [32, 9]. On the other hand, our intuition for
non-uniform task sampling mechanism is that the tasks are not equally important for retaining the knowledge from previous domains. The tasks that carry more information are more beneficial for the model to remember previous domains, and should be sampled more frequently. To achieve this goal, we propose an efficient adaptive task sampling scheme in memory that accelerates training and reduces gradient estimation variance. As shown in Figure 4, the sampling probability of Miniimagenet and Aircraft are adjusted and increased based on the scheme suggesting the importance of these domains are higher than that of Omniglot for retaining knowledge.
Figure 4: A simple example of uniform task sampling and our adaptive memory task sampling method for sampling tasks from memory buffer during meta training.