CentOS7 安装pip
Prerequest
yum -y install epel-releaseyum -y install python-pip
pip install --upgrade pip
Alternative:
pip install tensorflow
pip install tensorflow-gpu
in python prompt:
import tensorflow as tf
hello = tf.constant('Hello, TensorFlow!')
sess = tf.Session()
print(sess.run(hello))
git clone https://github.com/tensorflow/nmt
Installation
Simple Trainningnmt/scripts/download_iwslt15.sh /tmp/nmt_data
mkdir /tmp/nmt_model
python -m nmt.nmt \
--src=vi --tgt=en \
--vocab_prefix=/tmp/nmt_data/vocab \
--train_prefix=/tmp/nmt_data/train \
--dev_prefix=/tmp/nmt_data/tst2012 \
--test_prefix=/tmp/nmt_data/tst2013 \
--out_dir=/tmp/nmt_model \
--num_train_steps=12000 \
--steps_per_stats=100 \
--num_layers=2 \
--num_units=128 \
--dropout=0.2 \
--metrics=bleu
Reference:
https://ehlxr.me/2017/01/07/CentOS-7-%E5%AE%89%E8%A3%85-Python3%E3%80%81pip3/https://www.tensorflow.org/install/install_linux#ValidateYourInstallation
https://github.com/tensorflow/nmt
没有评论:
发表评论