Commit 5716a8bf authored by mzed's avatar mzed
Browse files

silencing warnings. using "final"

parent 83517dc6
......@@ -15,7 +15,7 @@
void filtfilt(vector<double> const& b, vector<double> const& a, vector<double> & x, vector<double> & y, PADTYPE padtype, int padlen)
{
int ntaps = max(a.size(), b.size());
int ntaps = int(max(a.size(), b.size()));
if (padtype == NONE)
padlen=0;
......@@ -81,7 +81,7 @@ void lfilter(vector<double> const& b, vector<double> const& a, vector<double> co
vector<double> _a = a;
// Pad a or b with zeros so they are the same length.
unsigned int k = max(a.size(), b.size());
unsigned int k = int (max(a.size(), b.size()));
if (_a.size() < k)
_a.resize(k, 0.);
......@@ -97,7 +97,7 @@ void lfilter(vector<double> const& b, vector<double> const& a, vector<double> co
}
vector<double> z = zi;
unsigned int n = x.size();
unsigned int n = int(x.size());
y.resize(n);
for (unsigned int m=0; m<n; m++) {
y[m] = _b[0] * x[m] + z[0];
......@@ -121,7 +121,7 @@ void lfilter_zi(vector<double> const& b, vector<double> const& a, vector<double>
}
}
unsigned int n = max(_a.size(), _b.size());
unsigned int n = int (max(_a.size(), _b.size()));
// Pad a or b with zeros so they are the same length.
if (_a.size() < n)
......
......@@ -54,7 +54,7 @@ void even_ext(vector<datatype> const& src, vector<datatype> & dst, unsigned int
copy(src.begin(), src.end(), dst.begin()+n);
t += src.size();
for (unsigned int i=src.size()-2; i>src.size()-n-2; i--) {
for (unsigned int i = int (src.size()-2); i>src.size()-n-2; i--) {
dst[t++] = src[i];
}
}
......@@ -77,7 +77,7 @@ void odd_ext(vector<datatype> const& src, vector<datatype> & dst, unsigned int n
copy(src.begin(), src.end(), dst.begin()+n);
t += src.size();
for (unsigned int i=src.size()-2; i>src.size()-n-2; i--) {
for (unsigned int i = int (src.size() - 2); i>src.size()-n-2; i--) {
dst[t++] = 2 * src[src.size()-1] - src[i];
}
}
......@@ -100,7 +100,7 @@ void const_ext(vector<datatype> const& src, vector<datatype> & dst, unsigned int
copy(src.begin(), src.end(), dst.begin()+n);
t += src.size();
for (unsigned int i=src.size()-2; i>src.size()-n-2; i--) {
for (unsigned int i = int (src.size() - 2); i>src.size()-n-2; i--) {
dst[t++] = src[src.size()-1];
}
}
......
......@@ -18,7 +18,7 @@
*/
template<typename T>
class classificationTemplate : public modelSet<T> {
class classificationTemplate final : public modelSet<T> {
public:
enum classificationTypes { knn, svm };
......
......@@ -18,7 +18,7 @@
/** Class for implementing a knn classifier */
template<typename T>
class knnClassification : public baseModel<T> {
class knnClassification final : public baseModel<T> {
public:
/** Constructor that takes training examples in
......
......@@ -24,7 +24,7 @@
* This class includes both running and training, and constructors for reading trained models from JSON.
*/
template<typename T>
class neuralNetwork : public baseModel<T> {
class neuralNetwork final : public baseModel<T> {
public:
/** This is the constructor for building a trained model from JSON. */
......
......@@ -19,7 +19,7 @@
*/
template<typename T>
class regressionTemplate : public modelSet<T> {
class regressionTemplate final : public modelSet<T> {
public:
/** with no arguments, just make an empty vector */
regressionTemplate();
......
......@@ -22,7 +22,7 @@
*/
template<typename T>
class seriesClassificationTemplate {
class seriesClassificationTemplate final {
public:
/** Constructor, no params */
......
......@@ -15,7 +15,7 @@
#include "../dependencies/libsvm/libsvm.h"
template<typename T>
class svmClassification : public baseModel<T> {
class svmClassification final : public baseModel<T> {
public:
enum SVMType{ C_SVC = 0, NU_SVC, ONE_CLASS, EPSILON_SVR, NU_SVR };
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment