Question about dpo

How do I tell when to start counting the dpo? Is it at the beginning of the cycle, the end, or at the highest fertile day?