MCPcopy Create free account
hub / github.com/NVIDIA/TensorRT / input_spec

Method input_spec

samples/python/detectron2/infer.py:86–91  ·  view source on GitHub ↗

Get the specs for the input tensor of the network. Useful to prepare memory allocations. :return: Two items, the shape of the input tensor and its (numpy) datatype.

(self)

Source from the content-addressed store, hash-verified

84 assert len(self.allocations) > 0
85
86 def input_spec(self):
87 """
88 Get the specs for the input tensor of the network. Useful to prepare memory allocations.
89 :return: Two items, the shape of the input tensor and its (numpy) datatype.
90 """
91 return self.inputs[0]['shape'], self.inputs[0]['dtype']
92
93 def output_spec(self):
94 """

Callers 2

mainFunction · 0.95
mainFunction · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected