]> ruin.nu Git - germs.git/blobdiff - src/modelidentifier.h
DOC: more doxygen documentation
[germs.git] / src / modelidentifier.h
index bbf30377ad7eef88c243cb92dd6454d5b834dcac..a725136bf565f2813b1c5e601ebcb6f523713b43 100644 (file)
 
 #include "geneorder.h"
 
-#include <map>
+#include <queue>
+#include <string>
+#include <stdexcept>
+
+struct fann;
+class Model;
 
 
 /**
  */
 class ModelIdentifier{
        public:
-               enum Model{Whirl,X,FatX,Zipper,Cloud};
+
+               /**
+                * Creates a new identifier given an artificial neural network
+                *
+                * \param ann filename, including path, to the neural network
+                *
+                * \throws std::invalid_argument exception if the ann could not be
+                * opened
+                */
+               ModelIdentifier(std::string ann);
 
                /**
                 * Identifies the model for a given gene order.
-                * \returns a map with the model as key and the score between 0 and 1
+                *
+                * \returns a priority_queue with the model as key and the score between -1 and 1
                 */
-               std::map<Model,double> identify(const GeneOrder& go);
+               std::priority_queue<std::pair<double,Model> > identify(const GeneOrder& go);
+
+               ~ModelIdentifier();
+       private:
+               fann* _ann;
+
+               //disable for the moment
+               void operator=(const ModelIdentifier&){}
 
-               virtual ~ModelIdentifier(){};
 };
 
 #endif