Chris@9
|
1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
|
Chris@9
|
2
|
Chris@9
|
3 /*
|
Chris@9
|
4 pYIN - A fundamental frequency estimator for monophonic audio
|
Chris@9
|
5 Centre for Digital Music, Queen Mary, University of London.
|
Chris@9
|
6
|
Chris@9
|
7 This program is free software; you can redistribute it and/or
|
Chris@9
|
8 modify it under the terms of the GNU General Public License as
|
Chris@9
|
9 published by the Free Software Foundation; either version 2 of the
|
Chris@9
|
10 License, or (at your option) any later version. See the file
|
Chris@9
|
11 COPYING included with this distribution for more information.
|
Chris@9
|
12 */
|
Chris@9
|
13
|
matthiasm@0
|
14 #ifndef _MONONOTEPARAMETERS_H_
|
matthiasm@0
|
15 #define _MONONOTEPARAMETERS_H_
|
matthiasm@0
|
16
|
matthiasm@0
|
17 #include <iostream>
|
matthiasm@0
|
18 #include <vector>
|
matthiasm@0
|
19 #include <exception>
|
matthiasm@0
|
20
|
matthiasm@0
|
21 using std::vector;
|
matthiasm@0
|
22
|
matthiasm@0
|
23 class MonoNoteParameters
|
matthiasm@0
|
24 {
|
matthiasm@0
|
25 public:
|
matthiasm@0
|
26 MonoNoteParameters();
|
matthiasm@0
|
27 virtual ~MonoNoteParameters();
|
matthiasm@0
|
28
|
matthiasm@0
|
29 // model architecture parameters
|
matthiasm@0
|
30 size_t minPitch; // lowest pitch in MIDI notes
|
matthiasm@0
|
31 size_t nPPS; // number of pitches per semitone
|
matthiasm@0
|
32 size_t nS; // number of semitones
|
matthiasm@0
|
33 size_t nSPP; // number of states per pitch
|
matthiasm@0
|
34 size_t n; // number of states (will be calcualted from other parameters)
|
matthiasm@0
|
35
|
matthiasm@0
|
36 // initial state probabilities
|
matthiasm@0
|
37 vector<double> initPi;
|
matthiasm@0
|
38
|
matthiasm@0
|
39 // transition parameters
|
matthiasm@0
|
40 double pAttackSelftrans;
|
matthiasm@0
|
41 double pStableSelftrans;
|
matthiasm@0
|
42 double pStable2Silent;
|
matthiasm@0
|
43 double pSilentSelftrans;
|
matthiasm@0
|
44 double sigma2Note; // standard deviation of next note Gaussian distribution
|
matthiasm@0
|
45 double maxJump;
|
matthiasm@0
|
46 double pInterSelftrans;
|
matthiasm@0
|
47
|
matthiasm@0
|
48 double priorPitchedProb;
|
matthiasm@0
|
49 double priorWeight;
|
matthiasm@0
|
50
|
matthiasm@0
|
51 double minSemitoneDistance; // minimum distance for a transition
|
matthiasm@0
|
52
|
matthiasm@0
|
53 double sigmaYinPitchAttack;
|
matthiasm@0
|
54 double sigmaYinPitchStable;
|
matthiasm@0
|
55 double sigmaYinPitchInter;
|
matthiasm@0
|
56
|
matthiasm@0
|
57 double yinTrust;
|
matthiasm@0
|
58
|
matthiasm@0
|
59 };
|
matthiasm@0
|
60
|
Chris@9
|
61 #endif
|