liger-kernel 0.1.0__py3-none-any.whl → 0.2.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,307 @@
1
+ Metadata-Version: 2.1
2
+ Name: liger-kernel
3
+ Version: 0.2.0
4
+ Summary: Efficient Triton kernels for LLM Training
5
+ Home-page: https://github.com/linkedin/Liger-Kernel
6
+ License: BSD-2-Clause
7
+ Keywords: triton,kernels,LLM training,deep learning,Hugging Face,PyTorch,GPU optimization
8
+ Classifier: Development Status :: 4 - Beta
9
+ Classifier: Intended Audience :: Developers
10
+ Classifier: Intended Audience :: Science/Research
11
+ Classifier: Intended Audience :: Education
12
+ Classifier: License :: OSI Approved :: BSD License
13
+ Classifier: Programming Language :: Python :: 3
14
+ Classifier: Programming Language :: Python :: 3.8
15
+ Classifier: Programming Language :: Python :: 3.9
16
+ Classifier: Programming Language :: Python :: 3.10
17
+ Classifier: Topic :: Software Development :: Libraries
18
+ Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
19
+ Description-Content-Type: text/markdown
20
+ License-File: LICENSE
21
+ License-File: NOTICE
22
+ Requires-Dist: torch>=2.1.2
23
+ Requires-Dist: triton>=2.3.0
24
+ Requires-Dist: transformers>=4.42.0
25
+ Provides-Extra: dev
26
+ Requires-Dist: matplotlib>=3.7.2; extra == "dev"
27
+ Requires-Dist: flake8>=4.0.1.1; extra == "dev"
28
+ Requires-Dist: black>=24.4.2; extra == "dev"
29
+ Requires-Dist: isort>=5.13.2; extra == "dev"
30
+ Requires-Dist: pytest>=7.1.2; extra == "dev"
31
+ Requires-Dist: datasets>=2.19.2; extra == "dev"
32
+
33
+ # Liger Kernel: Efficient Triton Kernels for LLM Training
34
+
35
+
36
+
37
+ [![Downloads](https://static.pepy.tech/badge/liger-kernel)](https://pepy.tech/project/liger-kernel) [![PyPI version](https://badge.fury.io/py/liger-kernel.svg)](https://badge.fury.io/py/liger-kernel) [![PyPI version](https://badge.fury.io/py/liger-kernel-nightly.svg)](https://badge.fury.io/py/liger-kernel-nightly)
38
+ [![](https://dcbadge.vercel.app/api/server/cudamode?style=flat)](https://discord.gg/CX2YmNmn)
39
+
40
+ <img src="https://raw.githubusercontent.com/linkedin/Liger-Kernel/main/docs/images/logo-banner.png">
41
+
42
+ [Installation](#installation) | [Getting Started](#getting-started) | [Examples](#examples) | [APIs](#apis) | [Structure](#structure) | [Contributing](#contributing)
43
+
44
+ <details>
45
+ <summary>Latest News 🔥</summary>
46
+
47
+ - [2024/8/31] CUDA MODE talk, [Liger-Kernel: Real-world Triton kernel for LLM Training](https://discord.gg/6CNeDAjq?event=1273323969788772455)
48
+ - [2024/8/23] Official release: check out our [X post](https://x.com/hsu_byron/status/1827072737673982056)
49
+
50
+ </details>
51
+
52
+
53
+ **Liger (Linkedin GPU Efficient Runtime) Kernel** is a collection of Triton kernels designed specifically for LLM training. It can effectively increase multi-GPU **training throughput by 20%** and reduces **memory usage by 60%**. We have implemented **Hugging Face Compatible** `RMSNorm`, `RoPE`, `SwiGLU`, `CrossEntropy`, `FusedLinearCrossEntropy`, and more to come. The kernel works out of the box with [Flash Attention](https://github.com/Dao-AILab/flash-attention), [PyTorch FSDP](https://pytorch.org/tutorials/intermediate/FSDP_tutorial.html), and [Microsoft DeepSpeed](https://github.com/microsoft/DeepSpeed). We welcome contributions from the community to gather the best kernels for LLM training.
54
+
55
+ ## Supercharge Your Model with Liger Kernel
56
+
57
+
58
+ ![Banner](https://raw.githubusercontent.com/linkedin/Liger-Kernel/main/docs/images/banner.GIF)
59
+
60
+ With one line of code, Liger Kernel can increase throughput by more than 20% and reduce memory usage by 60%, thereby enabling longer context lengths, larger batch sizes, and massive vocabularies.
61
+
62
+
63
+ | Speed Up | Memory Reduction |
64
+ |--------------------------|-------------------------|
65
+ | ![Speed up](https://raw.githubusercontent.com/linkedin/Liger-Kernel/main/docs/images/e2e-tps.png) | ![Memory](https://raw.githubusercontent.com/linkedin/Liger-Kernel/main/docs/images/e2e-memory.png) |
66
+
67
+ > **Note:**
68
+ > - Benchmark conditions: LLaMA 3-8B, Batch Size = 8, Data Type = `bf16`, Optimizer = AdamW, Gradient Checkpointing = True, Distributed Strategy = FSDP1 on 8 A100s.
69
+ > - Hugging Face models start to OOM at a 4K context length, whereas Hugging Face + Liger Kernel scales up to 16K.
70
+
71
+ ## Examples
72
+
73
+ ### Basic
74
+
75
+ | **Example** | **Description** | **Lightning Studio** |
76
+ |------------------------------------------------|---------------------------------------------------------------------------------------------------|----------------------|
77
+ | [**Hugging Face Trainer**](https://github.com/linkedin/Liger-Kernel/tree/main/examples/huggingface) | Train LLaMA 3-8B ~20% faster with over 40% memory reduction on Alpaca dataset using 4 A100s with FSDP | TBA |
78
+ | [**Lightning Trainer**](https://github.com/linkedin/Liger-Kernel/tree/main/examples/lightning) | Increase 15% throughput and reduce memory usage by 40% with LLaMA3-8B on MMLU dataset using 8 A100s with DeepSpeed ZeRO3 | TBA |
79
+
80
+ ### Advanced
81
+
82
+ | **Example** | **Description** | **Lightning Studio** |
83
+ |------------------------------------------------|---------------------------------------------------------------------------------------------------|----------------------|
84
+ | [**Medusa Multi-head LLM (Retraining Phase)**](https://github.com/linkedin/Liger-Kernel/tree/main/examples/medusa) | Reduce memory usage by 80% with 5 LM heads and improve throughput by 40% using 8 A100s with FSDP | TBA |
85
+
86
+ ## Key Features
87
+
88
+ - **Ease of use:** Simply patch your Hugging Face model with one line of code, or compose your own model using our Liger Kernel modules.
89
+ - **Time and memory efficient:** In the same spirit as Flash-Attn, but for layers like **RMSNorm**, **RoPE**, **SwiGLU**, and **CrossEntropy**! Increases multi-GPU training throughput by 20% and reduces memory usage by 60% with **kernel fusion**, **in-place replacement**, and **chunking** techniques.
90
+ - **Exact:** Computation is exact—no approximations! Both forward and backward passes are implemented with rigorous unit tests and undergo convergence testing against training runs without Liger Kernel to ensure accuracy.
91
+ - **Lightweight:** Liger Kernel has minimal dependencies, requiring only Torch and Triton—no extra libraries needed! Say goodbye to dependency headaches!
92
+ - **Multi-GPU supported:** Compatible with multi-GPU setups (PyTorch FSDP, DeepSpeed, DDP, etc.).
93
+
94
+ ## Target Audiences
95
+
96
+ - **Researchers**: Looking to compose models using efficient and reliable kernels for frontier experiments.
97
+ - **ML Practitioners**: Focused on maximizing GPU training efficiency with optimal, high-performance kernels.
98
+ - **Curious Novices**: Eager to learn how to write reliable Triton kernels to enhance training efficiency.
99
+
100
+
101
+ ## Installation
102
+
103
+ ### Dependencies
104
+
105
+ - `torch >= 2.1.2`
106
+ - `triton >= 2.3.0`
107
+ - `transformers >= 4.42.0`
108
+
109
+ > **Note:**
110
+ > Our kernels inherit the full spectrum of hardware compatibility offered by [Triton](https://github.com/triton-lang/triton).
111
+
112
+ To install the stable version:
113
+
114
+ ```bash
115
+ $ pip install liger-kernel
116
+ ```
117
+
118
+ To install the nightly version:
119
+
120
+ ```bash
121
+ $ pip install liger-kernel-nightly
122
+ ```
123
+
124
+ To install from source:
125
+
126
+ ```bash
127
+ git clone https://github.com/linkedin/Liger-Kernel.git
128
+ cd Liger-Kernel
129
+ pip install -e .
130
+ ```
131
+ ## Getting Started
132
+
133
+ There are a couple ways to apply Liger kernels, depending on the level of customization required.
134
+
135
+ ### 1. Use AutoLigerKernelForCausalLM
136
+
137
+ Using the `AutoLigerKernelForCausalLM` is the simplest approach, as you don't have to import a model-specific patching API. If the model type is supported, the modeling code will be automatically patched using the default settings.
138
+
139
+ ```python
140
+ from liger_kernel.transformers import AutoLigerKernelForCausalLM
141
+
142
+ # This AutoModel wrapper class automatically monkey-patches the
143
+ # model with the optimized Liger kernels if the model is supported.
144
+ model = AutoLigerKernelForCausalLM.from_pretrained("path/to/some/model")
145
+ ```
146
+
147
+ ### 2. Apply Model-Specific Patching APIs
148
+
149
+ Using the [patching APIs](#patching), you can swap Hugging Face models with optimized Liger Kernels.
150
+
151
+ ```python
152
+ import transformers
153
+ from liger_kernel.transformers import apply_liger_kernel_to_llama
154
+
155
+ model = transformers.AutoModelForCausalLM("path/to/llama/model")
156
+
157
+ # Adding this line automatically monkey-patches the model with the optimized Liger kernels
158
+ apply_liger_kernel_to_llama()
159
+
160
+ # You could alternatively specify exactly which kernels are applied
161
+ apply_liger_kernel_to_llama(
162
+ rope=True,
163
+ swiglu=True,
164
+ cross_entropy=True,
165
+ fused_linear_cross_entropy=False,
166
+ rms_norm=False
167
+ )
168
+ ```
169
+
170
+ ### 3. Compose Your Own Model
171
+
172
+ You can take individual [kernels](#kernels) to compose your models.
173
+
174
+ ```python
175
+ from liger_kernel.transformers import LigerFusedLinearCrossEntropyLoss
176
+ import torch.nn as nn
177
+ import torch
178
+
179
+ model = nn.Linear(128, 256).cuda()
180
+
181
+ # fuses linear + cross entropy layers together and performs chunk-by-chunk computation to reduce memory
182
+ loss_fn = LigerFusedLinearCrossEntropyLoss()
183
+
184
+ input = torch.randn(4, 128, requires_grad=True, device="cuda")
185
+ target = torch.randint(256, (4, ), device="cuda")
186
+
187
+ loss = loss_fn(model.weight, input, target)
188
+ loss.backward()
189
+ ```
190
+
191
+
192
+ ## Structure
193
+
194
+ ### Source Code
195
+
196
+ - `ops/`: Core Triton operations.
197
+ - `transformers/`: PyTorch `nn.Module` implementations built on Triton operations, compliant with the `transformers` API.
198
+
199
+ ### Tests
200
+
201
+ - `transformers/`: Correctness tests for the Triton-based layers.
202
+ - `convergence/`: Patches Hugging Face models with all kernels, runs multiple iterations, and compares weights, logits, and loss layer-by-layer.
203
+
204
+ ### Benchmark
205
+
206
+ - `benchmark/`: Execution time and memory benchmarks compared to Hugging Face layers.
207
+
208
+ ## APIs
209
+
210
+ ### AutoModel
211
+
212
+ | **AutoModel Variant** | **API** |
213
+ |-----------|---------|
214
+ | AutoModelForCausalLM | `liger_kernel.transformers.AutoLigerKernelForCausalLM` |
215
+
216
+
217
+ ### Patching
218
+
219
+ | **Model** | **API** | **Supported Operations** |
220
+ |-------------|--------------------------------------------------------------|-------------------------------------------------------------------------|
221
+ | LLaMA 2 & 3 | `liger_kernel.transformers.apply_liger_kernel_to_llama` | RoPE, RMSNorm, SwiGLU, CrossEntropyLoss, FusedLinearCrossEntropy |
222
+ | Mistral | `liger_kernel.transformers.apply_liger_kernel_to_mistral` | RoPE, RMSNorm, SwiGLU, CrossEntropyLoss, FusedLinearCrossEntropy |
223
+ | Mixtral | `liger_kernel.transformers.apply_liger_kernel_to_mixtral` | RoPE, RMSNorm, SwiGLU, CrossEntropyLoss |
224
+ | Gemma1 | `liger_kernel.transformers.apply_liger_kernel_to_gemma` | RoPE, RMSNorm, GeGLU, CrossEntropyLoss, FusedLinearCrossEntropy |
225
+ | Gemma2 | `liger_kernel.transformers.apply_liger_kernel_to_gemma2` | RoPE, RMSNorm, GeGLU, CrossEntropyLoss |
226
+ | Qwen2 | `liger_kernel.transformers.apply_liger_kernel_to_qwen2` | RoPE, RMSNorm, SwiGLU, CrossEntropyLoss, FusedLinearCrossEntropy |
227
+ | Phi3 | `liger_kernel.transformers.apply_liger_kernel_to_phi3` | RoPE, RMSNorm, SwiGLU, CrossEntropyLoss, FusedLinearCrossEntropy |
228
+
229
+
230
+
231
+ ### Kernels
232
+
233
+ | **Kernel** | **API** |
234
+ |---------------------------------|-------------------------------------------------------------|
235
+ | RMSNorm | `liger_kernel.transformers.LigerRMSNorm` |
236
+ | RoPE | `liger_kernel.transformers.liger_rotary_pos_emb` |
237
+ | SwiGLU | `liger_kernel.transformers.LigerSwiGLUMLP` |
238
+ | GeGLU | `liger_kernel.transformers.LigerGEGLUMLP` |
239
+ | CrossEntropy | `liger_kernel.transformers.LigerCrossEntropyLoss` |
240
+ | FusedLinearCrossEntropy | `liger_kernel.transformers.LigerFusedLinearCrossEntropyLoss`|
241
+
242
+ - **RMSNorm**: [RMSNorm](https://arxiv.org/pdf/1910.07467), which normalizes activations using their root mean square, is implemented by fusing the normalization and scaling steps into a single Triton kernel, and achieves ~3X speedup with ~3X peak memory reduction.
243
+ - **RoPE**: [Rotary Positional Embedding](https://arxiv.org/pdf/2104.09864) is implemented by fusing the query and key embedding rotary into a single kernel with inplace replacement, and achieves ~3X speedup with ~3X peak memory reduction.
244
+ - **SwiGLU**: [Swish Gated Linear Units](https://arxiv.org/pdf/2002.05202), given by
245
+ $$\text{SwiGLU}(x)=\text{Swish}_{\beta}(xW+b)\otimes(xV+c)$$
246
+ , is implemented by fusing the elementwise multiplication (denoted by $\otimes$) into a single kernel with inplace replacement, and achieves parity speed with ~1.5X peak memory reduction.
247
+ - **GeGLU**: [GELU Gated Linear Units](https://arxiv.org/pdf/2002.05202), given by
248
+ $$\text{GeGLU}(x)=\text{GELU}(xW+b)\otimes(xV+c)$$
249
+ , is implemented by fusing the elementwise multiplication into a single kernel with inplace replacement, and achieves parity speed with ~1.5X peak memory reduction. Note that the [tanh approximation form of GELU](https://pytorch.org/docs/stable/generated/torch.nn.GELU.html) is used.
250
+ - **CrossEntropy**: [Cross entropy loss](https://pytorch.org/docs/stable/generated/torch.nn.CrossEntropyLoss.html) is implemented by computing both the loss and gradient in the forward pass with inplace replacement of input to reduce the peak memory by avoiding simultaneous materialization of both input logits and gradient. It achieves >2X speedup and >4X memory reduction for common vocab sizes (e.g., 32K, 128K, etc.).
251
+ <!-- TODO: verify vocab sizes are accurate -->
252
+ - **FusedLinearCrossEntropy**: Peak memory usage of cross entropy loss is further improved by fusing the model head with the CE loss and chunking the input for block-wise loss and gradient calculation, a technique inspired by [Efficient Cross Entropy](https://github.com/mgmalek/efficient_cross_entropy). It achieves >4X memory reduction for 128k vocab size. **This is highly effective for large batch size, large sequence length, and large vocabulary sizes.** Please refer to the [Medusa example](https://github.com/linkedin/Liger-Kernel/tree/main/examples/medusa) for individual kernel usage.
253
+
254
+
255
+ <!-- TODO: be more specific about batch size -->
256
+ > **Note:**
257
+ > Reported speedups and memory reductions are with respect to the LLaMA 3-8B Hugging Face layer implementations. All models use 4K hidden size and 4K sequence length and are evaluated based on memory usage and wall time for the forward+backward pass on a single NVIDIA A100 80G GPU using small batch sizes. Liger kernels exhibit more efficient scaling to larger batch sizes, detailed further in the [Benchmark](./benchmark) folder.
258
+
259
+ ## Note on ML Compiler
260
+
261
+ ### Torch Compile
262
+
263
+ Since Liger Kernel is 100% Triton-based, it works seamlessly with [`torch.compile`](https://pytorch.org/tutorials/intermediate/torch_compile_tutorial.html). In the following example, Liger Kernel can further optimize the model on top of Torch Compile, reducing the memory by more than half.
264
+
265
+ | Configuration | Throughput (tokens/sec) | Memory Reserved (GB) |
266
+ |--------------------------------|----------------------------|-------------------------|
267
+ | Torch Compile | 3780 | 66.4 |
268
+ | Torch Compile + Liger Kernel | 3702 | 31.0 |
269
+
270
+ > **Note:**
271
+ > 1. Benchmark conditions: LLaMA 3-8B, Batch Size = 8, Seq Len = 4096, Data Type = `bf16`, Optimizer = AdamW, Gradient Checkpointing = True, Distributed Strategy = FSDP1 on 8 A100s.
272
+ > 2. Tested on torch `2.5.0.dev20240731+cu118`
273
+
274
+ ## Contributing
275
+
276
+ [CONTRIBUTING GUIDE](https://github.com/linkedin/Liger-Kernel/blob/main/CONTRIBUTING.md)
277
+
278
+ ## Acknowledgement
279
+
280
+ - [@claire_yishan](https://twitter.com/claire_yishan) for the LOGO design
281
+ - [flash-attn](https://github.com/Dao-AILab/flash-attention) and [Unsloth](https://github.com/unslothai/unsloth) for inspiration in Triton kernels for training
282
+ - [tiny shakespeare dataset](https://raw.githubusercontent.com/karpathy/char-rnn/master/data/tinyshakespeare/input.txt) by Andrej Karpathy for convergence testing
283
+ - [Efficient Cross Entropy](https://github.com/mgmalek/efficient_cross_entropy) for lm_head + cross entropy inspiration
284
+
285
+
286
+ ## License
287
+
288
+ [BSD 2-CLAUSE](https://github.com/linkedin/Liger-Kernel/blob/main/LICENSE)
289
+
290
+ ## Contact
291
+
292
+ - For collaboration, please send email to byhsu@linkedin.com
293
+
294
+ ## Cite this work
295
+
296
+ Biblatex entry:
297
+ ```bib
298
+ @software{liger2024,
299
+ title = {Liger-Kernel: Efficient Triton Kernels for LLM Training},
300
+ author = {Hsu, Pin-Lun and Dai, Yun and Kothapalli, Vignesh and Song, Qingquan and Tang, Shao and Zhu, Siyu},
301
+ url = {https://github.com/linkedin/Liger-Kernel},
302
+ year = {2024}
303
+ }
304
+ ```
305
+
306
+ ## Star History
307
+ [![Star History Chart](https://api.star-history.com/svg?repos=linkedin/Liger-Kernel&type=Date)](https://star-history.com/#linkedin/Liger-Kernel&Date)
@@ -0,0 +1,33 @@
1
+ liger_kernel/env_report.py,sha256=LFUJ6UMkFFGPBYXBlqHFGy4bhsemEpSI-_1edSazlHI,1130
2
+ liger_kernel/ops/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
3
+ liger_kernel/ops/cross_entropy.py,sha256=6-jI03Yw_B8gHLmqxTOMpbFMRJhNNaE4DKpmowWYrTE,9177
4
+ liger_kernel/ops/fused_linear_cross_entropy.py,sha256=RCStJoBsgiAa03ZupWhZEHjnAbm52iNiMDsGs6VDtnY,8385
5
+ liger_kernel/ops/geglu.py,sha256=f8j9qnZgqvXFDFStZ5WbtRPDuNo9FBdVdXX7ufMHNpE,4052
6
+ liger_kernel/ops/rms_norm.py,sha256=B0FDElKiTygv1CdG3NzbeOeC7nj_-2vmNIg4RHistHI,9517
7
+ liger_kernel/ops/rope.py,sha256=8TOkpjmeekQEp1x6OAXTAWwoTTcEhNHSk9GnjuhW-Cw,8570
8
+ liger_kernel/ops/swiglu.py,sha256=MRbSIXsBLqlFr9ZdtuFqSjLJJ-716URmQIhxQ57GGEw,2915
9
+ liger_kernel/ops/utils.py,sha256=vsFIywd8LQlVPRA3RPZOm5HyN8c0cS4NFEEnwjNw-MI,1427
10
+ liger_kernel/transformers/__init__.py,sha256=Um9ZRvT289MVFoGmliSva3q3YLRDqwYmBLxIj0rD9nI,403
11
+ liger_kernel/transformers/auto_model.py,sha256=WQyaORi2zPIWTLhuAWCRPIzyHd5T4my4yGHQrt1-uBA,1247
12
+ liger_kernel/transformers/cross_entropy.py,sha256=G-L4EaUYVc25NKZ2jrlaG-d5YUvDqJdUlawPN7K1d1g,389
13
+ liger_kernel/transformers/fused_linear_cross_entropy.py,sha256=X6ni--b5F2GRxL46PrgjsvQuWEcKp3Z2cELdMRR0oyY,518
14
+ liger_kernel/transformers/geglu.py,sha256=QcrME_8ooIn0xa59LaC0aoOdRrBIFd11Y0bAyF0NfCw,1130
15
+ liger_kernel/transformers/monkey_patch.py,sha256=vbYmT7povRJQA49Ra7GGD3hMN2lVTXmsxO9R8lfQSoI,13022
16
+ liger_kernel/transformers/rms_norm.py,sha256=YxBSn2bIfh24De8Xb7QhhmdG3taauj_qJNvEjlazonU,912
17
+ liger_kernel/transformers/rope.py,sha256=m-ah8vZBYW8tfplTXCiAPMHJWlB1tdp_JPXJeWE-Boo,943
18
+ liger_kernel/transformers/swiglu.py,sha256=0-tVJ8xEYfhxnduc16PflXFj8sZPxdx9sHUn3hfwCI4,2468
19
+ liger_kernel/transformers/trainer_integration.py,sha256=W3ON51O5GkyzNJsItz0y5rKx-uy2f2cFfveZpqbUdhw,123
20
+ liger_kernel/transformers/model/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
21
+ liger_kernel/transformers/model/gemma.py,sha256=EcdkGbSj_qroTDFl0Sc_HLyDyY0xcDhwrgkM_wkXnw8,4987
22
+ liger_kernel/transformers/model/llama.py,sha256=6McXLi_Bt35WuxaJ_0CzEnOtayHXiPw5vjiDsaQKdJU,5323
23
+ liger_kernel/transformers/model/mistral.py,sha256=_MQJrDntlxBO5cJwgTjr2rk2nNd5FAXVnzcTg_PEekQ,5079
24
+ liger_kernel/transformers/model/phi3.py,sha256=zmjOsVV5TjKJ0U2dCm6W-8WCx1toKoh2Wm2PZu3XOIw,4927
25
+ liger_kernel/transformers/model/qwen2.py,sha256=Va4uiZaVzCG2V7XKDfHjZyYTre5vPQM02j83jnnhono,4873
26
+ liger_kernel/triton/__init__.py,sha256=yfRe0zMb47QnqjecZWG7LnanfCTzeku7SgWRAwNVmzU,101
27
+ liger_kernel/triton/monkey_patch.py,sha256=5BcGKTtdqeYchypBIBopGIWPx1-cFALz7sOKoEsqXJ0,1584
28
+ liger_kernel-0.2.0.dist-info/LICENSE,sha256=OhzLDHJ0to4a8sodVLELZiCFylZ1NAAYLs-HrjPy0ag,1312
29
+ liger_kernel-0.2.0.dist-info/METADATA,sha256=eAzgrCGOn_jpoiH8VomABxzt7CThKfBqOIKH5Qmfm3w,17049
30
+ liger_kernel-0.2.0.dist-info/NOTICE,sha256=BXkXY9aWvEy_7MAB57zDu1z8uMYT1i1l9B6EpHuBa8s,173
31
+ liger_kernel-0.2.0.dist-info/WHEEL,sha256=eOLhNAGa2EW3wWl_TU484h7q1UNgy0JXjjoqKoxAAQc,92
32
+ liger_kernel-0.2.0.dist-info/top_level.txt,sha256=2eghu4hA3LnkM7ElW92tQ8zegWKgSbeo-k-aGe1YnvY,13
33
+ liger_kernel-0.2.0.dist-info/RECORD,,
@@ -1,16 +0,0 @@
1
- Metadata-Version: 2.1
2
- Name: liger-kernel
3
- Version: 0.1.0
4
- License-File: LICENSE
5
- License-File: NOTICE
6
- Requires-Dist: torch>=2.1.2
7
- Requires-Dist: triton>=2.3.0
8
- Requires-Dist: transformers>=4.40.1
9
- Provides-Extra: dev
10
- Requires-Dist: matplotlib>=3.7.2; extra == "dev"
11
- Requires-Dist: flake8>=4.0.1.1; extra == "dev"
12
- Requires-Dist: black>=24.4.2; extra == "dev"
13
- Requires-Dist: isort>=5.13.2; extra == "dev"
14
- Requires-Dist: pre-commit>=3.7.1; extra == "dev"
15
- Requires-Dist: torch-tb-profiler>=0.4.1; extra == "dev"
16
-
@@ -1,27 +0,0 @@
1
- liger_kernel/ops/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
- liger_kernel/ops/cross_entropy.py,sha256=YTHKVyPW748EWtbWJeKdIe9S1dEq6i90_PbBuCD-9s0,9178
3
- liger_kernel/ops/fused_linear_cross_entropy.py,sha256=58MmDhLJGR5b8ixztkhR707yp0VY28oBRASFVwGbeV8,7346
4
- liger_kernel/ops/geglu.py,sha256=5tGinryOOYRpGtKwJ4B1ertwtzd81xdjevD3Ha7H1AY,3849
5
- liger_kernel/ops/rms_norm.py,sha256=AQ1jaCXUlrBazqAPg-Cpf2K5OsO4byDKcdfWsGy9-zI,4848
6
- liger_kernel/ops/rope.py,sha256=fYBct8gDQfKPZdMWlzkZZ8kBzh6nQ7DIpDsc7lZwM8c,8584
7
- liger_kernel/ops/swiglu.py,sha256=MRbSIXsBLqlFr9ZdtuFqSjLJJ-716URmQIhxQ57GGEw,2915
8
- liger_kernel/ops/utils.py,sha256=vsFIywd8LQlVPRA3RPZOm5HyN8c0cS4NFEEnwjNw-MI,1427
9
- liger_kernel/transformers/__init__.py,sha256=nVvk0h7er3fdgubQF8Z8KjA3ew-q5oJHyJRg5cKmBoc,205
10
- liger_kernel/transformers/cross_entropy.py,sha256=G-L4EaUYVc25NKZ2jrlaG-d5YUvDqJdUlawPN7K1d1g,389
11
- liger_kernel/transformers/fused_linear_cross_entropy.py,sha256=h0AW9ubFGfz4DBwgh2CLW8rpKo9PvxYpB6AUzjx-1b0,501
12
- liger_kernel/transformers/geglu.py,sha256=FrLBHZRdI68jw9RR6MSTE59-xCzueOwSRp9jL8y-j98,896
13
- liger_kernel/transformers/monkey_patch.py,sha256=FjaRZVWm_ZMHO3NXc4IT6EpCTWJOdZKP72mZq01qbrA,5006
14
- liger_kernel/transformers/rms_norm.py,sha256=2LHfEctSpzuNRaoZ9uUECSFK8fZeIxIsHm9QbEHZvDQ,452
15
- liger_kernel/transformers/rope.py,sha256=m-ah8vZBYW8tfplTXCiAPMHJWlB1tdp_JPXJeWE-Boo,943
16
- liger_kernel/transformers/swiglu.py,sha256=8kt4MffEZT5vx3k0WA-GO-WPLv5kGdnu_nAwlJyMI2U,1516
17
- liger_kernel/transformers/trainer_integration.py,sha256=gt0fF-se2XiIB6PocHBPBuD6tLCOtQRcb20WfUS2ceA,1645
18
- liger_kernel/transformers/model/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
19
- liger_kernel/transformers/model/llama.py,sha256=4mfVTMrY7T-xiJeQJe02hBVnAwNCKlvLGp49gj6TWiU,5298
20
- liger_kernel/triton/__init__.py,sha256=yfRe0zMb47QnqjecZWG7LnanfCTzeku7SgWRAwNVmzU,101
21
- liger_kernel/triton/monkey_patch.py,sha256=5BcGKTtdqeYchypBIBopGIWPx1-cFALz7sOKoEsqXJ0,1584
22
- liger_kernel-0.1.0.dist-info/LICENSE,sha256=OhzLDHJ0to4a8sodVLELZiCFylZ1NAAYLs-HrjPy0ag,1312
23
- liger_kernel-0.1.0.dist-info/METADATA,sha256=E_OSiFz2sC4jmWO4VH3sTXWiR3Ev7qNy5oSLSWk-s8g,504
24
- liger_kernel-0.1.0.dist-info/NOTICE,sha256=BXkXY9aWvEy_7MAB57zDu1z8uMYT1i1l9B6EpHuBa8s,173
25
- liger_kernel-0.1.0.dist-info/WHEEL,sha256=eOLhNAGa2EW3wWl_TU484h7q1UNgy0JXjjoqKoxAAQc,92
26
- liger_kernel-0.1.0.dist-info/top_level.txt,sha256=2eghu4hA3LnkM7ElW92tQ8zegWKgSbeo-k-aGe1YnvY,13
27
- liger_kernel-0.1.0.dist-info/RECORD,,