What is the difference between using greedy sampling and setting topk=1?

I have a question: When I use topk=1, how does it differ from using greedy sampling? Or are they essentially the same?