Rosetta 3.5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
CamShiftEvaluator.cc
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 PoseEvaluator
11 /// @brief PoseEvaluator
12 /// @detailed
13 ///
14 ///
15 /// @author Nikolas Sgourakis ?
16 ///
17 
18 
19 // Unit Headers
21 
22 // Package Headers
23 
24 // Project Headers
26 #include <core/pose/Pose.hh>
27 
28 // AUTO-REMOVED #include <basic/options/option.hh>
29 // AUTO-REMOVED #include <basic/options/keys/evaluation.OptionKeys.gen.hh>
30 
31 
32 // ObjexxFCL Headers
33 // AUTO-REMOVED #include <ObjexxFCL/string.functions.hh>
34 
35 // Utility headers
36 #include <basic/Tracer.hh>
37 #include <utility/exit.hh>
38 // AUTO-REMOVED #include <utility/file/file_sys_util.hh>
39 
40 #include <utility/vector1.hh>
41 
42 // C++ headers
43 
44 static basic::Tracer tr("protocols.simple_filter.CamShiftEvaluator");
45 
46 namespace protocols {
47 namespace simple_filters {
48 
49 using namespace core;
50 
51 #ifdef __native_client__
52 #define system(a) 1
53 #endif
54 
55 
57  : ExternalEvaluator( tag )
58 {
59  #ifdef WIN32
60  utility_exit_with_message("don't use CamShiftEvaluator on a BillBox");
61  #endif
62  // if (!utility::file::file_exists( scratch_dir()+"/SPARTA" ) ) {
63  // std::string command( "cp -Rf $HOME/SPARTA "+scratch_dir());
64  std::string command( "rsync -azvu $HOME/camshift-1.35.0 "+scratch_dir());
65  int ret(system(command.c_str()));
66  if( ret ){
67  utility_exit_with_message("System command failed:'" + command + "'" );
68  }
69 
70 
71  std::string command2( "rsync -azvu $HOME/scripts/calculate_cs_rms.pl "+scratch_dir());
72  int ret2(system(command2.c_str()));
73  if( ret2 ){
74  utility_exit_with_message("System command failed:'" + command2 + "'" );
75  }
76 
77  //}
78  set_command( "export CAMSHIFT_DIR="+scratch_dir()+
79  "/camshift-1.35.0; $CAMSHIFT_DIR/bin/camshift --data ~/camshift-1.35.0/data/ --pdb __POSE.pdb >tmpc_RESULT "
80  "; perl " +scratch_dir()+"/calculate_cs_rms.pl "+cs_file+" tmpc_RESULT > __RESULT" );
81 }
82 
83 bool CamShiftEvaluator::applicable( pose::Pose const& pose ) const {
84  return pose.is_fullatom();
85 }
86 
87 
88 }
89 }