There are several differences between PyRosetta1.0 and PyRosetta2.0 and we are in the process of updating the workshops. Until then, please be aware of the following changes:
The Pose object no longer accepts a (string) filename argument. The pose_from_pdb method now returns a Pose object. The lines on page 9 and page 12 still work in PyRosetta2.0. In summary:
p = Pose()
pose_from_pdb( p , 'favorite.pdb' )
p = pose_from_pdb( 'favorite.pdb' )
p = Pose( 'favorite.pdb' )
When importing modules in ipython, leave off the .py of the filename. Ipython will get confused and import the desired module, and then fail to import a "py" module. This appears on page 11.
Fails (will work in a python but not ipython)
The TwoBodyEMapVector object no longer exists, use the EMapVector object instead. This appears on page 15 (Workshop #3).
emap = rosetta.core.scoring.EMapVector()
emap = rosetta.core.scoring.TwoBodyEMapVector()
To test the ClassicFragmentMover using a ConstantLengthFragSet, please use the Robetta server (http://robetta.bakerlab.org/fragmentsubmit.jsp) as specified on page 19. Otherwise, the sample fragment files test3_fragments (3-mer fragments) and test9_fragments (9-mer fragments) can be found under ~/test/data. The file test_in.pdb referenced on page 21 (Workshop #5) is also in ~/test/data (or get it here).
The standard_packer_task methods have changed names. The fix_everything method is now named temporarily_fix_everything. The set_pack_residue method is now named temporarily_set_pack_residue. This appears on page 28.
task_pack = standard_packer_task(pose)
The TaskFactory methods have changed names. The standard_packer_task method is now named create_packer_task. This appears on page 30.
task_design = TaskFactory.create_packer_task(pose)
task_design = TaskFactory.standard_packer_task(pose)
The Read_resfile methods was moved, it is now located in rosetta.core.pack.task namespace. This appears on page 30.
rosetta.core.pack.task.parse_resfile(pose, task, filename)
The JobDistributor object has been renamed PyJobDistributor. All of its methods are the same. This appears on page 36.
jd = PyJobDistributor("output",10,scorefxn_low)
task_jd = JobDistributor("output",10,scorefxn_low)
The setup_foldtree method of the DockingProtocol has been changed. Another method provides similar functionality and should be a suitable substitute. The alternate method requires an additional Vector1 argument specifying which jumps (identified by jump number) can be moved (e.g. test_dock.pdb loads in with one jump, jump number 1, which can be moved to establish a jump between chains E and I). This appears on page 34.
rosetta.protocols.docking.setup_foldtree( pose , "E_I" , Vector1(  ) )
setup_foldtree( pose , "E_I" , Vector1(  ) )
DockingProtocol().setup_foldtree( pose , "E_I" )