文档反馈

问题文档片段

问题文档片段包含公式时,显示为空格。

提交类型
issue

有点复杂...

找人问问吧。

请选择提交类型

问题类型
规范和低错类

- 规范和低错类:

- 错别字或拼写错误,标点符号使用错误、公式错误或显示异常。

- 链接错误、空单元格、格式错误。

- 英文中包含中文字符。

- 界面和描述不一致,但不影响操作。

- 表述不通顺,但不影响理解。

- 版本号不匹配:如软件包名称、界面版本号。

易用性

- 易用性:

- 关键步骤错误或缺失,无法指导用户完成任务。

- 缺少主要功能描述、关键词解释、必要前提条件、注意事项等。

- 描述内容存在歧义指代不明、上下文矛盾。

- 逻辑不清晰,该分类、分项、分步骤的没有给出。

正确性

- 正确性:

- 技术原理、功能、支持平台、参数类型、异常报错等描述和软件实现不一致。

- 原理图、架构图等存在错误。

- 命令、命令参数等错误。

- 代码片段错误。

- 命令无法完成对应功能。

- 界面错误,无法指导操作。

- 代码样例运行报错、运行结果不符。

风险提示

- 风险提示:

- 对重要数据或系统存在风险的操作,缺少安全提示。

内容合规

- 内容合规:

- 违反法律法规,涉及政治、领土主权等敏感词。

- 内容侵权。

请选择问题类型

问题描述

点击输入详细问题描述,以帮助我们快速定位问题。

mindsponge.common.get_pdb_info

mindsponge.common.get_pdb_info(pdb_path)[源代码]

从pdb文件中获取原子坐标,残基序号等信息。针对蛋白质全原子坐标编码分为两种形式:分别为稀疏编码和稠密编码,详见: common.make_atom14_positions。本函数提供使用以上两种编码方式获取的蛋白质特征信息。

参数:
  • pdb_path (str) - 输入pdb文件的路径。

返回:

dict,包含以下key值

  • aatype (numpy.array) 蛋白质一级序列编码,编码方式参考 common.residue_constants.restype_order, 取值范围 [0,20] ,若为20表示该氨基酸为unkown(UNK)。 shape (Nres,)

  • all_atom_positions (numpy.array) pdb文件对应蛋白质序列所有原子坐标。 shape (Nres,37)

  • all_atom_mask (numpy.array) 蛋白质所有原子坐标掩码。shape (Nres,37) ,若对应位置为0则表示该氨基酸不含该原子坐标。

  • atom14_atom_exists (numpy.array) 按照稠密编码方式编码,蛋白质全原子掩码,有原子位置为1,无原子位置为0。shape (Nres,14)

  • atom14_gt_exists (numpy.array) 按照稠密编码方式编码,蛋白质全原子掩码,默认与atom14_atom_exists一致。shape (Nres,14)

  • atom14_gt_positions (numpy.array) 按照稠密编码方式编码,蛋白质全原子坐标。shape (Nres,14,3)

  • residx_atom14_to_atom37 (numpy.array) 稀疏编码方式原子在稠密编码方式中的索引映射。shape (Nres,14)

  • residx_atom37_to_atom14 (numpy.array) 稠密编码方式原子在稀疏编码方式中的索引映射。shape (Nres,37)

  • atom37_atom_exists (numpy.array) 按稀疏编码方式编码,蛋白质全原子掩码信息,有原子位置为1,无原子位置为0。shape (Nres,37)

  • atom14_alt_gt_positions (numpy.array) 按稠密编码方式编码,因手性蛋白对应全原子坐标。shape (Nres,14,3)

  • atom14_alt_gt_exists (numpy.array) 按照稠密编码方式编码,对应手性蛋白全原子掩码。shape (Nres,14)

  • atom14_atom_is_ambiguous (numpy.array) 由于部分氨基酸结构具有局部对称性,其对称原子编码可调换,具体原子参考 common.residue_atom_renaming_swaps 该特征记录了原子不确定的编码位置。shape (Nres,14)

  • residue_index (numpy.array) 蛋白质序列编码index信息,大小从1到 Nres 。shape (Nres,)

符号:
  • Nres - 蛋白质中氨基酸个数,按蛋白质一级序列排列。

支持平台:

Ascend GPU

样例:

>>> from mindsponge.common import get_pdb_info
>>> pdb_path = "YOUR PDB PATH"
>>> pdb_feature = get_pdb_info(pdb_path)
>>> for feature in pdb_feature:
>>>     print(feature, pdb_feature[feature])
# Nres represents the Amino acid num of the input pdb.
aatype (Nres,)
all_atom_positions (Nres, 37, 3)
all_atom_mask (Nres, 37)
atom14_atom_exists (Nres, 14)
atom14_gt_exists (Nres, 14)
atom14_gt_positions (Nres, 14, 3)
residx_atom14_to_atom37 (Nres, 14)
residx_atom37_to_atom14 (Nres, 37)
atom37_atom_exists (Nres, 37)
atom14_alt_gt_positions (Nres, 14, 3)
atom14_alt_gt_exists (Nres, 14)
atom14_atom_is_ambiguous (Nres, 14)
residue_index (Nres, )