如何解决pycharm 没有正确显示文档字符串数学?
正如标题所说,每当我在 pycharm 中查看文档字符串时,即使在阅读模式下我也看不到正确的数学,我认为应该向我展示数学而不是生成数学的“代码”。
谁能告诉我如何解决这个问题,因为尝试读取像这样复杂的数学函数的文档字符串变得非常烦人。
当我将 .py 文件转换为 .md 时会发生这种情况
可以读取文件,但仍然无法解释数学运算。我需要一些特殊的乳胶插件吗?
当我将其转换为 .rst 时,我得到以下信息:
很明显,这种格式在 pycharm 中根本不起作用。
Edit2:根据要求,我添加了一个带有包含数学的文档字符串的类。
class FullyConnectedTensorProduct(TensorProduct):
r"""Fully-connected weighted tensor product
All the possible path allowed by :math:`|l_1 - l_2| \leq l_{out} \leq l_1 + l_2` are made.
The output is a sum on different paths:
.. math::
z_w = \sum_{u,v} w_{uvw} x_u \otimes y_v + \cdots \text{other paths}
where :math:`u,v,w` are the indices of the multiplicities.
Parameters
----------
irreps_in1 : `Irreps`
representation of the first input
irreps_in2 : `Irreps`
representation of the second input
irreps_out : `Irreps`
representation of the output
normalization : {'component','norm'}
see `TensorProduct`
internal_weights : bool
see `TensorProduct`
shared_weights : bool
see `TensorProduct`
"""
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。