Chain of Preference Optimization: Improving Chain-of-Thought Reasoning in LLMs