iCub-main
clustering.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2006-2018 Istituto Italiano di Tecnologia (IIT)
3  * Copyright (C) 2006-2010 RobotCub Consortium
4  * All rights reserved.
5  *
6  * This software may be modified and distributed under the terms
7  * of the BSD-3-Clause license. See the accompanying LICENSE file for
8  * details.
9 */
10 
22 #ifndef __CLUSTERING_H__
23 #define __CLUSTERING_H__
24 
25 #include <map>
26 #include <set>
27 
28 #include <yarp/os/Property.h>
29 #include <yarp/sig/Vector.h>
30 
31 namespace iCub
32 {
33 
34 namespace ctrl
35 {
36 
43 {
44 public:
52  virtual std::map<size_t,std::set<size_t>> cluster(const std::vector<yarp::sig::Vector> &data,
53  const yarp::os::Property &options) = 0;
54 
58  virtual ~Clustering() { }
59 };
60 
61 
70 class DBSCAN : public Clustering
71 {
72 public:
83  std::map<size_t,std::set<size_t>> cluster(const std::vector<yarp::sig::Vector> &data,
84  const yarp::os::Property &options) override;
85 
89  virtual ~DBSCAN() { }
90 };
91 
92 }
93 
94 }
95 
96 #endif
97 
98 
99 
@ data
Abstract class for clustering.
Definition: clustering.h:43
virtual ~Clustering()
Virtual destructor.
Definition: clustering.h:58
virtual std::map< size_t, std::set< size_t > > cluster(const std::vector< yarp::sig::Vector > &data, const yarp::os::Property &options)=0
Cluster the provided data.
Data clustering based on DBSCAN algorithm.
Definition: clustering.h:71
std::map< size_t, std::set< size_t > > cluster(const std::vector< yarp::sig::Vector > &data, const yarp::os::Property &options) override
Cluster the provided data.
Definition: clustering.cpp:152
virtual ~DBSCAN()
Virtual destructor.
Definition: clustering.h:89
This file contains the definition of unique IDs for the body parts and the skin parts of the robot.