23 #ifndef PROBE_CLASH_SCORE_HH
24 #define PROBE_CLASH_SCORE_HH
32 #include "utils/coot-utils.hh"
33 #include "coot-utils/coot-coord-utils.hh"
48 if (s.length() > 14) {
49 std::string chain_local = s.substr(0,2);
50 std::string res_no_str = s.substr(2, 4);
51 std::string atom_name_local = s.substr(11, 4);
53 int resno_local = util::string_to_int(res_no_str);
54 if (chain_local[0] ==
' ') {
55 if (chain_local.length() > 1)
56 chain_id = std::string(chain_local.substr(1));
58 chain_id = chain_local;
61 atom_name = atom_name_local;
63 catch (
const std::exception &e) {
64 std::cout <<
"WARNING:: " << e.what() << std::endl;
75 std::vector<probe_atom_spec_t> to_atoms;
79 unsigned int size()
const {
return to_atoms.size(); }
81 std::vector<probe_atom_spec_t>::const_iterator it;
82 it = std::find(to_atoms.begin(), to_atoms.end(), spec);
83 if (it == to_atoms.end()) {
84 to_atoms.push_back(spec);
92 std::vector<one_way_probe_contact_t> contacts;
96 for (
unsigned int i=0; i<contacts.size(); i++) {
97 if (contacts[i].from_atom == from_atom) {
98 contacts[i].add(to_atom);
104 new_contact.add(to_atom);
105 contacts.push_back(new_contact);
108 unsigned int size()
const {
110 for (
unsigned int i=0; i<contacts.size(); i++)
111 s += contacts[i].size();
121 int n_hydrogen_bonds;
122 int n_small_overlaps;
123 int n_close_contacts;
129 int n_hydrogen_bonds_in,
130 int n_small_overlaps_in,
131 int n_close_contacts_in,
132 int n_wide_contacts_in) {
134 n_bad_overlaps = n_bad_overlaps_in;
135 n_hydrogen_bonds = n_hydrogen_bonds_in;
136 n_small_overlaps = n_small_overlaps_in;
137 n_close_contacts = n_close_contacts_in;
138 n_wide_contacts = n_wide_contacts_in;
150 std::map<std::pair<probe_atom_spec_t, probe_atom_spec_t>,
bool> ref_specs;
151 spec_eraser(
const std::map<std::pair<probe_atom_spec_t, probe_atom_spec_t>,
bool> &ref_specs_in) {
152 ref_specs = ref_specs_in;
182 #endif // PROBE_CLASH_SCORE_HH
SCM probe_clash_score_scm(const std::string &dots_file_name)
return scheme false on failure or a scheme list
PyObject * probe_clash_score_py(const std::string &dots_file_name)
return scheme false on failure or a scheme list
probe atom type
Definition: probe-clash-score.hh:45
probe clash score
Definition: probe-clash-score.hh:117
This doesn't work.
Definition: probe-clash-score.hh:148