How to write a new relay op?

Hi all, I’m fused about if i want to write a new relay op, Does it mean that I have to write logic in the C++ language? or I just need to write logic in python? Any examples in writing relay op?
Thanks.
Any comments are welcome.

you can search already finished operator such as ‘roi_pool’ ‘roi_align’ in topi/python/topi/ .Then follow the original code.