From 002f21851231e05e1dc9c3a79d00fe0f0b99aea8 Mon Sep 17 00:00:00 2001 From: chenxujun Date: Mon, 17 Apr 2023 10:58:36 +0800 Subject: [PATCH] Fix typos, test=document_fix (#52937) --- paddle/phi/common/data_type.h | 4 ++-- paddle/phi/common/thread_data_registry.h | 4 ++-- paddle/phi/common/transform.h | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/paddle/phi/common/data_type.h b/paddle/phi/common/data_type.h index f06d4a01fde..58852cf5adb 100644 --- a/paddle/phi/common/data_type.h +++ b/paddle/phi/common/data_type.h @@ -39,7 +39,7 @@ enum class DataType { BOOL, - UINT8, // BYte + UINT8, // Byte INT8, // Char UINT16, INT16, @@ -70,7 +70,7 @@ enum class DataType { BFLOAT16, NUM_DATA_TYPES, - // See Note [ Why we need ALL in baisc kernel key member? ] + // See Note [ Why we need ALL in basic kernel key member? ] ALL_DTYPE = UNDEFINED, }; diff --git a/paddle/phi/common/thread_data_registry.h b/paddle/phi/common/thread_data_registry.h index bdae7fb9b88..53f5136f6bc 100644 --- a/paddle/phi/common/thread_data_registry.h +++ b/paddle/phi/common/thread_data_registry.h @@ -44,7 +44,7 @@ class ThreadDataRegistry { } // Returns current snapshot of all threads. Make sure there is no thread - // create/destory when using it. + // create/destroy when using it. template < typename Alias = T, typename = std::enable_if_t::value>> @@ -53,7 +53,7 @@ class ThreadDataRegistry { } // Returns current snapshot of all threads. Make sure there is no thread - // create/destory when using it. + // create/destroy when using it. std::unordered_map> GetAllThreadDataByRef() { return impl_->GetAllThreadDataByRef(); diff --git a/paddle/phi/common/transform.h b/paddle/phi/common/transform.h index a56103a6e52..ffee95a3770 100644 --- a/paddle/phi/common/transform.h +++ b/paddle/phi/common/transform.h @@ -33,7 +33,7 @@ namespace phi { // range defined by a pair of iterators. // // - The specialization for CPU calls std::transform. -// - The specialization for CUDA calls thrust::tranform. +// - The specialization for CUDA calls thrust::transform. // // NOTE: We need to define InputIter and OutputIter defined as // different types, because the InputIter points op's inputs and @@ -41,7 +41,7 @@ namespace phi { // // NOTE: We don't assume that InputIter to be const InputType* and // OutputIter to be OutputType*, because we might use a iterator -// class, paddle::fluid::operators::RowwiseTRansformIterator. +// class, paddle::fluid::operators::RowwiseTransformIterator. template struct Transform { // The unary version. @@ -94,7 +94,7 @@ struct Transform { #if defined(__NVCC__) || defined(__HIPCC__) -// PointerToThrustDevicePtr has two speicalizations, one casts a (CUDA +// PointerToThrustDevicePtr has two specializations, one casts a (CUDA // device) pointer into thrust::device_ptr, the other keeps rest types // un-casted. template -- GitLab