def main():
with open(path, 'r') as data_file:
movieList = json.load(data_file)
count = 0
np.seterr(divide='ignore', invalid='ignore')
for movie in movieList:
if movie["reviews"] and movie["critics"]:
readMovie(movie)
# reviewer_list[movie["movieTitle"]] = recommender(movie)
# cluster[movie["movieTitle"]] = HAC(movie)
score_list[movie["movieTitle"]] = newScore(movie)
count += 1
print count
break
with open("scoreList.json", 'w+') as outfile:
json.dump(score_list, outfile, indent=4, separators=(',', ': '))
评论列表
文章目录