Skip to content
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

[WIP] Increase-test-coverage for keras_tensor and variables+ Fix __invert__ + Fix FloorDivide #944

Conversation

Faisal-Alsrheed
Copy link
Contributor

@Faisal-Alsrheed Faisal-Alsrheed commented Sep 22, 2023

Increase-test-coverage for keras_tensor + Fix __invert__ method and update FloorDiv references in keras_tensor.py

  1. Fixes a TypeError encountered when using the unary bitwise inversion (~) on a KerasTensor object. The __invert__ method had an incorrect signature, accepting an unnecessary other parameter.
  2. Updates references from FloorDiv to FloorDivide to align with the correct operation name.

Changes:

  1. Modified the __invert__ method in keras_tensor.py to remove the other parameter and correctly call the LogicalNot operation:

  2. Updated all occurrences of FloorDiv to FloorDivide in keras_tensor.py to ensure correct behavior.

@codecov
Copy link

codecov bot commented Sep 22, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: -16.57% ⚠️

Comparison is base (9bf92c8) 83.83% compared to head (e2ab5dc) 67.26%.
Report is 6 commits behind head on main.

❗ Current head e2ab5dc differs from pull request most recent head 6513f13. Consider uploading reports for the commit 6513f13 to get more accurate results

Additional details and impacted files
@@             Coverage Diff             @@
##             main     #944       +/-   ##
===========================================
- Coverage   83.83%   67.26%   -16.57%     
===========================================
  Files         319      319               
  Lines       28879    28879               
  Branches     5529     5529               
===========================================
- Hits        24211    19426     -4785     
- Misses       3148     8117     +4969     
+ Partials     1520     1336      -184     
Flag Coverage Δ
keras_core 67.26% <100.00%> (-16.47%) ⬇️
keras_core-jax ?
keras_core-numpy ?
keras_core-tensorflow 67.26% <100.00%> (+0.18%) ⬆️
keras_core-torch ?

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
keras_core/backend/common/keras_tensor.py 99.29% <100.00%> (+29.07%) ⬆️

... and 89 files with indirect coverage changes

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Faisal-Alsrheed Faisal-Alsrheed changed the title [WIP] Increase-test-coverage for keras_tensor [WIP] Increase-test-coverage for keras_tensor + Fix __invert__ + Fix FloorDivide Sep 22, 2023
@Faisal-Alsrheed Faisal-Alsrheed changed the title [WIP] Increase-test-coverage for keras_tensor + Fix __invert__ + Fix FloorDivide [WIP] Increase-test-coverage for keras_tensor and variables+ Fix __invert__ + Fix FloorDivide Sep 22, 2023
@fchollet
Copy link
Member

Keras Core is becoming Keras 3, and we're switching development to the main repository! Please reopen this PR in the keras-team/keras repository. Unfortunately we aren't able to automatically transfer PRs (but we have transferred all issues).

@fchollet fchollet closed this Sep 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants