Skip to content

Conversation

@Mohamed-Ashraf273
Copy link
Contributor

@Mohamed-Ashraf273 Mohamed-Ashraf273 commented Jun 21, 2025

Hi @fchollet
I just added a check for np.ndarray in the function that was recently merged.

@codecov-commenter
Copy link

codecov-commenter commented Jun 21, 2025

Codecov Report

Attention: Patch coverage is 25.00000% with 3 lines in your changes missing coverage. Please review.

Project coverage is 82.72%. Comparing base (be9b002) to head (0466f3b).

Files with missing lines Patch % Lines
keras/src/backend/openvino/core.py 25.00% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master   #21407      +/-   ##
==========================================
- Coverage   82.72%   82.72%   -0.01%     
==========================================
  Files         565      565              
  Lines       55219    55221       +2     
  Branches     8608     8609       +1     
==========================================
  Hits        45682    45682              
- Misses       7427     7429       +2     
  Partials     2110     2110              
Flag Coverage Δ
keras 82.53% <25.00%> (-0.01%) ⬇️
keras-jax 63.33% <0.00%> (-0.01%) ⬇️
keras-numpy 58.53% <0.00%> (-0.01%) ⬇️
keras-openvino 33.79% <25.00%> (-0.01%) ⬇️
keras-tensorflow 63.74% <0.00%> (-0.01%) ⬇️
keras-torch 63.37% <0.00%> (-0.01%) ⬇️

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

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

elif isinstance(index, (int, np.integer, np.ndarray)):
if isinstance(index, (np.ndarray, np.integer)):
if isinstance(index, np.ndarray):
assert len(index.shape) == 0, (
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please use ValueError instead of assert.

Copy link
Contributor Author

@Mohamed-Ashraf273 Mohamed-Ashraf273 Jun 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@fchollet
Done!

Copy link
Contributor

@rkazants rkazants left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@fchollet, looks good to me. Recommend to merge

@Mohamed-Ashraf273
Copy link
Contributor Author

@fchollet

@rkazants
Copy link
Contributor

rkazants commented Jul 6, 2025

@fchollet, looks good to me. Recommend to merge

@fchollet fchollet merged commit e32175a into keras-team:master Jul 7, 2025
7 checks passed
@Mohamed-Ashraf273 Mohamed-Ashraf273 deleted the getitem branch July 8, 2025 09:01
Mohamed-Ashraf273 added a commit to Mohamed-Ashraf273/keras that referenced this pull request Jul 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants