fixed bugs in epoch tagging