-
Notifications
You must be signed in to change notification settings - Fork 625
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
bump tensorflow to 2.15 in CI #4847
Conversation
Hello. You may have forgotten to update the changelog!
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #4847 +/- ##
=======================================
Coverage 99.65% 99.66%
=======================================
Files 382 382
Lines 34507 34501 -6
=======================================
- Hits 34389 34384 -5
+ Misses 118 117 -1 ☔ View full report in Codecov by Sentry. |
Great job finding this :) does it still work on older tf versions? |
I did: pip install tensorflow-macos==2.10
pytest tests/interfaces/default_qubit_2_integration/test_tensorflow_qnode_default_qubit_2.py \
tests/test_operation.py::TestBroadcasting::test_with_tf_function with python 3.9, and it passed |
For some reason in 2.15, the
ndim()
of an abstract tensor with shape specified asNone
was -1, so it didn't raise an error, and didn't get handled with this exception handlingDescription of the change
qml.math.ndim(tensor)
always returnslen(tensor.shape)
for tensorflow. this will still raise errors as expected for abstract tensors with abstract shapes (only happens when the user specifies the shape as None before compiling a function).ran a bunch of tests (tf interface tests, the
tf.function
test that failed in test_operation.py) locally with python 3.9, TF 2.10 just to make sure I didn't break old versions of tensorflow, they all passed 🙌