def _compressor_op(self, matrix_compressor, a_matrix_tfvar):
    """Creates compressor op based on matrix_compressor.

    Meant to create the factors once at begin_compression_step.
    Args:
      matrix_compressor: specifies the matrix compressor object.
      a_matrix_tfvar: the tf tensor to be compressed.
    """

    [b_matrix_out, c_matrix_out
    ] = tf.compat.v1.py_function(matrix_compressor.static_matrix_compressor,
                                 [a_matrix_tfvar], [tf.float32, tf.float32])

    self.b_matrix_tfvar.assign(b_matrix_out)
    self.c_matrix_tfvar.assign(c_matrix_out)
    return