[med-svn] [Git][med-team/plip][master] 6 commits: New upstream version 1.4.1+dfsg

Alexandre Mestiashvili gitlab at salsa.debian.org
Thu Apr 26 15:07:30 BST 2018


Alexandre Mestiashvili pushed to branch master at Debian Med / plip


Commits:
6e96fce5 by Alexandre Mestiashvili at 2018-04-26T15:27:56+02:00
New upstream version 1.4.1+dfsg
- - - - -
5dce734a by Alexandre Mestiashvili at 2018-04-26T15:27:57+02:00
Update upstream source from tag 'upstream/1.4.1+dfsg'

Update to upstream version '1.4.1+dfsg'
with Debian dir 2ae39b1459caa9ab92f87377b829ee59f9ece922
- - - - -
aa269aaa by Alexandre Mestiashvili at 2018-04-26T15:32:27+02:00
Bump Policy to 4.1.4

- - - - -
d62e3d9f by Alexandre Mestiashvili at 2018-04-26T15:42:48+02:00
Make pymol suggested, remove from build-deps

- - - - -
7b0dcd76 by Alexandre Mestiashvili at 2018-04-26T15:58:53+02:00
Install docs shipped with source

- - - - -
23b74ed7 by Alexandre Mestiashvili at 2018-04-26T16:02:32+02:00
Update changelog

Gbp-Dch: Ignore

- - - - -


11 changed files:

- CHANGES.txt
- DOCUMENTATION.md
- README.md
- debian/changelog
- debian/control
- + debian/plip.docs
- plip/modules/plipxml.py
- plip/modules/report.py
- plip/modules/supplemental.py
- plip/plipcmd
- setup.py


Changes:

=====================================
CHANGES.txt
=====================================
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -1,6 +1,12 @@
 Changelog
 ---------
 
+# 1.4.1
+* Improved import of modules
+* Corrections for README and documentation
+* Several improvements for error handling
+* independence from PyMOL when used without visualization features
+
 # 1.4.0
 * __Full Python 3 Compatibility__
 * __Read PDB files from stdin with "-f -" and write to stdout with "-O" (capital "O")__


=====================================
DOCUMENTATION.md
=====================================
--- a/DOCUMENTATION.md
+++ b/DOCUMENTATION.md
@@ -37,7 +37,7 @@ Please refer to the webpages of the corresponding tools to get help for installa
 To install all dependencies for PLIP, either just install PyMOL and then use the `pip` installation routine or install all tools and clone from GitHub.
 The current version of PLIP depends on
 * OpenBabel >=2.3.2
-* PyMOL 1.7.x with Python bindings
+* PyMOL 1.7.x with Python bindings (optional, for visualization only)
 * Imagemagick >=6.9.x (optional)
 
 and should be executed with Python 2.7.x.
@@ -351,170 +351,123 @@ The best fit with the least difference in observed targets is chosen as an estim
 | Metal Complex | [140, 64, 153] | violetpurple | dashed line |
 
 
-
 ### XML Report Documentation
 
-**report**
-
-Contains all binding site information
-
-**plipversion**
-
-Version of PLIP used for generating the output file
-
-**bindingsite**
-
-Information for one bindingsite. Has a unique ID and attribute `has_interactions`
-
-
-**identifiers**
-
-Ligand/bindingsite identifiers
-
-
-**longname**
-
-Long name of ligand, contains all het ids of ligands in one composite cluster
-
-
-**ligtype**
-
-Classification of ligand, can be SMALLMOLECULE/POLYMER/DNA/RNA/ION or combinations of the first four with ION
-
-
-**hetid**
-
-PDB hetero ID of the ligand
-
-
-**chain**
-
-Chain assigned to the ligand in the PDB file
-
-
-**position**
-Position in chain of the ligand in the PDB file
-
-**composite**
-
-Can be True or False depending on whether the ligand consists of several separate subunits or not
-
-
-**members**
-
-Lists the members of a composite ligand cluster
-
-
-**smiles**
-
-The SMILES string of the complete (composite) ligand
-
-
-**lig_properties**
-
-Additional information on the ligand, i.e. number of functional atoms
-
-
-**num_heavy_atoms**
-
-Number of heavy atoms in the ligand
-
-
-**num_hbd**
-
-Number of hydrogen bond donors in the ligand
-
-
-**num_unpaired_hbd**
-
-Number of unpaired hydrogen bond donors in the ligand (not involved as acceptor/donor in hydrogen bonds, salt bridges,
-water bridges, metal complexes)
-
-
-**num_hba**
-
-Number of hydrogen bond acceptors in the ligand
-
-
-**num_unpaired_hba**
-
-Number of unpaired hydrogen bond acceptors in the ligand (not involved as acceptor/donor in hydrogen bonds, salt bridges,
-water bridges, metal complexes)
-
-
-**num_hal**
-
-Number of halogen bond donors in the ligand
-
-
-**num_unpaired_hal**
-
-Number of unpaired halogen bond donors in the ligand
-
-
-**num_aromatic_rings**
-
-Number of aromatic rings in the ligand
-
-
-**interacting chains**
-
-Lists the chains the ligand interacts with
-
-
-**bs_residues**
-
-Listing of binding site residues the ligand is near to or interacts with. Contains the type of amino acid, information
-on contact, a unique id and the minimal distance to the ligand in Angstrom
-
-
-**interactions**
-
-Detailed information on all interactions (general attributes documented below)
-
-
-**resnr**
-
-Residue number of interacting amino acid
-
-
-**restype**
-
-Residue type of interacting amino acid
-
-
-**reschain**
-
-Residue chain of interacting amino acid
-
-**resnr_ligand**
-
-Residue number of interacting ligand residue
-
-
-**restype_ligand**
-
-Residue type of interacting ligand residue
-
-
-**reschain_ligand**
-
-Residue chain of interacting ligand residue
-
-
-**dist**
-
-Distance of interacting atoms or groups in Angstrom
-
-
-**ligcoo**
-
-Coordinates of interacting ligand atom or interaction center in ligand
-
-
-**protcoo**
-
-Coordinates of interacting protein atom or interaction center in ligand
+| Attribute  | Description |
+| ------------ | -------------- |
+| report | Contains all binding site information |
+
+#### report
+
+| Attribute  | Description |
+| ------------ | -------------- |
+| plipversion | Version of PLIP used for generating the output file |
+| bindingsite | Information for one bindingsite. Has a unique ID and attribute `has_interactions` |
+| date_of_creation | Date of the analyis |
+| citation_information | How to cite PLIP |
+| mode | Documents if PLIP was started in default or any special mode (e.g. intra-protein interactions) |
+| pdbid | PDB identifier of the input file |
+| pdbfile | Name of the input PDB file |
+| pdbfixes | Were any fixes applied automatically to the input file? |
+| filename | Filename of the processed PDB file |
+| excluded_ligands | List of excluded ligands |
+
+### bindingsite
+
+| Attribute  | Description |
+| ------------ | -------------- |
+| identifiers | Ligand/bindingsite identifiers |
+| lig_properties | Additional information on the ligand, i.e. number of functional atoms |
+| interacting chains | Lists the chains the ligand interacts with |
+| bs_residues | Listing of binding site residues the ligand is near to or interacts with.  |
+| interactions | Detailed information on all interactions |
+| mappings | Contains mappings from canonical SMILES to PDB in smiles_to_pdb |
+
+### identifiers
+
+| Attribute  | Description |
+| ------------ | -------------- |
+| longname | Long name of ligand, contains all het ids of ligands in one composite cluster |
+| ligtype | Classification of ligand, can be SMALLMOLECULE/POLYMER/DNA/RNA/ION or combinations of the first four with ION |
+| hetid | PDB hetero ID of the ligand |
+| chain | Chain assigned to the ligand in the PDB file |
+| position | Position in chain of the ligand in the PDB file |
+| composite | Can be True or False depending on whether the ligand consists of several separate subunits or not |
+| members | Lists the members of a composite ligand cluster |
+| smiles | The SMILES string of the complete (composite) ligand |
+
+### lig_properties
+
+| Attribute  | Description |
+| ------------ | -------------- |
+| num_heavy_atoms | Number of heavy atoms in the ligand |
+| num_hbd | Number of hydrogen bond donors in the ligand |
+| num_unpaired_hbd | Number of unpaired hydrogen bond donors in the ligand |
+| num_hba | Number of hydrogen bond acceptors in the ligand |
+| num_unpaired_hba | Number of unpaired hydrogen bond acceptors in the ligand |
+| num_hal | Number of halogen bond donors in the ligand |
+| num_unpaired_hal | Number of unpaired halogen bond donors in the ligand |
+| num_aromatic_rings | Number of aromatic rings in the ligand |
+| num_rotatable_bonds | Number of rotatable bonds in the ligand |
+| molweight | Molecular weight of the ligand |
+| logp | logP value of the ligand |
+
+### bs_residues
+
+Contains a list of bs_residue entries selected with a primary distance cutoff. As IDs, ech bs_residue lists aa (three-letter amino acid code), contact (boolean, indicated if residue interactions with the ligand or not), id (a continuous ID), min_dist (The minimal distance to the ligand).
+
+| Attribute  | Description |
+| ------------ | -------------- |
+bs_residue | Concatenated chain of position and residue number |
+
+### interactions
+
+Interactions are subdivided by interaction type. Most interaction types share the same information (types and IDs of interacting residue, distances), while some information is specific to certain types (charges, directionality, ring geometries, etc.)
+
+Type | Attribute  | Description |
+| ------------| ------------ | -------------- |
+All | resnr | Residue number of interacting amino acid |
+All | restype | Residue type of interacting amino acid |
+All | reschain | Residue chain of interacting amino acid |
+All | resnr_lig | Residue number of interacting ligand residue |
+All | restype_lig | Residue type of interacting ligand residue |
+All | reschain_lig | Residue chain of interacting ligand residue
+All | dist | Distance of interacting atoms or groups in Angstrom |
+All (except metal_complex) | ligcoo | Coordinates of interacting ligand atom or interaction center in ligand |
+All (except metal_complex)| protcoo | Coordinates of interacting protein atom or interaction center in ligand |
+hydrogen_bond | sidechain | Is the H-Bond formed with the sidechain of the protein? |
+hydrogen_bond | dist_h-a | Distance between H-Bond hydrogen and acceptor atom |
+hydrogen_bond | dist_d-a | Distance between H-Bond donor and acceptor atoms |
+hydrogen_bond, water_bridge, halogen_bond | don_angle | Angle at the donor |
+hydrogen_bond, water_bridge | protisdon | Is protein the donor? |
+hydrogen_bond, water_bridge, halogen_bond | donoridx/don_idx | Atom ID of the donor atom |
+hydrogen_bond, water_bridge, halogen_bond | donortype | Atom type of the donor atom |
+hydrogen_bond, water_bridge, halogen_bond | acceptoridx/acc_idx | Atom ID of the acceptor atom |
+hydrogen_bond, water_bridge, halogen_bond | acceptortype | Atom type of the acceptor atom |
+water_bridge | dist_a-w | Distance between the acceptor and interacting atom from water |
+water_bridge | dist_d-w | Distance between the donor and water interacting atom from water |
+water_bridge | water_angle | Angle at the interacting water atoms
+water_bridge | water_idx | Atom ID of the water oxygen atom |
+halogen_bond | acc_angle | Angle at the aceptor |
+salt_bridge | protispos | Does the protein carry the positive charge? |
+salt_bridge, pi_cation_interaction | lig_group | Functional group in the ligand |
+salt_bridge, pi_stack | lig_idx_list | List of atom IDs from the functional group in the ligand |
+pi_stack | cent_dist | Distance between the ring centers |
+pi_stack | angle | Angle between the ring planes |
+pi_stack, pi_cation_interaction | offset | Offset between the interacting groups |
+pi_stack | type | Stacking type (Perpendicular or T-Shaped) |
+pi_cation_interaction | protcharged | Does the protein provide the charge? |
+metal_complex| metalcoo | Coordinates of interacting metal atom |
+metal_complex| targetcoo | Coordinates of interacting protein atom or interaction center in the chelating target group (in protein or ligand) |
+metal_complex | metal_idx | Atom ID of the metal ion |
+metal_complex | metal_type | Atom type of the metal |
+metal_complex | target_idx | Atom ID of the target interacting atom |
+metal_complex | target_type | Atom type of the target interacting atom |
+metal_complex | coordination | Metal coordination number |
+metal_complex | location | Location of the target group |
+metal_complex | rms | RMS of the geometry fit |
+metal_complex | geometry | Metal coordination type |
+metal_complex | complexnum | Continous numbering for the metal complex |
 
 ## Testing
 To run the tests, run the following set of commands.


=====================================
README.md
=====================================
--- a/README.md
+++ b/README.md
@@ -3,7 +3,7 @@
 **Protein-Ligand Interaction Profiler (PLIP)**
 
  Analyze non-covalent protein-ligand interactions in 3D structures
- 
+
  <img src="https://github.com/ssalentin/plip/blob/development/pliplogo.png"  alt="PLIP Logo" height="100">
 
 ## How to use PLIP
@@ -51,7 +51,7 @@ my_mol.analyze()
 my_interactions = my_mol.interaction_sets[my_bsid] # Contains all interaction data
 
 # Now print numbers of all residues taking part in pi-stacking
-print [pistack.resnr for pistack in s.pistacking] # Prints [84, 129]
+print [pistack.resnr for pistack in my_interactions.pistacking] # Prints [84, 129]
 ```
 
 #### 3. View and process the results
@@ -67,7 +67,7 @@ Newer commits from the stable and development branch may contains new but untest
 Previous to using PLIP, make sure you have the following tools and libraries installed:
 * Python 2.7.x
 * OpenBabel >=2.3.2
-* PyMOL 1.7.x with Python bindings
+* PyMOL 1.7.x with Python bindings (optional, for visualization only)
 * Imagemagick >=6.9.x (optional)
 
 ## Contributions


=====================================
debian/changelog
=====================================
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,14 @@
+plip (1.4.1+dfsg-1) unstable; urgency=medium
+
+  * New upstream version 1.4.1+dfsg
+  * d/control:
+    - bump Policy to 4.1.4
+    - make pymol optional, remove from build-depends and depends
+      add to Suggests:
+  * Install docs shipped with source
+
+ -- Alexandre Mestiashvili <mestia at debian.org>  Thu, 26 Apr 2018 15:43:43 +0200
+
 plip (1.4.0~b+dfsg-1) unstable; urgency=medium
 
   [ Steffen Möller ]


=====================================
debian/control
=====================================
--- a/debian/control
+++ b/debian/control
@@ -6,23 +6,22 @@ Priority: optional
 Build-Depends: debhelper (>= 11),
                dh-python,
                help2man,
-               pymol,
                python-all,
                python-lxml,
                python-numpy,
                python-openbabel,
                python-setuptools,
                python-future
-Standards-Version: 4.1.3
+Standards-Version: 4.1.4
 Vcs-Browser: https://salsa.debian.org/med-team/plip
 Vcs-Git: https://salsa.debian.org/med-team/plip.git
 Homepage: https://projects.biotec.tu-dresden.de/plip-web/plip/
 
 Package: plip
 Architecture: all
-Depends: pymol,
-         ${misc:Depends},
+Depends: ${misc:Depends},
          ${python:Depends}
+Suggests: pymol
 Description: fully automated protein-ligand interaction profiler
  The Protein-Ligand Interaction Profiler (PLIP) is a tool to analyze
  and visualize protein-ligand interactions in PDB files.


=====================================
debian/plip.docs
=====================================
--- /dev/null
+++ b/debian/plip.docs
@@ -0,0 +1,2 @@
+README.md
+DOCUMENTATION.md


=====================================
plip/modules/plipxml.py
=====================================
--- a/plip/modules/plipxml.py
+++ b/plip/modules/plipxml.py
@@ -195,6 +195,8 @@ class BSite(XMLStorage):
         self.ligtype = self.getdata(bindingsite, 'identifiers/ligtype')
         self.smiles = self.getdata(bindingsite, 'identifiers/smiles')
         self.inchikey = self.getdata(bindingsite, 'identifiers/inchikey')
+        self.position = self.getdata(bindingsite, 'identifiers/position')
+        self.chain = self.getdata(bindingsite, 'identifiers/chain')
 
         # Information on binding site members
         self.members = []
@@ -289,11 +291,7 @@ class PLIPXML(XMLStorage):
 
     def load_data(self, xmlfile):
         """Loads/parses an XML file and saves it as a tree if successful."""
-        try:
-            self.doc = etree.parse(xmlfile)
-        except IOError:
-            sys.__stderr__.write("XML %s file could not be read." % xmlfile)
-            sys.exit(1)
+        self.doc = etree.parse(xmlfile)
 
 class PLIPXMLREST(PLIPXML):
     """Parses and stores all from a PLIP XML file from the PLIP REST service"""
@@ -304,8 +302,4 @@ class PLIPXMLREST(PLIPXML):
         """Loads and parses an XML resource and saves it as a tree if successful"""
         #TODO Implement error handling
         f = urlopen("http://projects.biotec.tu-dresden.de/plip-rest/pdb/%s?format=xml" % pdbid.lower())
-        try:
-            self.doc = etree.parse(f)
-        except IOError:
-            sys.__stderr__.write("XML file for PDB ID %s could not be read." % pdbid)
-            sys.exit(1)
+        self.doc = etree.parse(f)


=====================================
plip/modules/report.py
=====================================
--- a/plip/modules/report.py
+++ b/plip/modules/report.py
@@ -19,7 +19,7 @@ from . import config
 # External libraries
 import lxml.etree as et
 
-__version__ = '1.4.0'
+__version__ = '1.4.1'
 
 class StructureReport:
     """Creates reports (xml or txt) for one structure/"""


=====================================
plip/modules/supplemental.py
=====================================
--- a/plip/modules/supplemental.py
+++ b/plip/modules/supplemental.py
@@ -27,8 +27,6 @@ import pybel
 from pybel import *
 from openbabel import *
 import numpy as np
-from pymol import cmd
-from pymol import finish_launching
 import itertools
 
 # Settings
@@ -221,9 +219,10 @@ def cmd_exists(c):
 
 def initialize_pymol(options):
     """Initializes PyMOL"""
+    import pymol
     # Pass standard arguments of function to prevent PyMOL from printing out PDB headers (workaround)
-    finish_launching(args=['pymol', options, '-K'])
-    cmd.reinitialize()
+    pymol.finish_launching(args=['pymol', options, '-K'])
+    pymol.cmd.reinitialize()
 
 
 def start_pymol(quiet=False, options='-p', run=False):
@@ -234,7 +233,7 @@ def start_pymol(quiet=False, options='-p', run=False):
     if run:
         initialize_pymol(options)
     if quiet:
-        cmd.feedback('disable', 'all', 'everything')
+        pymol.cmd.feedback('disable', 'all', 'everything')
 
 def nucleotide_linkage(residues):
     """Support for DNA/RNA ligands by finding missing covalent linkages to stitch DNA/RNA together."""
@@ -410,7 +409,7 @@ def read(fil):
 def readmol(path, as_string=False):
     """Reads the given molecule file and returns the corresponding Pybel molecule as well as the input file type.
     In contrast to the standard Pybel implementation, the file is closed properly."""
-    supported_formats = ['pdb', 'mmcif']
+    supported_formats = ['pdb']
     # Fix for Windows-generated files: Remove carriage return characters
     if "\r" in path and as_string:
         path = path.replace('\r', '')
@@ -495,7 +494,4 @@ def message(msg, indent=False, mtype='standard', caption=False):
         msg = colorlog('Info:  ' + msg, 'green')
     if indent:
         msg = '  ' + msg
-    if mtype in ['error', 'warning']:
-        sys.stderr.write(msg)
-    else:
-        sys.stdout.write(msg)
+    sys.stderr.write(msg)


=====================================
plip/plipcmd
=====================================
--- a/plip/plipcmd
+++ b/plip/plipcmd
@@ -9,13 +9,12 @@ from __future__ import print_function
 from __future__ import absolute_import
 
 # Own modules
-from modules.preparation import *
-from modules.visualize import visualize_in_pymol
-from modules.plipremote import VisualizerData
-from modules.report import StructureReport,__version__
-from modules import config
-from modules.mp import parallel_fn
-from modules.webservices import check_pdb_status, fetch_pdb
+from plip.modules.preparation import *
+from plip.modules.plipremote import VisualizerData
+from plip.modules.report import StructureReport,__version__
+from plip.modules import config
+from plip.modules.mp import parallel_fn
+from plip.modules.webservices import check_pdb_status, fetch_pdb
 
 # Python standard library
 import sys
@@ -73,6 +72,7 @@ def process_pdb(pdbfile, outpath, as_string=False):
     ######################################
 
     if config.PYMOL or config.PICS:
+        from plip.modules.visualize import visualize_in_pymol
         complexes = [VisualizerData(mol, site) for site in sorted(mol.interaction_sets)
                      if not len(mol.interaction_sets[site].interacting_res) == 0]
         if config.MAXTHREADS > 1:
@@ -253,6 +253,13 @@ if __name__ == '__main__':
     config.NOFIXFILE = arguments.nofixfile
     config.KEEPMOD = arguments.keepmod
     config.DNARECEPTOR = arguments.dnareceptor
+    # Make sure we have pymol with --pics and --pymol
+    if config.PICS or config.PYMOL:
+        try:
+            import pymol
+        except ImportError:
+            write_message("PyMOL is required for --pics and --pymol.\n", mtype='error')
+            raise
     # Assign values to global thresholds
     for t in thresholds:
         tvalue = getattr(arguments, t.name)


=====================================
setup.py
=====================================
--- a/setup.py
+++ b/setup.py
@@ -6,7 +6,7 @@ setup.py - Setup configuration file for pip, etc.
 from setuptools import setup
 
 setup(name='plip',
-      version='1.4.0',
+      version='1.4.1',
       description='PLIP - Fully automated protein-ligand interaction profiler',
       classifiers=[
           'Development Status :: 5 - Production/Stable',



View it on GitLab: https://salsa.debian.org/med-team/plip/compare/caf52b101f6144ff869e4eb9b0eb6349578bf44b...23b74ed79058a03cb56204bad72032d259596a65

---
View it on GitLab: https://salsa.debian.org/med-team/plip/compare/caf52b101f6144ff869e4eb9b0eb6349578bf44b...23b74ed79058a03cb56204bad72032d259596a65
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20180426/87275f53/attachment-0001.html>


More information about the debian-med-commit mailing list