Closed amaarora closed 5 years ago
Check out this pull request on
You'll be able to see Jupyter notebook diff and discuss changes. Powered by ReviewNB.
This is not going to work each time we have a function instead of an instance of a class (it's going to show "function" instead of the function name) so we need to use something else here that checks for a __name__
attribute then reverts to a __class__.__name__
.
checks for a
__name__
attribute then reverts to a__class__.__name__
Thanks @sgugger! I have updated PR to getattr(o, '__name__', o.__class__.__name__)
and this seems to work for me.
Thanks!
While looking into
DataSource
I got an errorThis can be replicated by:
From what I understand, issue occurs due to calling
__name__
on RegexLabeller() and this PR attempts to fix it.