-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AttributeError: 'tqdm' object has no attribute 'disable' #487
Comments
+1 |
could you provide a basic bit of code which lets us reproduce this error? |
@casperdcl Sorry I cannot, I almost forget it now... @kaufmann42 Could you provide it? Thanks. |
closed (#488) |
the problem still exists |
@acheshkov on which version of |
@casperdcl , 4.24.0 |
I am having the same problem with tqdm ...while training a neural network at 493rd epoch (everytime).. |
Same error 4.28.1 |
I had the same error (version: 4.46.0) |
Same error here with the latest version. Please reopen the issue. |
Do you by any chance have a file named |
On the latest version, 4.53.0, I get a similar error:
Just for context, Before updating to this version, I had version 4.46.0 and the same code generated the error |
Please use |
Both
And
result in the same error: |
no, you need: with tqdm(desc="Writing to File", bar_format=BAR_DEFAULT_VIEW, total=intersection_df[0].count()) as pbar:
with open(output, 'w') as f:
for idx, row in intersection_df.iterrows():
f.write(str(row[0])+"\t"+str(row[1])+"\n")
pbar.update(1) Then check what lines are actually causing the error (probably incorrect use somewhere else in the code) |
Got the same issue with
and I get the same issue if I use It seems to happen when the type of the
It works |
Why this problem is still here in 2021? in if disable:
self.iterable = iterable
self.disable = disable
with self._lock:
self.pos = self._get_free_pos(self)
self._instances.remove(self)
self.n = initial
self.total = total
self.leave = leave
return It looks really like a bug, |
This is still a bug, and I have seen other internal instances where there must be untested code paths explicitly around the |
This seems to clean up the problem nicely, albeit harshly. I've placed this in my empty
|
原因很简单,你们的数据集吧文件夹内部有文件是错误类型,去检查一下数据集 |
The reason is very simple. There are files in your dataset folder that are of the wrong type. Go check the dataset |
The bug is still among us. |
+1 |
2 similar comments
+1 |
+1 |
+1 Traceback (most recent call last): |
I changed the tqdm version to 4.19.9 which solved the problem. |
faced the same error when i was installed it in venv. when i installed it on a conda env, i was able to used it. |
This little change between versions Update: Was able to solve this by proxying tqdm with a class TQDMManager(BaseManager):
def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.register('_tqdm', tqdm)
def tqdm(self, *args, **kwargs) -> tqdm:
# noinspection PyUnresolvedReferences
return self._tqdm(*args, **kwargs)
@contextlib.contextmanager
def get_proxy_tqdm(*args, **kwargs) -> tqdm:
manager = TQDMManager()
try:
manager.start()
yield manager.tqdm(*args, **kwargs)
finally:
manager.shutdown() Would still be nice if this gets properly solved. |
tqdm
achieved maximum iterations and got the following errors:The text was updated successfully, but these errors were encountered: