Skip to content
Snippets Groups Projects
Commit ea2be59a authored by kotsifa2's avatar kotsifa2
Browse files

Changed printing of configurations

parent 90302e73
No related branches found
No related tags found
No related merge requests found
......@@ -218,85 +218,85 @@ enum SEARCH_KIND
void PROMISENodeConfiguration::print() {
INFO(" promise");
printf(" promise");
for (auto &it : ApproxChoices) {
DEBUG(" ");
printf(" ");
switch (it.first) {
case APPROX::SWING_LEVEL :
DEBUG("swing_level");
printf("swing_level");
break;
default:
ERROR("Unknown approximation option");
break;
// TODO additional approx methods to be printed here
}
DEBUG(" %d", it.second);
printf(" %d", it.second);
}
DEBUG("\n");
printf("\n");
}
void GPUNodeConfiguration::print() {
DEBUG(" gpu");
printf(" gpu");
for (auto &it : ApproxChoices) {
DEBUG(" ");
printf(" ");
switch (it.first) {
case TENSOR_OP::ADD :
DEBUG("add");
printf("add");
break;
case TENSOR_OP::BATCHNORM :
DEBUG ("batchnorm");
printf("batchnorm");
break;
case TENSOR_OP::CONV :
DEBUG("conv");
printf("conv");
break;
case TENSOR_OP::GROUP_CONV :
DEBUG("group_conv");
printf("group_conv");
break;
case TENSOR_OP::MUL :
DEBUG("mul");
printf("mul");
break;
case TENSOR_OP::RELU :
DEBUG("relu");
printf("relu");
break;
case TENSOR_OP::CLIPPED_RELU :
DEBUG("clipped_relu");
printf("clipped_relu");
break;
case TENSOR_OP::TANH :
DEBUG ("tanh");
printf("tanh");
break;
case TENSOR_OP::POOL_MAX :
DEBUG("pool_max");
printf("pool_max");
break;
case TENSOR_OP::POOL_MEAN :
DEBUG("pool_mean");
printf("pool_mean");
break;
case TENSOR_OP::POOL_MIN :
DEBUG("pool_min");
printf("pool_min");
break;
case TENSOR_OP::SOFTMAX :
DEBUG("softmax");
printf("softmax");
break;
case TENSOR_OP::FFT :
DEBUG("fft");
printf("fft");
break;
case TENSOR_OP::REDUCE :
DEBUG("reduce");
printf("reduce");
break;
case TENSOR_OP::PROJECTIVE_T :
DEBUG("projectiveT");
printf("projectiveT");
break;
case TENSOR_OP::MAP1 :
DEBUG("map1");
printf("map1");
break;
case TENSOR_OP::MAP2 :
DEBUG("map2");
printf("map2");
break;
case TENSOR_OP::MAP3 :
DEBUG("map3");
printf("map3");
break;
default :
ERROR("Unknown tensor operation.");
......@@ -306,22 +306,22 @@ void GPUNodeConfiguration::print() {
auto &approxVec = it.second;
for (auto &inner_it : approxVec) {
DEBUG(" ");
printf(" ");
switch (inner_it.first) {
case APPROX::FP32 :
DEBUG("fp32");
printf("fp32");
break;
case APPROX::FP16 :
DEBUG("fp16");
printf("fp16");
break;
case APPROX::PERFORATION :
DEBUG("perf");
printf("perf");
break;
case APPROX::INPUT_SAMPLING :
DEBUG("samp");
printf("samp");
break;
case APPROX::REDUCTION_SAMPLING :
DEBUG("red_samp");
printf("red_samp");
break;
default:
ERROR("Unknown approximation option");
......@@ -329,27 +329,27 @@ void GPUNodeConfiguration::print() {
// TODO additional approx methods to be printed here
}
DEBUG(" %d", inner_it.second);
printf(" %d", inner_it.second);
}
}
DEBUG("\n");
printf("\n");
}
void Configuration::print() {
DEBUG("+++++\n");
DEBUG("%s %f %f %f %f\n", name.c_str(), speedup, energy, accuracy, accuracyLoss);
printf("+++++\n");
printf("%s %f %f %f %f\n", name.c_str(), speedup, energy, accuracy, accuracyLoss);
for (std::map<std::string, NodeConfiguration* >::const_iterator it = setup.begin();
it != setup.end(); ++it) {
DEBUG("%s :", it->first.c_str());
printf("%s :", it->first.c_str());
it->second->print();
}
DEBUG("-----\n");
printf("-----\n");
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment