Giter Site home page Giter Site logo

ditschuk / pytorch-tsmixer Goto Github PK

View Code? Open in Web Editor NEW
75.0 75.0 10.0 20 KB

A pip-installable PyTorch implementation of TSMixer, providing an easy-to-use and efficient solution for time-series forecasting.

License: MIT License

Python 100.00%
forecasting pip time-series tsmixer

pytorch-tsmixer's People

Contributors

ditschuk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

pytorch-tsmixer's Issues

`ValueError` when batch size is 1.

Thank you for publishing this implementation of TSMixer - particularly useful to have TSMixerExt included!

I'm seeing errors when I try to call the model with a batch size of 1, and am wondering if I'm doing something wrong or whether it is a bug? For example:

from torchtsmixer import TSMixer
import torch

model = TSMixer(
    sequence_length=10,
    prediction_length=5,
    input_channels=2,
    output_channels=1
)

# Call with batch size of 2 (this works)
x_batch = torch.rand(2, 10, 2)
print(model(x_batch).shape)
# torch.Size([2, 5, 1])

# Call with batch size of 1 (this fails)
x_batch = torch.rand(1, 10, 2)
print(model(x_batch).shape)
# ValueError: Expected more than 1 value per channel when training, got input size torch.Size([1, 20, 1])

Training stuck

Hi, first of all, thanks for you implementation of TSMixerExtended

I have some doubt, I initialize the model and start the training process, but the predictions start much lower, and grow up slow each epoch, the training process get stuck on some local minimun aparently.

Exist some torch process that I have to do before? I am new using torch

About normalization

Hi,

I'm an author of TSMixer.
Thanks for sharing the implementation.
I'd like to inform you that we have used LayerNorm rather than BatchNorm for better stability in handling non-stationary time series.
Also, though there is no significant difference in our experiments, I normalized both the time and feature dimensions (2D norm) rather than time dimension only (1D norm).

Best,
Si-An

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.