[ Skip to the content ]

Institute of Formal and Applied Linguistics Wiki


[ Back to the navigation ]

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision Both sides next revision
spark:spark-introduction [2014/11/11 09:05]
straka
spark:spark-introduction [2014/11/11 09:06]
straka
Line 71: Line 71:
  
 lines = sc.textFile("/net/projects/spark-example-data/points", sc.defaultParallelism) lines = sc.textFile("/net/projects/spark-example-data/points", sc.defaultParallelism)
-data = lines.map(lambda line: np.array([float(x) for x in line.split()])).cache()+data = lines.map(lambda line: map(floatline.split())).cache()
  
 K = 50 K = 50

[ Back to the navigation ] [ Back to the content ]