bmcfee / muda

A library for augmenting annotated audio data
ISC License
230 stars 33 forks source link

Refactor iterator api #6

Closed bmcfee closed 9 years ago

bmcfee commented 9 years ago

Stochastic iterators can be more simply designed with multiple inheritance.

A special state information function can be abstracted out, and all transformers (iterable or not) can be rewritten to access parameters through the state object. This way, sampling and transformation become separate.

This might even make more sense as a context manager.