‘Dims3’ in namespace ‘nvinfer1’ does not name a type!!

Hello,
I got the following error while trying to compile the latest jetson tx2 codes:

/home/shervin/Desktop/jetson-inference/tensorNet.h:159:12: error: ‘Dims3’ in namespace ‘nvinfer1’ does not name a type
nvinfer1::Dims3 mInputDims;

It seems like this is being compiled on host and not Jetson TX2. Please follow the directions from the repo to compile on TX2. Otherwise there may be minor changes to get it working on the host (not officially supported by the GitHub repo at this time).