Hi all.
I am working through the Lesson 3 Rossman notebook
When I get to the command (just below the Sample subsection)
m.fit(lr, 3, metrics=[exp_rmspe])
I get KeyError: <weakref at 0x7fb6eb4e2688; to 'tqdm' at 0x7fb6eed23c88>
The details are below. Has anyone dealt with this error, or know what to do about it?
KeyError Traceback (most recent call last)
in ()
----> 1 m.fit(lr, 3, metrics=[exp_rmspe])
~/fastai/courses/dl1/fastai/learner.py in fit(self, lrs, n_cycle, wds, **kwargs)
285 self.sched = None
286 layer_opt = self.get_layer_opt(lrs, wds)
–> 287 return self.fit_gen(self.model, self.data, layer_opt, n_cycle, **kwargs)
288
289 def warm_up(self, lr, wds=None):
~/fastai/courses/dl1/fastai/learner.py in fit_gen(self, model, data, layer_opt, n_cycle, cycle_len, cycle_mult, cycle_save_name, best_save_name, use_clr, use_clr_beta, metrics, callbacks, use_wd_sched, norm_wds, wds_sched_mult, use_swa, swa_start, swa_eval_freq, **kwargs)
232 metrics=metrics, callbacks=callbacks, reg_fn=self.reg_fn, clip=self.clip, fp16=self.fp16,
233 swa_model=self.swa_model if use_swa else None, swa_start=swa_start,
–> 234 swa_eval_freq=swa_eval_freq, **kwargs)
235
236 def get_layer_groups(self): return self.models.get_layer_groups()
~/fastai/courses/dl1/fastai/model.py in fit(model, data, n_epochs, opt, crit, metrics, callbacks, stepper, swa_model, swa_start, swa_eval_freq, **kwargs)
121 if hasattr(cur_data, ‘val_sampler’): cur_data.val_sampler.set_epoch(epoch)
122 num_batch = len(cur_data.trn_dl)
–> 123 t = tqdm(iter(cur_data.trn_dl), leave=False, total=num_batch)
124 if all_val: val_iter = IterBatch(cur_data.val_dl)
125
~/fastai/courses/dl1/fastai/imports.py in tqdm(*args, **kwargs)
45 if in_notebook():
46 def tqdm(*args, **kwargs):
—> 47 clear_tqdm()
48 return tq.tqdm(*args, file=sys.stdout, **kwargs)
49 def trange(*args, **kwargs):
~/fastai/courses/dl1/fastai/imports.py in clear_tqdm()
41 inst = getattr(tq.tqdm, ‘_instances’, None)
42 if not inst: return
—> 43 for i in range(len(inst)): inst.pop().close()
44
45 if in_notebook():
~/anaconda3/envs/fastai/lib/python3.6/site-packages/tqdm/_tqdm.py in close(self)
1096 # decrement instance pos and remove from internal set
1097 pos = abs(self.pos)
-> 1098 self._decr_instances(self)
1099
1100 # GUI mode
~/anaconda3/envs/fastai/lib/python3.6/site-packages/tqdm/_tqdm.py in _decr_instances(cls, instance)
436 with cls._lock:
437 try:
–> 438 cls._instances.remove(instance)
439 except KeyError:
440 if not instance.gui: # pragma: no cover
~/anaconda3/envs/fastai/lib/python3.6/_weakrefset.py in remove(self, item)
107 if self._pending_removals:
108 self._commit_removals()
–> 109 self.data.remove(ref(item))
110
111 def discard(self, item):
KeyError: <weakref at 0x7fb6eb4e2688; to ‘tqdm’ at 0x7fb6eed23c88>