-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Lab1, Part1: Assertion fails #116
Comments
global seed alone fails to ensure reproducibility, probably have to specify an operation-level seed to get the same result |
hi, i got the same question, did you get this done! |
Ran into the same exact issue. |
It sems that to get deterministic behavior in the latest Tensor Flow you need to use
However this will not solve the problem, as you need to recalculate the results in test library anyway |
Getting same issue here:
Did anyone get any solution? |
1) tf.random.set_seed only sets the global seed https://www.tensorflow.org/api_docs/python/tf/random/set_seed 2) we need to set keras set_random_seed to make all seeds be deterministic. docs : https://www.tensorflow.org/api_docs/python/tf/config/experimental/enable_op_determinism, https://www.tensorflow.org/api_docs/python/tf/keras/utils/set_random_seed. enable_op_determinism might not be needed here but its good to have. fixes aamini#116
Yes, the suggested PR by prashantkhurana works for me. Maybe the version of mitdeeplearning should be upped. I use NVidia CUDA RTX A5000 with x64 ubuntu, tensorflow 2.12, python 3.11 UPD: also tested on Apple M1 Pro tensorflow-metal w tensorflow 2.12 |
I'm getting the same error using Google Colab. |
same here |
Getting the same assertion error: Arrays are not almost equal to 7 decimals |
Getting same assertion error |
It looks like #118 has solved the issue. When will we merge it? |
Same error getting on Google colab. Any fix yet? |
Still getting this error on colab even after replacing tf.random.set_seed(1) with |
I think is's because mitdeeplearning library file mitdeeplearning/lab1.py need to be patched also with the new values but in colab you use remote version, this should work after version update. See the PR above. I tested in both on x64 and Apple M1 so likely it will work. |
same error /usr/local/lib/python3.10/dist-packages/ipykernel/ipkernel.py:283: DeprecationWarning:
|
In "### Defining a network Layer ###" while defining OurDenseLayer class, even in solution
The text was updated successfully, but these errors were encountered: