mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-06 12:20:52 +01:00
Fix common typos and misspellings (#164413)
Summary: This commit fixes numerous typos and misspellings found throughout the codebase. The fixes improve code readability and documentation consistency across C++, Python, CUDA, and documentation files. ## Typos Fixed | Before | After | Occurrences | |--------|-------|-------------| | occured | occurred | 14 | | accross | across | 9 | | lenght/lenghts | length/lengths | 8 | | unneccessary | unnecessary | 5 | | Peform | Perform | 4 | | furture | future | 3 | | paritioned | partitioned | 2 | | desireable | desirable | 2 | | registerations | registrations | 2 | | seperated | separated | 2 | | intialized | initialized | 2 | | capatibility | compatibility | 2 | | peformed | performed | 2 | | Exmple | Example | 2 | | comma_seperated | comma_separated | 2 | | cumsuming | consuming | 2 | | neccessary | necessary | 1 | | ParamterMetadataTable | ParameterMetadataTable | 1 | | matached | matched | 1 | | conaitner | container | 1 | | reivew | review | 1 | | prioriry | priority | 1 | | Alocated | Allocated | 1 | | opportunixtically | opportunistically | 1 | | peformance | performance | 1 | | equavalent | equivalent | 1 | | asssumed | assumed | 1 | | valdiation | validation | 1 | | apprear | appear | 1 | | consectuve | consecutive | 1 | | dependending | depending | 1 | | copnversion | conversion | 1 | | weigted | weighted | 1 | | repreesenting | representing | 1 | | finialize | finalize | 1 | | unintialized | uninitialized | 1 | | conbined | combined | 1 | | tesnor | tensor | 1 | | desugared | discarded | 1 | | behaviour | behavior | 1 | | paramerizaitons | parametrizations | 1 | | compute_output_lenghths_kernel | compute_output_lengths_kernel | 1 | Test Plan: N/A - mostly comments - waiting on CI Differential Revision: D83695665 Pull Request resolved: https://github.com/pytorch/pytorch/pull/164413 Approved by: https://github.com/eqy, https://github.com/larryliu0820
This commit is contained in:
parent
3ddf2018d0
commit
b6b7a44dec
|
|
@ -905,7 +905,7 @@ class Vectorized8 : public Vectorizedi {
|
|||
// Because loadu(const void* ptr, T count) requires zero initialization for
|
||||
// upper 128 bits. However, by using _mm256_castsi128_si256, the upper 128
|
||||
// bits of the result are undefined.
|
||||
// TODO<leslie> We can use _mm256_zextsi128_si256 in the furture,
|
||||
// TODO<leslie> We can use _mm256_zextsi128_si256 in the future,
|
||||
// since gcc 9.3 doesn't support it now.
|
||||
__m128i input_128 = _mm_loadl_epi64(reinterpret_cast<const __m128i*>(ptr));
|
||||
return _mm256_castsi128_si256(input_128);
|
||||
|
|
@ -1844,7 +1844,7 @@ Vectorized<int16_t> inline shift_256_16(
|
|||
c0 = _mm256_srav_epi32(a0, b0);
|
||||
c0 = _mm256_shuffle_epi8(c0, ctl_1_0);
|
||||
|
||||
// Peform shifting the same way for input array elements with
|
||||
// Perform shifting the same way for input array elements with
|
||||
// idx%2==1.
|
||||
__m256i a1 = _mm256_and_si256(a, keep_1);
|
||||
__m256i b1 = _mm256_shuffle_epi8(b, ctl_1_0);
|
||||
|
|
@ -2180,7 +2180,7 @@ Vectorized<T> inline shift_256_8(
|
|||
c0 = _mm256_srlv_epi32(a0, b0);
|
||||
c0 = _mm256_shuffle_epi8(c0, ctl_3_0);
|
||||
|
||||
// Peform shifting the same way for input array elements with
|
||||
// Perform shifting the same way for input array elements with
|
||||
// idx%4==1.
|
||||
__m256i a1 = _mm256_shuffle_epi8(a, ctl_1_3);
|
||||
__m256i b1 = _mm256_shuffle_epi8(b, ctl_1_0);
|
||||
|
|
@ -2193,7 +2193,7 @@ Vectorized<T> inline shift_256_8(
|
|||
c1 = _mm256_srlv_epi32(a1, b1);
|
||||
c1 = _mm256_shuffle_epi8(c1, ctl_3_1);
|
||||
|
||||
// Peform shifting the same way for input array elements with
|
||||
// Perform shifting the same way for input array elements with
|
||||
// idx%4==2.
|
||||
__m256i a2 = _mm256_shuffle_epi8(a, ctl_2_3);
|
||||
__m256i b2 = _mm256_shuffle_epi8(b, ctl_2_0);
|
||||
|
|
@ -2206,7 +2206,7 @@ Vectorized<T> inline shift_256_8(
|
|||
c2 = _mm256_srlv_epi32(a2, b2);
|
||||
c2 = _mm256_shuffle_epi8(c2, ctl_3_2);
|
||||
|
||||
// Peform shifting the same way for input array elements with
|
||||
// Perform shifting the same way for input array elements with
|
||||
// idx%4==3.
|
||||
__m256i a3 = _mm256_and_si256(a, keep_3);
|
||||
__m256i b3 = _mm256_shuffle_epi8(b, ctl_3_0);
|
||||
|
|
|
|||
|
|
@ -1088,7 +1088,7 @@ class Vectorized8 : public Vectorizedi {
|
|||
// Because loadu(const void* ptr, T count) requires zero initialization for
|
||||
// upper 384 bits. However, by using _mm512_castsi128_si512, the upper 384
|
||||
// bits of the result are undefined.
|
||||
// TODO<leslie> We can use _mm512_zextsi128_si512 in the furture,
|
||||
// TODO<leslie> We can use _mm512_zextsi128_si512 in the future,
|
||||
// since gcc 9.3 doesn't support it now.
|
||||
__m128i input_128 = _mm_loadu_si128(reinterpret_cast<const __m128i*>(ptr));
|
||||
return _mm512_castsi128_si512(input_128);
|
||||
|
|
@ -2022,7 +2022,7 @@ Vectorized<T> inline shift_512_8(
|
|||
c0 = _mm512_srlv_epi16(a0, b0);
|
||||
c0 = _mm512_shuffle_epi8(c0, ctl_1_0);
|
||||
|
||||
// Peform shifting the same way for input array elements with
|
||||
// Perform shifting the same way for input array elements with
|
||||
// idx%2==1.
|
||||
__m512i a1 = _mm512_and_si512(a, keep_1);
|
||||
__m512i b1 = _mm512_shuffle_epi8(b, ctl_1_0);
|
||||
|
|
|
|||
|
|
@ -1379,7 +1379,7 @@ void run_cudnn_SDP_fprop(
|
|||
cudnnHandle_t handle = getCudnnHandle();
|
||||
|
||||
// NB: The key initialization will round up sequence length, stride data etc.
|
||||
// if use_ragged_in_dense is enabled (to allow multiple sequence lenghths to
|
||||
// if use_ragged_in_dense is enabled (to allow multiple sequence lengths to
|
||||
// reuse the same cached value/graph)
|
||||
auto key = MHACacheKeyWrapper(
|
||||
b,
|
||||
|
|
|
|||
|
|
@ -437,7 +437,7 @@ class TestLiteScriptModule(TestCase):
|
|||
# additional context to the exception message and preserve the correct
|
||||
# C++ stack trace for symbolication. i.e. it isn't possible to add
|
||||
# the debug handle string to show where in the Python code the exception
|
||||
# occured w/o first changing
|
||||
# occurred w/o first changing
|
||||
# torch::jit::JITException to extend c10::Error.
|
||||
self.assertTrue("self.val and val are same" in error_message)
|
||||
|
||||
|
|
|
|||
|
|
@ -532,16 +532,16 @@ def _decompose_and_get_gm_with_new_signature_constants(
|
|||
_verify_stack_trace(gm)
|
||||
_verify_placeholder_names(gm, new_graph_signature)
|
||||
|
||||
gm, new_graph_signature = _remove_unneccessary_copy_op_pass(
|
||||
gm, new_graph_signature = _remove_unnecessary_copy_op_pass(
|
||||
gm, new_graph_signature
|
||||
)
|
||||
|
||||
# When we apply parameterixzation rule to unwrap
|
||||
# When we apply parameterization rule to unwrap
|
||||
# subclasses, the state dict will now have different
|
||||
# desugared parameters. We need to manually filter those
|
||||
# and update the ep.state_dict. Ideally, we should just return
|
||||
# the state dict of ep.module but ep.module only stores params
|
||||
# buffers that participate in forward. If we undo this behaviour,
|
||||
# buffers that participate in forward. If we undo this behavior,
|
||||
# it would break some downstream users.
|
||||
new_state_dict = {
|
||||
**ep.state_dict,
|
||||
|
|
@ -781,7 +781,7 @@ def _decompose_and_get_gm_with_new_signature_constants(
|
|||
return gm, new_graph_signature, ep.state_dict
|
||||
|
||||
|
||||
def _remove_unneccessary_copy_op_pass(
|
||||
def _remove_unnecessary_copy_op_pass(
|
||||
gm: torch.fx.GraphModule, new_graph_signature: ExportGraphSignature
|
||||
) -> tuple[torch.fx.GraphModule, ExportGraphSignature]:
|
||||
"""
|
||||
|
|
@ -894,7 +894,7 @@ def _get_updated_module_call_graph(
|
|||
user_input_counter += 1
|
||||
|
||||
# For all the parameters and buffers, we first see
|
||||
# if they are result of paramerizaitons and if they
|
||||
# if they are result of parametrizations and if they
|
||||
# are, we log them and error later
|
||||
old_param_to_desugared = defaultdict(list)
|
||||
for name, target in new_graph_params_buffers.items():
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user