Skip to content

Commit b676a90

Browse files
committed
update-2024-06-30_09:09:19
1 parent 68a2c9e commit b676a90

40 files changed

+81
-11
lines changed
File renamed without changes.
File renamed without changes.

ai-infra/网络/IB-docker.md

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
2+
3+
4+
5+
6+
7+
8+
```
9+
yum install libibverbs
10+
```
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

llm-compression/quantization/fp8.md

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
2+
3+
4+
https://arxiv.org/pdf/2209.05433
5+
6+
FP8 FORMATS FOR DEEP LEARNING
7+
8+
9+
10+
FP8 Quantization: The Power of the Exponent
11+
12+
https://arxiv.org/pdf/2208.09225
13+
14+
15+
https://zhuanlan.zhihu.com/p/574825662
16+
17+
FP8 量化-原理、实现与误差分析
18+
19+
20+
https://zhuanlan.zhihu.com/p/619431625
21+
22+
FP8 量化基础
23+
24+

llm-inference/vllm/REF.md

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
2+
3+
引擎启动参数:
4+
5+
https://docs.vllm.ai/en/stable/models/engine_args.html
6+
7+
8+
9+
max-num-seqs:默认 256,
10+
11+
当 max-num-seqs 比较小时,较迟接收到的 request 会进入 waiting_list,直到前面有request 结束后再被添加进生成队列。
12+
13+
当 max-num-seqs 太大时,会出现一部分 request 在生成了 3-4 个 tokens 之后,被加入到 waiting_list(有些用户出现生成到一半卡住的情况)。过大或过小的 max-num-seqs 都会影响用户体验。
14+
15+
16+
max-num-batched-tokens:很重要的配置,比如你配置了 max-num-batched-tokens=1000 那么你大概能在一个 batch 里面处理 10 条平均长度约为 100 tokens 的 inputs。max-num-batched-tokens 应尽可能大,来充分发挥 continuous batching 的优势。不过似乎(对于 TGI 是这样,vllm 不太确定),在提供 HF 模型时,该 max-num-batched-tokens 能够被自动推导出来。
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
2+
3+
4+
--privileged 特权模型下,昇腾或者英伟达的 docker runtime 中会默认分配本机所有卡。
5+
6+
7+
8+
- ASCEND_VISIBLE_DEVICES 容器级控制卡
9+
- ASCEND_RT_VISIBLE_DEVICES 进程级控制卡 类似于 CUDA_VISIBLE_DEVICES
10+
11+
12+
13+
14+
15+

llm-performance/vllm-benchmark.md

+13
Original file line numberDiff line numberDiff line change
@@ -50,3 +50,16 @@ print(f"Throughput: {len(requests) / elapsed_time:.2f} requests/s, "
5050

5151

5252

53+
54+
```
55+
# run python-based benchmarks and upload the result to buildkite
56+
python3 benchmarks/benchmark_latency.py --output-json latency_results.json 2>&1 | tee benchmark_latency.txt
57+
bench_latency_exit_code=$?
58+
59+
python3 benchmarks/benchmark_throughput.py --input-len 256 --output-len 256 --output-json throughput_results.json 2>&1 | tee benchmark_throughput.txt
60+
bench_throughput_exit_code=$?
61+
```
62+
63+
64+
65+

llm-performance/vllm/README.md

Whitespace-only changes.

paper/README.md

-11
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,3 @@
33

44

55

6-
7-
Reducing Activation Recomputation in Large Transformer Models:https://arxiv.org/pdf/2205.05198
8-
9-
**选择性激活重计算**(selective activation recomputation),是一种策略,即只对那些**占用大量内存但重新计算成本不高的Transformer层的部分激活进行存储和重计算**。例如,在自注意力机制中,某些操作(如: $QK^T$矩阵乘法、softmax、softmax dropout和对V的注意力)会产生较大的激活,但每个输入元素所需的浮点运算次数却相对较低。通过选择性地存储这些激活,可以在使用较少内存的同时,以较低的计算开销重新计算未存储的激活。
10-
11-
12-
13-
通过结合使用序列并行性(sequence parallelism)和张量并行性(tensor parallelism),以及选择性激活重计算,论文中的方法能够在减少5倍激活内存需求的同时,将由激活重计算引起的执行时间开销降低90%以上。这使得在大规模参数的语言模型上训练变换器模型变得更加高效。
14-
15-
16-

paper/training/重计算.md paper/training/Reducing Activation Recomputation in Large Transformer Models.md

+3
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,10 @@ Reducing Activation Recomputation in Large Transformer Models:https://arxiv.or
77
**选择性激活重计算**(selective activation recomputation),是一种策略,即只对那些**占用大量内存但重新计算成本不高的Transformer层的部分激活进行存储和重计算**。例如,在自注意力机制中,某些操作(如: $QK^T$矩阵乘法、softmax、softmax dropout和对V的注意力)会产生较大的激活,但每个输入元素所需的浮点运算次数却相对较低。通过选择性地存储这些激活,可以在使用较少内存的同时,以较低的计算开销重新计算未存储的激活。
88

99

10+
1011
通过结合使用序列并行性(sequence parallelism)和张量并行性(tensor parallelism),以及选择性激活重计算,论文中的方法能够在减少5倍激活内存需求的同时,将由激活重计算引起的执行时间开销降低90%以上。这使得在大规模参数的语言模型上训练变换器模型变得更加高效。
1112

1213

1314

15+
16+

0 commit comments

Comments
 (0)