Skip to content

Commit 9e9b535

Browse files
[CodeStyle][Typos][C-[6-7],C-[24-26]] Fix typo('classfication','classfy','creats','creatation','corss') (#7610)
* fix-c19-c23 * fix-c6-c7-c24-c26
1 parent bbedf0b commit 9e9b535

File tree

5 files changed

+6
-10
lines changed

5 files changed

+6
-10
lines changed

_typos.toml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,6 @@ Similarily = "Similarily"
3636
Simle = "Simle"
3737
Sovler = "Sovler"
3838
Successed = "Successed"
39-
classfy = "classfy"
40-
corss = "corss"
41-
creatation = "creatation"
42-
creats = "creats"
4339
dafault = "dafault"
4440
datas = "datas"
4541
decribe = "decribe"

docs/design/motivation/api.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ fQ = f(paddle.layer.data(input_name="Q"))
6161

6262
topology = paddle.layer.less_than(
6363
paddle.layer.cross_entropy(fA, fQ),
64-
paddle.layer.corss_entropy(fB, fQ))
64+
paddle.layer.cross_entropy(fB, fQ))
6565

6666
# Derive parameters required in topology and create them in model.
6767
parameters = paddle.parameters.create(topology)

docs/design/others/simple_op_design.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ message OpProto {
6464
To generate Python code automatically:
6565

6666
```python
67-
def create_python_ops_creatation_functions():
67+
def create_python_ops_creation_functions():
6868
op_protos = paddle.framework.OpRegistry.get_all_op_proto()
6969
for type_name in op_protos:
7070
op_proto = op_protos[type_name]
@@ -77,7 +77,7 @@ def create_python_ops_creatation_functions():
7777
__impl__.__doc__ = create_doc_string(op_proto)
7878
globals()[type_name] = __impl__
7979

80-
create_python_ops_creatation_functions()
80+
create_python_ops_creation_functions()
8181
```
8282

8383
### Message from Python to C++

docs/dev_guides/custom_device_docs/stream_api_en.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ C_Status (*create_stream)(const C_Device device, C_Stream* stream)
1010
1111
### Description
1212
13-
It creats a stream, which is used to execute asynchronous tasks within the framework. In the stream, tasks are done in order. When the device does not support asynchronous execution, the API is required to be implemented with an empty method.
13+
It creates a stream, which is used to execute asynchronous tasks within the framework. In the stream, tasks are done in order. When the device does not support asynchronous execution, the API is required to be implemented with an empty method.
1414
1515
### Parameter
1616

docs/guides/model_convert/convert_from_pytorch/nlp_migration_experiences_cn.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -354,7 +354,7 @@ A:有的,例如:
354354
下面以 BERT 模型为例介绍转换的过程:
355355

356356
- 如果 PyTorch repo 中已经提供权重,那么可以直接下载并进行后续的转换。huggingface 的 transformers 中提供了大部分模型参数,使用模型权重名称`model_name_or_path`即可加载(如`bert-base-uncased`)。或者从 huggingface 官网直接下载:https://huggingface.co/bert-base-uncased/tree/main
357-
- 如果没有提供,则可以基于 PyTorch 代码,随机生成一个初始化权重(定义完 model 以后,使用`torch.save()` API 保存模型权重),然后将生成的 PyTorch 权重 (`bert_sequence_classfy.pth`) 转换为飞桨模型权重。
357+
- 如果没有提供,则可以基于 PyTorch 代码,随机生成一个初始化权重(定义完 model 以后,使用`torch.save()` API 保存模型权重),然后将生成的 PyTorch 权重 (`bert_sequence_classify.pth`) 转换为飞桨模型权重。
358358

359359
```python
360360
from transformers import BertModel
@@ -366,7 +366,7 @@ PATH = './torch_weight.bin'
366366
torch.save(hf_model.state_dict(), PATH)
367367
```
368368

369-
然后将生成的 PyTorch 权重 (`bert_sequence_classfy.pth`) 转换为飞桨模型权重,转换代码如下(代码解释详见代码后的 FAQ)
369+
然后将生成的 PyTorch 权重 (`bert_sequence_classify.pth`) 转换为飞桨模型权重,转换代码如下(代码解释详见代码后的 FAQ)
370370

371371
```python
372372
def convert_pytorch_checkpoint_to_paddle(

0 commit comments

Comments
 (0)