py-packman 1.4.0__zip

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. Program Files/Python39/Lib/site-packages/packman/__init__.py +18 -0
  2. Program Files/Python39/Lib/site-packages/packman/__main__.py +4 -0
  3. Program Files/Python39/Lib/site-packages/packman/__pycache__/__init__.cpython-39.pyc +0 -0
  4. Program Files/Python39/Lib/site-packages/packman/__pycache__/__main__.cpython-39.pyc +0 -0
  5. Program Files/Python39/Lib/site-packages/packman/anm/__init__.py +25 -0
  6. Program Files/Python39/Lib/site-packages/packman/anm/__pycache__/__init__.cpython-39.pyc +0 -0
  7. Program Files/Python39/Lib/site-packages/packman/anm/__pycache__/anm.cpython-39.pyc +0 -0
  8. Program Files/Python39/Lib/site-packages/packman/anm/__pycache__/hd_anm.cpython-39.pyc +0 -0
  9. Program Files/Python39/Lib/site-packages/packman/anm/anm.py +317 -0
  10. Program Files/Python39/Lib/site-packages/packman/anm/hd_anm.py +656 -0
  11. Program Files/Python39/Lib/site-packages/packman/apps/__init__.py +25 -0
  12. Program Files/Python39/Lib/site-packages/packman/apps/__pycache__/__init__.cpython-39.pyc +0 -0
  13. Program Files/Python39/Lib/site-packages/packman/apps/__pycache__/calculate_entropy.cpython-39.pyc +0 -0
  14. Program Files/Python39/Lib/site-packages/packman/apps/__pycache__/dci.cpython-39.pyc +0 -0
  15. Program Files/Python39/Lib/site-packages/packman/apps/__pycache__/hdanm.cpython-39.pyc +0 -0
  16. Program Files/Python39/Lib/site-packages/packman/apps/__pycache__/predict_hinge.cpython-39.pyc +0 -0
  17. Program Files/Python39/Lib/site-packages/packman/apps/calculate_entropy.py +60 -0
  18. Program Files/Python39/Lib/site-packages/packman/apps/dci.py +323 -0
  19. Program Files/Python39/Lib/site-packages/packman/apps/hdanm.py +47 -0
  20. Program Files/Python39/Lib/site-packages/packman/apps/predict_hinge.py +375 -0
  21. Program Files/Python39/Lib/site-packages/packman/bin/GUI.py +709 -0
  22. Program Files/Python39/Lib/site-packages/packman/bin/PACKMAN.py +154 -0
  23. Program Files/Python39/Lib/site-packages/packman/bin/__init__.py +27 -0
  24. Program Files/Python39/Lib/site-packages/packman/bin/__pycache__/GUI.cpython-39.pyc +0 -0
  25. Program Files/Python39/Lib/site-packages/packman/bin/__pycache__/PACKMAN.cpython-39.pyc +0 -0
  26. Program Files/Python39/Lib/site-packages/packman/bin/__pycache__/__init__.cpython-39.pyc +0 -0
  27. Program Files/Python39/Lib/site-packages/packman/bin/logo.ico +0 -0
  28. Program Files/Python39/Lib/site-packages/packman/constants/Constants.py +236 -0
  29. Program Files/Python39/Lib/site-packages/packman/constants/__init__.py +3 -0
  30. Program Files/Python39/Lib/site-packages/packman/constants/__pycache__/Constants.cpython-39.pyc +0 -0
  31. Program Files/Python39/Lib/site-packages/packman/constants/__pycache__/__init__.cpython-39.pyc +0 -0
  32. Program Files/Python39/Lib/site-packages/packman/entropy/__init__.py +12 -0
  33. Program Files/Python39/Lib/site-packages/packman/entropy/__pycache__/__init__.cpython-39.pyc +0 -0
  34. Program Files/Python39/Lib/site-packages/packman/entropy/__pycache__/entropy.cpython-39.pyc +0 -0
  35. Program Files/Python39/Lib/site-packages/packman/entropy/entropy.py +155 -0
  36. Program Files/Python39/Lib/site-packages/packman/geometry/__init__.py +17 -0
  37. Program Files/Python39/Lib/site-packages/packman/geometry/__pycache__/__init__.cpython-39.pyc +0 -0
  38. Program Files/Python39/Lib/site-packages/packman/geometry/__pycache__/geometry.cpython-39.pyc +0 -0
  39. Program Files/Python39/Lib/site-packages/packman/geometry/geometry.py +112 -0
  40. Program Files/Python39/Lib/site-packages/packman/molecule/__init__.py +45 -0
  41. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/__init__.cpython-39.pyc +0 -0
  42. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/annotations.cpython-39.pyc +0 -0
  43. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/atom.cpython-39.pyc +0 -0
  44. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/bond.cpython-39.pyc +0 -0
  45. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/chain.cpython-39.pyc +0 -0
  46. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/hetmol.cpython-39.pyc +0 -0
  47. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/model.cpython-39.pyc +0 -0
  48. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/molecule.cpython-39.pyc +0 -0
  49. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/protein.cpython-39.pyc +0 -0
  50. Program Files/Python39/Lib/site-packages/packman/molecule/__pycache__/residue.cpython-39.pyc +0 -0
  51. Program Files/Python39/Lib/site-packages/packman/molecule/annotations.py +92 -0
  52. Program Files/Python39/Lib/site-packages/packman/molecule/atom.py +332 -0
  53. Program Files/Python39/Lib/site-packages/packman/molecule/bond.py +186 -0
  54. Program Files/Python39/Lib/site-packages/packman/molecule/chain.py +323 -0
  55. Program Files/Python39/Lib/site-packages/packman/molecule/hetmol.py +224 -0
  56. Program Files/Python39/Lib/site-packages/packman/molecule/model.py +703 -0
  57. Program Files/Python39/Lib/site-packages/packman/molecule/molecule.py +470 -0
  58. Program Files/Python39/Lib/site-packages/packman/molecule/protein.py +162 -0
  59. Program Files/Python39/Lib/site-packages/packman/molecule/residue.py +322 -0
  60. Program Files/Python39/Lib/site-packages/packman/tests/__init__.py +4 -0
  61. Program Files/Python39/Lib/site-packages/packman/tests/__pycache__/__init__.cpython-39.pyc +0 -0
  62. Program Files/Python39/Lib/site-packages/packman/tests/anm/__init__.py +0 -0
  63. Program Files/Python39/Lib/site-packages/packman/tests/anm/__pycache__/__init__.cpython-39.pyc +0 -0
  64. Program Files/Python39/Lib/site-packages/packman/tests/anm/__pycache__/test_anm.cpython-39.pyc +0 -0
  65. Program Files/Python39/Lib/site-packages/packman/tests/anm/test_anm.py +52 -0
  66. Program Files/Python39/Lib/site-packages/packman/tests/data/1prw.hng +3 -0
  67. Program Files/Python39/Lib/site-packages/packman/tests/data/1prw.pdb +1871 -0
  68. Program Files/Python39/Lib/site-packages/packman/tests/data/4hla.cif +5058 -0
  69. Program Files/Python39/Lib/site-packages/packman/tests/data/__init__.py +0 -0
  70. Program Files/Python39/Lib/site-packages/packman/tests/data/__pycache__/__init__.cpython-39.pyc +0 -0
  71. Program Files/Python39/Lib/site-packages/packman/tests/entropy/__init__.py +0 -0
  72. Program Files/Python39/Lib/site-packages/packman/tests/entropy/__pycache__/__init__.cpython-39.pyc +0 -0
  73. Program Files/Python39/Lib/site-packages/packman/tests/entropy/__pycache__/test_entropy.cpython-39.pyc +0 -0
  74. Program Files/Python39/Lib/site-packages/packman/tests/entropy/test_entropy.py +30 -0
  75. Program Files/Python39/Lib/site-packages/packman/tests/molecule/__init__.py +0 -0
  76. Program Files/Python39/Lib/site-packages/packman/tests/molecule/__pycache__/__init__.cpython-39.pyc +0 -0
  77. Program Files/Python39/Lib/site-packages/packman/tests/molecule/__pycache__/test_molecule.cpython-39.pyc +0 -0
  78. Program Files/Python39/Lib/site-packages/packman/tests/molecule/test_molecule.py +95 -0
  79. Program Files/Python39/Lib/site-packages/packman/utilities/__init__.py +1 -0
  80. Program Files/Python39/Lib/site-packages/packman/utilities/__pycache__/__init__.cpython-39.pyc +0 -0
  81. Program Files/Python39/Lib/site-packages/packman/utilities/__pycache__/utilities.cpython-39.pyc +0 -0
  82. Program Files/Python39/Lib/site-packages/packman/utilities/utilities.py +180 -0
  83. Program Files/Python39/Lib/site-packages/py_packman-1.4.0-py3.9.egg-info/PKG-INFO +86 -0
  84. Program Files/Python39/Lib/site-packages/py_packman-1.4.0-py3.9.egg-info/SOURCES.txt +51 -0
  85. Program Files/Python39/Lib/site-packages/py_packman-1.4.0-py3.9.egg-info/dependency_links.txt +1 -0
  86. Program Files/Python39/Lib/site-packages/py_packman-1.4.0-py3.9.egg-info/entry_points.txt +3 -0
  87. Program Files/Python39/Lib/site-packages/py_packman-1.4.0-py3.9.egg-info/requires.txt +5 -0
  88. Program Files/Python39/Lib/site-packages/py_packman-1.4.0-py3.9.egg-info/top_level.txt +1 -0
  89. Program Files/Python39/Scripts/packman-script.py +33 -0
  90. Program Files/Python39/Scripts/packman.exe +0 -0
@@ -0,0 +1,30 @@
1
+ from ... import molecule
2
+ from ...entropy import PackingEntropy
3
+ import unittest
4
+
5
+ import logging
6
+ from os import remove as rm
7
+
8
+ class TestMolecule(unittest.TestCase):
9
+
10
+ def setUp(self):
11
+ self.mol = molecule.load_structure('packman/tests/data/4hla.cif',ftype='cif')
12
+
13
+ def test_PackingEntropy(self):
14
+ obj = PackingEntropy(self.mol[0].get_atoms())
15
+
16
+ self.assertIsInstance(obj, PackingEntropy)
17
+ self.assertIsNotNone( obj.get_surafacepoints() )
18
+ self.assertIsNotNone( obj.get_total_chain_entropy('A') )
19
+ self.assertIsNotNone( obj.get_total_entropy() )
20
+
21
+ self.assertIsInstance( self.mol[0].get_entropy('PackingEntropy') , float )
22
+ self.assertIsInstance( self.mol[0]['A'].get_entropy('PackingEntropy') , float )
23
+ self.assertIsInstance( [i for i in self.mol[0]['A'].get_residues()][0].get_entropy('PackingEntropy') , float )
24
+ self.assertNotEqual( self.mol[0]['A'].get_entropy('PackingEntropy') , self.mol[0]['B'].get_entropy('PackingEntropy') )
25
+
26
+ def tearDown(self):
27
+ logging.info('Entropy Test Done.')
28
+
29
+ if(__name__=='__main__'):
30
+ unittest.main()
@@ -0,0 +1,95 @@
1
+ from ... import molecule
2
+ import unittest
3
+
4
+ import logging
5
+ from os import remove as rm
6
+
7
+ class TestMolecule(unittest.TestCase):
8
+
9
+ def setUp(self):
10
+ self.mol = molecule.load_structure('packman/tests/data/4hla.cif',ftype='cif')
11
+
12
+ def test_load_pdb(self):
13
+ self.assertTrue( molecule.load_structure('packman/tests/data/1prw.pdb',ftype='pdb') )
14
+
15
+ def test_load_cif(self):
16
+ self.assertTrue( molecule.load_structure('packman/tests/data/4hla.cif',ftype='cif') )
17
+
18
+ def test_Protein(self):
19
+ #Basic
20
+ self.assertIsInstance( self.mol, molecule.Protein )
21
+
22
+ #Write Methods
23
+ self.assertTrue( self.mol.write_structure( 'test.cif',ftype='cif') )
24
+ self.assertTrue( self.mol.write_structure( 'test.pdb',ftype='pdb') )
25
+ with self.assertRaises(Exception) as file_format_problem:
26
+ self.assertTrue( self.mol.write_structure( 'test',ftype='random') )
27
+ self.assertTrue( 'Please provide appropriate "ftype" argument. (cif/pdb).' in str(file_format_problem.exception) )
28
+ rm( 'test.cif' )
29
+ rm( 'test.pdb' )
30
+
31
+ self.assertNotEqual( len([i for i in self.mol]) , 0 )
32
+
33
+ def test_Model(self):
34
+ #Basic
35
+ self.assertIsInstance( self.mol[0], molecule.Model )
36
+ self.assertIsInstance( self.mol[0].get_parent(), molecule.Protein )
37
+ self.assertIsNotNone( self.mol[0].get_id() )
38
+
39
+ #Get Methods
40
+ self.assertNotEqual( len( [i for i in self.mol[0].get_chains()] ) , 0 )
41
+ self.assertNotEqual( len( [i for i in self.mol[0].get_residues()] ), 0 )
42
+ self.assertNotEqual( len( [i for i in self.mol[0].get_atoms()] ) , 0 )
43
+ self.assertNotEqual( len( [i for i in self.mol[0].get_calpha()] ) , 0 )
44
+ self.assertNotEqual( len( [i for i in self.mol[0].get_backbone()] ), 0 )
45
+
46
+ def test_Chain(self):
47
+ #Basic
48
+ self.assertIsInstance( self.mol[0]['A'], molecule.Chain )
49
+ self.assertIsInstance( self.mol[0]['A'].get_parent(), molecule.Model )
50
+ self.assertIsNotNone( self.mol[0].get_id() )
51
+
52
+ #Get Methods
53
+ self.assertNotEqual( len( [i for i in self.mol[0].get_residues()] ), 0 )
54
+ self.assertNotEqual( len( [i for i in self.mol[0].get_atoms()] ) , 0 )
55
+ self.assertNotEqual( len( [i for i in self.mol[0].get_calpha()] ) , 0 )
56
+ self.assertNotEqual( len( [i for i in self.mol[0].get_backbone()] ), 0 )
57
+
58
+ def test_Residue(self):
59
+ #Basic
60
+ Residues = [ i for i in self.mol[0]['A'].get_residues() ]
61
+ self.assertIsInstance( Residues[0], molecule.Residue )
62
+ self.assertIsInstance( Residues[0].get_parent(), molecule.Chain )
63
+ self.assertIsNotNone( Residues[0].get_id() )
64
+
65
+ #Get Methods
66
+ self.assertNotEqual( len( [i for i in Residues[0].get_atoms()] ) , 0 )
67
+ self.assertNotEqual( len( [i for i in Residues[0].get_backbone()] ), 0 )
68
+
69
+ self.assertIsNotNone( Residues[0].get_calpha() )
70
+ self.assertIsNotNone( Residues[0].get_tip() )
71
+ self.assertIsNotNone( Residues[0].get_centerofgravity() )
72
+
73
+ def test_Atom(self):
74
+ #Basic
75
+ Residues = [ i for i in self.mol[0]['A'].get_residues() ]
76
+ self.assertIsInstance( Residues[0], molecule.Residue )
77
+ self.assertIsInstance( Residues[0].get_parent(), molecule.Chain )
78
+ self.assertIsNotNone( Residues[0].get_id() )
79
+
80
+ #Get Methods
81
+ self.assertNotEqual( len( [i for i in Residues[0].get_atoms()] ) , 0 )
82
+ self.assertNotEqual( len( [i for i in Residues[0].get_backbone()] ), 0 )
83
+
84
+ self.assertIsNotNone( Residues[0].get_calpha() )
85
+ self.assertIsNotNone( Residues[0].get_tip() )
86
+ self.assertIsNotNone( Residues[0].get_centerofgravity() )
87
+
88
+ def test_Bond(self):
89
+ self.assertEqual( len([i.get_id() for i in self.mol[0].get_bonds()]) , 1542 )
90
+
91
+ def tearDown(self):
92
+ logging.info('Molecule Test Done.')
93
+
94
+ if(__name__=='__main__'):
95
+ unittest.main()
@@ -0,0 +1 @@
1
+ from .utilities import *
@@ -0,0 +1,180 @@
1
+ """This class contains all the utilities that are neccessary for carriying out structural superimposition, sequence matching etc.
2
+
3
+
4
+ """
5
+
6
+ import numpy
7
+
8
+ def superimporse(reference,target,use='calpha',ids=[],change_target=True):
9
+ """This function is used to superimpose the Target Chain(coordinates will be changed) on the Reference Chain(coordinates will change).
10
+
11
+ The superimposition currently is done on the basis of matching Residue ID. If both the proteins have unequal amount of residues,
12
+ still their matching residues will be used for the superimposition.
13
+
14
+ It is important to note that sometimes proteins (although same type and chain) have different numbering scheme.
15
+ In such case, the superimposition will not be carried out. Change the IDs of the taget/reference in such a way that it will match each other.
16
+
17
+ For more information about how to change ID of the residue, read : packman.molecule.Residue class
18
+
19
+ Args:
20
+ reference (packman.molecule.Chain): Chain whose coordinates will remain same and will be used as a reference.
21
+ target (packman.molecule.Chain): Chain whose coordinates will be changed according to the reference chain.
22
+ use (str): Which atoms to be used for superimposition (Options: calpha, backbone)
23
+ ids (list): Use only particular residues to align (Provide IDs) eg... ids=[1,2,5,77] will use only 1,2,5 and 77th residues to align two chains
24
+ change_target (bool): Change the coordinates of the target chain based on the reference
25
+
26
+ Returns:
27
+ R (numpy.matrix): Rotation matrix for Target Chain w.r.t Reference Chain.
28
+ t (numpy.array): Translation vector for Target Chain w.r.t Reference Chain.
29
+ """
30
+
31
+ if(use=='calpha'):
32
+ atoms1=[i for i in reference.get_calpha() ]
33
+ atoms2=[i for i in target.get_calpha() ]
34
+ if(use=='backbone'):
35
+ atoms1=[j for i in reference.get_backbone() for j in i]
36
+ atoms2=[j for i in target.get_backbone() for j in i ]
37
+
38
+ #Finding common residues to align
39
+ res1=[i.get_parent().get_id() for i in atoms1]
40
+ res2=[i.get_parent().get_id() for i in atoms2]
41
+
42
+ if(ids==[]):
43
+ common_residues=list(set(res1).intersection(res2))
44
+ else:
45
+ common_residues=list( set(res1).intersection(res2).intersection(ids) )
46
+
47
+ atoms1=[i for i in atoms1 if i.get_parent().get_id() in common_residues]
48
+ atoms2=[i for i in atoms2 if i.get_parent().get_id() in common_residues]
49
+
50
+ atoms1_location=[i.get_location() for i in atoms1]
51
+ atoms2_location=[i.get_location() for i in atoms2]
52
+
53
+ #Subtract Mean
54
+ Centroid1=numpy.mean(atoms1_location,axis=0)
55
+ Centroid2=numpy.mean(atoms2_location,axis=0)
56
+ Am= numpy.subtract(atoms1_location,Centroid1)
57
+ Bm= numpy.subtract(atoms2_location,Centroid2)
58
+
59
+ #Dot is matrix multiplication for array
60
+ H= numpy.mat(Bm.T) * numpy.mat(Am)
61
+
62
+ #Find Rotation
63
+ U, S, Vt = numpy.linalg.svd(H)
64
+ R = Vt.T * U.T
65
+
66
+ #Special Reflection Case
67
+ if numpy.linalg.det(R) < 0:
68
+ Vt[2,:] *= -1
69
+ R = Vt.T * U.T
70
+
71
+ t = numpy.dot(-R , Centroid2) + Centroid1
72
+
73
+ #Change the location of the target
74
+ if(change_target):
75
+ for i in target.get_atoms():
76
+ new_location=numpy.dot(R , i.get_location()) + t
77
+ i.set_location( numpy.array(new_location.tolist()[0]) )
78
+ else:
79
+ None
80
+
81
+ return R, t
82
+
83
+ def RMSD(group1,group2,use='calpha',ids=[]):
84
+ """
85
+ """
86
+ if(use=='calpha'):
87
+ atoms1=[i for i in group1.get_calpha() ]
88
+ atoms2=[i for i in group2.get_calpha() ]
89
+ if(use=='backbone'):
90
+ atoms1=[j for i in group1.get_backbone() for j in i]
91
+ atoms2=[j for i in group2.get_backbone() for j in i ]
92
+
93
+ #Finding common residues to align
94
+ res1=[i.get_parent().get_id() for i in atoms1]
95
+ res2=[i.get_parent().get_id() for i in atoms2]
96
+
97
+ if(ids==[]):
98
+ common_residues=list(set(res1).intersection(res2))
99
+ else:
100
+ common_residues=list( set(res1).intersection(res2).intersection(ids) )
101
+
102
+ atoms1=[i for i in atoms1 if i.get_parent().get_id() in common_residues]
103
+ atoms2=[i for i in atoms2 if i.get_parent().get_id() in common_residues]
104
+
105
+ atoms1_location=[i.get_location() for i in atoms1]
106
+ atoms2_location=[i.get_location() for i in atoms2]
107
+
108
+ R,t = superimporse(group1,group2,use,ids,change_target=False)
109
+
110
+ for i in range(0,len(atoms2_location)):
111
+ atoms2_location[i] = numpy.dot(R , atoms2_location[i]) + t
112
+ atoms2_location[i] = numpy.array(atoms2_location[i].tolist()[0])
113
+
114
+ return numpy.mean( [numpy.abs( numpy.linalg.norm(atoms1_location[i]-atoms2_location[i]) ) for i in range(0,len(atoms1_location))] )
115
+
116
+ def load_hinge(filename):
117
+ """Load the hinge information neccessary for the hd-ANM and other methods.
118
+
119
+ About .hng File:
120
+ - hdANM requires the information about hinges and domains in the .hng format.
121
+ - Each column in the .hng file is tab delimited.
122
+ - Each row in the .hng file follows collowing pattern:
123
+
124
+ Filename_ChainID Domain/HingeId ResidueStartPosition:ResidueEndPosition
125
+
126
+ Example of .hng file for PDBID 1EXR::
127
+
128
+ 1EXR_A D1 1:70
129
+ 1EXR_A H1 70:90
130
+ 1EXR_A D2 90:148
131
+
132
+ Above format means that there are two domains (D1 and D2) separated by a hinge (H1). D1 stretches from residue 1 to 70; D2 stretches from 90 to 148 and hinge H1 is in the middle.
133
+
134
+
135
+ Args:
136
+ filename (string) : filepath and name of the .hng file
137
+
138
+ Returns:
139
+ HNGinfo (dictionary) : residue based hinge and domain information.
140
+ """
141
+ HNGinfo={}
142
+ for i in open(filename):
143
+ line=i.strip().split()
144
+ HNGinfo[ line[0]+'_'+line[1] ]=[float(j) for j in line[2].split(':')]
145
+ return HNGinfo
146
+
147
+ '''
148
+ ##################################################################################################
149
+ # Non Algorithm Functions #
150
+ ##################################################################################################
151
+ '''
152
+
153
+ def WriteOBJ(atoms,faces, fh):
154
+ """Write the .obj file to visualize the obtain alpha shape tesselations.
155
+
156
+ Args:
157
+ atoms (packman.molecule.Atom): Atoms (Just for the node records)
158
+ faces ([float]) : SelectedTesselations (See the packman.apps.predict_hinge)
159
+ fh (file) : Output file with .obj extension
160
+
161
+ """
162
+ NewIDs={i.get_id():numi+1 for numi,i in enumerate(atoms)}
163
+ fh.write('mtllib master.mtl\ng\n'.encode())
164
+ fh.write('usemtl atoms\n'.encode())
165
+ for i in atoms:
166
+ x,y,z=i.get_location()
167
+ fh.write("v %f %f %f\n".encode()%(x,y,z))
168
+
169
+ line='usemtl bonds\nl'
170
+ for i in atoms:
171
+ line=line+" "+str(NewIDs[i.get_id()])
172
+ line=line+'\n'
173
+ fh.write(line.encode())
174
+
175
+ fh.write('usemtl faces\n'.encode())
176
+ for i in faces:
177
+ faces=[NewIDs[j.get_id()] for j in i]
178
+ fh.write("f %i %i %i %i\n".encode()%(faces[0],faces[1],faces[2],faces[3]))
179
+ #fh.write("l %i %i %i %i\n"%(faces[0],faces[1],faces[2],faces[3]))
180
+ return True
@@ -0,0 +1,86 @@
1
+ Metadata-Version: 2.1
2
+ Name: py-packman
3
+ Version: 1.4.0
4
+ Summary: A software package for molecular PACKing and Motion ANalysis (PACKMAN)
5
+ Home-page: https://github.com/Pranavkhade/PACKMAN
6
+ Author: Pranav Khade
7
+ Author-email: pranavk@iastate.edu
8
+ License: MIT
9
+ Description: [![PyPI version](https://badge.fury.io/py/py-packman.svg)](https://badge.fury.io/py/py-packman) [![Build Status](https://travis-ci.com/Pranavkhade/PACKMAN.svg?branch=master)](https://travis-ci.com/Pranavkhade/PACKMAN) [![Documentation Status](https://readthedocs.org/projects/py-packman/badge/?version=latest)](https://py-packman.readthedocs.io/en/latest/?badge=latest) [![Downloads](https://pepy.tech/badge/py-packman)](https://pepy.tech/project/py-packman)
10
+
11
+
12
+ PACKMAN: PACKing and Motion ANalysis
13
+ ------------------------------------
14
+ <img src="https://github.com/Pranavkhade/PACKMAN/blob/master/docs/_static/gallary/logo.gif" width="250">
15
+
16
+ This package focuses on studying molecular structures and their dynamics using a simple yet informative property known as Protein Packing. Over the last few years, we have worked on several techniques to capture and quantify the protein packing, resulting in a few publications. This package has all the code to repeat and further develop these techniques.
17
+
18
+
19
+ DOCUMENTATION
20
+ -------------
21
+ * [IMPORTANT : Documentation, Tutorials & More](https://py-packman.readthedocs.io)
22
+
23
+ INSTALLATION
24
+ ------------
25
+
26
+ 1. Installing with pip (Recommended)
27
+ ```
28
+ pip install py-packman
29
+ ```
30
+
31
+ 2. Installing from source
32
+ ```
33
+ git clone https://github.com/Pranavkhade/PACKMAN
34
+ cd PACKMAN
35
+ python setup.py install
36
+ ```
37
+
38
+ HOW TO USE
39
+ ----------
40
+
41
+ PACKMAN, along with its components, can be accessed via Graphical User Interface (GUI), Command-line Interface (CLI), and Application programming interface (API).
42
+
43
+ For the GUI, please run the following command.
44
+ ```
45
+ python -m packman gui
46
+ ```
47
+ OR
48
+ ```
49
+ python3 -m packman gui
50
+ ```
51
+
52
+ For the CLI and API, please read the tutorials & documentation.
53
+
54
+ WEB SERVERS
55
+ -----------
56
+ * [Hinge Prediction Web Server](https://packman.bb.iastate.edu/)
57
+ * [hd-ANM Web Server](https://hdanm.bb.iastate.edu/)
58
+ * [Packing Entropy Web Server](https://packing-entropy.bb.iastate.edu/)
59
+
60
+ RELATED RESEARCH ARTICLES
61
+ -------------------------
62
+ * [PACKMAN-molecule](https://doi.org/10.1093/bioadv/vbac007)
63
+ * [Hinge Prediction](https://doi.org/10.1016/j.jmb.2019.11.018)
64
+ * [Compliance](https://doi.org/10.1002/prot.25968)
65
+ * [hd-ANM](https://doi.org/10.1016/j.bpj.2021.10.017)
66
+ * [Packing Entropy](coming_soon)
67
+
68
+ ACKNOWLEDGEMENTS
69
+ ----------------
70
+
71
+ The development of the PACKMAN package is supported by [NSF](https://www.nsf.gov/) grant DBI 1661391. The authors also thank [ResearchIT@Iowa State University](https://researchit.las.iastate.edu/about-research-it-iowa-state-university) for helping with many aspects of computing.
72
+ Keywords: protein,dynamics,protein packing,protein domain,protein hinge
73
+ Platform: UNKNOWN
74
+ Classifier: Intended Audience :: Education
75
+ Classifier: Intended Audience :: Science/Research
76
+ Classifier: License :: OSI Approved :: MIT License
77
+ Classifier: Operating System :: MacOS
78
+ Classifier: Operating System :: Microsoft :: Windows
79
+ Classifier: Operating System :: POSIX
80
+ Classifier: Programming Language :: Python
81
+ Classifier: Programming Language :: Python :: 2
82
+ Classifier: Programming Language :: Python :: 3
83
+ Classifier: Topic :: Scientific/Engineering :: Bio-Informatics
84
+ Classifier: Topic :: Scientific/Engineering :: Chemistry
85
+ Classifier: Topic :: Scientific/Engineering :: Mathematics
86
+ Description-Content-Type: text/markdown
@@ -0,0 +1,51 @@
1
+ README.md
2
+ setup.py
3
+ packman/__init__.py
4
+ packman/__main__.py
5
+ packman/anm/__init__.py
6
+ packman/anm/anm.py
7
+ packman/anm/hd_anm.py
8
+ packman/apps/__init__.py
9
+ packman/apps/calculate_entropy.py
10
+ packman/apps/dci.py
11
+ packman/apps/hdanm.py
12
+ packman/apps/predict_hinge.py
13
+ packman/bin/GUI.py
14
+ packman/bin/PACKMAN.py
15
+ packman/bin/__init__.py
16
+ packman/bin/logo.ico
17
+ packman/constants/Constants.py
18
+ packman/constants/__init__.py
19
+ packman/entropy/__init__.py
20
+ packman/entropy/entropy.py
21
+ packman/geometry/__init__.py
22
+ packman/geometry/geometry.py
23
+ packman/molecule/__init__.py
24
+ packman/molecule/annotations.py
25
+ packman/molecule/atom.py
26
+ packman/molecule/bond.py
27
+ packman/molecule/chain.py
28
+ packman/molecule/hetmol.py
29
+ packman/molecule/model.py
30
+ packman/molecule/molecule.py
31
+ packman/molecule/protein.py
32
+ packman/molecule/residue.py
33
+ packman/tests/__init__.py
34
+ packman/tests/anm/__init__.py
35
+ packman/tests/anm/test_anm.py
36
+ packman/tests/data/1prw.hng
37
+ packman/tests/data/1prw.pdb
38
+ packman/tests/data/4hla.cif
39
+ packman/tests/data/__init__.py
40
+ packman/tests/entropy/__init__.py
41
+ packman/tests/entropy/test_entropy.py
42
+ packman/tests/molecule/__init__.py
43
+ packman/tests/molecule/test_molecule.py
44
+ packman/utilities/__init__.py
45
+ packman/utilities/utilities.py
46
+ py_packman.egg-info/PKG-INFO
47
+ py_packman.egg-info/SOURCES.txt
48
+ py_packman.egg-info/dependency_links.txt
49
+ py_packman.egg-info/entry_points.txt
50
+ py_packman.egg-info/requires.txt
51
+ py_packman.egg-info/top_level.txt
@@ -0,0 +1,3 @@
1
+ [console_scripts]
2
+ packman = packman.bin.PACKMAN:main
3
+
@@ -0,0 +1,5 @@
1
+ numpy
2
+ scipy
3
+ networkx
4
+ mlxtend
5
+ scikit-learn
@@ -0,0 +1,33 @@
1
+ #!"C:\Program Files\Python39\python.exe"
2
+ # EASY-INSTALL-ENTRY-SCRIPT: 'py-packman==1.4.0','console_scripts','packman'
3
+ import re
4
+ import sys
5
+
6
+ # for compatibility with easy_install; see #2198
7
+ __requires__ = 'py-packman==1.4.0'
8
+
9
+ try:
10
+ from importlib.metadata import distribution
11
+ except ImportError:
12
+ try:
13
+ from importlib_metadata import distribution
14
+ except ImportError:
15
+ from pkg_resources import load_entry_point
16
+
17
+
18
+ def importlib_load_entry_point(spec, group, name):
19
+ dist_name, _, _ = spec.partition('==')
20
+ matches = (
21
+ entry_point
22
+ for entry_point in distribution(dist_name).entry_points
23
+ if entry_point.group == group and entry_point.name == name
24
+ )
25
+ return next(matches).load()
26
+
27
+
28
+ globals().setdefault('load_entry_point', importlib_load_entry_point)
29
+
30
+
31
+ if __name__ == '__main__':
32
+ sys.argv[0] = re.sub(r'(-script\.pyw?|\.exe)?$', '', sys.argv[0])
33
+ sys.exit(load_entry_point('py-packman==1.4.0', 'console_scripts', 'packman')())