Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
CartesianHybridize.hh
Go to the documentation of this file.
1 // -*- mode:c++;tab-width:2;indent-tabs-mode:t;show-trailing-whitespace:t;rm-trailing-spaces:t -*-
2 // vi: set ts=2 noet:
3 //
4 // (c) Copyright Rosetta Commons Member Institutions.
5 // (c) This file is part of the Rosetta software suite and is made available under license.
6 // (c) The Rosetta software is developed by the contributing members of the Rosetta Commons.
7 // (c) For more information, see http://www.rosettacommons.org. Questions about this can be
8 // (c) addressed to University of Washington UW TechTransfer, email: license@u.washington.edu.
9 
10 /// @file
11 /// @brief
12 /// @author Yifan Song
13 /// @author Frank DiMaio
14 
15 
16 #ifndef INCLUDED_protocols_hybridization_CartesianHybridize_hh
17 #define INCLUDED_protocols_hybridization_CartesianHybridize_hh
18 
21 
22 #include <core/id/AtomID.hh>
23 #include <core/id/AtomID_Map.hh>
26 #include <core/fragment/FragSet.hh>
27 
29 
30 #include <protocols/loops/Loop.hh>
31 #include <protocols/loops/Loops.hh>
32 
33 #include <protocols/moves/Mover.hh>
34 
35 #include <ObjexxFCL/format.hh>
36 #include <numeric/random/random.hh>
37 #include <numeric/xyz.functions.hh>
38 #include <numeric/model_quality/rms.hh>
39 #include <numeric/model_quality/maxsub.hh>
40 
41 #include <basic/options/option.hh>
42 #include <basic/options/keys/OptionKeys.hh>
43 #include <basic/options/keys/in.OptionKeys.gen.hh>
44 #include <basic/Tracer.hh>
45 
46 #include <boost/unordered/unordered_map.hpp>
47 
48 namespace protocols {
49 //namespace comparative_modeling {
50 namespace hybridization {
51 
52 using namespace core;
53 using namespace protocols::moves;
54 using namespace protocols::loops;
55 
57 public:
59 
61  utility::vector1 < core::pose::PoseOP > const & templates_in,
62  utility::vector1 < core::Real > const & template_wts_in,
63  utility::vector1 < protocols::loops::Loops > const & template_chunks_in,
64  utility::vector1 < protocols::loops::Loops > const & template_contigs_in,
65  core::fragment::FragSetOP fragments9_in );
66 
67  // initialize options to defaults
68  void init();
69 
70  // run the protocol
71  void apply(core::pose::Pose & pose);
72 
73  // set the centroid scorefunction
74  void set_scorefunction(core::scoring::ScoreFunctionOP scorefxn_in);
75 
76  // set options
77  void set_increase_cycles(core::Real increase_cycles_in) { increase_cycles_=increase_cycles_in; }
78  void set_no_global_frame(bool no_global_frame_in) { no_global_frame_=no_global_frame_in; }
79  void set_linmin_only(bool linmin_only_in) { linmin_only_=linmin_only_in; }
80  void set_cartfrag_overlap(core::Size cartfrag_overlap_in) { cartfrag_overlap_=cartfrag_overlap_in; }
81 
82  //
83  std::string get_name() const { return "CartesianHybridize"; }
84 
85 protected:
86  // apply a homologue fragment
87  void apply_frag( core::pose::Pose &pose, core::pose::Pose &templ, protocols::loops::Loop &frag, bool superpose=true);
88 
89  // apply a sequence fragment
90  void apply_frame( core::pose::Pose & pose, core::fragment::Frame &frame );
91 
92 private:
93  // parameters
95  core::Size ncycles_, cartfrag_overlap_;
96  bool no_global_frame_, linmin_only_;
97 
98  // fragments
103  boost::unordered_map<core::Size, core::fragment::Frame> library_;
104 
105  // scorefunctions
106  core::scoring::ScoreFunctionOP lowres_scorefxn_, min_scorefxn_, bonds_scorefxn_, nocst_scorefxn_;
107 }; //class CartesianHybridize
108 
109 } // hybridize
110 //} // comparative_modeling
111 } // protocols
112 
113 #endif