awslabs/gluonts

Change seasonality of "D" to 7, and 52 for "W"

Open

#975 opened on Aug 4, 2020

View on GitHub
 (2 comments) (0 reactions) (0 assignees)Python (753 forks)batch import
enhancementgood first issue

Repository metrics

Stars
 (3,888 stars)
PR merge metrics
 (Avg merge 26d 17h) (4 merged PRs in 30d)

Description

Description

  • currently we have DEFAULT_SEASONALITIES = {"H": 24, "D": 1, "W": 1, "M": 12, "B": 5}
  • however, having a seasonality of 1 has no real benefit to my knowledge (please correct me if I'm mistaken)
    • I base my knowledge on NBEATSEstimator and Naive2Predictor
  • therefore I suggest seasonality of 7 for Daily data "D"
    • to me this makes sense since this would capture the seasonality of workdays and weekends and in general the work week
  • additionally we could think of a seasonality of 52 (or 4) for weekly data "W"

Examples

  • Wavenet:
                {
                    "H": 7 * 24,
                    "D": 7,
                    "W": 52,
                    "M": 12,
                    "B": 7 * 5,
                    "min": 24 * 60,
                },
  • DeepState:
FREQ_LONGEST_PERIOD_DICT = {
    "M": 12,  # yearly seasonality
    "W-SUN": 52,  # yearly seasonality
    "D": 31,  # monthly seasonality
    "B": 22,  # monthly seasonality
    "H": 168,  # weekly seasonality
    "T": 1440,  # daily seasonality
}

Contributor guide