Commit fac59bd2b26769f7e6c67412509c918feb0d29ae

Authored by Scott Klum
1 parent 700eae96

Merging

sdk/plugins/regions.cpp
... ... @@ -149,7 +149,7 @@ class RectFromLandmarksTransform : public UntrainableTransform
149 149 void project(const Template &src, Template &dst) const
150 150 {
151 151 if (src.file.landmarks().isEmpty()) {
152   - qWarning("No landmarks");
  152 + qWarning("No landmarks for %s", qPrintable(src.file.fileName()));
153 153 dst = src;
154 154 return;
155 155 }
... ...
sdk/plugins/stasm.cpp
... ... @@ -20,9 +20,9 @@ class StasmInitializer : public Initializer
20 20 {
21 21 Globals->abbreviations.insert("RectFromStasmEyes","RectFromLandmarks([27, 28, 29, 30, 31, 32, 33, 34, 35, 36],0.125,6.0)+Resize(44,168)"); //
22 22 Globals->abbreviations.insert("RectFromStasmJaw","RectFromLandmarks([0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14],10)");
23   - Globals->abbreviations.insert("RectFromStasmBrow","RectFromLandmarks([15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26],0.05,6.5)+Resize(44,230)");
24   - Globals->abbreviations.insert("RectFromStasmNose","RectFromLandmarks([37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47],0.05,1.25)");
25   - Globals->abbreviations.insert("RectFromStasmMouth","RectFromLandmarks([48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66],0.15,3.0)+Resize(44,110)");
  23 + Globals->abbreviations.insert("RectFromStasmBrow","RectFromLandmarks([15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26],0.25,6.5)+Resize(44,230)");
  24 + Globals->abbreviations.insert("RectFromStasmNose","RectFromLandmarks([38, 39, 40, 41, 42, 43, 44, 67],0.1,1.5)+Resize(44,44)");
  25 + Globals->abbreviations.insert("RectFromStasmMouth","RectFromLandmarks([48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66],0.3,3.0)+Resize(44,110)");
26 26 }
27 27 };
28 28  
... ... @@ -53,13 +53,16 @@ class StasmTransform : public UntrainableTransform
53 53 src.m(), (src.m().channels() == 3), qPrintable(Globals->sdkPath + "/share/openbr/models/stasm/mu-68-1d.conf"), qPrintable(Globals->sdkPath + "/share/openbr/models/stasm/mu-76-2d.conf"), qPrintable(Globals->sdkPath + "/share/openbr/models/stasm/"));
54 54  
55 55 if (nlandmarks == 0) {
56   - qWarning("Unable to detect Stasm landmarks");
  56 + qWarning("Unable to detect Stasm landmarks for %s", qPrintable(src.file.fileName()));
57 57 dst.file.setBool("FTE");
58   - dst.m() = Mat();
  58 + dst.m() = src.m();
  59 + return;
59 60 }
60 61  
61 62 for (int i = 0; i < nlandmarks; i++)
62 63 dst.file.appendLandmark(QPointF(landmarks[2 * i], landmarks[2 * i + 1]));
  64 +
  65 + dst.m() = src.m();
63 66 }
64 67 };
65 68  
... ...