| 108 | } |
| 109 | |
| 110 | void PulseCollection::registerMulti(const std::vector<Pulse>& buf) |
| 111 | { |
| 112 | assert(buf.size()); |
| 113 | |
| 114 | auto it = std::max_element(buf.begin(), buf.end(), |
| 115 | [](const Pulse& p1, const Pulse& p2){ return p1.d < p2.d; }); |
| 116 | const Pulse& p = *it; |
| 117 | |
| 118 | // Only include pulses if separation > minsep |
| 119 | if (p.d * 2 > m_args.minsep) |
| 120 | pulses.push_back(p); |
| 121 | } |
| 122 | |
| 123 | void PulseCollection::registerSingle(const std::vector<Pulse>& buf) |
| 124 | { |