Circular encoding for dates #1567
Replies: 2 comments 3 replies
-
Hey @PeterPirog, we have something very similar, which is the https://ludwig-ai.github.io/ludwig-docs/user_guide/configuration/#wave-encoder It's functionally very similar, in that every dimension (days, months, etc.) follow a cyclical period. The only difference I am aware of is that the wave encoder uses the sine function, whereas the one described in the kaggle notebook uses both sine and cosine. If you would like to add the variant in the notebook, that would be much appreciated! cc @w4nderlust in case you'd like to add anything. |
Beta Was this translation helpful? Give feedback.
-
Thanks for the contribution @PeterPirog , looks great! |
Beta Was this translation helpful? Give feedback.
-
I wonder if circular encoder is used to convert dates.
Of course years increases lineary but for days period is 7, for months period is 12, for hours period is 12 or 24
In my preprocessing models I like to use circular encoding because sometimes it improve accuracy.
Link: https://www.kaggle.com/avanwyk/encoding-cyclical-features-for-deep-learning
By the way I'm not sure how to define date
2021-01-15 10:37:17.369573
in YAMLI try to use code below but there is some problem with it:
I'm very satisfy that I can test ludwig framework very intensively for last week
I focused how can I use my domain knowledge to use it in YAML configuration. Typicaly I use tensorflow models (lastly I try tensorflow probability layers) but in ludwig time from configuartion YAML file to model serving is impressing.
I'm layman in pytorch so I try to use code in branch tf-legacy
Beta Was this translation helpful? Give feedback.
All reactions