Add seeking to rawread and macca, and tests#73
Open
pconerly wants to merge 5 commits intobeetbox:mainfrom
Open
Add seeking to rawread and macca, and tests#73pconerly wants to merge 5 commits intobeetbox:mainfrom
pconerly wants to merge 5 commits intobeetbox:mainfrom
Conversation
sampsyo
reviewed
Aug 23, 2018
Member
sampsyo
left a comment
There was a problem hiding this comment.
Looks great!! I'm excited to have some real unit tests here too. I've left a few comments inline.
audioread/macca.py
Outdated
| yield blob | ||
|
|
||
| def seek(self, pos): | ||
| """Seeks to the position in the file""" |
Member
There was a problem hiding this comment.
Style nitpicking: it's nice to write docstrings (a) in the imperative voice, and (b) as complete sentences, including a period. So I suggest:
Seek to a position in the file.
|
|
||
| #### wavetest.wav | ||
|
|
||
| Produced with `make_test_wave.py` |
Member
There was a problem hiding this comment.
It's a little confusing that there are files called test.wav and wavtest.wav. Maybe it would be useful to describe what each one is for, and how they're different?
Author
There was a problem hiding this comment.
I'm using test.wav for the macca backend--- I'll find some better names for it. We also might not need both
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
@sampsyo
WIP towards #71 and #72 . On the path of adding seeking, I did a variety of things:
block_samplesintoaudio_open. It works inmaccaandrawreadand I'm sure it's broken (viaUnexpected keyword arg) in the other backends.rawreadandmaccarawreadandmaccaMoving
block_samplesto the init for the other backends, and adding seeking to them is still needed. But let me know how this looks!Todos: