Skip to main content
QUICK REVIEW

[Paper Review] On the Effectiveness of Low-Rank Matrix Factorization for LSTM Model Compression

Genta Indra Winata, Andrea Madotto|arXiv (Cornell University)|Aug 27, 2019
Topic ModelingComputer Science47 references26 citations
TL;DR

This paper proposes low-rank matrix factorization (MF) as a post-processing compression method for Long Short-Term Memory (LSTM) networks, demonstrating that MF outperforms pruning in compressing LSTM recurrent gates—especially for additive recurrences—by preserving salient features through higher matrix norm stability. The method achieves up to 2x (200% faster) inference speed with minimal performance drop, and even slight improvement after fine-tuning on highly compressed models.

ABSTRACT

Despite their ubiquity in NLP tasks, Long Short-Term Memory (LSTM) networks suffer from computational inefficiencies caused by inherent unparallelizable recurrences, which further aggravates as LSTMs require more parameters for larger memory capacity. In this paper, we propose to apply low-rank matrix factorization (MF) algorithms to different recurrences in LSTMs, and explore the effectiveness on different NLP tasks and model components. We discover that additive recurrence is more important than multiplicative recurrence, and explain this by identifying meaningful correlations between matrix norms and compression performance. We compare our approach across two settings: 1) compressing core LSTM recurrences in language models, 2) compressing biLSTM layers of ELMo evaluated in three downstream NLP tasks.

Motivation & Objective

  • To investigate the effectiveness of low-rank matrix factorization (MF) and pruning for compressing LSTM models in NLP tasks.
  • To determine whether MF or pruning is more effective for different LSTM components, particularly additive vs. multiplicative recurrences.
  • To analyze the relationship between matrix norms (L1, nuclear) and compression performance.
  • To evaluate compression in both language modeling and downstream NLP tasks, including fine-tuning effects on highly compressed models.
  • To provide a practical, post-processing compression method for already-tuned, compact models where retraining is costly.

Proposed method

  • Apply low-rank matrix factorization to weight matrices in LSTM gates (W_i, W_h) by decomposing them into two lower-rank matrices (U × V), reducing parameter count.
  • Use structured pruning to remove low-magnitude weights in LSTM matrices, comparing performance with MF at varying compression ratios.
  • Measure compression effectiveness via inference speedup and evaluation metric drop (e.g., perplexity, accuracy) on PTB, Wiki-Text 2, SQuAD, and SNLI.
  • Analyze matrix norms (L1, standard deviation, nuclear norm) to correlate structural properties with compression performance.
  • Perform fine-tuning on highly compressed models (e.g., ~98% compression) to recover or improve performance.
  • Compare MF and pruning across different components (W_i vs. W_h) and tasks to identify patterns in compressibility.

Experimental results

Research questions

  • RQ1Does low-rank matrix factorization outperform pruning in compressing LSTM models across diverse NLP tasks?
  • RQ2Is additive recurrence more compressible or more critical than multiplicative recurrence in LSTMs?
  • RQ3How do matrix norms (L1, nuclear) correlate with compression performance and model stability?
  • RQ4Can highly compressed models (e.g., 98% reduction) be fine-tuned to achieve better performance than the original model?
  • RQ5Does the inherent low-rank structure of certain weight matrices (e.g., W_h) explain better compression outcomes?

Key findings

  • Low-rank matrix factorization consistently outperforms pruning in compressing LSTM gates, especially for additive recurrences, due to better preservation of salient features.
  • Additive recurrence (W_i) is more compressible and critical than multiplicative recurrence (W_h), as MF on W_i yields better performance at high compression ratios.
  • Matrix norms—particularly L1 norm and its standard deviation—show strong correlation with compression performance: MF increases norm variability, indicating better retention of important weights.
  • Nuclear norm analysis confirms that W_h is inherently lower-rank than W_i, explaining why MF works better on W_h in some settings, especially when compression is low.
  • After fine-tuning, models compressed to ~98% parameter reduction achieved up to 2x (200%) faster inference while slightly outperforming the uncompressed baseline on PTB.
  • Pruning performs better than MF only on highly sparse matrices like W_h in ELMo, where it maintains L1 norm stability by zeroing already-small values.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.