Skip to content

Commit

Permalink
mini fixes in the doc (#71)
Browse files Browse the repository at this point in the history
  • Loading branch information
mariogeiger authored Jan 21, 2025
1 parent c0ee728 commit 25e588e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
4 changes: 3 additions & 1 deletion docs/tutorials/etp.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
Equivariant Tensor Product
==========================

The submodule :class:`cuequivariance.descriptors` contains many descriptors of Equivariant Tensor Products (:class:`cuequivariance.EquivariantTensorProduct`).
The submodule :class:`cuequivariance.descriptors` contains many descriptors of Equivariant Tensor Products represented by the class :class:`cuequivariance.EquivariantTensorProduct`.

Examples
--------
Expand Down Expand Up @@ -59,6 +59,7 @@ Execution on JAX

import jax
import jax.numpy as jnp
import cuequivariance as cue
import cuequivariance_jax as cuex

e = cue.descriptors.linear(
Expand All @@ -83,6 +84,7 @@ We can execute an :class:`cuequivariance.EquivariantTensorProduct` with PyTorch.
.. jupyter-execute::

import torch
import cuequivariance as cue
import cuequivariance_torch as cuet

e = cue.descriptors.linear(
Expand Down
6 changes: 3 additions & 3 deletions docs/tutorials/stp.rst
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ The subscripts of this tensor product are "uv,iu,iv" where "uv" represents the m
d

Each operand of the tensor product descriptor has a list of segments.
We can add segments to the descriptor using the `add_segment` method.
We can add segments to the descriptor using the :meth:`add_segment <cuequivariance.SegmentedTensorProduct.add_segment>` method.
We can add the segments of the input and output representations to the descriptor.

.. jupyter-execute::
Expand Down Expand Up @@ -90,15 +90,15 @@ Finally, we can normalize the paths for the last operand such that the output is

As we can see, the paths coefficients has been normalized.

Now we can create a tensor product from the descriptor and execute it. In PyTorch, we can use the :class:`cuet.TensorProduct` class.
Now we can create a tensor product from the descriptor and execute it. In PyTorch, we can use the :class:`cuet.TensorProduct <cuequivariance_torch.TensorProduct>` class.

.. jupyter-execute::

linear_torch = cuet.TensorProduct(d, use_fallback=True)
linear_torch


In JAX, we can use the :func:`cuex.tensor_product` function.
In JAX, we can use the :func:`cuex.tensor_product <cuequivariance_jax.tensor_product>` function.

.. jupyter-execute::

Expand Down

0 comments on commit 25e588e

Please sign in to comment.