Skip to content

Fix 3 typos in tensor.ipynb (Tensor tutorial)#2430

Open
Jah-yee wants to merge 1 commit intotensorflow:masterfrom
Jah-yee:fix/115278-typo-every-other-item
Open

Fix 3 typos in tensor.ipynb (Tensor tutorial)#2430
Jah-yee wants to merge 1 commit intotensorflow:masterfrom
Jah-yee:fix/115278-typo-every-other-item

Conversation

@Jah-yee
Copy link
Copy Markdown

@Jah-yee Jah-yee commented Apr 19, 2026

Good day

This PR fixes 3 typos in the TensorFlow tensor tutorial notebook (site/en/guide/tensor.ipynb), addressing issue #115278:

Changes made:

  1. "Every other item" → "Every odd item" (Cell 48, single-axis indexing section)
    The slice selects indices 1, 3, 5, 7... (1st, 3rd, 5th, 7th positions), which are more accurately described as odd-numbered items rather than "every other item"

  2. "2-rank tensor" → "rank-2 tensor" (Cell 53)
    For consistency with the earlier terminology used in the same document: A "matrix" or "rank-2" tensor

  3. Missing period fixed in string comment (Cell 100)
    "# Tensors can be strings, too here is a scalar string." → "# Tensors can be strings, too. Here is a scalar string."

Verification:

  • All 3 fixes verified in the edited notebook
  • Branch pushed to

Thank you for your attention. If there are any issues or suggestions, please leave a comment and I will address them promptly.

Warmly,
RoomWithOutRoof

1. Changed "Every other item" to "Every odd item" in single-axis indexing
   example - more accurate since indices 1,3,5... are odd positions

2. Changed "2-rank tensor" to "rank-2 tensor" for consistency
   with earlier "rank-2 tensor" terminology in the same document

3. Added missing period in string tensor comment:
   "Tensors can be strings, too here is a scalar string." ->
   "Tensors can be strings, too. Here is a scalar string."

Fixes tensorflow/tensorflow#115278
@Jah-yee Jah-yee requested a review from a team as a code owner April 19, 2026 12:37
@google-cla
Copy link
Copy Markdown

google-cla bot commented Apr 19, 2026

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@github-actions
Copy link
Copy Markdown

Preview

Preview and run these notebook edits with Google Colab: Rendered notebook diffs available on ReviewNB.com.

Format and style

Use the TensorFlow docs notebook tools to format for consistent source diffs and lint for style:
$ python3 -m pip install -U --user git+https://github.com/tensorflow/docs

$ python3 -m tensorflow_docs.tools.nbfmt notebook.ipynb
$ python3 -m tensorflow_docs.tools.nblint --arg=repo:tensorflow/docs notebook.ipynb
If commits are added to the pull request, synchronize your local branch: git pull origin fix/115278-typo-every-other-item

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant