Skip to content

Commit

Permalink
Fixing reaction scoring
Browse files Browse the repository at this point in the history
  • Loading branch information
Christopher Henry committed Feb 13, 2025
1 parent ee19f85 commit 92fafba
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions modelseedpy/core/msmodelutl.py
Original file line number Diff line number Diff line change
Expand Up @@ -891,17 +891,17 @@ def assign_reliability_scores_to_reactions(self):
#if msrxn["pathways"] == None:
# basescore = 50
#Penalizing if there is no deltaG
if msrxn.deltag == 10000000:
if msrxn.delta_g == 10000000 or msrxn.delta_g == None:
basescore = 200
else:
#Penalizing in the direction of infeasiblility
if msrxn.deltag <= -5:
if msrxn.delta_g <= -5:
reversescore += 20
if msrxn.deltag <= -10:
if msrxn.delta_g <= -10:
reversescore += 20
if msrxn.deltag >= 5:
if msrxn.delta_g >= 5:
forwardscore += 20
if msrxn.deltag >= 10:
if msrxn.delta_g >= 10:
forwardscore += 20
#Penalizing reactions in direction of production of ATP
for cpd in msrxn.metabolites:
Expand All @@ -914,7 +914,7 @@ def assign_reliability_scores_to_reactions(self):
basescore += 40
if cpd.formula == None:
basescore += 60
if cpd.deltag == 10000000:
if cpd.delta_g == 10000000 or cpd.delta_g == None:
basescore += 20
self.reliability_scores[reaction.id] = {}
self.reliability_scores[reaction.id][">"] = basescore+forwardscore
Expand Down

0 comments on commit 92fafba

Please sign in to comment.