40 #include <basic/Tracer.hh>
41 #include <utility/exit.hh>
42 #include <utility/stream_util.hh>
43 #include <utility/string_util.hh>
44 #include <basic/MetricValue.hh>
46 #include <utility/vector1.hh>
49 static basic::Tracer
TR(
"protocols.toolbox.PoseMetricCalculators.CatPiCalculator");
53 namespace pose_metric_calculators {
58 distance_cutoff_(5.0),
67 distance_cutoff_(dist_cutoff),
78 if ( key ==
"cat_pi" ) {
79 basic::check_cast( valptr, &
cat_pi_total_,
"cat_pi expects to return a Size" );
80 (
static_cast<basic::MetricValue<core::Size> *
>(valptr))->set(
cat_pi_total_ );
83 basic::Error() <<
"CatPiCalculator cannot compute the requested metric " << key << std::endl;
93 basic::Error() <<
"CatPiCalculator cannot compute metric " << key << std::endl;
109 if(acceptor.name3() ==
"TYR" || acceptor.name3() ==
"PHE" || acceptor.name3() ==
"TRP"){
111 if(res_num1 == res_num2)
continue;
114 if(donate.name3() ==
"ARG" || donate.name3() ==
"LYS" ){
116 bool get_out_of_loop=
false;
119 core::Size acc_atm = acceptor.first_sidechain_atom();
120 acc_atm != acceptor.nheavyatoms();
125 if(acceptor.atom_name(acc_atm) ==
" CB ")
continue;
128 core::chemical::AtomIndices::const_iterator
129 don_num = donate.Hpos_polar_sc().begin(),
130 don_nume = donate.Hpos_polar_sc().end();
131 don_num != don_nume; ++don_num
140 get_out_of_loop=
true;