Comments (5)
In that case we'd need a continuous emission probability model. For continuous emissions hmmlearn only supports Gaussian / Gaussian mixtures. We could of course use one of those instead of the current multinomial distribution; I mostly followed the pYIN paper (eqn 6) for defining the emission probability. For continuous emission we'll need to come up with a new heuristic to define our prior.
I thought about this before, and I wanted to use a (scaled) Dirichlet or element-wise Beta distribution because the support is constrained in [0, 1], but hmmlearn does not support them; that was where I previously gave up implementing the continuous emission.
from crepe.
Hi @jongwook. I think my discussions with @justinsalamon today prompted this issue. I used librosa.sequence.viterbi to decode discrete emissions directly from the posterior observations emitted by the network. I tried the same transition matrix you propose. I found that this significantly reduced the number of half/double frequency errors I was getting when working with speech data. The output pitch is still quantized, but can be smoothed or dithered to reduce binning effects if needed.
from crepe.
@maxrmorrison Thanks for the context! I haven't thought in that way, i.e. interpreting the salience matrix as the observation probability distribution, but it does look like a better way to utilize the full salience matrix.
Are you normalizing each column to sum to 1? There's still some theoretical gap because the salience is obtained using multi-label binary cross-entropy instead of softmax, but if it works in practice, we should totally use it.
hmmlearn requires us to explicitly provide the emission probability distribution p(obs|state) and the observation sequence obs: timestep -> state, while librosa accepts the collapsed p(state|timestep) disregarding the observation space. The latter works just fine when we are predicting p(state|timestep) directly.
I'll welcome a PR that replaces hmmlearn with librosa.sequence.viterbi
.
from crepe.
A PR has been started! Regarding the theoretical justification, yes: the output of softmax (the posterior distribution) should be used and not the raw logits. As the network was trained to minimize the distance between the categorical posterior distribution and the (also categorical), it is reasonable to decode directly from this distribution rather than after an additional sampling process (e.g., argmax).
from crepe.
@maxrmorrison @jongwook Delighted to see this moving forward!
One quick question - librosa is a pretty heavy dependency. Could we just carve out just the viterbi decoding code, so as to avoid having the entire library as a dependency?
from crepe.
Related Issues (20)
- Can you support the input of [Batch,samples]?
- New question old issue on install error HOT 3
- Compatibility with spleeter
- Can you provide these 6 training data?
- Monterey HOT 1
- performance on MIK-1K HOT 2
- Re-training for alternate samplerate HOT 2
- I ran into an error when I install crepe HOT 1
- Fail to install crepe
- update PYPI package to work with hmmlearn==0.2.8 and viterbi=True HOT 1
- Permute layer HOT 2
- Poor confidence issue
- Maximum real-time speed of the model HOT 1
- Pitch estimation for 44.1kHz audio
- AttributeError: type object 'Distribution' has no attribute '_finalize_feature_opts'
- Where does 1997.3794084376191 come from?
- SSL Error when installing crepe HOT 13
- preprocessing implementation in other languages
- Support `hmmlearn==0.3.0` for M1 Mac HOT 2
- Getting a graph execution error / JIT compilation failed with latest versions
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from crepe.