From 53f3748426001e4be9923a25f9f3394707f4e206 Mon Sep 17 00:00:00 2001 From: Susheel Thapa Date: Fri, 20 Oct 2023 06:35:15 +0545 Subject: [PATCH 1/3] Chore: Fix the typo in multiple files --- site/en/community/contribute/docs_style.md | 2 +- site/en/guide/migrate/evaluator.ipynb | 2 +- site/en/guide/sparse_tensor.ipynb | 7 ++++++- site/en/guide/tf_numpy_type_promotion.ipynb | 5 +++-- site/en/hub/tutorials/boundless.ipynb | 2 +- site/en/hub/tutorials/s3gan_generation_with_tf_hub.ipynb | 2 +- site/en/hub/tutorials/tf2_object_detection.ipynb | 2 +- site/en/hub/tutorials/wiki40b_lm.ipynb | 2 +- site/en/r1/guide/autograph.ipynb | 2 +- site/en/r1/guide/distribute_strategy.ipynb | 6 +++--- site/en/r1/tutorials/representation/unicode.ipynb | 4 ++-- 11 files changed, 21 insertions(+), 15 deletions(-) diff --git a/site/en/community/contribute/docs_style.md b/site/en/community/contribute/docs_style.md index eba78afa896..d4e42cb5235 100644 --- a/site/en/community/contribute/docs_style.md +++ b/site/en/community/contribute/docs_style.md @@ -63,7 +63,7 @@ repository like this: * \[Basics\]\(../../guide/basics.ipynb\) produces [Basics](../../guide/basics.ipynb). -This is the prefered approach because this way the links on +This is the preferred approach because this way the links on [tensorflow.org](https://www.tensorflow.org), [GitHub](https://github.com/tensorflow/docs){:.external} and [Colab](https://github.com/tensorflow/docs/tree/master/site/en/guide/bazics.ipynb){:.external} diff --git a/site/en/guide/migrate/evaluator.ipynb b/site/en/guide/migrate/evaluator.ipynb index fd8bd12d1e1..c8f848e4406 100644 --- a/site/en/guide/migrate/evaluator.ipynb +++ b/site/en/guide/migrate/evaluator.ipynb @@ -122,7 +122,7 @@ "\n", "In TensorFlow 1, you can configure a `tf.estimator` to evaluate the estimator using `tf.estimator.train_and_evaluate`.\n", "\n", - "In this example, start by defining the `tf.estimator.Estimator` and speciyfing training and evaluation specifications:" + "In this example, start by defining the `tf.estimator.Estimator` and specifying training and evaluation specifications:" ] }, { diff --git a/site/en/guide/sparse_tensor.ipynb b/site/en/guide/sparse_tensor.ipynb index cd38fdf55ab..407561ec6f5 100644 --- a/site/en/guide/sparse_tensor.ipynb +++ b/site/en/guide/sparse_tensor.ipynb @@ -31,6 +31,11 @@ "# limitations under the License." ] }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [] + }, { "cell_type": "markdown", "metadata": { @@ -620,7 +625,7 @@ "\n", "However, there are a few cases where it can be useful to distinguish zero values from missing values. In particular, this allows for one way to encode missing/unknown data in your training data. For example, consider a use case where you have a tensor of scores (that can have any floating point value from -Inf to +Inf), with some missing scores. You can encode this tensor using a sparse tensor where the explicit zeros are known zero scores but the implicit zero values actually represent missing data and not zero. \n", "\n", - "Note: This is generally not the intended usage of `tf.sparse.SparseTensor`s; and you might want to also consier other techniques for encoding this such as for example using a separate mask tensor that identifies the locations of known/unknown values. However, exercise caution while using this approach, since most sparse operations will treat explicit and implicit zero values identically." + "Note: This is generally not the intended usage of `tf.sparse.SparseTensor`s; and you might want to also consider other techniques for encoding this such as for example using a separate mask tensor that identifies the locations of known/unknown values. However, exercise caution while using this approach, since most sparse operations will treat explicit and implicit zero values identically." ] }, { diff --git a/site/en/guide/tf_numpy_type_promotion.ipynb b/site/en/guide/tf_numpy_type_promotion.ipynb index a9e176c5db6..51bea78914f 100644 --- a/site/en/guide/tf_numpy_type_promotion.ipynb +++ b/site/en/guide/tf_numpy_type_promotion.ipynb @@ -178,7 +178,8 @@ "* `f32*` means Python `float` or weakly-typed `f32`\n", "* `c128*` means Python `complex` or weakly-typed `c128`\n", "\n", - "The asterik (*) denotes that the corresponding type is “weak” - such a dtype is temporarily inferred by the system, and could defer to other dtypes. This concept is explained more in detail [here](#weak_tensor)." + "The asterisk\n", + " (*) denotes that the corresponding type is “weak” - such a dtype is temporarily inferred by the system, and could defer to other dtypes. This concept is explained more in detail [here](#weak_tensor)." ] }, { @@ -449,7 +450,7 @@ "source": [ "### WeakTensor Construction\n", "\n", - "WeakTensors are created if you create a tensor without specifing a dtype the result is a WeakTensor. You can check whether a Tensor is \"weak\" or not by checking the weak attribute at the end of the Tensor's string representation." + "WeakTensors are created if you create a tensor without specifying a dtype the result is a WeakTensor. You can check whether a Tensor is \"weak\" or not by checking the weak attribute at the end of the Tensor's string representation." ] }, { diff --git a/site/en/hub/tutorials/boundless.ipynb b/site/en/hub/tutorials/boundless.ipynb index 570e9413362..4697a810bb8 100644 --- a/site/en/hub/tutorials/boundless.ipynb +++ b/site/en/hub/tutorials/boundless.ipynb @@ -271,7 +271,7 @@ "* The input image with a mask applied\n", "* The masked image with the extrapolation to complete it\n", "\n", - "we can use these two images to show a comparisson visualization." + "we can use these two images to show a comparison visualization." ] }, { diff --git a/site/en/hub/tutorials/s3gan_generation_with_tf_hub.ipynb b/site/en/hub/tutorials/s3gan_generation_with_tf_hub.ipynb index d8efd802ae0..bd73cffebdf 100644 --- a/site/en/hub/tutorials/s3gan_generation_with_tf_hub.ipynb +++ b/site/en/hub/tutorials/s3gan_generation_with_tf_hub.ipynb @@ -86,7 +86,7 @@ "2. Click **Runtime > Run all** to run each cell in order.\n", " * Afterwards, the interactive visualizations should update automatically when you modify the settings using the sliders and dropdown menus.\n", "\n", - "Note: if you run into any issues, youn can try restarting the runtime and rerunning all cells from scratch by clicking **Runtime > Restart and run all...**.\n", + "Note: if you run into any issues, you can try restarting the runtime and rerunning all cells from scratch by clicking **Runtime > Restart and run all...**.\n", "\n", "[1] Mario Lucic\\*, Michael Tschannen\\*, Marvin Ritter\\*, Xiaohua Zhai, Olivier\n", " Bachem, Sylvain Gelly, [High-Fidelity Image Generation With Fewer Labels](https://arxiv.org/abs/1903.02271), ICML 2019." diff --git a/site/en/hub/tutorials/tf2_object_detection.ipynb b/site/en/hub/tutorials/tf2_object_detection.ipynb index 38b162068d9..3793ad20485 100644 --- a/site/en/hub/tutorials/tf2_object_detection.ipynb +++ b/site/en/hub/tutorials/tf2_object_detection.ipynb @@ -291,7 +291,7 @@ "id": "yX3pb_pXDjYA" }, "source": [ - "Intalling the Object Detection API" + "Installing the Object Detection API" ] }, { diff --git a/site/en/hub/tutorials/wiki40b_lm.ipynb b/site/en/hub/tutorials/wiki40b_lm.ipynb index e696160faca..ad94ce0aab8 100644 --- a/site/en/hub/tutorials/wiki40b_lm.ipynb +++ b/site/en/hub/tutorials/wiki40b_lm.ipynb @@ -214,7 +214,7 @@ " # Generate the tokens from the language model\n", " generation_outputs = module(generation_input_dict, signature=\"prediction\", as_dict=True)\n", "\n", - " # Get the probablities and the inputs for the next steps\n", + " # Get the probabilities and the inputs for the next steps\n", " probs = generation_outputs[\"probs\"]\n", " new_mems = [generation_outputs[\"new_mem_{}\".format(i)] for i in range(n_layer)]\n", "\n", diff --git a/site/en/r1/guide/autograph.ipynb b/site/en/r1/guide/autograph.ipynb index f028b33ce9f..790dbb49df1 100644 --- a/site/en/r1/guide/autograph.ipynb +++ b/site/en/r1/guide/autograph.ipynb @@ -241,7 +241,7 @@ "id": "m-jWmsCmByyw" }, "source": [ - "AutoGraph supports common Python statements like `while`, `for`, `if`, `break`, and `return`, with support for nesting. Compare this function with the complicated graph verson displayed in the following code blocks:" + "AutoGraph supports common Python statements like `while`, `for`, `if`, `break`, and `return`, with support for nesting. Compare this function with the complicated graph version displayed in the following code blocks:" ] }, { diff --git a/site/en/r1/guide/distribute_strategy.ipynb b/site/en/r1/guide/distribute_strategy.ipynb index 79d6293eba7..cc51259b78e 100644 --- a/site/en/r1/guide/distribute_strategy.ipynb +++ b/site/en/r1/guide/distribute_strategy.ipynb @@ -118,7 +118,7 @@ "## Types of strategies\n", "`tf.distribute.Strategy` intends to cover a number of use cases along different axes. Some of these combinations are currently supported and others will be added in the future. Some of these axes are:\n", "\n", - "* Syncronous vs asynchronous training: These are two common ways of distributing training with data parallelism. In sync training, all workers train over different slices of input data in sync, and aggregating gradients at each step. In async training, all workers are independently training over the input data and updating variables asynchronously. Typically sync training is supported via all-reduce and async through parameter server architecture.\n", + "* Synchronous vs asynchronous training: These are two common ways of distributing training with data parallelism. In sync training, all workers train over different slices of input data in sync, and aggregating gradients at each step. In async training, all workers are independently training over the input data and updating variables asynchronously. Typically sync training is supported via all-reduce and async through parameter server architecture.\n", "* Hardware platform: Users may want to scale their training onto multiple GPUs on one machine, or multiple machines in a network (with 0 or more GPUs each), or on Cloud TPUs.\n", "\n", "In order to support these use cases, we have 4 strategies available. In the next section we will talk about which of these are supported in which scenarios in TF." @@ -371,7 +371,7 @@ "id": "hQv1lm9UPDFy" }, "source": [ - "So far we've talked about what are the different stategies available and how you can instantiate them. In the next few sections, we will talk about the different ways in which you can use them to distribute your training. We will show short code snippets in this guide and link off to full tutorials which you can run end to end." + "So far we've talked about what are the different strategies available and how you can instantiate them. In the next few sections, we will talk about the different ways in which you can use them to distribute your training. We will show short code snippets in this guide and link off to full tutorials which you can run end to end." ] }, { @@ -595,7 +595,7 @@ "### Examples and Tutorials\n", "Here are some examples that show end to end usage of various strategies with Estimator:\n", "\n", - "1. [End to end example](https://github.com/tensorflow/ecosystem/tree/master/distribution_strategy) for multi worker training in tensorflow/ecosystem using Kuberentes templates. This example starts with a Keras model and converts it to an Estimator using the `tf.keras.estimator.model_to_estimator` API.\n", + "1. [End to end example](https://github.com/tensorflow/ecosystem/tree/master/distribution_strategy) for multi worker training in tensorflow/ecosystem using Kubernetes templates. This example starts with a Keras model and converts it to an Estimator using the `tf.keras.estimator.model_to_estimator` API.\n", "2. Official [ResNet50](https://github.com/tensorflow/models/blob/master/official/r1/resnet/imagenet_main.py) model, which can be trained using either `MirroredStrategy` or `MultiWorkerMirroredStrategy`.\n", "3. [ResNet50](https://github.com/tensorflow/tpu/blob/master/models/experimental/distribution_strategy/resnet_estimator.py) example with TPUStrategy." ] diff --git a/site/en/r1/tutorials/representation/unicode.ipynb b/site/en/r1/tutorials/representation/unicode.ipynb index 98aaacff5b9..301a64d72fc 100644 --- a/site/en/r1/tutorials/representation/unicode.ipynb +++ b/site/en/r1/tutorials/representation/unicode.ipynb @@ -136,7 +136,7 @@ "id": "jsMPnjb6UDJ1" }, "source": [ - "Note: When using python to construct strings, the handling of unicode differs betweeen v2 and v3. In v2, unicode strings are indicated by the \"u\" prefix, as above. In v3, strings are unicode-encoded by default." + "Note: When using python to construct strings, the handling of unicode differs between v2 and v3. In v2, unicode strings are indicated by the \"u\" prefix, as above. In v3, strings are unicode-encoded by default." ] }, { @@ -587,7 +587,7 @@ "id": "CapnbShuGU8i" }, "source": [ - "First, we decode the sentences into character codepoints, and find the script identifeir for each character." + "First, we decode the sentences into character codepoints, and find the script identifier for each character." ] }, { From 57e7adb5be0b912a6efa4b9f1e81694e616d0c87 Mon Sep 17 00:00:00 2001 From: 8bitmp3 <19637339+8bitmp3@users.noreply.github.com> Date: Wed, 25 Oct 2023 15:12:40 +0000 Subject: [PATCH 2/3] Update site/en/guide/tf_numpy_type_promotion.ipynb --- site/en/guide/tf_numpy_type_promotion.ipynb | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/site/en/guide/tf_numpy_type_promotion.ipynb b/site/en/guide/tf_numpy_type_promotion.ipynb index 51bea78914f..1b0f6d116c8 100644 --- a/site/en/guide/tf_numpy_type_promotion.ipynb +++ b/site/en/guide/tf_numpy_type_promotion.ipynb @@ -178,8 +178,7 @@ "* `f32*` means Python `float` or weakly-typed `f32`\n", "* `c128*` means Python `complex` or weakly-typed `c128`\n", "\n", - "The asterisk\n", - " (*) denotes that the corresponding type is “weak” - such a dtype is temporarily inferred by the system, and could defer to other dtypes. This concept is explained more in detail [here](#weak_tensor)." + "The asterisk (*) denotes that the corresponding type is “weak” - such a dtype is temporarily inferred by the system, and could defer to other dtypes. This concept is explained more in detail [here](#weak_tensor)." ] }, { From 2c5c356edfe1f80070ee8bc1d9956cad612cecb6 Mon Sep 17 00:00:00 2001 From: 8bitmp3 <19637339+8bitmp3@users.noreply.github.com> Date: Tue, 19 Dec 2023 23:36:54 +0000 Subject: [PATCH 3/3] Update site/en/guide/sparse_tensor.ipynb --- site/en/guide/sparse_tensor.ipynb | 5 ----- 1 file changed, 5 deletions(-) diff --git a/site/en/guide/sparse_tensor.ipynb b/site/en/guide/sparse_tensor.ipynb index 407561ec6f5..45f1e3fd3c3 100644 --- a/site/en/guide/sparse_tensor.ipynb +++ b/site/en/guide/sparse_tensor.ipynb @@ -31,11 +31,6 @@ "# limitations under the License." ] }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [] - }, { "cell_type": "markdown", "metadata": {