@@ -45,13 +45,13 @@ def merge_covalent_bonds(
45
45
for bond_dict in covalent_bonds :
46
46
bond_unique_string = []
47
47
entity_counts = (
48
- all_entity_counts [bond_dict ["left_entity" ]],
49
- all_entity_counts [bond_dict ["right_entity" ]],
48
+ all_entity_counts [str ( bond_dict ["left_entity" ]) ],
49
+ all_entity_counts [str ( bond_dict ["right_entity" ]) ],
50
50
)
51
51
for i in ["left" , "right" ]:
52
52
for j in ["entity" , "position" , "atom" ]:
53
53
k = f"{ i } _{ j } "
54
- bond_unique_string .append (bond_dict [k ])
54
+ bond_unique_string .append (str ( bond_dict [k ]) )
55
55
bond_unique_string = "_" .join (bond_unique_string )
56
56
bonds_recorder [bond_unique_string ].append (bond_dict )
57
57
bonds_entity_counts [bond_unique_string ] = entity_counts
@@ -220,10 +220,10 @@ def atom_array_to_input_json(
220
220
for idx , i in enumerate (["left" , "right" ]):
221
221
atom = atom_array [atoms [idx ]]
222
222
positon = atom .res_id
223
- bond_dict [f"{ i } _entity" ] = label_entity_id_to_entity_id_in_json [
224
- atom .label_entity_id
225
- ]
226
- bond_dict [f"{ i } _position" ] = str (positon )
223
+ bond_dict [f"{ i } _entity" ] = int (
224
+ label_entity_id_to_entity_id_in_json [ atom .label_entity_id ]
225
+ )
226
+ bond_dict [f"{ i } _position" ] = int (positon )
227
227
bond_dict [f"{ i } _atom" ] = atom .atom_name
228
228
bond_dict [f"{ i } _copy" ] = int (atom .copy_id )
229
229
0 commit comments