雾聪
2023-08-18 e837d6b9f7c85ac97247a4f457548e17655eea4c
funasr/runtime/onnxruntime/src/vocab.h
@@ -7,10 +7,10 @@
#include <vector>
using namespace std;
namespace funasr {
class Vocab {
  private:
    vector<string> vocab;
    bool IsChinese(string ch);
    bool IsEnglish(string ch);
    void LoadVocabFromYaml(const char* filename);
@@ -18,8 +18,10 @@
    Vocab(const char *filename);
    ~Vocab();
    int Size();
    string Vector2String(vector<int> in);
    bool IsChinese(string ch);
    void Vector2String(vector<int> in, std::vector<std::string> &preds);
    string Vector2StringV2(vector<int> in);
};
} // namespace funasr
#endif