import tensorflow as tf

            initializer = tf.random_uniform_initializer(minval=-weight_scale, maxval=weight_scale)
        else:
            initializer = tf.random_normal_initializer(stddev=weight_scale)

        with tf.device('/cpu:0'):  # embeddings can take a very large amount of memory, so
            # storing them in GPU memory can be impractical
            if encoder.binary:
                embeddings = None  # inputs are token ids, which need to be mapped to vectors (embeddings)
