Icon representing a recipe

Recipe: Fast Relax 1.0

created by LociOiling

Profile


Name
Fast Relax 1.0
ID
107977
Shared with
Public
Parent
None
Children
Created on
September 18, 2022 at 01:16 AM UTC
Updated on
September 18, 2022 at 01:16 AM UTC
Description

V2 port of the classic shared by Frankie_says in 2011

https://old.fold.it/portal/recipe/34893

Best for


Code


--[[ FastRelax Based on a recipe used in Rosetta, as described in a Foldit publication in PNAS: Firas Khatib, Seth Cooper, Michael D. Tyka, Kefan Xu, Ilya Makedon, Zoran Popovic, David Baker and Foldit Players. Algorithm discovery by protein folding game players. Proceedings of the National Academy of Sciences of the United States of America (2011) http://www.pnas.org/content/108/47/18949.abstract Converted from v1 Lua by Rav3n_pl's v1 to v2 converter, FolditLuaConverter. Fast Relax 1.0 - LociOiling -- 2022/09/17 + converted using FolditLuaConverter + fixed #NEED EDIT! lines (only two in this case) + minimal testing ]]-- -- options at end p=print CI=behavior.SetClashImportance S=structure.ShakeSidechainsSelected WA=structure.WiggleAll function Score() if energy==true then return current.GetEnergyScore() -- #NEED EDIT! remove(true) if you have it#() else return current.GetScore() -- #NEED EDIT! remove(true) if you have it#() end end function round(x)--cut all afer 3-rd place return x-x%0.001 end function SaveBest() local g=Score()-bestScore if g>0 then bestScore=Score() save.Quicksave(3) else save.Quickload(3) end end function FastRelax() bestScore=Score() save.Quicksave(3) p("Starting FastRelax, Score: ",round(bestScore)) selection.SelectAll() recentbest.Save() repeat local ss=Score() CI(0.02) S(shakes) WA(wiggles) CI(0.25) S(shakes) WA(wiggles) CI(0.55) S(shakes) WA(wiggles) CI(1) S(shakes) WA(wiggles) recentbest.Restore() SaveBest() local g=Score()-ss p("Loop gain: ",round(g)) until g<minPpi p("End score: ",round(Score())) end -- options below VVVV energy=false --set true to seek energy in exploration puzzles minPpi=2 --minimum points gain per loop shakes=2 --number of shakes wiggles=5 --number of wiggles -- main call FastRelax() --end of script

Comments


Artoria2e5 Lv 1

On the rosetta side they've change the script up a bit, at https://www.rosettacommons.org/docs/latest/application_documentation/structure_prediction/relax#description-of-algorithm. Changes are:

  • CI order.
  • Now they have a new coord_cst_weight, which seems to be some sort of band-in-space to discourage super huge movements.

The documentation also mentions a whole family of relax scripts. The different CI schedule can be found in PMC8299543 supplementary info table SI1, https://europepmc.org/articles/PMC8299543/bin/NIHMS1650092-supplement-supinfo.pdf. PMC8299543 / PMID 33249652 can be treated as the primary citation for this new family of relax functions with different shake and wiggle CI.

I think I can find enough time to get a new version out, minus the BiS part.

Another discrepancy is minimization tolerance. I have no idea how to even approximate that one. Perhaps with "Rosetta energy" calculation and cycle-by-cycle score change tracking?