Closed marcopeix closed 1 month ago
Check out this pull request on
See visual diffs & provide feedback on Jupyter Notebooks.
Powered by ReviewNB
Please also add a test verifying that as the finetune depth increases the loss is lower in the
nbs/docs/tutorials/06_finetuning.ipynb
notebook.
Such a test doesn't always work; i.e. it's not always the case that finetuning improves the model. So I'm removing it again....
What changed between now and 7bc1b5d1e554b1ad8fc7c420bcad1b87151b9048? That one has very different results (nb link). This is supposed to be deterministic, isn't it? I'd expect to be able to reproduce the metrics from that commit every time, especially the monotonic part, right now 2 and 3 yield the same result which is highly suspicious.
What changed between now and 7bc1b5d? That one has very different results (nb link). This is supposed to be deterministic, isn't it? I'd expect to be able to reproduce the metrics from that commit every time, especially the monotonic part, right now 2 and 3 yield the same result which is highly suspicious.
Nothing really changed, the issue is that it doesn't hold in general that:
I tweaked the parameters so that the results are not good but monotonic (however as said before, finetuning isn't guaranteed to provide results that are strictly better when increasing the parameters)
Thanks! So the test would pass now? It'd be great having loss_depth1 > loss_depth2 > loss_depth3
to detect possible regressions or the parameter not being passed through correctly.
Thanks! So the test would pass now? It'd be great having
loss_depth1 > loss_depth2 > loss_depth3
to detect possible regressions or the parameter not being passed through correctly.
No, because:
so we shouldn't market that view, either. And a test on that is useless too; if it fails, the results might still be better than before.
I've updated the example to explain that also (so users see that increasing depth can also worsen performance, and it's a bit of trial and error).
The tutorial fails if the parameter isn't passed through correctly, so we're covered there anyways.
Add the
finetune_depth
parameter to control how many layers are finetuned. Adjust tutorials and capabilities with new parameter.