Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
TensorSpeech
GitHub Repository: TensorSpeech/TensorFlowTTS
Path: blob/master/examples/cpptflite/src/MelGenerateTF.h
1559 views
1
#ifndef MELGENERATETF_H
2
#define MELGENERATETF_H
3
4
#include "TfliteBase.h"
5
6
class MelGenerateTF : public TfliteBase
7
{
8
public:
9
10
MelGenerateTF(const char* modelFilename):TfliteBase(modelFilename),
11
inputIndexs(interpreter->inputs()),
12
ouptIndex(interpreter->outputs()[1]) {};
13
14
MelGenData infer(const std::vector<int32_t> inputIds);
15
16
private:
17
std::vector<int32_t> _speakerId{0};
18
std::vector<float> _speedRatio{1.0};
19
std::vector<float> _f0Ratio{1.0};
20
std::vector<float> _enegyRatio{1.0};
21
22
const std::vector<int32_t> inputIndexs;
23
const int32_t ouptIndex;
24
25
};
26
27
#endif // MELGENERATETF_H
28