Skip to content

Commit

Permalink
fix file names and no plotting if no structures
Browse files Browse the repository at this point in the history
  • Loading branch information
thomashopf committed Nov 10, 2024
1 parent 0df4bf8 commit 3a14a63
Showing 1 changed file with 12 additions and 11 deletions.
23 changes: 12 additions & 11 deletions evcouplings/compare/protocol.py
Original file line number Diff line number Diff line change
Expand Up @@ -888,7 +888,7 @@ def models(**kwargs):
("remapped", seqmap, ("N", "CA", "C", "O")),
("renumbered", None, None)
]:
outcfg[name + "_model_pdb_files"] = {
outcfg[f"model_{name}_pdb_files"] = {
filename: mapping_index for mapping_index, filename in
remap_chains(
sifts_map,
Expand All @@ -903,8 +903,8 @@ def models(**kwargs):
d_intra = None
outcfg["model_distmap_monomer"] = None
outcfg["model_distmap_monomer_residues_file"] = None
outcfg["remapped_model_pdb_files"] = None
outcfg["renumbered_model_pdb_files"] = None
outcfg["model_remapped_pdb_files"] = None
outcfg["model_renumbered_pdb_files"] = None

# Step 3: Compare ECs to distance maps

Expand Down Expand Up @@ -943,14 +943,15 @@ def models(**kwargs):
score_column="score"
)

# Step 4: Make contact map plots
# if no structures available, defaults to EC-only plot
outcfg["model_contact_map_files"] = _make_contact_maps(
ec_table, d_intra, None, sifts_map, **{
**kwargs,
"prefix": kwargs["prefix"] + "_model"
}
)
# Step 4: Make contact map plots;
# unlike in standard protocol, only make plots of structures available
if len(sifts_map.hits) > 0:
outcfg["model_contact_map_files"] = _make_contact_maps(
ec_table, d_intra, None, sifts_map, **{
**kwargs,
"prefix": kwargs["prefix"] + "_model"
}
)

return outcfg

Expand Down

0 comments on commit 3a14a63

Please sign in to comment.