You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I tried to run notebook-example over my Anaconda environment and faced with "float division by zero exception"
This is a code which causes exception: https://gist.github.com/Daiver/b4f9115a9e33a1ca233d0defbabee6d9 (basically notebook-example copy-pasted inside one .py file)
This is stacktrace:
C:\Users\Daiver\Anaconda3\python.exe C:/Users/Daiver/PycharmProjects/untitled/main.py
Python version 3.6.5 |Anaconda, Inc.| (default, Mar 29 2018, 13:32:41) [MSC v.1900 64 bit (AMD64)]
Catalyst version: 0.6
Files already downloaded and verified
Files already downloaded and verified
0 * Epoch (train): 0% 1/1563 [00:00<15:06, 1.72it/s, base/batch_time=0.01562, base/data_time=0.01562, base/sample_per_second=2048.43759, loss=2.32288, lr=0.00100, momentum=0.90000, precision01=3.12500, precision03=18.75000, precision05=56.25000]Traceback (most recent call last):
File "C:/Users/Daiver/PycharmProjects/untitled/main.py", line 113, in <module>
main()
File "C:/Users/Daiver/PycharmProjects/untitled/main.py", line 109, in main
epochs=n_epochs, verbose=True)
File "C:\Users\Daiver\PycharmProjects\untitled\catalyst\dl\runner.py", line 210, in train
verbose=verbose
File "C:\Users\Daiver\PycharmProjects\untitled\catalyst\dl\runner.py", line 159, in run
self.run_event(callbacks=callbacks, event="on_batch_end")
File "C:\Users\Daiver\PycharmProjects\untitled\catalyst\dl\runner.py", line 92, in run_event
getattr(self.state, f"{event}_pre")(state=self.state)
File "C:\Users\Daiver\PycharmProjects\untitled\catalyst\dl\state.py", line 203, in on_batch_end_pre
state.batch_size / elapsed_time
ZeroDivisionError: float division by zero
Process finished with exit code 1
It can be fixed by adding zero check on elapsed_time but i have no idea, why elapsed_time is zero
My python/catalyst versions
Python version 3.6.5 |Anaconda, Inc.| (default, Mar 29 2018, 13:32:41) [MSC v.1900 64 bit (AMD64)]
Catalyst version: 0.6
Catalyst was installed by clonning current repo (master branch, last commit 892d5e5 "Merge pull request #56 from dbrainio/master")
The text was updated successfully, but these errors were encountered:
Daiver
changed the title
"float division by zero" exception during notebook-example on windows
"float division by zero" exception during notebook-example on anaconda/windows
Jan 16, 2019
Currently, Catalyst is in alpha and we do a lot of breaking changes right now. Sorry for that!
Within a couple of weeks, we plan to release the stable version of Catalyst with a great number of new features!
Right now, you may add a zero-checker while we fixing it 😄
Good catch! Looks like we need some additional Windows testing, cause all code works like a charm on Linux and MacOS. Just to be sure, I have tested your code with:
Hi guys, thank you for great project.
I tried to run notebook-example over my Anaconda environment and faced with "float division by zero exception"
This is a code which causes exception: https://gist.github.com/Daiver/b4f9115a9e33a1ca233d0defbabee6d9 (basically notebook-example copy-pasted inside one .py file)
This is stacktrace:
It can be fixed by adding zero check on
elapsed_time
but i have no idea, whyelapsed_time
is zeroMy python/catalyst versions
Catalyst was installed by clonning current repo (master branch, last commit 892d5e5 "Merge pull request #56 from dbrainio/master")
The text was updated successfully, but these errors were encountered: