with tf.device('/cpu:0'):
    embedding = tf.get_variable('embedding', [vocabulary_size, embedding_size])
inputs = tf.nn.embedding_lookup(embedding, input_data)
Injecting pre-trained word2vec vectors into TensorFlow seq2seq