'Could not find mnist.onnx in data directories:

I tried to compile sampleOnnxMNIST as from this code https://github.com/NVIDIA/TensorRT/blob/main/samples/sampleOnnxMNIST/sampleOnnxMNIST.cpp but got this error

Could not find mnist.onnx in data directories: data/mnist/ data/samples/mnist/ &&&& FAILED

I know the problem is from the directory but I don't know how to fix it.



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source