ambiguous overloaded function.
backprop_result(MyAnn::backPropgration<double,
std::vector>(MultiLayerNeuron, 1.9, 8, 10, 12)); // debugtest.cpp line
70.
template <typename T,
template <typename ELEM, typename = std::allocator<ELEM> >
class CONT
>
CONT<CONT<T> > backPropgration(
const typename multiLayerExample<T, CONT>::mapInOut& examples,
const T& rate,
const typename CONT<T>::size_type& nIn,
const typename CONT<T>::size_type& nOut,
const typename CONT<T>::size_type& nHidden
); // inside backproagation.hpp
template <typename T,
template <typename ELEM, typename = std::allocator<ELEM> >
class CONT
CONT<CONT<T> > backPropgration(
const typename multiLayerExample<T, CONT>::mapInOut& examples,
const T& rate,
const typename CONT<T>::size_type& nIn,
const typename CONT<T>::size_type& nOut,
const typename CONT<T>::size_type& nHidden
)
{
// definition of code.
}
// this is inside backproapation.cpp
Here is my error:
../cs461/c++/debugtest.cpp(70) : error C2668:
'MyAnn::backPropgration' : ambiguous call to overloaded function
c:\cpw\msvc\cs461\c++\cppdef/backproagation.cpp(141):
could be 'std::vector<_Ty>
MyAnn::backPropgration<double,std::vector>(const std::map<_Kty,_Ty>
&,const T &,const unsigned int &,const unsigned int &,const unsigned
int &)'
with
[
_Ty=std::vector<double>,
_Kty=std::vector<std::vector<double>>,
T=double
]
c:\cpw\msvc\cs461\c++\cppdef\../backpropagation.hpp(22): or
'std::vector<_Ty>
MyAnn::backPropgration<double,std::vector>(const std::map<_Kty,_Ty>
&,const T &,const unsigned int &,const unsigned int &,const unsigned
int &)'
with
[
_Ty=std::vector<double>,
_Kty=std::vector<std::vector<double>>,
T=double
]
while trying to match the argument list '(std::map<_Kty,_Ty>,
double, int, int, int)'
with
[
_Kty=std::vector<std::vector<double>>,
_Ty=std::vector<double>
]