Classes | Functions

OpenTissue::kinematics::inverse::detail Namespace Reference

Classes

class  FunctionCalculator
class  GradientCalculator
class  ProjectionCalculator

Functions

template<typename output_iterator >
void write_benchmarks (std::string const &prefix, std::string const &matlab_filename, std::string const &latex_filename, output_iterator begin, output_iterator end)

Function Documentation

template<typename output_iterator >
void OpenTissue::kinematics::inverse::detail::write_benchmarks ( std::string const &  prefix,
std::string const &  matlab_filename,
std::string const &  latex_filename,
output_iterator  begin,
output_iterator  end 
) [inline]

Write Benchmarks. This function was created to make processing of benchmark data more easy. Below is a simple code sample illustrating how the function should be used.

  std::list<solver_type::Output> outputs;

  for(...)
  {
     ...
     solver_type::Output output;
     solver.solve(..., &output );
     outputs.push_back( output );
     ...
  }
  std::string prefix = ....;
  std::string matlab_file = ....;
  std::string latex_file = ....;

  write_benchmarks( prefix, matlab_file, latex_file, outputs.begin(), outputs.end() );
Parameters:
prefix A string value that is used to prefix all matlab figures. This is useful to make sure that the generated figures in the end all have unique names.
matlab_filename The path and name of the resulting matlab script. Running this script from matlab will produce a set of figures. Also all figures are automatically exported as both eps and png files.
latex_filename The path and name of the resulting latex file. Upon return this file will contain latex code for some of the statistics.
begin An iterator to the position of the first Output class.
end An iterator to the position one past the last Output class.