Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Mapping of the residues given in input failed. This can be due to a malformed residue file or a mistake in the reisdue numbering, type or chain. #27

Open
1 task done
avilella opened this issue Jan 23, 2025 · 1 comment
Labels
bug Something isn't working needs-triage Review is required to valid the label

Comments

@avilella
Copy link

Operating System

Unix (e.g., Ubuntu 20.04)

Version

1.0

Python Version (optional)

3.10.12

Python Virtual Environment

Not using a virtual environment

Execution Environment

Encapsulated environment from the SURFMAP Docker image

Bug Description

The command below used to work, but I think the chimera version that I now use might be introducing lines in the .pdb file that SURFACE doesn't know how to interpret.

See error below:

Running: /home/surfmap/MSMS//pdb_to_xyzr /input/0307326f3c557828716ec74b28fdf620.rf2.lcpb.mmkr.pdb > ./shells/0307326f3c557828716ec74b28fdf620.rf2.lcpb.mmkr.xyzr-tmp ...
                                                                                                                                                                                                                 surface property mapping: kyte_doolittle                                                                                                                                                                         Traceback (most recent call last):
  File "/home/surfmap/tools/SurfmapTools.py", line 177, in <module>
    main()
  File "/home/surfmap/tools/SurfmapTools.py", line 166, in main
    scalevalue = Structure.returnPropensity(dPDB[chainid][resid]["resname"], distmini, scale = "kyte_doolittle")
  File "/home/surfmap/tools/Structure.py", line 158, in returnPropensity
    kyte_doolittle = float(dkyte_doolittle[aa])
KeyError: 'UNK'

Mapping of the residues given in input failed. This can be due to a malformed residue file or a mistake in the reisdue numbering, type or chain.

Format should be the following:
chain residuenumber residuetype
example: A      5 LEU

Exiting now.

docker run --tty --rm --volume /bfx_nfs/surface/03/0307326f3c557828716ec74b28fdf620:/input/:rw --volume /bfx_nfs/surface/03/0307326f3c557828716ec74b28fdf620:/output/:rw nchenche/surfmap:v0.2 -pdb /input/0307326f3c557828716ec74b28fdf620.rf2.lcpb.mmkr.pdb -tomap all -d /output/0307326f3c557828716ec74b28fdf620.rf2.lcpb.mmkr_all.srfm

See a screenshot of the first few lines of the input file:

Image

Should getting rid of the non-ATOM lines fix the issue?

Steps to Reproduce

see above

Relevant Log Output

Additional context (optional)

No response

Confirmation

  • I confirm I have searched for duplicates and reviewed the relevant documentation.
@avilella avilella added bug Something isn't working needs-triage Review is required to valid the label labels Jan 23, 2025
@nchenche
Copy link
Collaborator

Hello @avilella,

The SURMAP pdb parsing process reads only 'ATOM' starting line so new lines will not cause an error.

From what i see however, the problem you encounter resides in an unknow residue name in your pdb:

kyte_doolittle = float(dkyte_doolittle[aa])
KeyError: 'UNK'

For properties like kyte-doolitle, wimley_white or stickiness, the 20 amino acids are assigned a specific value in a dictionary with their standard residue name as key. As a consequence, any non-standard or unknow residue names will generate a key error for those properties.

To solve your problem, you should remove this 'UNK' residues in your pdb.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs-triage Review is required to valid the label
Projects
None yet
Development

No branches or pull requests

2 participants