From dab9ab1897e8662d4b334cdd0d1db82e71060bb4 Mon Sep 17 00:00:00 2001 From: Florian Fervers Date: Thu, 13 Feb 2025 07:04:39 +0000 Subject: [PATCH] Fix some expressions in tutorial --- docs/source/gettingstarted/tutorial_notation.rst | 3 +-- docs/source/gettingstarted/tutorial_ops.rst | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/docs/source/gettingstarted/tutorial_notation.rst b/docs/source/gettingstarted/tutorial_notation.rst index 8570a59..ff0ac74 100644 --- a/docs/source/gettingstarted/tutorial_notation.rst +++ b/docs/source/gettingstarted/tutorial_notation.rst @@ -289,8 +289,7 @@ Some other examples: .. code:: - einx.flip("a [b]", x, c=2) # Flip pairs of values - einx.add("... [c]", x, b) # Add bias + einx.flip("a [b]", x, b=2) # Flip pairs of values einx.get_at("b [h w] c, b i [2] -> b i c", x, indices) # Gather values einx.softmax("b q [k] h", attn) # Part of attention operation diff --git a/docs/source/gettingstarted/tutorial_ops.rst b/docs/source/gettingstarted/tutorial_ops.rst index a6e668e..73ae356 100644 --- a/docs/source/gettingstarted/tutorial_ops.rst +++ b/docs/source/gettingstarted/tutorial_ops.rst @@ -240,7 +240,7 @@ All operations support expression rearranging: .. code:: - einx.add_at("b ([h w]) c, ([2] b) i, c i -> c [h w] b", image, coordinates, updates) + einx.add_at("b ([h w]) c, ([2] b) i, c i -> c [h w] b", image, coordinates, updates, h=256) Several operations from classical tensor frameworks can be expressed using universal einx indexing functions: