Google Cloud Dataproc 용 Python 클라이언트 라이브러리를 사용하여 클러스터를 자동으로 프로비저닝하고 작업을 제출하는 등의 스크립트를 실행하고 있습니다. 직장이면 ImportError: no module named pandas
과 함께 반환됩니다. 나는 판다 (pandas)를 가져오고, 스크립트에서 작업이 실행되는 다른 여러 패키지를 가져옵니다. 이 문제를 해결하는 방법을 모르겠습니다.Dataproc에서 작업 제출을 시도 할 때 "ImportError : 모듈 이름이 pandas"가 아닙니다.
이렇게 의미가 있습니까?
#!/bin/bash
list= "python-pandas, python-numpy, python-argparse"
ROLE=$(/usr/share/google/get_metadata_value attributes/dataproc-role)
if [[ "${ROLE}" == 'Master' ]]; then
for i in $list; do
sudo apt-get install -y $i
done
wget -P /home/anaconda2/ https://repo.continuum.io/archive/Anaconda2-4.3.1-Linux-x86_64.sh
bash /home/anaconda2/Anaconda2-4.3.1-Linux-x86_64.sh -b -f -p /home/anaconda2/
chmod /home/anaconda2 0777
/home/anaconda2/bin/pip install lxml
/home/anaconda2/bin/pip install jupyter-spark
/home/anaconda2/bin/pip install jgscm
fi
는 그런 것 같아요 [ 'pandas'] (http://pandas.pydata.org/) 모듈을 설치해야합니다. –