Skip to content
Snippets Groups Projects
Commit 33d64b5a authored by Studer Gabriel's avatar Studer Gabriel
Browse files

another sorting port for Python3

parent 802969a3
Branches
Tags
No related merge requests found
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
# tabula rasa first # tabula rasa first
scene.RemoveAll() scene.RemoveAll()
import functools
import ost.img.alg as img_alg import ost.img.alg as img_alg
from ost.mol.alg import EntityToDensityRosetta, HIGH_RESOLUTION from ost.mol.alg import EntityToDensityRosetta, HIGH_RESOLUTION
sdh=io.LoadPDB('data/sdh-complete.pdb') sdh=io.LoadPDB('data/sdh-complete.pdb')
...@@ -77,7 +77,7 @@ def Visualize(candidates): ...@@ -77,7 +77,7 @@ def Visualize(candidates):
return 0 return 0
else: else:
return 1 return 1
candidates=sorted(candidates, cmp_correl) candidates=sorted(candidates, key=functools.cmp_to_key(cmp_correl))
# create render objects and add to scene # create render objects and add to scene
for index, candidate in enumerate(candidates): for index, candidate in enumerate(candidates):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment