C++ Run torch_script model on cv::Mat

How do I run a python trained, dumped torch_script model on a cv::Mat of the right input size in C++?
My tries (doing this for the first time) fail with weirdest errors…
and I seem not to find a proper solution. Thank you, EL

This topic should have some valid approaches to convert a cv::Mat to a tensor.
You could try to resize the cv::Mat to the right spatial size in OpenCV and add a batch dimension in libtorch (or create a batch of image tensors).

Thank you. I am asking because my build system / linker fails (below). Not sure what the proper way is.