File tree Expand file tree Collapse file tree 3 files changed +5
-6
lines changed
Expand file tree Collapse file tree 3 files changed +5
-6
lines changed Original file line number Diff line number Diff line change 55from functools import partial , wraps
66from collections import namedtuple
77
8- import einops
98import torch
109from torch import nn
1110from torch import Tensor
Original file line number Diff line number Diff line change @@ -362,8 +362,10 @@ def molecule_to_atom_input(
362362 _ , last_atom_index = prev_src_tgt_atom_indices
363363 first_atom_index , _ = src_tgt_atom_indices
364364
365- src_atom_offset = offset + first_atom_index
366- tgt_atom_offset = offset - last_atom_index
365+ last_atom_index_from_end = prev_mol .GetNumAtoms () - last_atom_index
366+
367+ src_atom_offset = offset - last_atom_index_from_end
368+ tgt_atom_offset = offset + first_atom_index
367369
368370 atompair_ids [src_atom_offset , tgt_atom_offset ] = 1
369371 atompair_ids [tgt_atom_offset , src_atom_offset ] = 1
@@ -671,8 +673,6 @@ def alphafold3_input_to_molecule_input(
671673 * metal_ions_pool_lens
672674 ]
673675
674- total_atoms = sum (token_pool_lens )
675-
676676 # construct the token bonds
677677
678678 # will be linearly connected for proteins and nucleic acids
Original file line number Diff line number Diff line change 11[project ]
22name = " alphafold3-pytorch"
3- version = " 0.1.124 "
3+ version = " 0.1.125 "
44description = " Alphafold 3 - Pytorch"
55authors = [
66 {
name =
" Phil Wang" ,
email =
" [email protected] " }
You can’t perform that action at this time.
0 commit comments