From 6bbd6fa7ec53e1a0971fba40c96fa971d1022f74 Mon Sep 17 00:00:00 2001 From: B13nch3n <b13nch3n_01@theb-si.de> Date: Mon, 18 Jul 2022 14:27:08 +0200 Subject: [PATCH] Minor fixes --- translate2modelcif.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/translate2modelcif.py b/translate2modelcif.py index e685cb6..50ffdbb 100644 --- a/translate2modelcif.py +++ b/translate2modelcif.py @@ -251,7 +251,6 @@ def _get_protocol_steps_and_software(cnfg_file): # Must refer to existing data, so we try keywords step["output"] = "model" # get software -<<<<<<< HEAD step["software"] = [ { "name": "ColabFold", @@ -543,6 +542,8 @@ def _get_scores(data, prfx): with open(scrs_fle, encoding="utf8") as jfh: scrs_json = json.load(jfh) + # ToDo: is dict.update still the way to go when iterating multiple model + # directories? Aka, does dict.update overwrite old scores? data.update(scrs_json) @@ -613,11 +614,10 @@ def _get_modelcif_protocol(protocol_steps, target_entities, model): for sft in js_step["software"]: sftwre.append(_assemble_modelcif_software(sft)) sftwre = modelcif.SoftwareGroup(elements=sftwre) - # ToDo [internal]: add software parameters - if js_step['software_parameters']: + if js_step["software_parameters"]: params = [] # ToDo [internal]: handle lists! - for k, v in js_step['software_parameters'].items(): + for k, v in js_step["software_parameters"].items(): params.append( modelcif.SoftwareParameter(k, v) ) @@ -630,6 +630,7 @@ def _get_modelcif_protocol(protocol_steps, target_entities, model): if js_step["input"] == "target_sequences": input_data = modelcif.data.DataGroup(target_entities) + # ToDo: Add databases + versions elif js_step["input"] == "model": input_data = model else: -- GitLab