示例#1
0
文件: xlearn.py 项目: memoiry/xlearn
def create_ffm():
    """
	Create a field-aware factorization machine.
	"""
    model_type = 'ffm'
    handle = XLearnHandle()
    _check_call(_LIB.XLearnCreate(c_str(model_type), ctypes.byref(handle)))
    return XLearn(handle)
示例#2
0
文件: xlearn.py 项目: memoiry/xlearn
def create_linear():
    """
	Create a linear model.
	"""
    model_type = 'linear'
    handle = XLearnHandle()
    _check_call(_LIB.XLearnCreate(c_str(model_type), ctypes.byref(handle)))
    return XLearn(handle)