I would like to use a dictionary as input to the ScriptModule in C++
auto x = torch::OrderedDict<std::string, torch::Tensor>();
x.insert("feat1", torch::rand({1, 10, 64, 64}));
x.insert("feat2", torch::rand({1, 20, 16, 16}));
x.insert("feat3", torch::rand({1, 30, 8, 8}));
auto ouput = module({x});
however I got following error
error: no match for call to ‘(torch::jit::script::Module {aka torch::jit::Module}) ()’
35 | auto ouput = module({x});
do we have way to use dictionary as input in c++