무회blog

test, tensorflow , bert, 설치 , 윈도우환경 본문

Python/tensorflow

test, tensorflow , bert, 설치 , 윈도우환경

최무회 2020. 7. 29. 19:42

python 3.5
tensorflow 1.12.1
bert-serving-server 1.9.1
bert-serving-cline 1.9.1

1.BERT 클라이언트와 서버 설정
pip install bert-serving-server # server
pip install bert-serving-client # client,

bert-serving-start -model_dir chinese_L-12_H-768_A-12 -num_worker=1

bert-serving-start -model_dir /D:app_lib/bert_lib /chinese_L-12_H-768_A-12/ -num_worker=2

D:\app_src\anaconda\04-srcTest\test_bert\chinese_L-12_H-768_A-12


conda create -n tensorflow python==3.7

conda update -n base -c defaults conda
C:\app\Anaconda\anacondas\envs\tensorflow

conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/
conda config --set show_channel_urls yes

source activate tensorflow
activate tensorflow
pip install tensorflow

import tensorflow as tf
s=tf.constant(1)

conda install nb_conda

pip install --upgrade --ignore-installed tensorflow
pip install --user --upgrade --ignore-installed tensorflow

import tensorflow as tf

pip install bert-tensorflow

pip install bert-serving-server ===> pip install bert-serving-server==1.8

cmd 창에서 관리자 권한으로 실행 후 쥬피터에서 실행 가능

conda install nb_conda

Comments