GFormer: Accelerating Large Language Models with Optimized Transformers on Gaudi Processors
Heterogeneous hardware like Gaudi processor has been developed to enhance computations, especially matrix operations for Transformer-based large language models (LLMs) for generative AI tasks. However, our analysis indicates that Transformers are not fully optimized on such emerging hardware, primarily due to inadequate optimizations in non-matrix computational kernels like Softmax and in heterogeneous resource utilization, particularly when processing long sequences. To address these issues, we propose an integrated approach (called GFormer) that merges sparse and linear attention mechanisms. GFormer aims to maximize the computational capabilities of the Gaudi processor's Matrix Multiplication Engine (MME) and Tensor Processing Cores (TPC) without compromising model quality. GFormer includes a windowed self-attention kernel and an efficient outer product kernel for causal linear attention, aiming to optimize LLM inference on Gaudi processors. Evaluation shows that GFormer significantly improves efficiency and model performance across various tasks on the Gaudi processor and outperforms state-of-the-art GPUs.
Code (0)
등록된 구현이 없습니다.
Tasks
MMEMethods 이 논문이 사용한 방법론
Similar Papers 제목 키워드 기반
Clinical-Longformer and Clinical-BigBird: Transformers for long clinical sequences
Transformers-based models, such as BERT, have dramatically improved the performance for various natural language processing tasks. The clinical knowledge enriched model, namely ClinicalBERT, also achieved state-of-the-ar…
Clinical KnowledgeDocument ClassificationFew-Shot Learningnamed-entity-recognition+5SGFormer: Simplifying and Empowering Transformers for Large-Graph Representations
Learning representations on large-sized graphs is a long-standing challenge due to the inter-dependence nature involved in massive data points. Transformers, as an emerging class of foundation encoders for graph-structur…
Node Property PredictionPhilosophyProperty PredictionA Comparative Study of Pretrained Language Models for Long Clinical Text
Objective: Clinical knowledge enriched transformer models (e.g., ClinicalBERT) have state-of-the-art results on clinical NLP (natural language processing) tasks. One of the core limitations of these transformer models is…
Clinical KnowledgeDocument Classificationnamed-entity-recognitionNamed Entity Recognition+3SegFormer: Simple and Efficient Design for Semantic Segmentation with Transformers
We present SegFormer, a simple, efficient yet powerful semantic segmentation framework which unifies Transformers with lightweight multilayer perception (MLP) decoders. SegFormer has two appealing features: 1) SegFormer …
2D Semantic SegmentationC++ codeCrack SegmentationDecoder+2SGFormer: Single-Layer Graph Transformers with Approximation-Free Linear Complexity
Learning representations on large graphs is a long-standing challenge due to the inter-dependence nature. Transformers recently have shown promising performance on small graphs thanks to its global attention for capturin…
Deep AttentionRepresentation Learning