Commit 619ec78d authored by Jean-Marie Lepioufle's avatar Jean-Marie Lepioufle
Browse files


parent feb0b754
......@@ -4,11 +4,6 @@ from typing import Type
# TODO move decode example
class SimpleLinearModel(torch.nn.Module):
A very simple baseline model to resolve some of the
difficulties with bugs in the various train/validation loops
in code. Has only two layers.
def __init__(self, seq_length: int, n_time_series: int, output_seq_len=1):
self.forecast_history = seq_length
......@@ -101,7 +101,7 @@ validation.unscale()
# metrics: MSE
import numpy as np
m_fun = criterion_dict[m]()
#m_fun = criterion_dict[m]()
res = 0.0
for id in range(len(pred)):
for i in range(len(pred)):
res = res + sum(((validation[i][1].float()-pred[i].float())**2).numpy())[0]/validation.horizon_length/len(
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment