当前位置:网站首页>pyspark jieba 集群模型 对文本进行切词
pyspark jieba 集群模型 对文本进行切词
2022-08-09 14:55:00 【yisun123456】
如果是单个机器或者是local模式,简单的方式就是在节点上pip install jieba就完事了。但是在集群上肯定不能安装啊。怎么办呢??
spark可以使用自己的镜像。比如本地有一个conda的envs的环境。可以将这个打包,在提交任务的时候可以分发到各个executor上。
spark-submit \
--name seg_tags \
--queue root.niubi_queue \
--deploy-mode cluster \
--driver-memory 10g \
--executor-memory 10g \
--conf spark.dynamicAllocation.maxExecutors=300\
--conf spark.executor.cores=3\
--conf spark.default.parallelism=2000\
--conf spark.port.maxRetries=200\
--conf spark.yarn.dist.archives=hdfs://dfs4/user/niubi/niubi.tar.gz#mypython \
--conf spark.yarn.appMasterEnv.PYSPARK_PYTHON=./mypython/myEnvs/bin/python \
./seg_tags.py
边栏推荐
猜你喜欢
随机推荐
Qt对话框中show和exec的区别
记一次解决Mysql:Incorrect string value: ‘\xF0\x9F\x8D\x83\xF0\x9F...‘ for column 插入emoji表情报错问题
走得通,看得见!你的交通“好帮手”
Stock trading stylized how to understand their own trading system?
内存泄露检测工具VLD(Visual Leak Detector)使用说明
What are the misunderstandings about the programmatic trading system interface?
常微分方程的幂级数解法
【C语言初阶】详解分支语句
What do professional quantitative traders think about quantitative trading?
Several important functions of singly linked list (including insertion, deletion, reversal, etc.)
It is deeply recognized that the compiler can cause differences in the compilation results
编译器不同,模式不同,对结果的影响
How to List < Map> grouping numerical merge sort
C#轻量级ORM使用 Dapper+Contrib
cheerio根据多个class匹配
Simple analysis of regularization principle (L1 / L2 regularization)
Noun concept summary (not regularly updated ~ ~)
你知道亚马逊代运营的成本是多少吗?
【超级账本开发者系列】专访——肖慧 : 不忘初心,方得始终
PAT1027 打印沙漏