implements decorator for creating profile checkpoints