diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 47ebc39d47698..6b0d61a7eb8c0 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -50,7 +50,7 @@ repos: paddle/cinn/utils/registry.h )$ - repo: https://github.com/PFCCLab/typos-pre-commit-mirror.git - rev: v1.27.3 + rev: v1.29.4 hooks: - id: typos args: [--force-exclude] @@ -151,7 +151,7 @@ repos: exclude: | (?x)^( cmake/external/onnxruntime.cmake - )$ + )$ # Others - repo: local hooks: diff --git a/paddle/fluid/pir/serialize_deserialize/include/ir_serialize.h b/paddle/fluid/pir/serialize_deserialize/include/ir_serialize.h index a5554b7019c84..04de95a73e421 100644 --- a/paddle/fluid/pir/serialize_deserialize/include/ir_serialize.h +++ b/paddle/fluid/pir/serialize_deserialize/include/ir_serialize.h @@ -48,7 +48,7 @@ class ProgramWriter { Json program_json; /** value_id_map is used to record the serialize id of pir::Value. - * which is used to serilize op's operands. */ + * which is used to serialize op's operands. */ std::map value_id_map; /** xxx_id_ is used to record current id of IR structure diff --git a/paddle/phi/api/generator/tensor_operants_gen.py b/paddle/phi/api/generator/tensor_operants_gen.py index 24552a02603a7..ea1184bf0581a 100644 --- a/paddle/phi/api/generator/tensor_operants_gen.py +++ b/paddle/phi/api/generator/tensor_operants_gen.py @@ -534,7 +534,7 @@ def gene_tensor_api_implementation(self): func_args_code = ", ".join(["", *func_args]) else: func_args_code = "" - # func decalaration + # func declaration if func_name[-1] != '_': return f""" {self.get_return_type()} Tensor::{func_name}({self.get_define_args_without_first_tensor()}) const {{ @@ -564,7 +564,7 @@ def gene_operants_implementation(self): func_name = self.get_api_func_name() func_args = self.inputs['names'] + self.attrs['names'] func_args_code = ", ".join(func_args) - # func decalaration + # func declaration if func_name[-1] != '_': return f""" {self.get_return_type()} PhiTensorOperants::{func_name}({self.get_define_args()}) {{ @@ -635,7 +635,7 @@ def gene_operants_manager_implementation(self): {self.get_return_type()} OperantsManager::{specific_ops_map[func_name]}(const Tensor& x, const Scalar& y) {{{self.gene_operants_manager_code(is_specific_op=True)}}} """ - # func decalaration + # func declaration if func_name[-1] != '_': return ( final_code diff --git a/python/paddle/device/cuda/cuda_graphed_layer.py b/python/paddle/device/cuda/cuda_graphed_layer.py index 069d8a6c9476c..3f39e6181d3bb 100644 --- a/python/paddle/device/cuda/cuda_graphed_layer.py +++ b/python/paddle/device/cuda/cuda_graphed_layer.py @@ -179,8 +179,8 @@ def preserve_or_copy(self, args, kwargs): ) else: inputs = recursive_flatten_args_kwargs(args, kwargs) - for x_staic, x in zip(self.inputs_static, inputs): - x_staic.copy_(x, True) + for x_static, x in zip(self.inputs_static, inputs): + x_static.copy_(x, True) def record(self, f, *args, **kwargs): self.preserve_or_copy(args, kwargs) diff --git a/python/paddle/tensorrt/converter_utils.py b/python/paddle/tensorrt/converter_utils.py index a0ec503efc622..3deff77fdaf92 100644 --- a/python/paddle/tensorrt/converter_utils.py +++ b/python/paddle/tensorrt/converter_utils.py @@ -125,7 +125,7 @@ def get_trt_plugin(plugin_name, field_collection, version, plugin_namespace=""): ) assert ( plugin_creator - ), f"Unabled to find plugin creator with name{plugin_name}" + ), f"Unable to found plugin creator with name {plugin_name}" plugin = plugin_creator.create_plugin( name=plugin_name, field_collection=field_collection )