How to use hours of the day as a continuous feature?
Great question.

I'd say you should either use fourier transforms or sine / cosine transforms as they should get 0 to be right next to 23. The below post is talking about transforming day features, but should be easily applicable here.

Transforming day features

Transforming hour features