A和手语识别

2024-09-30 16:21:02 发布

您现在位置:Python中文网/ 问答频道 /正文

我正在研究GitHub上的手语识别https://github.com/udacity/AIND-Recognize。在

我有一个关于型号选择的问题。 当我在那里管理这个牢房的时候

import warnings 
from hmmlearn.hmm import GaussianHMM

def train_a_word(word, num_hidden_states, features):
    warnings.filterwarnings("ignore", category=DeprecationWarning)
    training = asl.build_training(features)  
    X, lengths = training.get_word_Xlengths(word)
    model = GaussianHMM(n_components=num_hidden_states, n_iter=1000).fit(X, lengths)
    logL = model.score(X, lengths)
    return model, logL

demoword = 'BOOK'
model, logL = train_a_word(demoword, 3 , features=features_ground)
print("Number of states trained in model for {} is {}".format(demoword, model.n_components))
print("logL = {}".format(logL))

这个错误:

^{pr2}$

我想不通,我想说的是,我们不应该修改这个单元格。在


Tags: importmodeltrainingcomponentstrainnumhiddenword