diff --git a/modules/mol/alg/pymod/lddt.py b/modules/mol/alg/pymod/lddt.py index 83c1b2d604bdbd06c3c0e50fe7ab9827d3beb84d..7c0a0dfe2c53cc5a42ee4b631348e73ae888046d 100644 --- a/modules/mol/alg/pymod/lddt.py +++ b/modules/mol/alg/pymod/lddt.py @@ -693,9 +693,10 @@ class lDDTScorer: # the only place where actually need to compute per-atom lDDT # scores for a_idx in range(len(atom_list)): - tmp = summed_per_atom_conserved[a_idx] / per_atom_exp[a_idx] - tmp = tmp / n_thresh - atom_list[a_idx].SetFloatProp(local_lddt_prop, tmp) + if per_atom_exp[a_idx] != 0: + tmp = summed_per_atom_conserved[a_idx] / per_atom_exp[a_idx] + tmp = tmp / n_thresh + atom_list[a_idx].SetFloatProp(local_lddt_prop, tmp) if local_contact_prop: conserved_prop = local_contact_prop + "_cons"