Skip to content

Commit e32bac4

Browse files
Fixed Typos in JEP doc files
1 parent 30208fa commit e32bac4

File tree

3 files changed

+10
-10
lines changed

3 files changed

+10
-10
lines changed

docs/jep/10657-sequencing-effects.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ def f(token, x):
132132
return token, x
133133
```
134134
If we rewrite `jax.print` to take in and return a token, we have now sequenced
135-
the two prints since the input to the second print depends is the output of the first print.
135+
the two prints since the input to the second print depends on the output of the first print.
136136
The actual value of `token` can be anything really, but we'll see in practice
137137
that the tokens are invisible to users.
138138

@@ -207,7 +207,7 @@ computations will take the token as input and return it as an output.
207207
The implementation of this token threading involves upgrading the JAX lowering machinery to do
208208
this bookkeeping automatically.
209209
The main challenges involve dealing with higher-order primitives like call primitives
210-
and control-flow primitives. We won't go into details in how to handle those in this design note.
210+
and control-flow primitives. We won't go into details on how to handle those in this design note.
211211

212212
## Blocking on output tokens
213213

docs/jep/9407-type-promotion.ipynb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -711,7 +711,7 @@
711711
"source": [
712712
"This behavior gives motivation to our `*` notation for scalar values: the `*` is reminiscent of a wildcard that can take on any desired value.\n",
713713
"\n",
714-
"The benefit of these semantics are that you can readily express sequences of operations with clean Python code, without having to explicitly cast scalars to the appropriate type. Imagine if rather than writing this:\n",
714+
"The benefit of these semantics is that you can readily express sequences of operations with clean Python code, without having to explicitly cast scalars to the appropriate type. Imagine if rather than writing this:\n",
715715
"```python\n",
716716
"3 * (x + 1) ** 2\n",
717717
"```\n",
@@ -801,7 +801,7 @@
801801
"\n",
802802
"5. Wherever possible, binary promotion should avoid resulting in types that are wider than the inputs. This is to ensure that JAX's implicit promotions remain friendly to accelerator-based workflows, in which users often want to restrict types to 32-bit (or in some cases 16-bit) values.\n",
803803
"\n",
804-
"Each new connection on the lattice introduces some level of convenience to the user (a new set of types that can interact without explicit casting), but the convenience may becomes too costly if any of the above criteria are violated. Developing a full promotion lattice involves striking a balance between this convenience and this cost."
804+
"Each new connection on the lattice introduces some level of convenience to the user (a new set of types that can interact without explicit casting), but the convenience may become too costly if any of the above criteria are violated. Developing a full promotion lattice involves striking a balance between this convenience and this cost."
805805
]
806806
},
807807
{
@@ -946,7 +946,7 @@
946946
"source": [
947947
"### How to handle `uint64`?\n",
948948
"\n",
949-
"The approached to mixed signed/unsigned integer promotion leaves out one type: `uint64`. Following the pattern above, the output of a mixed-integer operation involving `uint64` should result in `int128`, but this is not a standard available dtype.\n",
949+
"The approach to mixed signed/unsigned integer promotion leaves out one type: `uint64`. Following the pattern above, the output of a mixed-integer operation involving `uint64` should result in `int128`, but this is not a standard available dtype.\n",
950950
"\n",
951951
"Numpy's choice here is to promote to `float64`:"
952952
]
@@ -1335,7 +1335,7 @@
13351335
"However, these advantages comes with a few tradeoffs:\n",
13361336
"\n",
13371337
"- mixed float/integer promotion is very prone to precision loss: for example, `int64` (with a maximum value of $9.2 \\times 10^{18}$) can be promoted to `float16` (with a maximum value of $6.5 \\times 10^4$), meaning most representable values will become `inf`.\n",
1338-
"- as mentioned above, `f*` can no longer be thought of as a \"scalar type\", but whether as a different flavor of float64. In JAX's parlance, this is referred to as a [*weak type*](https://jax.readthedocs.io/en/latest/type_promotion.html#weakly-typed-values-in-jax), in that it is represented as 64-bit, but only weakly holds to this bit width in promotion with other values.\n",
1338+
"- as mentioned above, `f*` can no longer be thought of as a \"scalar type\", but as a different flavor of float64. In JAX's parlance, this is referred to as a [*weak type*](https://jax.readthedocs.io/en/latest/type_promotion.html#weakly-typed-values-in-jax), in that it is represented as 64-bit, but only weakly holds to this bit width in promotion with other values.\n",
13391339
"\n",
13401340
"Note that also, this approach still leaves the `uint64` promotion question unanswered, although it is perhaps reasonable to close the lattice by connecting `u64` to `f*`."
13411341
]

docs/jep/9407-type-promotion.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -311,7 +311,7 @@ for dtype in [np.int8, np.int16, np.int32, np.int64]:
311311

312312
This behavior gives motivation to our `*` notation for scalar values: the `*` is reminiscent of a wildcard that can take on any desired value.
313313

314-
The benefit of these semantics are that you can readily express sequences of operations with clean Python code, without having to explicitly cast scalars to the appropriate type. Imagine if rather than writing this:
314+
The benefit of these semantics is that you can readily express sequences of operations with clean Python code, without having to explicitly cast scalars to the appropriate type. Imagine if rather than writing this:
315315
```python
316316
3 * (x + 1) ** 2
317317
```
@@ -373,7 +373,7 @@ Broadly speaking, we want any additional connections to satisfy a few properties
373373

374374
5. Wherever possible, binary promotion should avoid resulting in types that are wider than the inputs. This is to ensure that JAX's implicit promotions remain friendly to accelerator-based workflows, in which users often want to restrict types to 32-bit (or in some cases 16-bit) values.
375375

376-
Each new connection on the lattice introduces some level of convenience to the user (a new set of types that can interact without explicit casting), but the convenience may becomes too costly if any of the above criteria are violated. Developing a full promotion lattice involves striking a balance between this convenience and this cost.
376+
Each new connection on the lattice introduces some level of convenience to the user (a new set of types that can interact without explicit casting), but the convenience may become too costly if any of the above criteria are violated. Developing a full promotion lattice involves striking a balance between this convenience and this cost.
377377

378378
+++ {"id": "GSqwTTS8nYdn"}
379379

@@ -457,7 +457,7 @@ Again, the connections added here are precisely the promotion semantics implemen
457457

458458
### How to handle `uint64`?
459459

460-
The approached to mixed signed/unsigned integer promotion leaves out one type: `uint64`. Following the pattern above, the output of a mixed-integer operation involving `uint64` should result in `int128`, but this is not a standard available dtype.
460+
The approach to mixed signed/unsigned integer promotion leaves out one type: `uint64`. Following the pattern above, the output of a mixed-integer operation involving `uint64` should result in `int128`, but this is not a standard available dtype.
461461

462462
Numpy's choice here is to promote to `float64`:
463463

@@ -680,7 +680,7 @@ This is important because `f16` and `bf16` are not comparable because they utili
680680
However, these advantages comes with a few tradeoffs:
681681

682682
- mixed float/integer promotion is very prone to precision loss: for example, `int64` (with a maximum value of $9.2 \times 10^{18}$) can be promoted to `float16` (with a maximum value of $6.5 \times 10^4$), meaning most representable values will become `inf`.
683-
- as mentioned above, `f*` can no longer be thought of as a "scalar type", but whether as a different flavor of float64. In JAX's parlance, this is referred to as a [*weak type*](https://jax.readthedocs.io/en/latest/type_promotion.html#weakly-typed-values-in-jax), in that it is represented as 64-bit, but only weakly holds to this bit width in promotion with other values.
683+
- as mentioned above, `f*` can no longer be thought of as a "scalar type", but as a different flavor of float64. In JAX's parlance, this is referred to as a [*weak type*](https://jax.readthedocs.io/en/latest/type_promotion.html#weakly-typed-values-in-jax), in that it is represented as 64-bit, but only weakly holds to this bit width in promotion with other values.
684684

685685
Note that also, this approach still leaves the `uint64` promotion question unanswered, although it is perhaps reasonable to close the lattice by connecting `u64` to `f*`.
686686

0 commit comments

Comments
 (0)