/
githubmirror
/
cmssw
Обзор
Документация
Войти
/
githubmirror
/
cmssw
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
CommonTools/Clustering1D/interface/Clusterizer1DCommons.h
26 строк
748 B
Cms Build
Clang-Format
03 июн 2019, 06:44
03 июн 2019, 06:44
6a63925
Код
Авторство
О чём код?
#ifndef _Clusterizer1DCommons_H_ #define _Clusterizer1DCommons_H_ #include "CommonTools/Clustering1D/interface/Cluster1D.h" namespace Clusterizer1DCommons { // typedef Clusterizer1DCommons::Cluster1D Cluster1D; inline double square(const double a) { return a * a; } template <class T> struct ComparePairs { bool operator()(const Cluster1D<T>& c1, const Cluster1D<T>& c2) { return (c1.position().value() < c2.position().value()); }; }; template <class T> void add(const std::vector<const T*>& source, std::vector<const T*>& dest) { for (typename std::vector<const T*>::const_iterator i = source.begin(); i != source.end(); ++i) { dest.push_back(*i); }; } } // namespace Clusterizer1DCommons #endif