TensorRT OnnxParser.parse returns false

Here is my code:

TRT_LOGGER = trt.Logger(trt.Logger.VERBOSE)

def build_engine(model_path):
with trt.Builder(TRT_LOGGER) as builder, builder.create_network() as network,
trt.OnnxParser(network, TRT_LOGGER) as parser:
builder.max_workspace_size = 1<<30
builder.max_batch_size = 1

    with open(model_path, 'rb') as f:
        value = parser.parse(f.read())
        print("Parser: ", value)

The output is False for the same.
I am using an AlexNet converted to an ONNX model.
I am currently on TensorRT-

Also, I would like some clarity on what the flags variable in Builder.create_network() does


In TRT 7, ONNX parser supports full-dimensions mode only. Your network definition must be created with the explicitBatch flag set (when using ONNX parser).

Please refer below link for more details regarding flags variable in Builder.create_netwrok():