Invites were sent out about a month ago based on certain criteria. If you were not a part of it, highly recommend Jeremy’s code walk throughs or my Study group until the new course comes out in Julyish to the public
Using the show_training_loop
function I get the following error:
File "/home/ubuntu/fastai-nlp/fastai_nlp/multi_label_classifier.py", line 114, in _get_multi_label_learner
print(learner.show_training_loop())
File "/home/ubuntu/clones/fastai2/fastai2/learner.py", line 233, in show_training_loop
if dl is None: dl = self.dls[ds_idx].new(shuffle=shuffle)
NameError: name '_loop' is not defined
I have investigated a bit and I have seen that in previous commits there was a definition of _loop
in
fastai2 / fastai2 / learner.py that in the most recent code is not:
# Cell
_loop = ['Start Fit', 'begin_fit', 'Start Epoch Loop', 'begin_epoch', 'Start Train', 'begin_train',
'Start Batch Loop', 'begin_batch', 'after_pred', 'after_loss', 'after_backward',
'after_step', 'after_cancel_batch', 'after_batch','End Batch Loop','End Train',
'after_cancel_train', 'after_train', 'Start Valid', 'begin_validate','Start Batch Loop',
'**CBs same as train batch**', 'End Batch Loop', 'End Valid', 'after_cancel_validate',
'after_validate', 'End Epoch Loop', 'after_cancel_epoch', 'after_epoch', 'End Fit',
'after_cancel_fit', 'after_fit']
If I add this piece of code in fastai2 / fastai2 / learner.py the error is fixed.
Is this the right way for show_training_loop
to work?
Thanks!
Hi,
I installed fastai2 today from github (I used the pip install -e ".[dev]"
), including the fastcore and nbdev.
when I run doc(IndexSplitter) to see the documentation, I get an error that if I want to see the full documentation and hyperlinks I need to pip install nbdev (which I have).
I ran conda list and the nbdev version under the fastai2 enviroment is 0.2.12.
am I missing something?
It was a mistake when we split the notebook in several parts. Fixed now!
You might also need the master version of nbdev since this is a bug I fixed recently.
I ran into an error of notebook 43_tabular.learner when running on google colab.
learn.predict(df.iloc[0])
---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
<ipython-input-19-7bebb4d34d49> in <module>()
----> 1 learn.predict(df.iloc[0])
13 frames
/usr/local/lib/python3.6/dist-packages/fastai2/torch_core.py in tensor(x, *rest, **kwargs)
110 else torch.tensor(x, **kwargs) if isinstance(x, (tuple,list))
111 else _array2tensor(x) if isinstance(x, ndarray)
--> 112 else as_tensor(x.values, **kwargs) if isinstance(x, (pd.Series, pd.DataFrame))
113 else as_tensor(x, **kwargs) if hasattr(x, '__array__') or is_iter(x)
114 else _array2tensor(array(x), **kwargs))
TypeError: can't convert np.ndarray of type numpy.object_. The only supported types are: float64, float32, float16, int64, int32, int16, int8, uint8, and bool
I installed fastai2 with:
import os
!pip install git+https://github.com/fastai/fastai2
os._exit(00)
@dhoa (as it says in the FAQ), you should be using the git version of fastcore too. Try that and see if you still get the error
Are random transforms being applied to the validation set?
I noticed this when running learn.get_preds
when I got slightly different results each time.
Faskbook2 notebook7 has this error when using tta in colab
https://colab.research.google.com/drive/19ZOGPzgn3afmCoO-dWuj_C59UnV4xOHz
No magic, aug_tfms
as batch_tfms
and GrandparentSplitter
as splitter
in Datablock
I still get the error. I tried first with
!pip install git+https://github.com/fastai/fastcore
!pip install git+https://github.com/fastai/fastai2
I tried also with the first cell in your walk-through:
!pip install -q feather-format kornia pyarrow wandb nbdev fastprogress fastai2 fastcore --upgrade
!pip install torch==1.3.1
It doesn’t work either.
Hi, If you want, you can try my notebook here. It works.
Thanks @JonathanSum. However I ran into a problem of tabular notebook that I wrote in this post Fastai v2 chat . I tried to install fastai2 from git repo and pip. Both cases doesn’t work. I will take a closed look at your notebook but I think there are not different from mine for installation.
Quick question: what is the status of multifit for v2? Is it possible to make it work in v2 right now even if the official port is not ready yet?
How can I unregister a function in TypeDispatch
?
Example:
I created a new tensor type: class TensorImageX(TensorImage): pass
I now want to inherit from Normalize
and create a class that only normalizes TensorImageX
but not TensorImage
.
It’s on my todo list