from pyspark import SparkConf, SparkContext

# 创建Spark上下文
conf = SparkConf().setAppName("example_app")
sc = SparkContext(conf=conf)
 

更多推荐