Closed abhijitramesh closed 2 years ago
I've run into the same bug.
I use dls.vocab=''
as a workaround. But this should be fixed not to make assumptions like that.
Hi @abhijitramesh and @slawekslex,
Prince Canuma here, a Data Scientist at Neptune.ai,
Thank you very much for spotting this bug and providing such detailed feedback,
Indeed, vocab is should be optional in such cases, I will submit this feedback to the engineering team and get back to you,
In the meantime, I think the workarounds that you guys came up with work fine although far from ideal:
neptune-fastai/neptune_fastai/impl/__init__.py
dls.vocab = ''
or dls.vocab = []
On the other hand, is this the only issue? Is there anything else I can help you with?
On the other hand, is this the only issue? Is there anything else I can help you with?
Thanks, @Blaizzy Nope, That is it for now. I will let you know if something comes up.
Describe the bug
Learner for regression models does not have the vocab parameter as it is generally a list of labels. While tracking experiments with neptune-ai for fastai/tsai the experiment fails as the vocab parameter is expected by neptune callback.
https://github.com/neptune-ai/neptune-fastai/blob/b8e0f3c308170861806c7e23423d76685f71f22e/neptune_fastai/impl/__init__.py#L200
https://github.com/neptune-ai/neptune-fastai/blob/b8e0f3c308170861806c7e23423d76685f71f22e/neptune_fastai/impl/__init__.py#L249
This should be an optional parameter since fastai and tsai by default exclude
_vocab
for regression models.Reproduction
This code is taken from https://timeseriesai.github.io/tsai/tutorials.html#Time-series-regression with modification to include neptune tracking.
Run the above snippet.
Expected behavior
The training starts and neptune logs everything normally.
Traceback
For the above snippet
Partial Traceback:
Complete Traceback:
Environment
The output of
pip list
:The operating system you're using: macOS 12.0.1 The output of
python --version
: Python 3.9.5Additional context
I found hotfix's for the problem but its not ideal:
This is not ideal we need vocab for classification.
learn._vocab=[]
These fixes are not ideal, vocab should be optional parameter in the init.py for the neptune_fastai implementation.