Commit 3f09f0baf4aaaa20d1cfc7f350099b5efd1a2099

Authored by Charles Otto
1 parent 4fd55360

Remove some special casing of label and some dated comments

Remove special casing of label in cache, and getCSVElement
openbr/frvt2012.cpp
... ... @@ -141,7 +141,6 @@ int32_t SdkEstimator::estimate_gender(const ONEFACE &input_face, int8_t &gender,
141 141 TemplateList templates;
142 142 templates.append(templateFromONEFACE(input_face));
143 143 templates >> *frvt2012_gender_transform.data();
144   - // TODO: lookup gender strings/expected int outputs -cao
145 144 mf = gender = templates.first().file.get<QString>("Subject") == "Male" ? 0 : 1;
146 145 return templates.first().file.failed() ? 4 : 0;
147 146 }
... ...
openbr/openbr_plugin.cpp
... ... @@ -434,7 +434,7 @@ TemplateList TemplateList::fromGallery(const br::File &amp;gallery)
434 434 }
435 435  
436 436 // indexes some property, assigns an integer id to each unique value of propName
437   -// stores the index values in "Label" of the output template list -cao
  437 +// stores the index values in "Label" of the output template list
438 438 TemplateList TemplateList::relabel(const TemplateList &tl, const QString & propName)
439 439 {
440 440 const QList<QString> originalLabels = tl.get<QString>(propName);
... ...
openbr/plugins/eigen3.cpp
... ... @@ -329,7 +329,7 @@ class LDATransform : public Transform
329 329  
330 330 void train(const TemplateList &_trainingSet)
331 331 {
332   - // creates "Label" -cao
  332 + // creates "Label"
333 333 TemplateList trainingSet = TemplateList::relabel(_trainingSet, "Subject");
334 334  
335 335 int instances = trainingSet.size();
... ...
openbr/plugins/gallery.cpp
... ... @@ -517,10 +517,7 @@ class csvGallery : public Gallery
517 517  
518 518 static QString getCSVElement(const QString &key, const QVariant &value, bool header)
519 519 {
520   - if ((key == "Label") && !header) {
521   - // problem -cao
522   - return value.value<QString>();
523   - } else if (value.canConvert<QString>()) {
  520 + if (value.canConvert<QString>()) {
524 521 if (header) return key;
525 522 else return value.value<QString>();
526 523 } else if (value.canConvert<QPointF>()) {
... ...
openbr/plugins/meta.cpp
... ... @@ -453,8 +453,6 @@ private:
453 453 const QString &file = src.file;
454 454 if (cache.contains(file)) {
455 455 dst = cache[file];
456   - // don't get this -cao
457   -// dst.file.set("Label", src.file.value("Label"));
458 456 } else {
459 457 transform->project(src, dst);
460 458 cacheLock.lock();
... ...