yuantn/MI-AOD

关于学习Unlabel数据集的分布问题

nancy618618618 opened this issue · 5 comments

您好,我在自己的数据集上使用您的方法,比如:10万的标注数据,先Label Training, 再从未标注池子里随机选10万的数据,进行训练学习未标注数据的分布,训练之后的结果在原验证集上指标降低了1个点,请问是什么原因呢,谢谢!

您好,可能是因为初始训练的结果不够稳定,影响了未标注数据分布的学习。可以考虑减小超参数 λ,或增大已标注集训练与最大化/最小化示例不确定性步骤的 epoch 数之比 epoch_ratio


Hello, it may be because the results of the initial training are not stable enough, which affects the learning of the unlabeled data distribution. You may reduce the hyperparameter λ, or increase the ratio of the number of epochs for Label Set Training step and those for Re-weighting and Minimizing/Maximizing Instance Uncertainty, epoch_ratio.

我理解是不是因为在学习未标注数据集的时候,标注数据集和未标注数据集之间的分布差异比较大,在学习的时候,模型趋向于学习了未标注数据集的信息,导致在原验证集上的指标降低

有可能是这样的,因此可以调整一下未标注数据对模型的影响,或者等待模型趋于稳定后再加入大量的未标注数据参与训练。


It may be the reason. So you can adjust the impact of the unlabeled data on the model, or wait for the model to stabilize before adding a large amount of unlabeled data to participate in training.

请问一下哦,有没有做过实验就是未标注集和标注集在做最大化最小化是比例不一致呢,比如标注集大一些,未标注集小一些,而不是像现在这样等量的。
以及哦,如果要修改这个比例不一样的话,要改哪里的代码呢

这方面的实验没有做过。
你可以通过修改 这里 第 36-37 行的 X_L_repeatX_U_repeat 来改变已标注集合与未标注集合的重复次数。
请注意,这里要保证两个集合的 重复次数*图像数量 严格保持相等。例如,已标注集中图像数量为 1000,未标注集中图像数量为 500,相应的重复次数可以设置为 1 和 2,或等比例地提高至 2 和 4。
在严格保证相等的前提下,对于 1:3 这种不可转换为有限小数的比例要尤为注意。例如,1000 和 333 这样的图像数量对应的重复次数最小只能是 333 和 1000。只有你将其修改为 999 和 333,才可以将重复次数最小设置为 1 和 3。


Experiments in this area have not yet been done.
You can change the number of repetitions of the labeled and unlabeled sets by modifying X_L_repeat and X_U_repeat on Lines 36-37 here.
Note that the number of repetitions * number of images of the two sets should be strictly equal. For example, if the number of images in the labeled set is 1000 and that in the unlabeled set is 500, the corresponding number of repetitions can be set to 1 and 2, or increased to 2 and 4 in equal proportions.
On the premise of strict equality, special attention should be paid to the ratio of 1:3, which is not convertible to finite decimals. For example, the number of images such as 1000 and 333 will have a minimum number of repetitions of 333 and 1000. Only if you modify it to 999 and 333, you can set the minimum number of repetitions to 1 and 3.