⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 math_01.cc

📁 这是一个从音频信号里提取特征参量的程序
💻 CC
字号:
// file: $isip/class/algo/Math/math_01.cc// version: $Id: math_01.cc,v 1.4 2002/07/03 21:08:36 picone Exp $//// isip include files//#include "Math.h"#include <String.h>#include <Console.h>// method: debug//// arguments://  const unichar* msg: (input) message to print//// return: a boolean value indicating status//boolean Math::debug(const unichar* msg_a) const {  // declare local variables  //  String value;  String numeric;  String output;  String empty_str;  // output the information message  //  output.debugStr(name(), msg_a, L":");  Console::put(output);  Console::increaseIndention();  // display the algorithm  //  output.debugStr(name(), msg_a, L"algorithm_d",                  ALGO_MAP.getName((long)algorithm_d));  Console::put(output);  // branch on algorithm and output algorithm specific data  //  if (algorithm_d == FUNCTION_CALCULATOR) {        // display number of operands    //    value.assign(num_operands_d);    output.debugStr(name(), msg_a, L"num_operands_d", value);    Console::put(output);        // increase the indention    //    Console::increaseIndention();        // loop over number of operands    //    for (long i = 0; i < num_operands_d; i++) {            // do some formatting for output information      //      value.assign(L"<");      value.concat(L"Operand number");      value.concat(L" ");      numeric.assign(i);      value.concat(numeric);      value.concat(L">");      value.concat(L":");      Console::put(value);      // increase the indention      //      Console::increaseIndention();            // display the function      //      output.debugStr(name(), msg_a, L"function_d",		      FUNC_MAP.getName((long)function_d(i)));      Console::put(output);            // display the operation      //      output.debugStr(name(), msg_a, L"operation_d",		      OPER_MAP.getName((long)operation_d(i)));      Console::put(output);            // display constant      //      value.assign(weight_d(i));      output.debugStr(name(), msg_a, L"weight_d", value);      Console::put(output);            // decrease the indention      //      Console::decreaseIndention();    }        // decrease the indention    //    Console::decreaseIndention();    // display constant    //    value.assign(const_d);    output.debugStr(name(), msg_a, L"const_d", value);    Console::put(output);  }  // else: error invalid algorithm  //  else {    return Error::handle(name(), L"debug", ERR_UNKALG,			 __FILE__, __LINE__);  }    // debug level  //  output.debugStr(name(), msg_a, L"debug_level_d",                  debug_level_d.getName());  Console::put(output);  // decrease indention  //  Console::decreaseIndention();  // exit gracefully  //  return true;}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -