Updated import_mallet to pre-compute transposed matrices.