I tried to compile a basic program with libtorch, but a C2066 error occurred.
Program’s code is below
#include <torch/torch.h>
int main()
{
auto a = torch::ones({ 2, 2 });
}
The error C2066 occurred in line 110 of rnn.h.
using RNNFunctionSignature = std::tuple<Tensor, Tensor>(
/*input=*/const Tensor&,
/*state=*/const Tensor&,
/*params=*/TensorList,
/*has_biases=*/bool,
/*layers=*/int64_t,
/*dropout=*/double,
/*train=*/bool,
/*bidirectional=*/bool,
/*batch_first=*/bool);
My compile enviroment is as follows:
Windows 10
Visual Studio 2017 (v141) with/std:c++latest