當前位置: 首頁>>代碼示例>>Java>>正文


Java History類代碼示例

本文整理匯總了Java中org.grouplens.lenskit.data.history.History的典型用法代碼示例。如果您正苦於以下問題:Java History類的具體用法?Java History怎麽用?Java History使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


History類屬於org.grouplens.lenskit.data.history包,在下文中一共展示了History類的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: getUserRatingVector

import org.grouplens.lenskit.data.history.History; //導入依賴的package包/類
/**
 * Get a user's ratings.
 * @param user The user ID.
 * @return The ratings to retrieve.
 */
private SparseVector getUserRatingVector(long user) {
    UserHistory<Rating> history = userEvents.getEventsForUser(user, Rating.class);
    if (history == null) {
        history = History.forUser(user);
    }

    return RatingVectorUserHistorySummarizer.makeRatingVector(history);
}
 
開發者ID:4DD8A19D69F5324F9D49D17EF78BBBCC,項目名稱:Introd_uction_to_Recom_mander_S_ystem,代碼行數:14,代碼來源:SimpleItemItemScorer.java

示例2: getUserRatingVector

import org.grouplens.lenskit.data.history.History; //導入依賴的package包/類
/**
 * Get a user's rating vector.
 * @param user The user ID.
 * @return The rating vector.
 */
private SparseVector getUserRatingVector(long user) {
    UserHistory<Rating> history = userDao.getEventsForUser(user, Rating.class);
    if (history == null) {
        history = History.forUser(user);
    }
    return RatingVectorUserHistorySummarizer.makeRatingVector(history);
}
 
開發者ID:4DD8A19D69F5324F9D49D17EF78BBBCC,項目名稱:Introd_uction_to_Recom_mander_S_ystem,代碼行數:13,代碼來源:SimpleUserUserItemScorer.java

示例3: getUserRatingVector

import org.grouplens.lenskit.data.history.History; //導入依賴的package包/類
/**
 * Get a user's ratings.
 * @param user The user ID.
 * @return The ratings to retrieve.
 */
private SparseVector getUserRatingVector(long user) {
	UserHistory<Rating> history = userEvents.getEventsForUser(user, Rating.class);
	if (history == null) {
		history = History.forUser(user);
	}

	return RatingVectorUserHistorySummarizer.makeRatingVector(history);
}
 
開發者ID:paolobarbaglia,項目名稱:coursera_recommender_systems,代碼行數:14,代碼來源:SimpleItemItemScorer.java

示例4: getUserRatingVector

import org.grouplens.lenskit.data.history.History; //導入依賴的package包/類
/**
 * Get a user's rating vector
 * @param user The user ID
 * @return The rating vector
 */
private SparseVector getUserRatingVector(long user) {
    UserHistory<Rating> history = userDao.getEventsForUser(user, Rating.class);
    if (history == null) {
        history = History.forUser(user);
    }
    return RatingVectorUserHistorySummarizer.makeRatingVector(history);
}
 
開發者ID:paolobarbaglia,項目名稱:coursera_recommender_systems,代碼行數:13,代碼來源:SimpleUserUserItemScorer.java

示例5: getUserRatingVector

import org.grouplens.lenskit.data.history.History; //導入依賴的package包/類
/**
 * Get a user's ratings.
 * 
 * @param user
 *            The user ID.
 * @return The ratings to retrieve.
 */
private SparseVector getUserRatingVector(long user) {
	UserHistory<Rating> history = userEvents.getEventsForUser(user,
			Rating.class);
	if (history == null) {
		history = History.forUser(user);
	}

	return RatingVectorUserHistorySummarizer.makeRatingVector(history);
}
 
開發者ID:paolobarbaglia,項目名稱:coursera_recommender_systems,代碼行數:17,代碼來源:SVDItemScorer.java


注:本文中的org.grouplens.lenskit.data.history.History類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。