arnavgrg commited on
Commit
aa9b295
1 Parent(s): 7d67215

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +16 -0
README.md CHANGED
@@ -1,3 +1,19 @@
1
  ---
2
  license: apache-2.0
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: apache-2.0
3
+ tags:
4
+ - text-generation-inference
5
  ---
6
+
7
+ This is an upscaled fp16 variant of the original Llama-2-7b-chat base model by Meta after it has been loaded with nf4 4-bit quantization via bitsandbytes.
8
+ The main idea here is to upscale the linear4bit layers to fp16 so that the quantization/dequantization cost doesn't have to paid for each forward pass at inference time.
9
+
10
+ _Note: The quantization operation to nf4 is not lossless, so the model weights for the linear layers are lossy, which means that this model will not work as well as the official base model._
11
+
12
+ To use this model, you can just load it via `transformers` in fp16:
13
+
14
+ ```python
15
+ import torch
16
+ from transformers import AutoModelForCausalLM
17
+
18
+ model = AutoModelForCausalLM.from_pretrained("arnavgrg/llama-2-7b-chat-nf4-fp16-upscaled", torch_dtype=torch.float16)
19
+ ```