|
@@ -196,7 +196,7 @@ void PPSuperregion::optimizeShape(Examples ®ions, NICE::Matrix &mask, Generic
|
|
|
throw("PPSuperRegion.cpp: please use ice library for this function");
|
|
|
#endif
|
|
|
}
|
|
|
-
|
|
|
+#ifdef NICE_USELIB_ICE
|
|
|
void PPSuperregion::getSuperregions(const Examples ®ions, const NICE::Matrix &mask, vector<ice::Region> &superregions, vector<int> &classes, NICE::Matrix &smask)
|
|
|
{
|
|
|
NICE::Image tmp (mask.rows(), mask.cols());
|
|
@@ -233,9 +233,11 @@ void PPSuperregion::getSuperregions(const Examples ®ions, const NICE::Matrix
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
+#endif
|
|
|
|
|
|
void PPSuperregion::trainShape(Examples ®ions, NICE::Matrix &mask)
|
|
|
{
|
|
|
+#ifdef NICE_USELIB_ICE
|
|
|
// bestimme Superregionen
|
|
|
vector<ice::Region> superregions;
|
|
|
vector<int> classes;
|
|
@@ -253,6 +255,9 @@ void PPSuperregion::trainShape(Examples ®ions, NICE::Matrix &mask)
|
|
|
NICE::Vector *tmp2 = new NICE::Vector(tmp);
|
|
|
shapefeats.push_back(pair<int, Example>(classes[i], Example(tmp2)));
|
|
|
}
|
|
|
+#else
|
|
|
+ throw("PPSuperRegion.cpp: please use ice library for this function");
|
|
|
+#endif
|
|
|
}
|
|
|
|
|
|
void PPSuperregion::finishShape(ClassNames &cn)
|