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
add dask
submodule
#1079
add dask
submodule
#1079
Conversation
Codecov Report
@@ Coverage Diff @@
## devel #1079 +/- ##
==========================================
- Coverage 84.81% 84.43% -0.39%
==========================================
Files 24 25 +1
Lines 1627 1651 +24
Branches 270 273 +3
==========================================
+ Hits 1380 1394 +14
- Misses 209 218 +9
- Partials 38 39 +1 |
@deschman from #278 (comment): do you mean the example code in the OP above doesn't work for you? |
I mean to say that I have been testing the devel branch with the code below. import time
import dask
from tqdm.dask import TqdmCallback as ProgressBar
schedule = []
for i in range(5):
schedule.append(dask.delayed(time.sleep)(i))
with ProgressBar():
dask.compute(schedule) This fails because Callback from dask 2021.2.0 does not have a pbar attribute. Edit: I took another look at your test code above and that seems to fail for the same reason. |
interesting... I ran you code (ubuntu,
|
I stepped through this more slowly and found the problem. Below is a traceback that is handled without any message. During handling, TqdmCallback._finish is called, where self.pbar is not defined due to the handled error. Perhaps an update to requirements or better handling of this error would be helpful? File "c:\users\deschman\spyder-env\lib\site-packages\dask\local.py", line 436, in get_async
start_state(dsk, state)
File "c:\users\deschman\spyder-env\lib\site-packages\tqdm\dask.py", line 27, in _start_state
self.pbar = self.tqdm_class(total=sum(
File "c:\users\deschman\spyder-env\lib\site-packages\tqdm\notebook.py", line 240, in __init__
self.container = self.status_printer(self.fp, total, self.desc, self.ncols)
File "c:\users\deschman\spyder-env\lib\site-packages\tqdm\notebook.py", line 117, in status_printer
raise ImportError(
ImportError: IProgress not found. Please update jupyter and ipywidgets. See https://ipywidgets.readthedocs.io/en/stable/user_install.html |
ah right. That's just Python's default traceback - always important to look for the first error :) |
based on
tqdm.keras
tqdm.dask.TqdmCallback
(adddask
submodule #1079, Create progress bar wrapper to use with dask #279 <- Dask support #278)Testing:
pip install "git+https://github.com/tqdm/tqdm@dask#egg=tqdm"