InceptionTime Model for Time Series#256
Conversation
|
Have to fix a couple of issues with the residual part. |
|
Hey @ToucheSir @darsnack @lorenzoh, |
|
Try building up your model bit-by-bit and checking for size mismatches on each submodule with a dummy input. |
Yeah I tried doing that. I dont understand how the forward pass works fine but the backprop gives an error. Will figure it out. |
|
Since only
|
|
The code can be tested with the following snipet :- data, blocks = load(datarecipes()["natops"]);
task = TSClassificationSingle(blocks, data);
traindl, validdl = taskdataloaders(data, task, 16);
callbacks = [ToGPU(), Metrics(accuracy)];
model = FastTimeSeries.Models.InceptionTime(24, 6);
learner = Learner(model, tasklossfn(task); data=(traindl, validdl), optimizer=ADAM(), callbacks = [ToGPU(), Metrics(accuracy)]);
fitonecycle!(learner, 10, 0.01) |
| bottleneck_block = bottleneck ? Conv1d(ni, nf, 1, bias = false) : identity | ||
|
|
||
| convs_layers = | ||
| [Conv1d(bottleneck ? nf : ni, nf, ks[i], bias = false) for i in range(1, stop = 3)] |
There was a problem hiding this comment.
I think it makes more sense to have Conv1d be lowercase conv1d, but that's a minor thing.
|
Hey guys, so the model is working for regression task too now, will push the notebook in a while. |
|
I have some suggestions for the notebook, but that can wait for a follow-up PR. Will try to have a look at the model again in the next couple of days. |
| inception = [] | ||
| shortcut = [] | ||
|
|
||
| for d in range(1, stop = depth) |
There was a problem hiding this comment.
Still many wild ranges floating around ;)
There was a problem hiding this comment.
Yeah, will fix that in the next commit.
ToucheSir
left a comment
There was a problem hiding this comment.
Mostly LGTM once docstrings are added and commented code is restored/removed.
3c51c9d to
67a989a
Compare
Hey, will push the docstrings today. This PR should be ready to go after it unless we want to further improve something. We can also discuss the future steps in our next biweekly. |
ToucheSir
left a comment
There was a problem hiding this comment.
Sorry about the delay on reviewing this. Let's get it merged.
This PR will contain the implementation of InceptionTime Model and it's use for classification and regression task.
Some of the commits from the PR #253 are also in this PR, but will take care of them when that PR is merged.