代做COMPSCI 753 Algorithms for Massive Data (Exam) 2021调试数据库编程

COMPSCI 753 (11/ 11/2021 17:00) Algorithms for Massive Data (Exam)

1 Locality-Sensitive Hashing

Given three documents S1, S2 , S3  and a customized query document q:

S1 = {3, 4, 5}, S2  = {0, 1, 2}, S3  = {0, 1, 3}, q = {2, 3, 4, h(y)};

h(y) = y   mod 6.

where y is the last digit of your Student ID. For instance, suppose my Stu- dentID=xxxxx7, my query document would be q= {2, 3, 4, 1}.

1.1    Computing MinHash Signatures

1. Generate the bit-vector representation for {S1, S2 , S3 , q} in feature space {0, 1, 2, 3, 4, 5}.        [1 mark]

2. Generate the MinHash matrix for {S1, S2 , S3 , q} using the following four MinHash functions.      [2 marks]

h1 (x) = x    mod 6

h2 (x) = (x + 1)   mod 6

h3 (x) = (x + 3)   mod 6

h4 (x) = (x + 5)   mod 6

3. Consider the query q and estimate the signature-based Jaccard similari- ties: J(q, S1 ), J(q, S2 ), and J(q, S3 ).    [1 mark]

1.2    Tuning Parameters for rNNS

In our lecture, we have learnt to formulate the collision probability (i.e., S- curve) given the number of bands b and the number of rows per band r as follows: Pr(s) = 1 - (1 - sr )b.

Consider three sets of parameters (r=2,b=10), (r=6,b=30), (r=10,b=50). The collision probabilities for similarity s in range of [0,1] for each (r ,b) are pro- vided accordingly as follows:

1. Which settings give at most 5% of false negatives for any 70%-similar pairs? Briefly explain the reason.    [1 mark]

2. Which settings give at most 15% of false positives for any 30%-similar pairs? Briefly explain the reason.    [1 mark]

1.3    c-Approximate Randomized rNNS [3 marks]

We have learnt that a family of functions H is called (d1 , d2 , p1 , p2 )-sensitive with collision probability p1  > p2  and c > 1 if the following conditions hold for any uniformly chosen h ∈ H and 8 x, y ∈ U :

If d(x, y) ≤ r , Pr[h(x) = h(y)] ≥ p1  for similar points, and

If d(x, y) ≥ cr , Pr[h(x) = h(y)] ≤ p2  for dissimilar points.

Consider a family transformation from (d1 , d2 , p1 , p2 )-sensitive to (d1 , d2 , 1 (1 — p1(k))L , 1 — (1 — p2(k))L )-sensitive,where k and L refer to the number of hash functions and the number of hash tables, respectively. Briefly describe steps to achieve such transformation. What is the expected impact on probability bounds after the transformation?

2    Data Stream Algorithms

2.1    Misra-Gries Algorithm [1 mark]

Given the data stream below, perform. the Misra-Gries algorithm with k = 3 counters and present the summary, including the elements and its counter values, when the execution of the algorithm is finished.

S = {4, 36, 14, 36, 57, 36, 22, 57, 5, 57}

2.2 CountMin Sketch Algorithm [4 marks]

Given the following three hash functions, perform the CountMin Sketch al- gorithm on the same data stream S in Section 2.1 and present the (i) hash table, (ii) counter matrix, and (iii) estimated frequency of each element in a stream after processing all elements.

h1 (x) = x    mod 3

h2 (x) = (3x + 1)   mod 3

h3 (x) = (5x + 2)    mod 3

2.3 Count Sketch Algorithm [4 marks]

Consider the same data stream S and hash functions in Section 2.2. Given the sign hash functions below, perform the Count Sketch algorithm and present the (i) hash table, (ii) counter matrix, and (iii) estimated frequency of each element in a stream after processing all elements.

s1 (x) = ((2x + 1)    mod 3)   mod 2

s2 (x) = ((3x + 2)    mod 3)   mod 2

s3 (x) = ((5x + 2)    mod 3)   mod 2

3 Algorithms for Graphs

3.1 Biased PageRank

Given a directed graph:

1. We have learnt the matrix formulation of PageRank r = M · r. Convert the above graph to a column-stochastic adjacency matrix.        [1 mark]

2. Compute the PageRank of the graph above.                        [2 marks]

3. Let β = 0.8, calculate the biased PageRank with the teleport set S = {[the last digit of your student ID] mod 4}.           [3 marks]

Note: The rank of each node should round to 3 decimal places.

3.2    Community Detection

1. Use two or three sentences to explain the diferences between modularity maximization and the Girvan-Newman algorithm for community detec- tion.                                                                          [2 marks]

2. In the modularity maximization algorithm, which pair of nodes in the graph below should be merged in the first step to maximize the gain of modularity? Explain your answer. If there are multiple pairs of nodes with the same modularity gain, report all of them to get full mark. [4 marks]

3.3    In  uence Maximization

1. Compute the influence spread of the seed set S = {1} using the Indepen- dent Cascade (IC) model on the following graph.                 [2 marks]

2. In the lecture, we have learnt a greedy algorithm to find a seed set for maximizing the influence based on the IC model. Starting with empty seed set, which node will be the first to be added to the seed set in the greedy algorithm?      [2 marks]

4 Recommender Systems

4.1    Collaborative filtering

Given the following user-item interaction matrix:

1. Apply the basic user-based collaborative filtering (without considering  bias) with cosine similarity. Give the top-1 recommended item to user  u2 .                                                                            [3 marks]

2. In the lecture, we have discussed how to model the rating bias including  (i) the bias over all transactions; (ii) the bias of a user; and (iii) the bias of an item in collaborative filtering. What is the rating of user u1 to item p2  if all biases are considered?                                          [3 marks]

Note: The predicted ratings should round to one decimal place.

4.2    Evaluation of recommender system

A recommender system generates a ranked list of items for a specific user u as (p3 ; p10 ; p5 ; p7 ; p1 ; p9 ; p2 ; p4 ; p6 ; p8 ). The ranked list contains all items that haven’t been purchased by the user in the training data. We find that the user only buys items p10  and p1  in the test data.

1. Compute the AUC for user u.                                           [1 mark]

2. If top-3 items are returned to the user, what are the values of Precision@3 and Recall@3?        [2 marks]

Note: The AUC, Precision@3 and Recall@3 should round to 2 decimal places.

4.3    Application of Recommendation Algorithms

A start-up company plans to build a system for recommending training courses to users. The company has 100,000 users and 500 courses. Each user in the database has a complete profile with age, gender, educational back- ground, and working experience. Each course has a short description of its content. Ninety percent of the users have taken one course, and the remaining users have taken more than two courses.

The data scientists in the company are considering three recommendation al- gorithms that we have learnt in the lectures: (a) user-based collaborative fil- tering; (b) item-based collaborative filtering; and (c) content-based approach.

1. Which of (a) and (b) is more appropriate for the above system? Explain the reason.        [2 marks]

2. If you were one of the data scientists, which of the above methods will you use for recommending new courses to users? Explain the reason. [2 marks]

3. The company wants a single model to support (i) recommending existing courses to an arbitrary group of users; (ii) recommending existing courses to new users; and (iii) recommending new courses to existing users. Which of the above methods can be used? If none of them apply, give a solution based on the methods we learnt in the lectures.     [3 marks]




热门主题

课程名

mktg2509 csci 2600 38170 lng302 csse3010 phas3226 77938 arch1162 engn4536/engn6536 acx5903 comp151101 phl245 cse12 comp9312 stat3016/6016 phas0038 comp2140 6qqmb312 xjco3011 rest0005 ematm0051 5qqmn219 lubs5062m eee8155 cege0100 eap033 artd1109 mat246 etc3430 ecmm462 mis102 inft6800 ddes9903 comp6521 comp9517 comp3331/9331 comp4337 comp6008 comp9414 bu.231.790.81 man00150m csb352h math1041 eengm4100 isys1002 08 6057cem mktg3504 mthm036 mtrx1701 mth3241 eeee3086 cmp-7038b cmp-7000a ints4010 econ2151 infs5710 fins5516 fin3309 fins5510 gsoe9340 math2007 math2036 soee5010 mark3088 infs3605 elec9714 comp2271 ma214 comp2211 infs3604 600426 sit254 acct3091 bbt405 msin0116 com107/com113 mark5826 sit120 comp9021 eco2101 eeen40700 cs253 ece3114 ecmm447 chns3000 math377 itd102 comp9444 comp(2041|9044) econ0060 econ7230 mgt001371 ecs-323 cs6250 mgdi60012 mdia2012 comm221001 comm5000 ma1008 engl642 econ241 com333 math367 mis201 nbs-7041x meek16104 econ2003 comm1190 mbas902 comp-1027 dpst1091 comp7315 eppd1033 m06 ee3025 msci231 bb113/bbs1063 fc709 comp3425 comp9417 econ42915 cb9101 math1102e chme0017 fc307 mkt60104 5522usst litr1-uc6201.200 ee1102 cosc2803 math39512 omp9727 int2067/int5051 bsb151 mgt253 fc021 babs2202 mis2002s phya21 18-213 cege0012 mdia1002 math38032 mech5125 07 cisc102 mgx3110 cs240 11175 fin3020s eco3420 ictten622 comp9727 cpt111 de114102d mgm320h5s bafi1019 math21112 efim20036 mn-3503 fins5568 110.807 bcpm000028 info6030 bma0092 bcpm0054 math20212 ce335 cs365 cenv6141 ftec5580 math2010 ec3450 comm1170 ecmt1010 csci-ua.0480-003 econ12-200 ib3960 ectb60h3f cs247—assignment tk3163 ics3u ib3j80 comp20008 comp9334 eppd1063 acct2343 cct109 isys1055/3412 math350-real math2014 eec180 stat141b econ2101 msinm014/msing014/msing014b fit2004 comp643 bu1002 cm2030
联系我们
EMail: 99515681@qq.com
QQ: 99515681
留学生作业帮-留学生的知心伴侣!
工作时间:08:00-21:00
python代写
微信客服:codinghelp
站长地图