fix bug in AutoLabels