Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Explain key matching in docstring of DensityCorrelations #373

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion python/featomic/featomic/clebsch_gordan/_density_correlations.py
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,19 @@ def compute(

where \\rho^{\\nu=1} is the input ``density`` of correlation order 1 (body order
2), and \\rho^{\\nu=n_{corr} + 1} is the output density of correlation order
``n_correlations + 1``
``n_correlations + 1``.

The input ``density`` must have at least ``"o3_lambda"`` and ``"o3_sigma"``
key dimensions, as well as a single components axis with the ``"o3_mu"``
dimension. Any other key dimensions present will be matched, while all properties
dimensions will have their full tensor product computed.

For instance, if the key dimensions of ``density`` are ``"o3_lambda"``,
``"o3_sigma"``, ``"center_type"``, and ``"neighbor_type"``, pairs of blocks will
only be combined if they have both the same center and neighbor atom type. To
jwa7 marked this conversation as resolved.
Show resolved Hide resolved
fully correlate all combinations of ``"neighbor_type"``, for example, this key
dimension should be moved to properties first, using the :py:class:`TensorMap`
``keys_to_properties`` method.
jwa7 marked this conversation as resolved.
Show resolved Hide resolved

Before performing any correlations, the properties dimensions of ``density`` are
modified to carry a "_1" suffix. At each iteration, the dimension names of the
Expand Down
Loading