Package org.apache.mahout.cf.taste.impl.recommender.svd

Examples of org.apache.mahout.cf.taste.impl.recommender.svd.SVDRecommender$Estimator


        // (2*(-0.24019223070763077)+7*(-0.6465846072812313)) / ((-0.24019223070763077) + (-0.6465846072812313)) = 5,65
        // Corn:
        // (2*(-0.24019223070763077)+2*(0.8196561646738477)) / (-0.24019223070763077+0.8196561646738477) = 2
        System.out.println("UserBased: Wolf should eat: "+id2thing.toStringID(r.getItemID())+" Rating: "+r.getValue());
      }
      SVDRecommender svdrecommender = new SVDRecommender(model, new SVDPlusPlusFactorizer(model, 4, 1000));
      for(RecommendedItem r : svdrecommender.recommend(id2thing.toLongID("Sheep"), 3)) {
        System.out.println("SVD: Sheep should eat: "+id2thing.toStringID(r.getItemID())+" Rating: "+r.getValue());
      }
    } catch (TasteException e) {
      e.printStackTrace();
    }
View Full Code Here

TOP

Related Classes of org.apache.mahout.cf.taste.impl.recommender.svd.SVDRecommender$Estimator

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.