-
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
Video bug fix #1349
Video bug fix #1349
Conversation
Codecov Report
@@ Coverage Diff @@
## main #1349 +/- ##
==========================================
- Coverage 92.34% 92.25% -0.09%
==========================================
Files 176 176
Lines 14140 14160 +20
==========================================
+ Hits 13057 13064 +7
- Misses 1083 1096 +13
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
hub/core/compression.py
Outdated
) | ||
nbytes = len(raw_video) | ||
size = np.prod(shape) | ||
if nbytes >= size: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please aslo add some comments why this logic is here.
hub/api/tests/test_video.py
Outdated
for i in range(10): | ||
assert ds.video[i].numpy().shape == sample.shape # type: ignore | ||
for path in video_paths[compression]: | ||
ds.create_tensor("video", htype="video", sample_compression=compression) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wouldn't this create this tensor multiple times?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed.
🚀 🚀 Pull Request
Checklist:
coverage-rate
upChanges
Fill missing tail frames from floating precision with blank frames.