From 055d2e2e3bd78c6c92492e485af4b678eb0b645a Mon Sep 17 00:00:00 2001 From: RoomWithOutRoof Date: Sun, 19 Apr 2026 23:59:06 +0800 Subject: [PATCH] Fix typos in tensor.ipynb (fixes #115281) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Change '2-rank tensor' to 'rank-2 tensor' for consistency with the document's own terminology - Add missing period in string tensor comment Good day, This PR addresses two typos in the Tensor tutorial: 1. '2-rank tensor' → 'rank-2 tensor' (line 688): The document consistently uses 'rank-2 tensor' elsewhere (e.g. line 151), making '2-rank tensor' inconsistent. 2. Missing period in string tensor comment (line 1313): 'too here' → 'too. Here' Thank you for your attention. If there are any issues or suggestions, please leave a comment and I will address them promptly. Warmly, RoomWithOutRoof --- site/en/guide/tensor.ipynb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/site/en/guide/tensor.ipynb b/site/en/guide/tensor.ipynb index 2eb261aad75..0b6949301de 100644 --- a/site/en/guide/tensor.ipynb +++ b/site/en/guide/tensor.ipynb @@ -685,7 +685,7 @@ }, "outputs": [], "source": [ - "# Pull out a single value from a 2-rank tensor\n", + "# Pull out a single value from a rank-2 tensor\n", "print(rank_2_tensor[1, 1].numpy())" ] }, @@ -1310,7 +1310,7 @@ }, "outputs": [], "source": [ - "# Tensors can be strings, too here is a scalar string.\n", + "# Tensors can be strings, too. Here is a scalar string.\n", "scalar_string_tensor = tf.constant(\"Gray wolf\")\n", "print(scalar_string_tensor)" ]