Classes | Functions | Variables
Util.cpp File Reference
#include <bwi_tools/common/Util.h>
#include <fstream>
#include <cmath>
#include <cassert>
#include <stdlib.h>
#include <limits>
Include dependency graph for Util.cpp:

Go to the source code of this file.

Classes

struct  ReplaceMap

Functions

std::string indent (unsigned int indentation)
void jsonReplaceStrings (Json::Value &value, const std::map< std::string, std::string > &replacementMap)
void jsonReplaceStrings (Json::Value &value, boost::function< void(Json::Value &)> replace)
bool readJson (const std::string &filename, Json::Value &value)
float softmax (float x1, float x2, float factor)
void softmax (const std::vector< unsigned int > &vals, float factor, std::vector< float > &probs)
std::string tempFilename ()
void tic (int id)
double toc (int id)
void toc (double &counter, int id)
void vectorMax (const std::vector< float > &arr, float &maxVal, unsigned int &maxInd)
unsigned int vectorMaxInd (const std::vector< float > &arr)

Variables

std::map< int, double > TIME_MAP

Function Documentation

std::string indent ( unsigned int  indentation)

Definition at line 133 of file Util.cpp.

void jsonReplaceStrings ( Json::Value value,
const std::map< std::string, std::string > &  replacementMap 
)

Definition at line 113 of file Util.cpp.

void jsonReplaceStrings ( Json::Value value,
boost::function< void(Json::Value &)>  replace 
)

Definition at line 117 of file Util.cpp.

bool readJson ( const std::string &  filename,
Json::Value value 
)

Definition at line 66 of file Util.cpp.

float softmax ( float  x1,
float  x2,
float  factor 
)

Definition at line 44 of file Util.cpp.

void softmax ( const std::vector< unsigned int > &  vals,
float  factor,
std::vector< float > &  probs 
)

Definition at line 51 of file Util.cpp.

std::string tempFilename ( )

Definition at line 137 of file Util.cpp.

void tic ( int  id)

Definition at line 13 of file Util.cpp.

double toc ( int  id)

Definition at line 17 of file Util.cpp.

void toc ( double &  counter,
int  id 
)

Definition at line 21 of file Util.cpp.

void vectorMax ( const std::vector< float > &  arr,
float &  maxVal,
unsigned int &  maxInd 
)

Definition at line 33 of file Util.cpp.

unsigned int vectorMaxInd ( const std::vector< float > &  arr)

Definition at line 25 of file Util.cpp.


Variable Documentation

std::map<int,double> TIME_MAP

Definition at line 11 of file Util.cpp.



bwi_tools
Author(s): Piyush Khandelwal
autogenerated on Fri Aug 28 2015 10:14:30