T(ea)rdrop

Trdrop - System Presentation

Alexander Isenko

A video analysis software

1

Trdrop - System Presentation

Problem - Tears

Alexander Isenko

2

Trdrop - System Presentation

Problem - FPS Drops

Alexander Isenko

3

Trdrop - System Presentation

Solution

Alexander Isenko

  • Calculate features with a single pass over multiple videos
  • Create a closured interface to process and modify frames with tasks
  • Automatic parallelization

4

Trdrop - System Presentation

Main Concept - Program Design

Alexander Isenko

5

Trdrop - System Presentation

Task Scheduler Concept

Alexander Isenko

6

Trdrop - System Presentation

Main Loop

Alexander Isenko

7

 int main(int argc, char** argv){

     Config config(-1, argc, argv);
     TaskScheduler scheduler(config.inputs);
     FPSPreTask fpsPreT("FPS",
                        config.inputs.size(),
                        config.pixelDifference);
     
     scheduler.addPreTask(std::make_shared<FPSPreTask>(fpsPreT));

     std::vector<double> framerates;
     while (scheduler.next()) {
          if (fpsPreT.result.successful()) {
	      framerates = fpsPreT.result.getSuccess();
	  }
     }
 }

Trdrop - System Presentation

Special Task - LoggerT

Alexander Isenko

8


  std::vector<tostring> convertions;
  LoggerTask<CSVFormatter> loggerT(
      convertions,
      { "Frameindex", "   " + fpsPreT.id },
      config.inputNames,
      config.logName
  );
  convertions.push_back([&](int ix){
      return trdrop::util::string_format(
          "%10i", scheduler.getCurrentFrameIndex());
  });
  convertions.push_back([&](int ix){
      return trdrop::util::string_format(
          "%6." + std::to_string(config.fpsPrecision) + "f", framerates[ix]);
  });
// class LoggerTask
public:
    void process(cv::Mat & res, const size_t currentFrame, const size_t vix) {
	std::vector<std::string> values;
        std::transform(conversions.begin(),
                       conversions.end(),
                       std::back_inserter(values),
                       [&](tostring f) { return f(vix); });

        (*streams[vix]) << formatter.format(values.begin(), values.end());
        });
}

Trdrop - System Presentation

Live Presentation & Questions?

Alexander Isenko

9

Trdrop

By cirquit

Trdrop

  • 102