Back to Recipes Homepage
recipe picture
Recipe: Tvdl enhanced DRW 1.2.4
Your rating: None Average: 4.6 (187 votes)


Name: Tvdl enhanced DRW 1.2.4
ID: 43754
Created on: Sat, 08/04/2012 - 01:24
Updated on: Thu, 10/25/2012 - 23:12

Ravs DRW with a lot more features. Selections, mutate options and a lot faster. Read the comment for more info. This version the starting clash importance is a factor for ALL clashimportance dependend parts. Fixed a score evaluation bug on slot 5 and qStab will allways return the best score during it. Included a warning if running on a low CI. Fixed missing a high score during rebuild phase.

Best For


Joined: 09/21/2011
Groups: Void Crushers
Some of the enhancements

This version of Rav3n_pl DRW has several new features and will run a lot faster.

First of all it is made totally V2 and uses option dialogs.
It has an optimised fuze and qStab, so will run a lot faster as the original.
The main optimalisation is that futile shakes are skipped.
Another main one is that unprommissing fuzes can be skipped.

Feature 1.
Can be used in design puzzles, has mutate options for that.

Feature 2.
It will continue with the next segments of the same length if there is a win unless the gain reaches a threshold (default number of segments/4). If the threshold is reached it will continue with the next length or main cycle.

Feature 3.
It will not try to rebuild the exact same segments for a second time unless the gain reaches a threshold (default number of segments)

Feature 4.
It will not try a fuze if the loss is too great depending on the size of the rebuild

Feature 5.
It will not try to rebuild frozen or locked parts

Feature 6.
You can specify where to work on, based on secondary structure and/or selected or non selected parts.

Feature 7.
If you want it can keep disulfide bridges intact (thanks Brow42)

Feature 8.
If the starting score is negative, default is that no wiggles will be done to avoid exploding the protein.

Feature 9.
If stopped, it will reset CI, best score and secondary structures.

Some of the smaller features:
You can skip cycles, handy after a crash. It breaks off rebuild tries if no chance of success. It works on puzzles even if the score is < -1000000 (but will be slower).
Fuze and qStab can be suppressed (default if score is negative from the start)
You can specify to disable bands when rebuilding and enable them afterwards.
And several minor bugfixes.

A final note:
I hope that more groups will follow and publish a good script from their pool.

Joined: 09/21/2011
Groups: Void Crushers

The selection mechanism was not working. Load the recipe again. When running it should give version number 1.0.1.

Joined: 03/20/2012
Groups: None

Hi Timo,

Really nice work!

Very effective, and tons of possible permutations
through the selection interface! :)

Joined: 09/21/2011
Groups: Void Crushers
Version 1.02 out

Now possible to specify selections in a text box. Tip: watch the output box.

Joined: 09/21/2011
Groups: Void Crushers
Version 1.0.3 Fixed broken bridge problem

There was a major bug (not finding the cys) fixed now. And a minor, during the fuze bridges could be broken, now if that happens all gains from the fuze are discarded. Hopefully I did that last part right.

Joined: 09/21/2011
Groups: Void Crushers
Version 1.0.4

Fixed a bug. If all rebuilds failed because of a broken bridge the current situation was not restored.

Joined: 09/21/2011
Groups: Void Crushers
Version 1.1.0

Included the bridgekeeping fuze. Now if bridgesaving is on most good gains during the fuze are kept. Also made some output changes and fixed an annoying bug. Rearranged the code keeping the bridges save.

Joined: 09/21/2011
Groups: Void Crushers
Explanation of the sliders

Some people have asked me for an explanation of the different sliders.

I can explain it better by describing the algorithm of the program and where each slider plays a part.

How does the script work with standard options.

- Select the 4 (Slider 7) worst parts by segments sum
- Do the rebuilding (search 15 rebuilds, Slider 1)
- The best scoring rebuilds after a shake are stored. Best on an aspect (sidechain, backbone, etcetera)
- Those rebuild are all stabilized
- The best of them is fuzed, only if the loss was not too much. (Slider 2)
- If the total gain during the rebuilds of that length is not over a threshold (Slider 3) continue with the next part .
- If that gain is over the threshold or if we have done all selected parts, begin the next subcycle with an increased length of the parts.
- If the length is over the maximum length increase the number of parts looked at by 3, and start the next main cycle with the minimum length.

- If getting back to a certain length, it will not try parts that have been done before, so if 1-3 was done, it will not try again 1-3. However, once the total gain reaches a threshold (Slider 4) all parts will be considered again in the next passes.
- You can limit the number of main cycles (Slider 5)
- And you can skip cycles, so it will probably skip the parts that have been done in an earlier run of DRW. (Slider 6)

Slider 1: In More Options. Default is 15. Variable name in the program: nrrebuild
Slider 2: Main Options, called Skip fuze. Default is Number of segments/4 but at least 30. In the program this number is multiplied by the number of segments being rebuild and divided by 3. Variable name maxlossbeforefuze.
Slider 3: Main Options, MinGain. Default is Number of segments/4. Variable name minGain.
Slider 4: More Options, Cleargain. Default is Number of segments. Variable name clearnottorevisitgain.
Slider 5: More Options, Cycles. Default 15. Variable name maxnrofRuns.
Slider 6: More Options, Skip Cycles. Default 0. Variable name nrskip
Slider 7: More Options, # to do in first cycle. Default 4. Variable name reBuild

Warning: if you change slider defaults by editing the script, CHECK that they still are within the bounds of the sliders or change that too.

Joined: 09/21/2011
Groups: Void Crushers
1.1.1 Bugfix Mutating a sphere after each rebuild

Thanx to Mottiger for reporting this one

Joined: 09/21/2011
Groups: Void Crushers
Version 1.1.2

Again thanks to mottiger for pointing this out.
CI while mutating is now settable. In some instances it was 0 (not helpful)
Also I made the size of the sphere where mutating takes place a settable option.

Joined: 09/21/2011
Groups: Void Crushers
Version 1.1.3

Autodetects exploration puzzles (thanks Datacute)

Joined: 09/21/2011
Groups: Void Crushers
1.1.4 Repaired score function for exploration

Negative scores where not handled well. Again thanks DataCute for reporting and helping with the fix.

Joined: 09/21/2011
Groups: Void Crushers
Version 1.2.0

The starting Clash Importance is now a factor for ALL clash importance dependend parts. So if that is 0.5 then every CI will be halved. (And after the script the CI will be back at 0.5)

lynnai's picture
User offline. Last seen 1 year 41 weeks ago. Offline
Joined: 05/16/2008
you rock my socks. :) we are

you rock my socks. :) we are talking ignious footware here.

I am amused that a script inside a game has gotten sophisticated enough to require bug reports and patches though.

Joined: 09/21/2011
Groups: Void Crushers
Version 1.2.1

The evaluation of the scores of slot 5 allways returned the first rebuild. Fixed.
qStab sometimes lost points, especially when running on low CI. Also fixed.

Joined: 09/21/2011
Groups: Void Crushers
Added a last minute opportunity to set the CI back to 1

This has bitten me a few times, so now when CI < 0.99 there will be a pop up asking if you want to change it.

bobcat's picture
User offline. Last seen 3 years 1 week ago. Offline
Joined: 12/05/2011
Groups: None
Last minute feature addition has a bug (!)

In both lines 92 and 93 the phrase 'behavior.GetClashImportance' is missing the '()' resulting in an 'attempt to compare function with number' error.

Joined: 09/21/2011
Groups: Void Crushers
Fixed it

Should have known better then releasing without testing

Joined: 11/17/2009
Groups: Russian team
Script fail.

Timo, your script is failing on 644.

I fixed it by checking the secondary structure ~= 'M'

Here is the fixed code:

function FindAminotype(at)
-- This one returns a list not a set
local result={}
for i=1,structure.GetCount() do
if structure.GetSecondaryStructure(i) ~= 'M' and structure.GetAminoAcid(i) == at then result[#result+1]=i end
return result

Joined: 09/21/2011
Groups: Void Crushers
1.2.4 Fixed missing a high score during rebuild phase

In rare situations this could happen. Tx Madde for reporting this.
To ComputerMage: very strange. In the script ligands are excluded by:

Want to try?
Add to Cookbook!
To download recipes to your cookbook, you need to have the game client running.



Developed by: UW Center for Game Science, UW Institute for Protein Design, Northeastern University, Vanderbilt University Meiler Lab, UC Davis
Supported by: DARPA, NSF, NIH, HHMI, Amazon, Microsoft, Adobe, RosettaCommons