"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "data/chempy/sidechains/generate1.py" between
pymol-v1.8.6.0.tar.bz2 and pymol-v2.1.0.tar.bz2

About: PyMOL is a Python-enhanced molecular graphics tool. It excels at 3D visualization of proteins, small molecules, density, surfaces, and trajectories. It also includes molecular editing, ray tracing, and movies. Open Source version.

generate1.py  (pymol-v1.8.6.0.tar.bz2):generate1.py  (pymol-v2.1.0.tar.bz2)
skipping to change at line 87 skipping to change at line 87
return result return result
def measure_all_torsions(sele,prot_dict): def measure_all_torsions(sele,prot_dict):
id_list = cmd.identify("((%s) and name ca)"%sele) id_list = cmd.identify("((%s) and name ca)"%sele)
for a in id_list: for a in id_list:
res_sele = "(alt '' and (byres id %d) and (%s))"%(a,sele) res_sele = "(alt '' and (byres id %d) and (%s))"%(a,sele)
lst = find_torsions(res_sele) lst = find_torsions(res_sele)
if len(lst): if len(lst):
cmd.iterate("(%s and n;ca)"%res_sele,"stored.resn=resn") cmd.iterate("(%s and n;ca)"%res_sele,"stored.resn=resn")
resn = pymol.stored.resn resn = pymol.stored.resn
print resn print(resn)
name_list = [] name_list = []
for a in lst: for a in lst:
pymol.stored.names = [] pymol.stored.names = []
for b in a: for b in a:
cmd.iterate("(%s and id %d)"%(res_sele,b),"stored.names.append(na me)") cmd.iterate("(%s and id %d)"%(res_sele,b),"stored.names.append(na me)")
name_list.append(tuple(pymol.stored.names)) name_list.append(tuple(pymol.stored.names))
res_dict = {} res_dict = {}
for a in name_list: for a in name_list:
dihe = cmd.get_dihedral("(%s and name %s)"%(res_sele,a[0]), dihe = cmd.get_dihedral("(%s and name %s)"%(res_sele,a[0]),
"(%s and name %s)"%(res_sele,a[1]), "(%s and name %s)"%(res_sele,a[1]),
"(%s and name %s)"%(res_sele,a[2]), "(%s and name %s)"%(res_sele,a[2]),
"(%s and name %s)"%(res_sele,a[3])) "(%s and name %s)"%(res_sele,a[3]))
res_dict[a]=dihe res_dict[a]=dihe
if not prot_dict.has_key(resn): if resn not in prot_dict:
prot_dict[resn]=[] prot_dict[resn]=[]
prot_dict[resn].append(res_dict) prot_dict[resn].append(res_dict)
sc_dict = {} sc_dict = {}
cmd.feedback('disable','selector','result') cmd.feedback('disable','selector','result')
cmd.feedback('disable','executive','action') cmd.feedback('disable','executive','action')
for fyle in glob("source/*"): for fyle in glob("source/*"):
cmd.load(fyle) cmd.load(fyle)
 End of changes. 2 change blocks. 
2 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)