mirror of
https://github.com/skindhu/Build-A-Large-Language-Model-CN.git
synced 2026-07-24 12:50:24 +08:00
add fourth chapter
This commit is contained in:
@@ -159,7 +159,7 @@ print(batch)
|
||||
|
||||
```python
|
||||
tensor([[ 6109, 3626, 6100, 345], #A
|
||||
[ 6109, 1110, 6622, 257]])
|
||||
[ 6109, 1110, 6622, 257]])
|
||||
|
||||
#A 第一行对应第一段文本,第二行对应第二段文本。
|
||||
```
|
||||
@@ -263,11 +263,11 @@ print("Variance:\n", var)
|
||||
|
||||
```python
|
||||
Mean:
|
||||
tensor([[0.1324],
|
||||
tensor([[0.1324],
|
||||
[0.2170]], grad_fn=<MeanBackward1>)
|
||||
|
||||
Variance:
|
||||
tensor([[0.0231],
|
||||
tensor([[0.0231],
|
||||
[0.0398]], grad_fn=<VarBackward0>)
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user